comparison pyink/comp_dock.py @ 1323:ffbbd3aa218d

Make a component from a group. User can translate a group into a component from context menu.
author Thinker K.F. Li <thinker@codemud.net>
date Sun, 30 Jan 2011 19:15:17 +0800
parents ab21c148b3c6
children c2a693a27eb9
comparison
equal deleted inserted replaced
1322:7f25abbc1b61 1323:ffbbd3aa218d
258 def on_treeview_components_cursor_changed(self, *args): 258 def on_treeview_components_cursor_changed(self, *args):
259 domview_ui = self._domview_ui 259 domview_ui = self._domview_ui
260 260
261 comp_name = self._current_component() 261 comp_name = self._current_component()
262 domview_ui.switch_component(comp_name) 262 domview_ui.switch_component(comp_name)
263
264 group = domview_ui.get_layer_group(0)
265 desktop = self._desktop # from comp_dock_base
266 desktop.setCurrentLayer(group.spitem)
263 pass 267 pass
264 268
265 def on_cellrenderer_comp_edited(self, renderer, path, 269 def on_cellrenderer_comp_edited(self, renderer, path,
266 new_text, *args): 270 new_text, *args):
267 print '%s - %s' % (path, new_text) 271 print '%s - %s' % (path, new_text)