From d7e4e8d6cc1d87c3e90426bbd2e4cca152b3ab65 Mon Sep 17 00:00:00 2001 From: Tony Ganch Date: Tue, 12 Sep 2017 15:32:11 +0000 Subject: [PATCH] Rename GetPrefferedSize to CalculatePrefferedSize See https://chromium-review.googlesource.com/c/chromium/src/+/516542 --- atom/browser/ui/views/frameless_view.cc | 2 +- atom/browser/ui/views/frameless_view.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/atom/browser/ui/views/frameless_view.cc b/atom/browser/ui/views/frameless_view.cc index 2ec4459f6b45..5182e1a0f7f1 100644 --- a/atom/browser/ui/views/frameless_view.cc +++ b/atom/browser/ui/views/frameless_view.cc @@ -98,7 +98,7 @@ void FramelessView::UpdateWindowTitle() { void FramelessView::SizeConstraintsChanged() { } -gfx::Size FramelessView::GetPreferredSize() const { +gfx::Size FramelessView::CalculatePreferredSize() const { return frame_->non_client_view()->GetWindowBoundsForClientBounds( gfx::Rect(frame_->client_view()->GetPreferredSize())).size(); } diff --git a/atom/browser/ui/views/frameless_view.h b/atom/browser/ui/views/frameless_view.h index 54dc3285fabc..112972c318ca 100644 --- a/atom/browser/ui/views/frameless_view.h +++ b/atom/browser/ui/views/frameless_view.h @@ -39,7 +39,7 @@ class FramelessView : public views::NonClientFrameView { void SizeConstraintsChanged() override; // Overridden from View: - gfx::Size GetPreferredSize() const override; + gfx::Size CalculatePreferredSize() const override; gfx::Size GetMinimumSize() const override; gfx::Size GetMaximumSize() const override; const char* GetClassName() const override;