Commits

Steve Borho committed 2e5b69e

qscilib: override search bar setVisible to give line entry focus

  • Participants
  • Parent commits fe6b56d

Comments (0)

Files changed (1)

File tortoisehg/hgqt/qscilib.py

             return
         super(SearchToolBar, self).wheelEvent(event)
 
+    def setVisible(self, visible=True):
+        super(SearchToolBar, self).setVisible(visible)
+        if visible:
+            self._le.setFocus()
+            self._le.selectAll()
+
     def _readsettings(self):
         self.setCaseInsensitive(self._settings.value('icase', False).toBool())
         self.setWrapAround(self._settings.value('wrap', False).toBool())