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

Side by Side Diff: third_party/WebKit/Source/web/WebFrameWidgetImpl.cpp

Issue 2807433003: No pointer captured when the pointer lock is applied (Closed)
Patch Set: Change the tests and move code to WebFrameWidgetBase 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2014 Google Inc. All rights reserved. 2 * Copyright (C) 2014 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 359 matching lines...) Expand 10 before | Expand all | Expand 10 after
370 return WebInputEventResult::kNotHandled; 370 return WebInputEventResult::kNotHandled;
371 371
372 // FIXME: pass event to m_localRoot's WebDevToolsAgentImpl once available. 372 // FIXME: pass event to m_localRoot's WebDevToolsAgentImpl once available.
373 373
374 AutoReset<const WebInputEvent*> current_event_change(&current_input_event_, 374 AutoReset<const WebInputEvent*> current_event_change(&current_input_event_,
375 &input_event); 375 &input_event);
376 376
377 DCHECK(client_); 377 DCHECK(client_);
378 if (client_->IsPointerLocked() && 378 if (client_->IsPointerLocked() &&
379 WebInputEvent::IsMouseEventType(input_event.GetType())) { 379 WebInputEvent::IsMouseEventType(input_event.GetType())) {
380 PointerLockMouseEvent(input_event); 380 PointerLockMouseEvent(coalesced_event);
381 return WebInputEventResult::kHandledSystem; 381 return WebInputEventResult::kHandledSystem;
382 } 382 }
383 383
384 if (mouse_capture_node_ && 384 if (mouse_capture_node_ &&
385 WebInputEvent::IsMouseEventType(input_event.GetType())) { 385 WebInputEvent::IsMouseEventType(input_event.GetType())) {
386 TRACE_EVENT1("input", "captured mouse event", "type", 386 TRACE_EVENT1("input", "captured mouse event", "type",
387 input_event.GetType()); 387 input_event.GetType());
388 // Save m_mouseCaptureNode since mouseCaptureLost() will clear it. 388 // Save m_mouseCaptureNode since mouseCaptureLost() will clear it.
389 Node* node = mouse_capture_node_; 389 Node* node = mouse_capture_node_;
390 390
(...skipping 815 matching lines...) Expand 10 before | Expand all | Expand 10 after
1206 return nullptr; 1206 return nullptr;
1207 } 1207 }
1208 1208
1209 LocalFrame* WebFrameWidgetImpl::FocusedLocalFrameAvailableForIme() const { 1209 LocalFrame* WebFrameWidgetImpl::FocusedLocalFrameAvailableForIme() const {
1210 if (!ime_accept_events_) 1210 if (!ime_accept_events_)
1211 return nullptr; 1211 return nullptr;
1212 return FocusedLocalFrameInWidget(); 1212 return FocusedLocalFrameInWidget();
1213 } 1213 }
1214 1214
1215 } // namespace blink 1215 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698