| OLD | NEW |
| (Empty) |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef CHROME_COMMON_AUTOMATION_CONSTANTS_H__ | |
| 6 #define CHROME_COMMON_AUTOMATION_CONSTANTS_H__ | |
| 7 | |
| 8 #include <string> | |
| 9 | |
| 10 namespace automation { | |
| 11 | |
| 12 // When passing the kTestingChannelID switch to the browser, prepend | |
| 13 // this prefix to the channel id to enable the named testing interface. | |
| 14 // Named testing interface is used when you want to connect an | |
| 15 // AutomationProxy to an already-running browser instance. | |
| 16 extern const char kNamedInterfacePrefix[]; | |
| 17 | |
| 18 // Amount of time to wait before querying the browser. | |
| 19 static const int kSleepTime = 250; | |
| 20 | |
| 21 // Recognized by the AutomationProvider's SendWebKeyboardEventToSelectedTab | |
| 22 // command. Specifies the type of the keyboard event. | |
| 23 enum KeyEventTypes { | |
| 24 kRawKeyDownType = 0, | |
| 25 kKeyDownType, | |
| 26 kCharType, | |
| 27 kKeyUpType, | |
| 28 }; | |
| 29 | |
| 30 // Recognized by the AutomationProvider's SendWebKeyboardEventToSelectedTab | |
| 31 // command. Specifies masks to be used in constructing keyboard event modifiers. | |
| 32 enum KeyModifierMasks { | |
| 33 kShiftKeyMask = 1 << 0, | |
| 34 kControlKeyMask = 1 << 1, | |
| 35 kAltKeyMask = 1 << 2, | |
| 36 kMetaKeyMask = 1 << 3, | |
| 37 kNumLockKeyMask = 1 << 4, | |
| 38 }; | |
| 39 | |
| 40 // Recognized by the AutomationProvider's ProcessWebMouseEvent command. | |
| 41 enum MouseEventType { | |
| 42 kMouseDown = 0, | |
| 43 kMouseUp, | |
| 44 kMouseMove, | |
| 45 kMouseEnter, | |
| 46 kMouseLeave, | |
| 47 kContextMenu, | |
| 48 }; | |
| 49 | |
| 50 enum MouseButton { | |
| 51 kLeftButton = 0, | |
| 52 kMiddleButton, | |
| 53 kRightButton, | |
| 54 kNoButton, | |
| 55 }; | |
| 56 | |
| 57 } // namespace automation | |
| 58 | |
| 59 // Used by AutomationProxy, declared here so that other headers don't need | |
| 60 // to include automation_proxy.h. | |
| 61 enum AutomationLaunchResult { | |
| 62 AUTOMATION_LAUNCH_RESULT_INVALID = -1, | |
| 63 AUTOMATION_SUCCESS, | |
| 64 AUTOMATION_TIMEOUT, | |
| 65 AUTOMATION_VERSION_MISMATCH, | |
| 66 AUTOMATION_CREATE_TAB_FAILED, | |
| 67 AUTOMATION_SERVER_CRASHED, | |
| 68 AUTOMATION_CHANNEL_ERROR, | |
| 69 }; | |
| 70 | |
| 71 enum AutomationMsg_NavigationResponseValues { | |
| 72 AUTOMATION_MSG_NAVIGATION_ERROR = 0, | |
| 73 AUTOMATION_MSG_NAVIGATION_SUCCESS, | |
| 74 AUTOMATION_MSG_NAVIGATION_AUTH_NEEDED, | |
| 75 AUTOMATION_MSG_NAVIGATION_BLOCKED_BY_MODAL_DIALOG, | |
| 76 }; | |
| 77 | |
| 78 // Used in the AutomationMsg_GetExtensionProperty to identify which extension | |
| 79 // property should be retrieved, instead of having separate messages for each | |
| 80 // property. | |
| 81 enum AutomationMsg_DEPRECATED_ExtensionProperty { | |
| 82 AUTOMATION_MSG_EXTENSION_ID = 0, | |
| 83 AUTOMATION_MSG_EXTENSION_NAME, | |
| 84 AUTOMATION_MSG_EXTENSION_VERSION, | |
| 85 AUTOMATION_MSG_EXTENSION_BROWSER_ACTION_INDEX, | |
| 86 }; | |
| 87 | |
| 88 // Specifies the font size on a page which is requested by an automation | |
| 89 // client. | |
| 90 enum AutomationPageFontSize { | |
| 91 SMALLEST_FONT = 8, | |
| 92 SMALL_FONT = 12, | |
| 93 MEDIUM_FONT = 16, | |
| 94 LARGE_FONT = 24, | |
| 95 LARGEST_FONT = 36 | |
| 96 }; | |
| 97 | |
| 98 enum FindInPageDirection { BACK = 0, FWD = 1 }; | |
| 99 enum FindInPageCase { IGNORE_CASE = 0, CASE_SENSITIVE = 1 }; | |
| 100 | |
| 101 #endif // CHROME_COMMON_AUTOMATION_CONSTANTS_H__ | |
| OLD | NEW |