X-Git-Url: http://git.onelab.eu/?p=sface.git;a=blobdiff_plain;f=sface%2Frspecwindow.py;h=2abd5fd8eacf513d9f040bb6a88f6160cc3ec691;hp=021d8fa5661f59e804aa25cce8ce8f672d52846b;hb=eb6b726661868a93d439c030ead00f4b7a2fe0a7;hpb=40456613e902f122d2fd13c1aac32bc72c0c1642 diff --git a/sface/rspecwindow.py b/sface/rspecwindow.py index 021d8fa..2abd5fd 100644 --- a/sface/rspecwindow.py +++ b/sface/rspecwindow.py @@ -15,7 +15,6 @@ class RSpecView(XmlView): XmlView.__init__(self, parent) def expandMatchingText(self, txt): - print "LHS", txt self.collapseAll() self.expandToDepth(0) @@ -28,8 +27,11 @@ class RSpecView(XmlView): self.expand(index) def search(index): - print index.data().toString() - if index.data().toString() == txt: + # voodoo alert: baris was using index.data() + # and apparently it worked. But after me + # messing around, only index.model().data(index) + # seems to give non-empty QVariant as output. + if index.model().data(index).toString() == txt: recursiveExpand(index) self.scrollTo(index, self.PositionAtCenter) return @@ -60,11 +62,9 @@ class RSpecWindow(QDialog): layout.addWidget(self.view) self.setLayout(layout) - print 'CHILDREN', str(self.children()) self.updateView() def showNode(self, hostname): - print "SHOWNODE" self.view.expandMatchingText(hostname) def updateView(self):