--- a/PLCOpenEditor.py Tue Dec 15 10:00:21 2009 +0100
+++ b/PLCOpenEditor.py Tue Dec 15 11:31:23 2009 +0100
@@ -1160,17 +1160,17 @@
def RefreshEditor(self, variablepanel = True):
selected = self.TabsOpened.GetSelection()
- visible = []
if USE_AUI:
for child in self.TabsOpened.GetChildren():
if isinstance(child, wx.aui.AuiTabCtrl):
- visible.append(child.GetActivePage())
+ window = child.GetWindowFromIdx(child.GetActivePage())
+ window.RefreshView()
+ if not window.IsDebugging() and self.TabsOpened.GetPageIndex(window) == selected and variablepanel:
+ self.RefreshVariablePanel(window.GetTagName())
elif selected >= 0:
- visible.append(selected)
- for idx in visible:
window = self.TabsOpened.GetPage(idx)
window.RefreshView()
- if not window.IsDebugging() and idx == selected and variablepanel:
+ if not window.IsDebugging() and variablepanel:
self.RefreshVariablePanel(window.GetTagName())
def RefreshVariablePanel(self, tagname):