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 org.chromium.content.browser; | 5 package org.chromium.content.browser; |
6 | 6 |
7 import android.os.Handler; | 7 import android.os.Handler; |
8 | 8 |
9 import org.chromium.base.UsedByReflection; | 9 import org.chromium.base.annotations.UsedByReflection; |
10 | 10 |
11 /** | 11 /** |
12 * An interface to provide smart clip data when requested. | 12 * An interface to provide smart clip data when requested. |
13 * | 13 * |
14 * NOTE: Some platforms may call these functions to extract smart clip data. | 14 * NOTE: Some platforms may call these functions to extract smart clip data. |
15 * Please make sure implementation of them is somewhere in the view | 15 * Please make sure implementation of them is somewhere in the view |
16 * hierarchy. | 16 * hierarchy. |
17 */ | 17 */ |
18 @UsedByReflection("ExternalOemSupport") | 18 @UsedByReflection("ExternalOemSupport") |
19 public interface SmartClipProvider { | 19 public interface SmartClipProvider { |
20 /** | 20 /** |
21 * Initiate extraction of text, HTML, and other information for clipping pup
oses (smart clip) | 21 * Initiate extraction of text, HTML, and other information for clipping pup
oses (smart clip) |
22 * from the rectangle area defined by starting positions (x and y), and widt
h and height. | 22 * from the rectangle area defined by starting positions (x and y), and widt
h and height. |
23 */ | 23 */ |
24 @UsedByReflection("ExternalOemSupport") | 24 @UsedByReflection("ExternalOemSupport") |
25 void extractSmartClipData(int x, int y, int width, int height); | 25 void extractSmartClipData(int x, int y, int width, int height); |
26 | 26 |
27 /** | 27 /** |
28 * Register a handler to handle smart clip data once extraction is done. | 28 * Register a handler to handle smart clip data once extraction is done. |
29 */ | 29 */ |
30 @UsedByReflection("ExternalOemSupport") | 30 @UsedByReflection("ExternalOemSupport") |
31 void setSmartClipResultHandler(final Handler resultHandler); | 31 void setSmartClipResultHandler(final Handler resultHandler); |
32 } | 32 } |
OLD | NEW |