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

Unified Diff: third_party/WebKit/Source/core/frame/WebFrameWidgetBase.h

Issue 2910233002: Do not fallback to FocusedOrMainFrame() in FocusedLocalFrameInWidget() (Closed)
Patch Set: Addressing dcheng@'s comments Created 3 years, 7 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: third_party/WebKit/Source/core/frame/WebFrameWidgetBase.h
diff --git a/third_party/WebKit/Source/core/frame/WebFrameWidgetBase.h b/third_party/WebKit/Source/core/frame/WebFrameWidgetBase.h
index eecd3144c82ad584c71e0691039856a3df9cc180..634e00b84042aae984e44fdc00b8a74af1c244ff 100644
--- a/third_party/WebKit/Source/core/frame/WebFrameWidgetBase.h
+++ b/third_party/WebKit/Source/core/frame/WebFrameWidgetBase.h
@@ -105,6 +105,12 @@ class CORE_EXPORT WebFrameWidgetBase
// the page is shutting down, but will be valid at all other times.
Page* GetPage() const;
+ // This method returns the focused frame belonging to this WebWidget: that is
+ // a focused frame with the same local root as the one corresponding to this
+ // widget. It will return nullptr if no frame is focused or the focused frame
+ // has a different local root.
+ LocalFrame* FocusedLocalFrame() const;
+
// A copy of the web drop data object we received from the browser.
Persistent<DataObject> current_drag_data_;
@@ -121,9 +127,13 @@ class CORE_EXPORT WebFrameWidgetBase
// Helper function to process events while pointer locked.
void PointerLockMouseEvent(const WebCoalescedInputEvent&);
+ // TODO(ekaramad): Can we remove this and make sure IME events are not called
+ // when there is no page focus?
+ // Represents whether or not this object should process incoming IME events.
+ bool ime_accept_events_ = true;
+
private:
void CancelDrag();
- LocalFrame* FocusedLocalFrameInWidget() const;
static bool ignore_input_events_;
RefPtr<UserGestureToken> pointer_lock_gesture_token_;

Powered by Google App Engine
This is Rietveld 408576698