comparison clients/editor/plugins/LayerTool.py @ 359:ad5818097cd6

* Some cleanups for Editor class to match new coding standards * Minor cleanups in imports
author cheesesucker@33b003aa-7bff-0310-803a-e67f0ece8222
date Sat, 26 Sep 2009 10:38:24 +0000
parents 8f64a9d1e7ab
children 598547404022
comparison
equal deleted inserted replaced
358:8f64a9d1e7ab 359:ad5818097cd6
75 75
76 # Fifedit plugin data 76 # Fifedit plugin data
77 self._editor = scripts.editor.getEditor() 77 self._editor = scripts.editor.getEditor()
78 self._action_show = Action(u"LayerTool", checkable=True) 78 self._action_show = Action(u"LayerTool", checkable=True)
79 scripts.gui.action.activated.connect(self.toggle, sender=self._action_show) 79 scripts.gui.action.activated.connect(self.toggle, sender=self._action_show)
80 self._editor._toolsMenu.addAction(self._action_show) 80 self._editor._tools_menu.addAction(self._action_show)
81 81
82 self._createGui() 82 self._createGui()
83 83
84 self.toggle() 84 self.toggle()
85 85
92 self._container.setDocked(False) 92 self._container.setDocked(False)
93 self._container.hide() 93 self._container.hide()
94 94
95 events.postMapShown.disconnect(self.update) 95 events.postMapShown.disconnect(self.update)
96 96
97 self._editor._toolsMenu.removeAction(self._action_show) 97 self._editor._tools_menu.removeAction(self._action_show)
98 98
99 def isEnabled(self): 99 def isEnabled(self):
100 """ Returns True if plugin is enabled """ 100 """ Returns True if plugin is enabled """
101 return self._enabled; 101 return self._enabled;
102 102