def dnd_genlist_user_anim_clicked(obj, item=None): win = StandardWindow("dnd-genlist-user-anim", "DnD-Genlist-User-Anim", autodel=True, size=(680,800)) bxx = Box(win, horizontal=True, size_hint_weight=EXPAND_BOTH) win.resize_object_add(bxx) bxx.show() for j in range(2): gl = Genlist(win, multi_select=True, size_hint_weight=EXPAND_BOTH, size_hint_align=FILL_BOTH) # START Drag and Drop handling win.callback_delete_request_add(win_del, gl) gl.drop_item_container_add(ELM_SEL_FORMAT_TARGETS, gl_item_getcb, dropcb=gl_dropcb) gl.drag_item_container_add(ANIM_TIME, DRAG_TIMEOUT, gl_item_getcb, gl_data_getcb) # We add mouse-down, up callbacks to start/stop drag animation gl.event_callback_add(EVAS_CALLBACK_MOUSE_DOWN, gl_obj_mouse_down, gl) # END Drag and Drop handling # FIXME: This causes genlist to resize the horiz axis very slowly :( # Reenable this and resize the window horizontally, then try to resize it back #elm_genlist_mode_set(gl, ELM_LIST_LIMIT) bxx.pack_end(gl) gl.show() for i in range(20): gl.item_append(itc1, img[i % 9], flags=ELM_GENLIST_ITEM_NONE) win.show()
def dnd_genlist_gengrid_clicked(obj, item=None): win = StandardWindow("dnd-genlist-gengrid", "DnD-Genlist-Gengrid", autodel=True, size=(680, 800)) bxx = Box(win, horizontal=True, size_hint_weight=EXPAND_BOTH) win.resize_object_add(bxx) bxx.show() gl = Genlist(win, multi_select=True, size_hint_weight=EXPAND_BOTH, size_hint_align=FILL_BOTH) win.callback_delete_request_add(win_del, gl) # START Drag and Drop handling gl.drop_item_container_add(ELM_SEL_FORMAT_TARGETS, gl_item_getcb, dropcb=gl_dropcb) gl.drag_item_container_add(ANIM_TIME, DRAG_TIMEOUT, gl_item_getcb, gl_dnd_default_anim_data_getcb) # END Drag and Drop handling # FIXME: This causes genlist to resize the horiz axis very slowly :( # Reenable this and resize the window horizontally, then try to resize it back #elm_genlist_mode_set(gl, ELM_LIST_LIMIT) bxx.pack_end(gl) gl.show() for i in range(20): gl.item_append(itc1, img[i % 9], flags=ELM_GENLIST_ITEM_NONE) grid = Gengrid(win, item_size=(conf.scale * 150, conf.scale * 150), horizontal=False, reorder_mode=False, multi_select=True, size_hint_weight=EXPAND_BOTH, size_hint_align=FILL_BOTH) win.callback_delete_request_add(win_del, grid) grid.drop_item_container_add(ELM_SEL_FORMAT_TARGETS, grid_item_getcb, dropcb=grid_dropcb) grid.drag_item_container_add(ANIM_TIME, DRAG_TIMEOUT, grid_item_getcb, grid_data_getcb) for i in range(20): grid.item_append(gic, img[i % 9]) bxx.pack_end(grid) grid.show() win.show()
def dnd_genlist_gengrid_clicked(obj, item=None): win = StandardWindow("dnd-genlist-gengrid", "DnD-Genlist-Gengrid", autodel=True, size=(680,800)) bxx = Box(win, horizontal=True, size_hint_weight=EXPAND_BOTH) win.resize_object_add(bxx) bxx.show() gl = Genlist(win, multi_select=True, size_hint_weight=EXPAND_BOTH, size_hint_align=FILL_BOTH) win.callback_delete_request_add(win_del, gl) # START Drag and Drop handling gl.drop_item_container_add(ELM_SEL_FORMAT_TARGETS, gl_item_getcb, dropcb=gl_dropcb) gl.drag_item_container_add(ANIM_TIME, DRAG_TIMEOUT, gl_item_getcb, gl_dnd_default_anim_data_getcb) # END Drag and Drop handling # FIXME: This causes genlist to resize the horiz axis very slowly :( # Reenable this and resize the window horizontally, then try to resize it back #elm_genlist_mode_set(gl, ELM_LIST_LIMIT) bxx.pack_end(gl) gl.show() for i in range(20): gl.item_append(itc1, img[i % 9], flags=ELM_GENLIST_ITEM_NONE) grid = Gengrid(win, item_size=(conf.scale * 150, conf.scale * 150), horizontal=False, reorder_mode=False, multi_select=True, size_hint_weight=EXPAND_BOTH, size_hint_align=FILL_BOTH) win.callback_delete_request_add(win_del, grid) grid.drop_item_container_add(ELM_SEL_FORMAT_TARGETS, grid_item_getcb, dropcb=grid_dropcb) grid.drag_item_container_add(ANIM_TIME, DRAG_TIMEOUT, grid_item_getcb, grid_data_getcb) for i in range(20): grid.item_append(gic, img[i % 9]) bxx.pack_end(grid) grid.show() win.show()
def dnd_genlist_user_anim_clicked(obj, item=None): win = StandardWindow("dnd-genlist-user-anim", "DnD-Genlist-User-Anim", autodel=True, size=(680, 800)) bxx = Box(win, horizontal=True, size_hint_weight=EXPAND_BOTH) win.resize_object_add(bxx) bxx.show() for j in range(2): gl = Genlist(win, multi_select=True, size_hint_weight=EXPAND_BOTH, size_hint_align=FILL_BOTH) # START Drag and Drop handling win.callback_delete_request_add(win_del, gl) gl.drop_item_container_add(ELM_SEL_FORMAT_TARGETS, gl_item_getcb, dropcb=gl_dropcb) gl.drag_item_container_add(ANIM_TIME, DRAG_TIMEOUT, gl_item_getcb, gl_data_getcb) # We add mouse-down, up callbacks to start/stop drag animation gl.event_callback_add(EVAS_CALLBACK_MOUSE_DOWN, gl_obj_mouse_down, gl) # END Drag and Drop handling # FIXME: This causes genlist to resize the horiz axis very slowly :( # Reenable this and resize the window horizontally, then try to resize it back #elm_genlist_mode_set(gl, ELM_LIST_LIMIT) bxx.pack_end(gl) gl.show() for i in range(20): gl.item_append(itc1, img[i % 9], flags=ELM_GENLIST_ITEM_NONE) win.show()