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

Side by Side Diff: content/browser/renderer_host/render_widget_host_view_aura.cc

Issue 1078123002: Send resize event when the screen info changes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: simpler Created 5 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
« no previous file with comments | « content/browser/renderer_host/render_widget_host_unittest.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/browser/renderer_host/render_widget_host_view_aura.h" 5 #include "content/browser/renderer_host/render_widget_host_view_aura.h"
6 6
7 #include <set> 7 #include <set>
8 8
9 #include "base/auto_reset.h" 9 #include "base/auto_reset.h"
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 2514 matching lines...) Expand 10 before | Expand all | Expand 10 after
2525 has_snapped_to_boundary_ = true; 2525 has_snapped_to_boundary_ = true;
2526 } 2526 }
2527 2527
2528 void RenderWidgetHostViewAura::OnShowContextMenu() { 2528 void RenderWidgetHostViewAura::OnShowContextMenu() {
2529 #if defined(OS_WIN) 2529 #if defined(OS_WIN)
2530 showing_context_menu_ = true; 2530 showing_context_menu_ = true;
2531 #endif 2531 #endif
2532 } 2532 }
2533 2533
2534 void RenderWidgetHostViewAura::InternalSetBounds(const gfx::Rect& rect) { 2534 void RenderWidgetHostViewAura::InternalSetBounds(const gfx::Rect& rect) {
2535 if (HasDisplayPropertyChanged(window_))
2536 host_->InvalidateScreenInfo();
2537
2538 SnapToPhysicalPixelBoundary(); 2535 SnapToPhysicalPixelBoundary();
2539 // Don't recursively call SetBounds if this bounds update is the result of 2536 // Don't recursively call SetBounds if this bounds update is the result of
2540 // a Window::SetBoundsInternal call. 2537 // a Window::SetBoundsInternal call.
2541 if (!in_bounds_changed_) 2538 if (!in_bounds_changed_)
2542 window_->SetBounds(rect); 2539 window_->SetBounds(rect);
2543 host_->WasResized(); 2540 host_->WasResized();
2544 delegated_frame_host_->WasResized(); 2541 delegated_frame_host_->WasResized();
2545 if (touch_editing_client_) { 2542 if (touch_editing_client_) {
2546 touch_editing_client_->OnSelectionOrCursorChanged(selection_anchor_, 2543 touch_editing_client_->OnSelectionOrCursorChanged(selection_anchor_,
2547 selection_focus_); 2544 selection_focus_);
(...skipping 216 matching lines...) Expand 10 before | Expand all | Expand 10 after
2764 2761
2765 //////////////////////////////////////////////////////////////////////////////// 2762 ////////////////////////////////////////////////////////////////////////////////
2766 // RenderWidgetHostViewBase, public: 2763 // RenderWidgetHostViewBase, public:
2767 2764
2768 // static 2765 // static
2769 void RenderWidgetHostViewBase::GetDefaultScreenInfo(WebScreenInfo* results) { 2766 void RenderWidgetHostViewBase::GetDefaultScreenInfo(WebScreenInfo* results) {
2770 GetScreenInfoForWindow(results, NULL); 2767 GetScreenInfoForWindow(results, NULL);
2771 } 2768 }
2772 2769
2773 } // namespace content 2770 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/renderer_host/render_widget_host_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698