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

Side by Side Diff: content/browser/android/content_view_core_impl.h

Issue 2667283007: Refactor Samsung SmartClip implementation. (Closed)
Patch Set: Really apply code review comments Created 3 years, 10 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 #ifndef CONTENT_BROWSER_ANDROID_CONTENT_VIEW_CORE_IMPL_H_ 5 #ifndef CONTENT_BROWSER_ANDROID_CONTENT_VIEW_CORE_IMPL_H_
6 #define CONTENT_BROWSER_ANDROID_CONTENT_VIEW_CORE_IMPL_H_ 6 #define CONTENT_BROWSER_ANDROID_CONTENT_VIEW_CORE_IMPL_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 241 matching lines...) Expand 10 before | Expand all | Expand 10 after
252 const base::android::JavaParamRef<jobject>& obj, 252 const base::android::JavaParamRef<jobject>& obj,
253 jboolean textTracksEnabled, 253 jboolean textTracksEnabled,
254 const base::android::JavaParamRef<jstring>& textTrackBackgroundColor, 254 const base::android::JavaParamRef<jstring>& textTrackBackgroundColor,
255 const base::android::JavaParamRef<jstring>& textTrackFontFamily, 255 const base::android::JavaParamRef<jstring>& textTrackFontFamily,
256 const base::android::JavaParamRef<jstring>& textTrackFontStyle, 256 const base::android::JavaParamRef<jstring>& textTrackFontStyle,
257 const base::android::JavaParamRef<jstring>& textTrackFontVariant, 257 const base::android::JavaParamRef<jstring>& textTrackFontVariant,
258 const base::android::JavaParamRef<jstring>& textTrackTextColor, 258 const base::android::JavaParamRef<jstring>& textTrackTextColor,
259 const base::android::JavaParamRef<jstring>& textTrackTextShadow, 259 const base::android::JavaParamRef<jstring>& textTrackTextShadow,
260 const base::android::JavaParamRef<jstring>& textTrackTextSize); 260 const base::android::JavaParamRef<jstring>& textTrackTextSize);
261 261
262 void ExtractSmartClipData(JNIEnv* env,
263 const base::android::JavaParamRef<jobject>& obj,
264 jint x,
265 jint y,
266 jint width,
267 jint height);
268
269 void SetBackgroundOpaque(JNIEnv* env, 262 void SetBackgroundOpaque(JNIEnv* env,
270 const base::android::JavaParamRef<jobject>& jobj, 263 const base::android::JavaParamRef<jobject>& jobj,
271 jboolean opaque); 264 jboolean opaque);
272 265
273 bool IsTouchDragDropEnabled(JNIEnv* env, 266 bool IsTouchDragDropEnabled(JNIEnv* env,
274 const base::android::JavaParamRef<jobject>& jobj); 267 const base::android::JavaParamRef<jobject>& jobj);
275 268
276 void OnDragEvent(JNIEnv* env, 269 void OnDragEvent(JNIEnv* env,
277 const base::android::JavaParamRef<jobject>& jobj, 270 const base::android::JavaParamRef<jobject>& jobj,
278 jint action, 271 jint action,
279 jint x, 272 jint x,
280 jint y, 273 jint y,
281 jint screen_x, 274 jint screen_x,
282 jint screen_y, 275 jint screen_y,
283 const base::android::JavaParamRef<jobjectArray>& j_mimeTypes, 276 const base::android::JavaParamRef<jobjectArray>& j_mimeTypes,
284 const base::android::JavaParamRef<jstring>& j_content); 277 const base::android::JavaParamRef<jstring>& j_content);
285 278
286 jint GetCurrentRenderProcessId( 279 jint GetCurrentRenderProcessId(
287 JNIEnv* env, 280 JNIEnv* env,
288 const base::android::JavaParamRef<jobject>& obj); 281 const base::android::JavaParamRef<jobject>& obj);
289 282
290 // -------------------------------------------------------------------------- 283 // --------------------------------------------------------------------------
291 // Public methods that call to Java via JNI 284 // Public methods that call to Java via JNI
292 // -------------------------------------------------------------------------- 285 // --------------------------------------------------------------------------
293 286
294 void HidePopupsAndPreserveSelection(); 287 void HidePopupsAndPreserveSelection();
295 288
296 void OnSmartClipDataExtracted(const base::string16& text,
297 const base::string16& html,
298 const gfx::Rect& clip_rect);
299
300 // Creates a popup menu with |items|. 289 // Creates a popup menu with |items|.
301 // |multiple| defines if it should support multi-select. 290 // |multiple| defines if it should support multi-select.
302 // If not |multiple|, |selected_item| sets the initially selected item. 291 // If not |multiple|, |selected_item| sets the initially selected item.
303 // Otherwise, item's "checked" flag selects it. 292 // Otherwise, item's "checked" flag selects it.
304 void ShowSelectPopupMenu(RenderFrameHost* frame, 293 void ShowSelectPopupMenu(RenderFrameHost* frame,
305 const gfx::Rect& bounds, 294 const gfx::Rect& bounds,
306 const std::vector<MenuItem>& items, 295 const std::vector<MenuItem>& items,
307 int selected_item, 296 int selected_item,
308 bool multiple, 297 bool multiple,
309 bool right_aligned); 298 bool right_aligned);
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after
462 scoped_refptr<GinJavaBridgeDispatcherHost> java_bridge_dispatcher_host_; 451 scoped_refptr<GinJavaBridgeDispatcherHost> java_bridge_dispatcher_host_;
463 452
464 DISALLOW_COPY_AND_ASSIGN(ContentViewCoreImpl); 453 DISALLOW_COPY_AND_ASSIGN(ContentViewCoreImpl);
465 }; 454 };
466 455
467 bool RegisterContentViewCore(JNIEnv* env); 456 bool RegisterContentViewCore(JNIEnv* env);
468 457
469 } // namespace content 458 } // namespace content
470 459
471 #endif // CONTENT_BROWSER_ANDROID_CONTENT_VIEW_CORE_IMPL_H_ 460 #endif // CONTENT_BROWSER_ANDROID_CONTENT_VIEW_CORE_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698