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

Unified Diff: content/renderer/render_widget.h

Issue 130773004: Start moving context menu code to RenderFrame. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 6 years, 11 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 side-by-side diff with in-line comments
Download patch
Index: content/renderer/render_widget.h
===================================================================
--- content/renderer/render_widget.h (revision 247964)
+++ content/renderer/render_widget.h (working copy)
@@ -34,6 +34,7 @@
#include "third_party/skia/include/core/SkBitmap.h"
#include "ui/base/ime/text_input_mode.h"
#include "ui/base/ime/text_input_type.h"
+#include "ui/base/ui_base_types.h"
#include "ui/gfx/native_widget_types.h"
#include "ui/gfx/range/range.h"
#include "ui/gfx/rect.h"
@@ -248,6 +249,7 @@
// the new value will be sent to the browser process.
void UpdateSelectionBounds();
+ void OnShowHostContextMenu(ContextMenuParams* params);
#if defined(OS_MACOSX) || defined(OS_WIN) || defined(USE_AURA)
// Checks if the composition range or composition character bounds have been
@@ -259,6 +261,12 @@
// Temporary for debugging purposes...
bool closing() const { return closing_; }
+ ui::MenuSourceType context_menu_source_type() {
+ return context_menu_source_type_; }
+ gfx::Point touch_editing_context_menu_location() {
+ return touch_editing_context_menu_location_;
+ }
+
protected:
// Friend RefCounted so that the dtor can be non-public. Using this class
// without ref-counting is an error.
@@ -336,7 +344,6 @@
float root_layer_scale);
void SetExternalPopupOriginAdjustmentsForEmulation(
ExternalPopupMenu* popup, ScreenMetricsEmulator* emulator);
- virtual void OnShowHostContextMenu(ContextMenuParams* params);
// RenderWidget IPC message handlers
void OnHandleInputEvent(const blink::WebInputEvent* event,
@@ -519,12 +526,6 @@
// won't be sent to WebKit or trigger DidHandleMouseEvent().
virtual bool WillHandleMouseEvent(const blink::WebMouseEvent& event);
- // Called by OnHandleInputEvent() to notify subclasses that a key event is
- // about to be handled.
- // Returns true if no further handling is needed. In that case, the event
- // won't be sent to WebKit or trigger DidHandleKeyEvent().
- virtual bool WillHandleKeyEvent(const blink::WebKeyboardEvent& event);
-
// Called by OnHandleInputEvent() to notify subclasses that a gesture event is
// about to be handled.
// Returns true if no further handling is needed. In that case, the event
@@ -803,6 +804,9 @@
// of compositing-related events (e.g. DidCommitCompositorFrame).
ObserverList<RenderFrameImpl> swapped_out_frames_;
+ ui::MenuSourceType context_menu_source_type_;
+ gfx::Point touch_editing_context_menu_location_;
+
DISALLOW_COPY_AND_ASSIGN(RenderWidget);
};

Powered by Google App Engine
This is Rietveld 408576698