25개 이상의 토픽을 선택하실 수 없습니다.
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
- import arcade
- from cld import *
- from desktop_Platform import *
-
- # Pass config init key-value pairs to context controller
- #
- # Conditions:
- # 1. Config tree has just been parsed
- def desktop_applyConfigInit(p):
- if (
- p.c.recentField == "cfgTree"
- ):
- for key in p.c.cfgTree["init"]:
- value = p.c.cfgTree["init"][key]
- # Boolean.
- if (
- value == "false"
- ):
- value = False
- elif (
- value == "true"
- ):
- value = True
- # Float.
- elif (
- cld_isdigit(value)
- ):
- value = float(value)
-
- p.ctrl.set(key, value)
|