| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 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 com.android.webview.chromium; | 5 package com.android.webview.chromium; |
| 6 | 6 |
| 7 import android.content.Context; | 7 import android.content.Context; |
| 8 import android.graphics.Bitmap; | 8 import android.graphics.Bitmap; |
| 9 import android.graphics.BitmapFactory; | 9 import android.graphics.BitmapFactory; |
| 10 import android.graphics.Canvas; | 10 import android.graphics.Canvas; |
| (...skipping 375 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 386 /** | 386 /** |
| 387 * @See AwContentsClient#startActionMode(View,ActionHandler,boolean) | 387 * @See AwContentsClient#startActionMode(View,ActionHandler,boolean) |
| 388 */ | 388 */ |
| 389 @Override | 389 @Override |
| 390 public SelectActionMode startActionMode( | 390 public SelectActionMode startActionMode( |
| 391 View view, ActionHandler actionHandler, boolean floating) { | 391 View view, ActionHandler actionHandler, boolean floating) { |
| 392 try { | 392 try { |
| 393 TraceEvent.begin("WebViewContentsClientAdapter.startActionMode"); | 393 TraceEvent.begin("WebViewContentsClientAdapter.startActionMode"); |
| 394 if (TRACE) Log.d(TAG, "startActionMode"); | 394 if (TRACE) Log.d(TAG, "startActionMode"); |
| 395 if (floating) return null; | 395 if (floating) return null; |
| 396 ActionMode.Callback callback = | 396 ActionMode.Callback callback = new SelectActionModeCallback(mContext
, actionHandler); |
| 397 new SelectActionModeCallback(view.getContext(), actionHandle
r); | |
| 398 ActionMode actionMode = view.startActionMode(callback); | 397 ActionMode actionMode = view.startActionMode(callback); |
| 399 return actionMode != null ? new SelectActionMode(actionMode) : null; | 398 return actionMode != null ? new SelectActionMode(actionMode) : null; |
| 400 } finally { | 399 } finally { |
| 401 TraceEvent.end("WebViewContentsClientAdapter.startActionMode"); | 400 TraceEvent.end("WebViewContentsClientAdapter.startActionMode"); |
| 402 } | 401 } |
| 403 } | 402 } |
| 404 | 403 |
| 405 /** | 404 /** |
| 406 * @See AwContentsClient#supportsFloatingActionMode() | 405 * @See AwContentsClient#supportsFloatingActionMode() |
| 407 */ | 406 */ |
| (...skipping 877 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1285 mAwPermissionRequest.deny(); | 1284 mAwPermissionRequest.deny(); |
| 1286 } | 1285 } |
| 1287 } | 1286 } |
| 1288 | 1287 |
| 1289 @Override | 1288 @Override |
| 1290 public void deny() { | 1289 public void deny() { |
| 1291 mAwPermissionRequest.deny(); | 1290 mAwPermissionRequest.deny(); |
| 1292 } | 1291 } |
| 1293 } | 1292 } |
| 1294 } | 1293 } |
| OLD | NEW |