OLD | NEW |
(Empty) | |
| 1 // Copyright 2014 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 #include "chrome/browser/guest_view/web_view/web_view_constants.h" |
| 6 |
| 7 namespace webview { |
| 8 |
| 9 // Attributes. |
| 10 const char kAttributeAutoSize[] = "autosize"; |
| 11 const char kAttributeMaxHeight[] = "maxheight"; |
| 12 const char kAttributeMaxWidth[] = "maxwidth"; |
| 13 const char kAttributeMinHeight[] = "minheight"; |
| 14 const char kAttributeMinWidth[] = "minwidth"; |
| 15 |
| 16 // API namespace. |
| 17 const char kAPINamespace[] = "webViewInternal"; |
| 18 |
| 19 // Events. |
| 20 const char kEventClose[] = "webViewInternal.onClose"; |
| 21 const char kEventConsoleMessage[] = "webViewInternal.onConsoleMessage"; |
| 22 const char kEventContentLoad[] = "webViewInternal.onContentLoad"; |
| 23 const char kEventContextMenu[] = "webViewInternal.contextmenu"; |
| 24 const char kEventDialog[] = "webViewInternal.onDialog"; |
| 25 const char kEventExit[] = "webViewInternal.onExit"; |
| 26 const char kEventFindReply[] = "webViewInternal.onFindReply"; |
| 27 const char kEventFrameNameChanged[] = "webViewInternal.onFrameNameChanged"; |
| 28 const char kEventLoadAbort[] = "webViewInternal.onLoadAbort"; |
| 29 const char kEventLoadCommit[] = "webViewInternal.onLoadCommit"; |
| 30 const char kEventLoadProgress[] = "webViewInternal.onLoadProgress"; |
| 31 const char kEventLoadRedirect[] = "webViewInternal.onLoadRedirect"; |
| 32 const char kEventLoadStart[] = "webViewInternal.onLoadStart"; |
| 33 const char kEventLoadStop[] = "webViewInternal.onLoadStop"; |
| 34 const char kEventMessage[] = "webViewInternal.onMessage"; |
| 35 const char kEventNewWindow[] = "webViewInternal.onNewWindow"; |
| 36 const char kEventPermissionRequest[] = "webViewInternal.onPermissionRequest"; |
| 37 const char kEventResponsive[] = "webViewInternal.onResponsive"; |
| 38 const char kEventSizeChanged[] = "webViewInternal.onSizeChanged"; |
| 39 const char kEventUnresponsive[] = "webViewInternal.onUnresponsive"; |
| 40 const char kEventZoomChange[] = "webViewInternal.onZoomChange"; |
| 41 |
| 42 // Event related constants. |
| 43 const char kWebViewEventPrefix[] = "webViewInternal."; |
| 44 |
| 45 // Parameters/properties on events. |
| 46 const char kContextMenuItems[] = "items"; |
| 47 const char kDefaultPromptText[] = "defaultPromptText"; |
| 48 const char kFindSearchText[] = "searchText"; |
| 49 const char kFindFinalUpdate[] = "finalUpdate"; |
| 50 const char kInitialHeight[] = "initialHeight"; |
| 51 const char kInitialWidth[] = "initialWidth"; |
| 52 const char kLastUnlockedBySelf[] = "lastUnlockedBySelf"; |
| 53 const char kLevel[] = "level"; |
| 54 const char kLine[] = "line"; |
| 55 const char kMessage[] = "message"; |
| 56 const char kMessageText[] = "messageText"; |
| 57 const char kMessageType[] = "messageType"; |
| 58 const char kName[] = "name"; |
| 59 const char kNewHeight[] = "newHeight"; |
| 60 const char kNewURL[] = "newUrl"; |
| 61 const char kNewWidth[] = "newWidth"; |
| 62 const char kOldHeight[] = "oldHeight"; |
| 63 const char kOldURL[] = "oldUrl"; |
| 64 const char kPermission[] = "permission"; |
| 65 const char kPermissionTypeDialog[] = "dialog"; |
| 66 const char kPermissionTypeDownload[] = "download"; |
| 67 const char kPermissionTypeFileSystem[] = "filesystem"; |
| 68 const char kPermissionTypeGeolocation[] = "geolocation"; |
| 69 const char kPermissionTypeLoadPlugin[] = "loadplugin"; |
| 70 const char kPermissionTypeMedia[] = "media"; |
| 71 const char kPermissionTypeNewWindow[] = "newwindow"; |
| 72 const char kPermissionTypePointerLock[] = "pointerLock"; |
| 73 const char kOldWidth[] = "oldWidth"; |
| 74 const char kProcessId[] = "processId"; |
| 75 const char kProgress[] = "progress"; |
| 76 const char kReason[] = "reason"; |
| 77 const char kRequestId[] = "requestId"; |
| 78 const char kSourceId[] = "sourceId"; |
| 79 const char kTargetURL[] = "targetUrl"; |
| 80 const char kWindowID[] = "windowId"; |
| 81 const char kWindowOpenDisposition[] = "windowOpenDisposition"; |
| 82 const char kOldZoomFactor[] = "oldZoomFactor"; |
| 83 const char kNewZoomFactor[] = "newZoomFactor"; |
| 84 |
| 85 // Internal parameters/properties on events. |
| 86 const char kInternalCurrentEntryIndex[] = "currentEntryIndex"; |
| 87 const char kInternalEntryCount[] = "entryCount"; |
| 88 const char kInternalProcessId[] = "processId"; |
| 89 |
| 90 // Parameters to callback functions. |
| 91 const char kFindNumberOfMatches[] = "numberOfMatches"; |
| 92 const char kFindActiveMatchOrdinal[] = "activeMatchOrdinal"; |
| 93 const char kFindSelectionRect[] = "selectionRect"; |
| 94 const char kFindRectLeft[] = "left"; |
| 95 const char kFindRectTop[] = "top"; |
| 96 const char kFindRectWidth[] = "width"; |
| 97 const char kFindRectHeight[] = "height"; |
| 98 const char kFindCanceled[] = "canceled"; |
| 99 |
| 100 // Initialization parameters. |
| 101 const char kParameterUserAgentOverride[] = "userAgentOverride"; |
| 102 |
| 103 // Miscellaneous. |
| 104 const char kMenuItemCommandId[] = "commandId"; |
| 105 const char kMenuItemLabel[] = "label"; |
| 106 const char kPersistPrefix[] = "persist:"; |
| 107 const char kStoragePartitionId[] = "storagePartitionId"; |
| 108 const unsigned int kMaxOutstandingPermissionRequests = 1024; |
| 109 const int kInvalidPermissionRequestID = 0; |
| 110 |
| 111 } // namespace webview |
OLD | NEW |