Skip to content

Commit

Permalink
Moved Navigator on top of tabs, FLTD-227
Browse files Browse the repository at this point in the history
  • Loading branch information
Daniele Paganelli committed Nov 16, 2016
1 parent d6555da commit a82eb9d
Showing 1 changed file with 7 additions and 9 deletions.
16 changes: 7 additions & 9 deletions misura/client/acquisition/measureinfo.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ def __init__(self, remote, fixedDoc=False, parent=None):
self.refreshSamples, QtCore.Qt.QueuedConnection)
self.connect(
self, QtCore.SIGNAL("currentChanged(int)"), self.tabChanged)
self.connect(
self, QtCore.SIGNAL("currentChanged(int)"), self.refreshSamples)
#self.connect(
# self, QtCore.SIGNAL("currentChanged(int)"), self.refreshSamples)

self.tabBar().setContextMenuPolicy(QtCore.Qt.CustomContextMenu)
self.tabBar().customContextMenuRequested.connect(self.show_menu)
Expand Down Expand Up @@ -85,11 +85,9 @@ def set_results(self, results):
i = self.indexOf(self.results)
if i >= 0:
self.removeTab(i)
else:
i = self.statusView is not False
i += self.thermalCycleView.isVisible()
i += 1
print 'BBBBBBBBBBBBB', i
i = self.statusView is not False
i += self.thermalCycleView.isVisible()
i += 1
self.results = results
self.insertTab(i, self.results, _('Navigator'))

Expand Down Expand Up @@ -131,13 +129,13 @@ def get_samples(self):
sample = getattr(self.remote, n, False)
if sample:
paths.append(p0 + n)
print 'GETSAMPLES', paths
return paths

def refresh_nodes(self, nodes=[]):
# Remove all node tabs
for nodevi in self.nodeViews.itervalues():
i = self.indexOf(nodevi)
print 'REMOVE NODEVI', i, nodevi, nodevi.remObj['fullpath']
if i < 0:
continue
self.removeTab(i)
Expand All @@ -163,7 +161,7 @@ def refresh_nodes(self, nodes=[]):
if not wg:
wg = conf.Interface(
self.server, node, node.describe(), self)
j = c - 1 + i
j = c + i
self.insertTab(j, wg, node['devpath'].capitalize())
self.nodeViews[n] = wg
self.nodes.append(n)
Expand Down

0 comments on commit a82eb9d

Please sign in to comment.