Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(144)

Unified Diff: client/site_tests/factory_ScriptWrapper/factory_ScriptWrapper.py

Issue 3226005: Refactory UI to grab shortcut keys, and tests to not look for triggers. (Closed) Base URL: http://git.chromium.org/git/autotest.git
Patch Set: Created 10 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: client/site_tests/factory_ScriptWrapper/factory_ScriptWrapper.py
diff --git a/client/site_tests/factory_ScriptWrapper/factory_ScriptWrapper.py b/client/site_tests/factory_ScriptWrapper/factory_ScriptWrapper.py
index 1fcb20b44cc97a01f4d5f0edf6a717e5f5c35bf2..a2a653e1103171d327aae4ba6f81fc74a5a6f96b 100644
--- a/client/site_tests/factory_ScriptWrapper/factory_ScriptWrapper.py
+++ b/client/site_tests/factory_ScriptWrapper/factory_ScriptWrapper.py
@@ -65,7 +65,7 @@ class factory_ScriptWrapper(test.test):
def key_release_callback(self, widget, event):
char = event.keyval in range(32,127) and chr(event.keyval) or None
char = event.keyval == gdk.keyval_from_name('Return') and '\n' or char
- if not self._ft_state.exit_on_trigger(event) and char is not None:
+ if char is not None:
self._script.send(char)
return True
@@ -73,15 +73,10 @@ class factory_ScriptWrapper(test.test):
window.connect('key-release-event', self.key_release_callback)
window.add_events(gdk.KEY_RELEASE_MASK)
- def run_once(self,
- test_widget_size=None,
- trigger_set=None,
- cmdline=None):
+ def run_once(self, cmdline=None):
factory.log('%s run_once' % self.__class__)
- self._ft_state = ful.State(trigger_set)
-
label = ful.make_label('', alignment=(0.5, 0.5))
test_widget = gtk.EventBox()
@@ -90,9 +85,7 @@ class factory_ScriptWrapper(test.test):
self._script = Script(cmdline, pexpect, label)
- self._ft_state.run_test_widget(
- test_widget=test_widget,
- test_widget_size=test_widget_size,
+ ful.run_test_widget(self.job, test_widget,
window_registration_callback=self.register_callbacks)
factory.log('%s run_once finished' % self.__class__)
« no previous file with comments | « client/site_tests/factory_Review/factory_Review.py ('k') | client/site_tests/factory_Touchpad/factory_Touchpad.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698