| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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 var chrome; | 5 var chrome; |
| 6 if (!chrome) | 6 if (!chrome) |
| 7 chrome = {}; | 7 chrome = {}; |
| 8 if (!chrome.searchBox) { | 8 if (!chrome.searchBox) { |
| 9 chrome.searchBox = new function() { | 9 chrome.searchBox = new function() { |
| 10 // ========================================================================= | 10 // ========================================================================= |
| (...skipping 10 matching lines...) Expand all Loading... |
| 21 // Private functions | 21 // Private functions |
| 22 // ========================================================================= | 22 // ========================================================================= |
| 23 native function GetQuery(); | 23 native function GetQuery(); |
| 24 native function GetVerbatim(); | 24 native function GetVerbatim(); |
| 25 native function GetSelectionStart(); | 25 native function GetSelectionStart(); |
| 26 native function GetSelectionEnd(); | 26 native function GetSelectionEnd(); |
| 27 native function GetX(); | 27 native function GetX(); |
| 28 native function GetY(); | 28 native function GetY(); |
| 29 native function GetWidth(); | 29 native function GetWidth(); |
| 30 native function GetHeight(); | 30 native function GetHeight(); |
| 31 native function GetStartMargin(); |
| 32 native function GetEndMargin(); |
| 33 native function GetRightToLeft(); |
| 31 native function GetAutocompleteResults(); | 34 native function GetAutocompleteResults(); |
| 32 native function GetContext(); | 35 native function GetContext(); |
| 33 native function GetDisplayInstantResults(); | 36 native function GetDisplayInstantResults(); |
| 34 native function GetThemeBackgroundInfo(); | 37 native function GetThemeBackgroundInfo(); |
| 35 native function GetThemeAreaHeight(); | 38 native function GetThemeAreaHeight(); |
| 36 native function NavigateContentWindow(); | 39 native function NavigateContentWindow(); |
| 37 native function SetSuggestions(); | 40 native function SetSuggestions(); |
| 38 native function SetQuerySuggestion(); | 41 native function SetQuerySuggestion(); |
| 39 native function SetQuerySuggestionFromAutocompleteResult(); | 42 native function SetQuerySuggestionFromAutocompleteResult(); |
| 40 native function SetQuery(); | 43 native function SetQuery(); |
| (...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 171 // Exported functions | 174 // Exported functions |
| 172 // ========================================================================= | 175 // ========================================================================= |
| 173 this.__defineGetter__('value', GetQuery); | 176 this.__defineGetter__('value', GetQuery); |
| 174 this.__defineGetter__('verbatim', GetVerbatim); | 177 this.__defineGetter__('verbatim', GetVerbatim); |
| 175 this.__defineGetter__('selectionStart', GetSelectionStart); | 178 this.__defineGetter__('selectionStart', GetSelectionStart); |
| 176 this.__defineGetter__('selectionEnd', GetSelectionEnd); | 179 this.__defineGetter__('selectionEnd', GetSelectionEnd); |
| 177 this.__defineGetter__('x', GetX); | 180 this.__defineGetter__('x', GetX); |
| 178 this.__defineGetter__('y', GetY); | 181 this.__defineGetter__('y', GetY); |
| 179 this.__defineGetter__('width', GetWidth); | 182 this.__defineGetter__('width', GetWidth); |
| 180 this.__defineGetter__('height', GetHeight); | 183 this.__defineGetter__('height', GetHeight); |
| 184 this.__defineGetter__('startMargin', GetStartMargin); |
| 185 this.__defineGetter__('endMargin', GetEndMargin); |
| 186 this.__defineGetter__('rtl', GetRightToLeft); |
| 181 this.__defineGetter__('nativeSuggestions', GetAutocompleteResultsWrapper); | 187 this.__defineGetter__('nativeSuggestions', GetAutocompleteResultsWrapper); |
| 182 this.__defineGetter__('context', GetContext); | 188 this.__defineGetter__('context', GetContext); |
| 183 this.__defineGetter__('displayInstantResults', GetDisplayInstantResults); | 189 this.__defineGetter__('displayInstantResults', GetDisplayInstantResults); |
| 184 this.__defineGetter__('themeBackgroundInfo', GetThemeBackgroundInfo); | 190 this.__defineGetter__('themeBackgroundInfo', GetThemeBackgroundInfo); |
| 185 this.__defineGetter__('themeAreaHeight', GetThemeAreaHeight); | 191 this.__defineGetter__('themeAreaHeight', GetThemeAreaHeight); |
| 186 this.setSuggestions = function(text) { | 192 this.setSuggestions = function(text) { |
| 187 SetSuggestions(text); | 193 SetSuggestions(text); |
| 188 }; | 194 }; |
| 189 this.setAutocompleteText = function(text, behavior) { | 195 this.setAutocompleteText = function(text, behavior) { |
| 190 SetQuerySuggestion(text, behavior); | 196 SetQuerySuggestion(text, behavior); |
| (...skipping 22 matching lines...) Expand all Loading... |
| 213 this.stopCapturingKeyStrokes = function() { | 219 this.stopCapturingKeyStrokes = function() { |
| 214 StopCapturingKeyStrokes(); | 220 StopCapturingKeyStrokes(); |
| 215 }; | 221 }; |
| 216 this.onchange = null; | 222 this.onchange = null; |
| 217 this.onsubmit = null; | 223 this.onsubmit = null; |
| 218 this.oncancel = null; | 224 this.oncancel = null; |
| 219 this.onresize = null; | 225 this.onresize = null; |
| 220 this.onautocompleteresults = null; | 226 this.onautocompleteresults = null; |
| 221 this.onkeypress = null; | 227 this.onkeypress = null; |
| 222 this.oncontextchange = null; | 228 this.oncontextchange = null; |
| 229 this.onmarginchange = null; |
| 223 }; | 230 }; |
| 224 } | 231 } |
| OLD | NEW |