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

Side by Side Diff: ui/base/test/ui_controls.h

Issue 1782773002: MacViews: Fix ViewTest.HandleAccelerator by faking window activation (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Faked activations for everyone! Created 4 years, 9 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 unified diff | Download patch
« no previous file with comments | « no previous file | ui/base/test/ui_controls_mac.mm » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef UI_BASE_TEST_UI_CONTROLS_H_ 5 #ifndef UI_BASE_TEST_UI_CONTROLS_H_
6 #define UI_BASE_TEST_UI_CONTROLS_H_ 6 #define UI_BASE_TEST_UI_CONTROLS_H_
7 7
8 #include "base/callback_forward.h" 8 #include "base/callback_forward.h"
9 #include "build/build_config.h" 9 #include "build/build_config.h"
10 #include "ui/events/keycodes/keyboard_codes.h" 10 #include "ui/events/keycodes/keyboard_codes.h"
(...skipping 26 matching lines...) Expand all
37 // Send a key press with/without modifier keys. 37 // Send a key press with/without modifier keys.
38 // 38 //
39 // If you're writing a test chances are you want the variant in ui_test_utils. 39 // If you're writing a test chances are you want the variant in ui_test_utils.
40 // See it for details. 40 // See it for details.
41 41
42 // Per the above comment, these methods can only be called from non-sharded test 42 // Per the above comment, these methods can only be called from non-sharded test
43 // suites. This method ensures that they're not accidently called by sharded 43 // suites. This method ensures that they're not accidently called by sharded
44 // tests. 44 // tests.
45 void EnableUIControls(); 45 void EnableUIControls();
46 46
47 #if defined(OS_MACOSX)
48 bool IsUIControlsEnabled();
49 #endif
50
47 bool SendKeyPress(gfx::NativeWindow window, 51 bool SendKeyPress(gfx::NativeWindow window,
48 ui::KeyboardCode key, 52 ui::KeyboardCode key,
49 bool control, 53 bool control,
50 bool shift, 54 bool shift,
51 bool alt, 55 bool alt,
52 bool command); 56 bool command);
53 bool SendKeyPressNotifyWhenDone(gfx::NativeWindow window, 57 bool SendKeyPressNotifyWhenDone(gfx::NativeWindow window,
54 ui::KeyboardCode key, 58 ui::KeyboardCode key,
55 bool control, 59 bool control,
56 bool shift, 60 bool shift,
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 #if defined(OS_MACOSX) 104 #if defined(OS_MACOSX)
101 // Returns true when tests need to use extra Tab and Shift-Tab key events 105 // Returns true when tests need to use extra Tab and Shift-Tab key events
102 // to traverse to the desired item; because the application is configured to 106 // to traverse to the desired item; because the application is configured to
103 // traverse more elements for accessibility reasons. 107 // traverse more elements for accessibility reasons.
104 bool IsFullKeyboardAccessEnabled(); 108 bool IsFullKeyboardAccessEnabled();
105 #endif 109 #endif
106 110
107 } // namespace ui_controls 111 } // namespace ui_controls
108 112
109 #endif // UI_BASE_TEST_UI_CONTROLS_H_ 113 #endif // UI_BASE_TEST_UI_CONTROLS_H_
OLDNEW
« no previous file with comments | « no previous file | ui/base/test/ui_controls_mac.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698