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

Side by Side Diff: ui/keyboard/resources/webui/api_adapter.js

Issue 20526005: Implement virtual keyboard hiding. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: rebase yet again Created 7 years, 3 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 | « ui/keyboard/resources/api_adapter.js ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 function insertText(text) { 5 function insertText(text) {
6 chrome.send('insertText', [ text ]); 6 chrome.send('insertText', [ text ]);
7 } 7 }
8 8
9 function sendKeyEvent(event) { 9 function sendKeyEvent(event) {
10 chrome.send('sendKeyEvent', [ event ]); 10 chrome.send('sendKeyEvent', [ event ]);
11 } 11 }
12 12
13 function hideKeyboard() {
14 chrome.send('hideKeyboard');
15 }
16
13 (function(exports) { 17 (function(exports) {
14 /** 18 /**
15 * An array to save callbacks of each request. 19 * An array to save callbacks of each request.
16 * @type {Array.<function(Object)>} 20 * @type {Array.<function(Object)>}
17 */ 21 */
18 var requestIdCallbackMap = []; 22 var requestIdCallbackMap = [];
19 23
20 /** 24 /**
21 * An incremental integer that represents a unique requestId. 25 * An incremental integer that represents a unique requestId.
22 * @type {number} 26 * @type {number}
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 if (!requestIdCallbackMap[requestId]) 73 if (!requestIdCallbackMap[requestId])
70 return; 74 return;
71 requestIdCallbackMap[requestId](inputContext); 75 requestIdCallbackMap[requestId](inputContext);
72 } 76 }
73 77
74 exports.OnTextInputBoxFocused = OnTextInputBoxFocused; 78 exports.OnTextInputBoxFocused = OnTextInputBoxFocused;
75 exports.getInputContext = GetInputContext; 79 exports.getInputContext = GetInputContext;
76 exports.cancelRequest = CancelRequest; 80 exports.cancelRequest = CancelRequest;
77 exports.GetInputContextCallback = GetInputContextCallback; 81 exports.GetInputContextCallback = GetInputContextCallback;
78 })(this); 82 })(this);
OLDNEW
« no previous file with comments | « ui/keyboard/resources/api_adapter.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698