예제 #1
0
def debug_set_root_folder():
    global profile_list
    global dp_root_folder_path
    dir_result = "/Users/allen/Desktop/sample_profiles"
    # dir_result = "/Users/allen/Desktop/empty"
    dp_root_folder_path= dir_result
    dp_root_folder_display.set("Selected: " + dir_result)
    root_folder_path_label.config(foreground='navy')

    profile_list = duck_objs.build_profile(dir_result)
    update_profile_display()
    enable_buttons()
예제 #2
0
def select_root_folder():
    global profile_list
    global dp_root_folder_path
    dir_result = filedialog.askdirectory()
    if len(dir_result) <= 0:
        return
    dp_root_folder_path = dir_result
    dp_root_folder_display.set("Selected: " + dir_result)
    root_folder_path_label.config(foreground='navy')
    profile_list = duck_objs.build_profile(dir_result)
    ui_reset()
    update_profile_display()
    enable_buttons()
예제 #3
0
def select_root_folder():
    global profile_list
    global sd_card_keymap_list
    global dp_root_folder_path
    dir_result = filedialog.askdirectory()
    if len(dir_result) <= 0:
        return
    dp_root_folder_path = dir_result
    dp_root_folder_display.set("Selected: " + dir_result)
    root_folder_path_label.config(foreground='navy')
    profile_list = duck_objs.build_profile(dir_result)
    dp_settings.load_from_path(dp_root_folder_path)
    try:
        sd_card_keymap_list = duck_objs.load_keymap(dp_root_folder_path)
    except Exception as e:
        print(e)
    print_fw_update_label()
    ui_reset()
    update_profile_display()
    enable_buttons()