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

Side by Side Diff: content/renderer/render_widget.cc

Issue 2431473003: Intersection Observer support for OOPIF (Closed)
Patch Set: Enabled test, fixed bugs Created 4 years, 1 month 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 #include "content/renderer/render_widget.h" 5 #include "content/renderer/render_widget.h"
6 6
7 #include <memory> 7 #include <memory>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/auto_reset.h" 10 #include "base/auto_reset.h"
(...skipping 484 matching lines...) Expand 10 before | Expand all | Expand 10 after
495 OnEnableDeviceEmulation) 495 OnEnableDeviceEmulation)
496 IPC_MESSAGE_HANDLER(ViewMsg_DisableDeviceEmulation, 496 IPC_MESSAGE_HANDLER(ViewMsg_DisableDeviceEmulation,
497 OnDisableDeviceEmulation) 497 OnDisableDeviceEmulation)
498 IPC_MESSAGE_HANDLER(ViewMsg_WasHidden, OnWasHidden) 498 IPC_MESSAGE_HANDLER(ViewMsg_WasHidden, OnWasHidden)
499 IPC_MESSAGE_HANDLER(ViewMsg_WasShown, OnWasShown) 499 IPC_MESSAGE_HANDLER(ViewMsg_WasShown, OnWasShown)
500 IPC_MESSAGE_HANDLER(ViewMsg_Repaint, OnRepaint) 500 IPC_MESSAGE_HANDLER(ViewMsg_Repaint, OnRepaint)
501 IPC_MESSAGE_HANDLER(ViewMsg_SetTextDirection, OnSetTextDirection) 501 IPC_MESSAGE_HANDLER(ViewMsg_SetTextDirection, OnSetTextDirection)
502 IPC_MESSAGE_HANDLER(ViewMsg_Move_ACK, OnRequestMoveAck) 502 IPC_MESSAGE_HANDLER(ViewMsg_Move_ACK, OnRequestMoveAck)
503 IPC_MESSAGE_HANDLER(ViewMsg_UpdateScreenRects, OnUpdateScreenRects) 503 IPC_MESSAGE_HANDLER(ViewMsg_UpdateScreenRects, OnUpdateScreenRects)
504 IPC_MESSAGE_HANDLER(ViewMsg_SetFrameSinkId, OnSetFrameSinkId) 504 IPC_MESSAGE_HANDLER(ViewMsg_SetFrameSinkId, OnSetFrameSinkId)
505 IPC_MESSAGE_HANDLER(ViewMsg_SetViewportIntersection,
506 OnSetViewportIntersection)
505 IPC_MESSAGE_HANDLER(ViewMsg_WaitForNextFrameForTests, 507 IPC_MESSAGE_HANDLER(ViewMsg_WaitForNextFrameForTests,
506 OnWaitNextFrameForTests) 508 OnWaitNextFrameForTests)
507 IPC_MESSAGE_HANDLER(InputMsg_RequestCompositionUpdate, 509 IPC_MESSAGE_HANDLER(InputMsg_RequestCompositionUpdate,
508 OnRequestCompositionUpdate) 510 OnRequestCompositionUpdate)
509 #if defined(OS_ANDROID) 511 #if defined(OS_ANDROID)
510 IPC_MESSAGE_HANDLER(InputMsg_ImeEventAck, OnImeEventAck) 512 IPC_MESSAGE_HANDLER(InputMsg_ImeEventAck, OnImeEventAck)
511 IPC_MESSAGE_HANDLER(InputMsg_RequestTextInputStateUpdate, 513 IPC_MESSAGE_HANDLER(InputMsg_RequestTextInputStateUpdate,
512 OnRequestTextInputStateUpdate) 514 OnRequestTextInputStateUpdate)
513 IPC_MESSAGE_HANDLER(InputMsg_ImeBatchEdit, 515 IPC_MESSAGE_HANDLER(InputMsg_ImeBatchEdit,
514 OnImeBatchEdit) 516 OnImeBatchEdit)
(...skipping 991 matching lines...) Expand 10 before | Expand all | Expand 10 after
1506 screen_metrics_emulator_->OnUpdateWindowScreenRect(window_screen_rect); 1508 screen_metrics_emulator_->OnUpdateWindowScreenRect(window_screen_rect);
1507 else 1509 else
1508 window_screen_rect_ = window_screen_rect; 1510 window_screen_rect_ = window_screen_rect;
1509 } 1511 }
1510 1512
1511 void RenderWidget::OnSetFrameSinkId(const cc::FrameSinkId& frame_sink_id) { 1513 void RenderWidget::OnSetFrameSinkId(const cc::FrameSinkId& frame_sink_id) {
1512 if (compositor_) 1514 if (compositor_)
1513 compositor_->SetFrameSinkId(frame_sink_id); 1515 compositor_->SetFrameSinkId(frame_sink_id);
1514 } 1516 }
1515 1517
1518 void RenderWidget::OnSetViewportIntersection(
1519 const gfx::Rect& viewport_intersection) {
1520 if (GetWebWidget())
1521 GetWebWidget()->setRemoteViewportIntersection(viewport_intersection);
1522 }
1523
1516 void RenderWidget::OnHandleCompositorProto(const std::vector<uint8_t>& proto) { 1524 void RenderWidget::OnHandleCompositorProto(const std::vector<uint8_t>& proto) {
1517 if (compositor_) 1525 if (compositor_)
1518 compositor_->OnHandleCompositorProto(proto); 1526 compositor_->OnHandleCompositorProto(proto);
1519 } 1527 }
1520 1528
1521 void RenderWidget::showImeIfNeeded() { 1529 void RenderWidget::showImeIfNeeded() {
1522 OnShowImeIfNeeded(); 1530 OnShowImeIfNeeded();
1523 } 1531 }
1524 1532
1525 ui::TextInputType RenderWidget::GetTextInputType() { 1533 ui::TextInputType RenderWidget::GetTextInputType() {
(...skipping 562 matching lines...) Expand 10 before | Expand all | Expand 10 after
2088 bool RenderWidget::isPointerLocked() { 2096 bool RenderWidget::isPointerLocked() {
2089 return mouse_lock_dispatcher_->IsMouseLockedTo( 2097 return mouse_lock_dispatcher_->IsMouseLockedTo(
2090 webwidget_mouse_lock_target_.get()); 2098 webwidget_mouse_lock_target_.get());
2091 } 2099 }
2092 2100
2093 blink::WebWidget* RenderWidget::GetWebWidget() const { 2101 blink::WebWidget* RenderWidget::GetWebWidget() const {
2094 return webwidget_internal_; 2102 return webwidget_internal_;
2095 } 2103 }
2096 2104
2097 } // namespace content 2105 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698