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

Side by Side Diff: content/public/android/java/src/org/chromium/content/browser/ContentViewCore.java

Issue 2290133002: Make WebView keep keyboard when losing focus (Closed)
Patch Set: Add some tests Created 4 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
OLDNEW
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 package org.chromium.content.browser; 5 package org.chromium.content.browser;
6 6
7 import android.annotation.SuppressLint; 7 import android.annotation.SuppressLint;
8 import android.annotation.TargetApi; 8 import android.annotation.TargetApi;
9 import android.app.Activity; 9 import android.app.Activity;
10 import android.app.SearchManager; 10 import android.app.SearchManager;
(...skipping 1290 matching lines...) Expand 10 before | Expand all | Expand 10 after
1301 return nativeGetCurrentRenderProcessId(mNativeContentViewCore); 1301 return nativeGetCurrentRenderProcessId(mNativeContentViewCore);
1302 } 1302 }
1303 1303
1304 /** 1304 /**
1305 * To be called when the ContentView is hidden. 1305 * To be called when the ContentView is hidden.
1306 */ 1306 */
1307 public void onHide() { 1307 public void onHide() {
1308 assert mWebContents != null; 1308 assert mWebContents != null;
1309 hidePopupsAndPreserveSelection(); 1309 hidePopupsAndPreserveSelection();
1310 mWebContents.onHide(); 1310 mWebContents.onHide();
1311 mImeAdapter.resetAndHideKeyboard();
Changwan Ryu 2016/09/21 01:22:45 As we talked offline, I'm still not convinced that
1311 } 1312 }
1312 1313
1313 private void hidePopupsAndClearSelection() { 1314 private void hidePopupsAndClearSelection() {
1314 mUnselectAllOnActionModeDismiss = true; 1315 mUnselectAllOnActionModeDismiss = true;
1315 hidePopups(); 1316 hidePopups();
1316 } 1317 }
1317 1318
1318 @CalledByNative 1319 @CalledByNative
1319 private void hidePopupsAndPreserveSelection() { 1320 private void hidePopupsAndPreserveSelection() {
1320 mUnselectAllOnActionModeDismiss = false; 1321 mUnselectAllOnActionModeDismiss = false;
(...skipping 2087 matching lines...) Expand 10 before | Expand all | Expand 10 after
3408 String textTrackTextShadow, String textTrackTextSize); 3409 String textTrackTextShadow, String textTrackTextSize);
3409 3410
3410 private native void nativeExtractSmartClipData(long nativeContentViewCoreImp l, 3411 private native void nativeExtractSmartClipData(long nativeContentViewCoreImp l,
3411 int x, int y, int w, int h); 3412 int x, int y, int w, int h);
3412 3413
3413 private native void nativeSetBackgroundOpaque(long nativeContentViewCoreImpl , boolean opaque); 3414 private native void nativeSetBackgroundOpaque(long nativeContentViewCoreImpl , boolean opaque);
3414 private native boolean nativeIsTouchDragDropEnabled(long nativeContentViewCo reImpl); 3415 private native boolean nativeIsTouchDragDropEnabled(long nativeContentViewCo reImpl);
3415 private native void nativeOnDragEvent(long nativeContentViewCoreImpl, int ac tion, int x, int y, 3416 private native void nativeOnDragEvent(long nativeContentViewCoreImpl, int ac tion, int x, int y,
3416 int screenX, int screenY, String[] mimeTypes, String content); 3417 int screenX, int screenY, String[] mimeTypes, String content);
3417 } 3418 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698