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 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.app.Activity; | 8 import android.app.Activity; |
9 import android.app.SearchManager; | 9 import android.app.SearchManager; |
10 import android.content.ClipboardManager; | 10 import android.content.ClipboardManager; |
(...skipping 1665 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1676 * @see View#onWindowFocusChanged(boolean) | 1676 * @see View#onWindowFocusChanged(boolean) |
1677 */ | 1677 */ |
1678 public void onWindowFocusChanged(boolean hasWindowFocus) { | 1678 public void onWindowFocusChanged(boolean hasWindowFocus) { |
1679 if (!hasWindowFocus) resetGestureDetection(); | 1679 if (!hasWindowFocus) resetGestureDetection(); |
1680 } | 1680 } |
1681 | 1681 |
1682 public void onFocusChanged(boolean gainFocus) { | 1682 public void onFocusChanged(boolean gainFocus) { |
1683 if (!gainFocus) { | 1683 if (!gainFocus) { |
1684 hideImeIfNeeded(); | 1684 hideImeIfNeeded(); |
1685 cancelRequestToScrollFocusedEditableNodeIntoView(); | 1685 cancelRequestToScrollFocusedEditableNodeIntoView(); |
| 1686 hidePastePopup(); |
1686 } | 1687 } |
1687 if (mNativeContentViewCore != 0) nativeSetFocus(mNativeContentViewCore,
gainFocus); | 1688 if (mNativeContentViewCore != 0) nativeSetFocus(mNativeContentViewCore,
gainFocus); |
1688 } | 1689 } |
1689 | 1690 |
1690 /** | 1691 /** |
1691 * @see View#onKeyUp(int, KeyEvent) | 1692 * @see View#onKeyUp(int, KeyEvent) |
1692 */ | 1693 */ |
1693 public boolean onKeyUp(int keyCode, KeyEvent event) { | 1694 public boolean onKeyUp(int keyCode, KeyEvent event) { |
1694 if (mPopupZoomer.isShowing() && keyCode == KeyEvent.KEYCODE_BACK) { | 1695 if (mPopupZoomer.isShowing() && keyCode == KeyEvent.KEYCODE_BACK) { |
1695 mPopupZoomer.hide(true); | 1696 mPopupZoomer.hide(true); |
(...skipping 1532 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3228 | 3229 |
3229 private native void nativeExtractSmartClipData(long nativeContentViewCoreImp
l, | 3230 private native void nativeExtractSmartClipData(long nativeContentViewCoreImp
l, |
3230 int x, int y, int w, int h); | 3231 int x, int y, int w, int h); |
3231 private native void nativeSetBackgroundOpaque(long nativeContentViewCoreImpl
, boolean opaque); | 3232 private native void nativeSetBackgroundOpaque(long nativeContentViewCoreImpl
, boolean opaque); |
3232 | 3233 |
3233 private native void nativeResumeResponseDeferredAtStart( | 3234 private native void nativeResumeResponseDeferredAtStart( |
3234 long nativeContentViewCoreImpl); | 3235 long nativeContentViewCoreImpl); |
3235 private native void nativeSetHasPendingNavigationTransitionForTesting( | 3236 private native void nativeSetHasPendingNavigationTransitionForTesting( |
3236 long nativeContentViewCoreImpl); | 3237 long nativeContentViewCoreImpl); |
3237 } | 3238 } |
OLD | NEW |