]> Git Repo - linux.git/commitdiff
perf scripts python: exported-sql-viewer.py: Select find text when find bar is activated
authorAdrian Hunter <[email protected]>
Mon, 20 May 2019 11:37:28 +0000 (14:37 +0300)
committerArnaldo Carvalho de Melo <[email protected]>
Wed, 5 Jun 2019 12:47:58 +0000 (09:47 -0300)
The user probably wants to replace the find text, so select the find
text when the find bar is activated.

That is fairly standard behaviour for search text entry.

Entering text will replace the current text, but using edit keys
(arrows, home, end etc) cancels the selection and enables editing.

Signed-off-by: Adrian Hunter <[email protected]>
Tested-by: Arnaldo Carvalho de Melo <[email protected]>
Cc: Jiri Olsa <[email protected]>
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
tools/perf/scripts/python/exported-sql-viewer.py

index 94489cf2ce0ea2ea54253cf618f7f478c021e9d3..6e7934f2ac9a31549cddfd1a669e6cc7f61b613e 100755 (executable)
@@ -400,6 +400,7 @@ class FindBar():
 
        def Activate(self):
                self.bar.show()
+               self.textbox.lineEdit().selectAll()
                self.textbox.setFocus()
 
        def Deactivate(self):
This page took 0.058656 seconds and 4 git commands to generate.