瀏覽代碼

Added updateSelection()

Gyedo Jeon 18 年之前
父節點
當前提交
525c9f9dc4
共有 1 個文件被更改,包括 6 次插入0 次删除
  1. 6 0
      direct/src/tkwidgets/SceneGraphExplorer.py

+ 6 - 0
direct/src/tkwidgets/SceneGraphExplorer.py

@@ -121,6 +121,12 @@ class SceneGraphExplorer(Pmw.MegaWidget, DirectObject):
         # Remove hooks
         # Remove hooks
         self.ignore('DIRECT_activeParent')
         self.ignore('DIRECT_activeParent')
         self.ignore('SGE_Update Explorer')
         self.ignore('SGE_Update Explorer')
+    
+    def updateSelection(self, searchKey):
+        # [gjeon] update SGE selection with directSession
+        sceneGraphItem = self._node.find(searchKey)
+        sceneGraphItem.reveal()
+        sceneGraphItem.select()
 
 
 class SceneGraphExplorerItem(TreeItem):
 class SceneGraphExplorerItem(TreeItem):