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

Side by Side Diff: chrome/browser/ui/android/context_menu_helper.h

Issue 1471993002: Resume cursor blinking on closing context menu (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: robusted onContextMenuClosed() and fixed nits Created 5 years 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 CHROME_BROWSER_UI_ANDROID_CONTEXT_MENU_HELPER_H_ 5 #ifndef CHROME_BROWSER_UI_ANDROID_CONTEXT_MENU_HELPER_H_
6 #define CHROME_BROWSER_UI_ANDROID_CONTEXT_MENU_HELPER_H_ 6 #define CHROME_BROWSER_UI_ANDROID_CONTEXT_MENU_HELPER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/android/jni_android.h" 10 #include "base/android/jni_android.h"
11 #include "base/callback.h" 11 #include "base/callback.h"
12 #include "base/memory/scoped_ptr.h" 12 #include "base/memory/scoped_ptr.h"
13 #include "content/public/browser/web_contents_user_data.h" 13 #include "content/public/browser/web_contents_user_data.h"
14 #include "content/public/common/context_menu_params.h" 14 #include "content/public/common/context_menu_params.h"
15 #include "ui/gfx/geometry/size.h" 15 #include "ui/gfx/geometry/size.h"
16 16
17 namespace content { 17 namespace content {
18 struct ContextMenuParams; 18 struct ContextMenuParams;
19 class WebContents; 19 class WebContents;
20 } 20 }
21 21
22 class ContextMenuHelper 22 class ContextMenuHelper
23 : public content::WebContentsUserData<ContextMenuHelper> { 23 : public content::WebContentsUserData<ContextMenuHelper> {
24 public: 24 public:
25 ~ContextMenuHelper() override; 25 ~ContextMenuHelper() override;
26 26
27 void ShowContextMenu(const content::ContextMenuParams& params); 27 bool ShowContextMenu(const content::ContextMenuParams& params);
28 28
29 void SetPopulator(jobject jpopulator); 29 void SetPopulator(jobject jpopulator);
30 30
31 // Methods called from Java via JNI ------------------------------------------ 31 // Methods called from Java via JNI ------------------------------------------
32 void OnStartDownload(JNIEnv* env, 32 void OnStartDownload(JNIEnv* env,
33 const base::android::JavaParamRef<jobject>& obj, 33 const base::android::JavaParamRef<jobject>& obj,
34 jboolean jis_link, 34 jboolean jis_link,
35 const base::android::JavaParamRef<jstring>& jheaders); 35 const base::android::JavaParamRef<jstring>& jheaders);
36 void SearchForImage(JNIEnv* env, 36 void SearchForImage(JNIEnv* env,
37 const base::android::JavaParamRef<jobject>& obj); 37 const base::android::JavaParamRef<jobject>& obj);
(...skipping 13 matching lines...) Expand all
51 content::WebContents* web_contents_; 51 content::WebContents* web_contents_;
52 52
53 content::ContextMenuParams context_menu_params_; 53 content::ContextMenuParams context_menu_params_;
54 54
55 DISALLOW_COPY_AND_ASSIGN(ContextMenuHelper); 55 DISALLOW_COPY_AND_ASSIGN(ContextMenuHelper);
56 }; 56 };
57 57
58 bool RegisterContextMenuHelper(JNIEnv* env); 58 bool RegisterContextMenuHelper(JNIEnv* env);
59 59
60 #endif // CHROME_BROWSER_UI_ANDROID_CONTEXT_MENU_HELPER_H_ 60 #endif // CHROME_BROWSER_UI_ANDROID_CONTEXT_MENU_HELPER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698