diff options
author | jennb@chromium.org <jennb@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-05-02 22:39:40 +0000 |
---|---|---|
committer | jennb@chromium.org <jennb@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-05-02 22:39:40 +0000 |
commit | 857361e582aca29b3c03e867876a00ec7466c7ec (patch) | |
tree | 972678c57c2940a945a5f00aa5958799c2f0f5a9 | |
parent | 68c7630b3ae6738e5b9ebb1998b3184fa930463c (diff) | |
download | chromium_src-857361e582aca29b3c03e867876a00ec7466c7ec.zip chromium_src-857361e582aca29b3c03e867876a00ec7466c7ec.tar.gz chromium_src-857361e582aca29b3c03e867876a00ec7466c7ec.tar.bz2 |
Update Panel mininimize/restore button on strip and expansion state change.
Previously code for each platform was doing it at draw/bounds change/layout.
Also removed nearby code that was obsoleted by overflow strip removal.
BUG=125039,125054
TEST=minimize/restore panels and drag them to/from dock. verify buttons update.
Review URL: http://codereview.chromium.org/10260028
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@135012 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | chrome/browser/ui/panels/detached_panel_strip.cc | 5 | ||||
-rw-r--r-- | chrome/browser/ui/panels/docked_panel_strip.cc | 6 | ||||
-rw-r--r-- | chrome/browser/ui/panels/native_panel.h | 7 | ||||
-rw-r--r-- | chrome/browser/ui/panels/panel.cc | 16 | ||||
-rw-r--r-- | chrome/browser/ui/panels/panel.h | 8 | ||||
-rw-r--r-- | chrome/browser/ui/panels/panel_browser_frame_view.cc | 82 | ||||
-rw-r--r-- | chrome/browser/ui/panels/panel_browser_frame_view.h | 1 | ||||
-rw-r--r-- | chrome/browser/ui/panels/panel_browser_titlebar_gtk.cc | 13 | ||||
-rw-r--r-- | chrome/browser/ui/panels/panel_browser_view.cc | 24 | ||||
-rw-r--r-- | chrome/browser/ui/panels/panel_browser_view.h | 2 | ||||
-rw-r--r-- | chrome/browser/ui/panels/panel_browser_window_cocoa.h | 2 | ||||
-rw-r--r-- | chrome/browser/ui/panels/panel_browser_window_cocoa.mm | 8 | ||||
-rw-r--r-- | chrome/browser/ui/panels/panel_browser_window_gtk.cc | 10 | ||||
-rw-r--r-- | chrome/browser/ui/panels/panel_browser_window_gtk.h | 2 | ||||
-rw-r--r-- | chrome/browser/ui/panels/panel_window_controller_cocoa.mm | 2 |
15 files changed, 78 insertions, 110 deletions
diff --git a/chrome/browser/ui/panels/detached_panel_strip.cc b/chrome/browser/ui/panels/detached_panel_strip.cc index af1697e..595e69a 100644 --- a/chrome/browser/ui/panels/detached_panel_strip.cc +++ b/chrome/browser/ui/panels/detached_panel_strip.cc @@ -38,13 +38,13 @@ void DetachedPanelStrip::AddPanel(Panel* panel, PositioningMask positioning_mask) { // positioning_mask is ignored since the detached panel is free-floating. DCHECK_NE(this, panel->panel_strip()); - panel->SetPanelStrip(this); + panel->set_panel_strip(this); panels_.insert(panel); } void DetachedPanelStrip::RemovePanel(Panel* panel) { DCHECK_EQ(this, panel->panel_strip()); - panel->SetPanelStrip(NULL); + panel->set_panel_strip(NULL); panels_.erase(panel); } @@ -196,6 +196,7 @@ void DetachedPanelStrip::UpdatePanelOnStripChange(Panel* panel) { Panel::USE_SYSTEM_ATTENTION)); panel->SetAlwaysOnTop(false); panel->EnableResizeByMouse(true); + panel->UpdateMinimizeRestoreButtonVisibility(); } void DetachedPanelStrip::OnPanelActiveStateChanged(Panel* panel) { diff --git a/chrome/browser/ui/panels/docked_panel_strip.cc b/chrome/browser/ui/panels/docked_panel_strip.cc index db2a1db..1b116d3 100644 --- a/chrome/browser/ui/panels/docked_panel_strip.cc +++ b/chrome/browser/ui/panels/docked_panel_strip.cc @@ -99,7 +99,7 @@ void DockedPanelStrip::AddPanel(Panel* panel, DCHECK_EQ(Panel::EXPANDED, panel->expansion_state()); DCHECK_NE(this, panel->panel_strip()); - panel->SetPanelStrip(this); + panel->set_panel_strip(this); bool known_position = (positioning_mask & KNOWN_POSITION) != 0; bool update_bounds = (positioning_mask & DO_NOT_UPDATE_BOUNDS) == 0; @@ -217,7 +217,7 @@ int DockedPanelStrip::GetRightMostAvailablePosition() const { void DockedPanelStrip::RemovePanel(Panel* panel) { DCHECK_EQ(this, panel->panel_strip()); - panel->SetPanelStrip(NULL); + panel->set_panel_strip(NULL); // Removing an element from the list will invalidate the iterator that refers // to it. We need to update the iterator in that case. @@ -883,9 +883,9 @@ void DockedPanelStrip::UpdatePanelOnStripChange(Panel* panel) { gfx::Size(max_panel_width, max_panel_height)); } panel->set_attention_mode(Panel::USE_PANEL_ATTENTION); - panel->SetAppIconVisibility(true); panel->SetAlwaysOnTop(true); panel->EnableResizeByMouse(true); + panel->UpdateMinimizeRestoreButtonVisibility(); } void DockedPanelStrip::OnPanelActiveStateChanged(Panel* panel) { diff --git a/chrome/browser/ui/panels/native_panel.h b/chrome/browser/ui/panels/native_panel.h index 072cd82..9ac3a95 100644 --- a/chrome/browser/ui/panels/native_panel.h +++ b/chrome/browser/ui/panels/native_panel.h @@ -81,15 +81,14 @@ class NativePanel { // will make sure that the panel is not obscured by other top-most windows. virtual void EnsurePanelFullyVisible() = 0; - // Sets whether the panel app icon is visible (usually refers to the app icons - // in the desktop bar). - virtual void SetPanelAppIconVisibility(bool visible) = 0; - // Sets whether the panel window is always on top. virtual void SetPanelAlwaysOnTop(bool on_top) = 0; // Enables resizing by dragging edges/corners. virtual void EnableResizeByMouse(bool enable) = 0; + + // Updates the visibility of the minimize and restore buttons. + virtual void UpdatePanelMinimizeRestoreButtonVisibility() = 0; }; // A NativePanel utility interface used for accessing elements of the diff --git a/chrome/browser/ui/panels/panel.cc b/chrome/browser/ui/panels/panel.cc index 7c89a8a0..3b6ed1a 100644 --- a/chrome/browser/ui/panels/panel.cc +++ b/chrome/browser/ui/panels/panel.cc @@ -157,11 +157,6 @@ gfx::Size Panel::ClampSize(const gfx::Size& size) const { return gfx::Size(new_width, new_height); } - -void Panel::SetAppIconVisibility(bool visible) { - native_panel_->SetPanelAppIconVisibility(visible); -} - void Panel::SetAlwaysOnTop(bool on_top) { if (always_on_top_ == on_top) return; @@ -174,17 +169,15 @@ void Panel::EnableResizeByMouse(bool enable) { native_panel_->EnableResizeByMouse(enable); } +void Panel::UpdateMinimizeRestoreButtonVisibility() { + native_panel_->UpdatePanelMinimizeRestoreButtonVisibility(); +} + void Panel::SetPreviewMode(bool in_preview) { DCHECK_NE(in_preview_mode_, in_preview); in_preview_mode_ = in_preview; } -void Panel::SetPanelStrip(PanelStrip* new_strip) { - panel_strip_ = new_strip; - if (panel_strip_ != NULL && initialized_) - native_panel_->PreventActivationByOS(panel_strip_->IsPanelMinimized(this)); -} - void Panel::SetExpansionState(ExpansionState new_state) { if (expansion_state_ == new_state) return; @@ -194,6 +187,7 @@ void Panel::SetExpansionState(ExpansionState new_state) { DCHECK(initialized_ && panel_strip_ != NULL); native_panel_->PreventActivationByOS(panel_strip_->IsPanelMinimized(this)); + UpdateMinimizeRestoreButtonVisibility(); content::NotificationService::current()->Notify( chrome::NOTIFICATION_PANEL_CHANGED_EXPANSION_STATE, diff --git a/chrome/browser/ui/panels/panel.h b/chrome/browser/ui/panels/panel.h index 477c5ac..aa26789 100644 --- a/chrome/browser/ui/panels/panel.h +++ b/chrome/browser/ui/panels/panel.h @@ -242,7 +242,7 @@ class Panel : public BrowserWindow, PanelStrip* panel_strip() const { return panel_strip_; } // Sets the current panel strip that contains this panel. - void SetPanelStrip(PanelStrip* new_strip); + void set_panel_strip(PanelStrip* new_strip) { panel_strip_ = new_strip; } ExpansionState expansion_state() const { return expansion_state_; } const gfx::Size& min_size() const { return min_size_; } @@ -283,9 +283,6 @@ class Panel : public BrowserWindow, // Sets minimum and maximum size for the panel. void SetSizeRange(const gfx::Size& min_size, const gfx::Size& max_size); - // Sets whether the panel app icon is visible in the taskbar. - void SetAppIconVisibility(bool visible); - // Whether the panel window is always on top. void SetAlwaysOnTop(bool on_top); bool always_on_top() const { return always_on_top_; } @@ -298,6 +295,9 @@ class Panel : public BrowserWindow, // enables the resize mouse cursors when mouse is hovering over the edges. void EnableResizeByMouse(bool enable); + // Sets whether the minimize or restore button, if any, are visible. + void UpdateMinimizeRestoreButtonVisibility(); + // Changes the preferred size to acceptable based on min_size() and max_size() gfx::Size ClampSize(const gfx::Size& size) const; diff --git a/chrome/browser/ui/panels/panel_browser_frame_view.cc b/chrome/browser/ui/panels/panel_browser_frame_view.cc index 45b39a9..b31d83e 100644 --- a/chrome/browser/ui/panels/panel_browser_frame_view.cc +++ b/chrome/browser/ui/panels/panel_browser_frame_view.cc @@ -312,6 +312,7 @@ PanelBrowserFrameView::PanelBrowserFrameView(BrowserFrame* frame, restore_button_resources.hover_image); restore_button_->SetTooltipText(restore_button_resources.tooltip_text); restore_button_->SetAccessibleName(restore_button_resources.tooltip_text); + restore_button_->SetVisible(false); // only visible when panel is minimized AddChildView(restore_button_); title_icon_ = new TabIconView(this); @@ -465,48 +466,27 @@ void PanelBrowserFrameView::Layout() { if (!panel_strip) return; - // Check if the width is only enough to show only the icon, or both icon - // and title. Hide corresponding controls accordingly. - // TODO(aburago) Make sure the close button is always visible even if the - // panel is too narrow. - bool show_close_button = true; - bool show_title_label = true; - bool show_restore_button = panel->CanRestore(); - bool show_minimize_button = panel->CanMinimize(); - - close_button_->SetVisible(show_close_button); - minimize_button_->SetVisible(show_minimize_button); - restore_button_->SetVisible(show_restore_button); - title_label_->SetVisible(show_title_label); - // Layout the close button. int right = width(); - if (show_close_button) { - gfx::Size close_button_size = close_button_->GetPreferredSize(); - close_button_->SetBounds( - width() - NonClientBorderThickness() - kCloseButtonAndBorderSpacing - - close_button_size.width(), - (NonClientTopBorderHeight() - close_button_size.height()) / 2, - close_button_size.width(), - close_button_size.height()); - right = close_button_->x(); - } - - // Layout the minimize/restore button. - views::ImageButton* minimize_or_restore_button = NULL; - if (show_minimize_button) - minimize_or_restore_button = minimize_button_; - else if (show_restore_button) - minimize_or_restore_button = restore_button_; - if (minimize_or_restore_button) { - gfx::Size button_size = minimize_or_restore_button->GetPreferredSize(); - minimize_or_restore_button->SetBounds( - right - kMinimizeButtonAndCloseButtonSpacing - button_size.width(), - (NonClientTopBorderHeight() - button_size.height()) / 2, - button_size.width(), - button_size.height()); - right = minimize_or_restore_button->x(); - } + gfx::Size close_button_size = close_button_->GetPreferredSize(); + close_button_->SetBounds( + width() - NonClientBorderThickness() - kCloseButtonAndBorderSpacing - + close_button_size.width(), + (NonClientTopBorderHeight() - close_button_size.height()) / 2, + close_button_size.width(), + close_button_size.height()); + right = close_button_->x(); + + // Layout the minimize and restore button. Both occupy the same space, + // but at most one is visible at any time. + gfx::Size button_size = minimize_button_->GetPreferredSize(); + minimize_button_->SetBounds( + right - kMinimizeButtonAndCloseButtonSpacing - button_size.width(), + (NonClientTopBorderHeight() - button_size.height()) / 2, + button_size.width(), + button_size.height()); + restore_button_->SetBoundsRect(minimize_button_->bounds()); + right = minimize_button_->x(); // Layout the icon. int icon_y = (NonClientTopBorderHeight() - kIconSize) / 2; @@ -517,15 +497,13 @@ void PanelBrowserFrameView::Layout() { kIconSize); // Layout the title. - if (show_title_label) { - int title_x = title_icon_->bounds().right() + kTitleSpacing; - int title_height = BrowserFrame::GetTitleFont().GetHeight(); - title_label_->SetBounds( - title_x, - icon_y + ((kIconSize - title_height - 1) / 2), - std::max(0, right - kTitleSpacing - title_x), - title_height); - } + int title_x = title_icon_->bounds().right() + kTitleSpacing; + int title_height = BrowserFrame::GetTitleFont().GetHeight(); + title_label_->SetBounds( + title_x, + icon_y + ((kIconSize - title_height - 1) / 2), + std::max(0, right - kTitleSpacing - title_x), + title_height); // Calculate the client area bounds. int top_height = NonClientTopBorderHeight(); @@ -811,6 +789,12 @@ void PanelBrowserFrameView::UpdateTitleBar() { title_label_->SetText(GetTitleText()); } +void PanelBrowserFrameView::UpdateTitleBarMinimizeRestoreButtonVisibility() { + Panel* panel = panel_browser_view_->panel(); + minimize_button_->SetVisible(panel->CanMinimize()); + restore_button_->SetVisible(panel->CanRestore()); +} + bool PanelBrowserFrameView::CanResize() const { return panel_browser_view_->panel()->CanResizeByMouse() != panel::NOT_RESIZABLE; diff --git a/chrome/browser/ui/panels/panel_browser_frame_view.h b/chrome/browser/ui/panels/panel_browser_frame_view.h index 02a01e0..953b19c 100644 --- a/chrome/browser/ui/panels/panel_browser_frame_view.h +++ b/chrome/browser/ui/panels/panel_browser_frame_view.h @@ -35,6 +35,7 @@ class PanelBrowserFrameView : public BrowserNonClientFrameView, virtual ~PanelBrowserFrameView(); void UpdateTitleBar(); + void UpdateTitleBarMinimizeRestoreButtonVisibility(); // Returns the height of the entire nonclient top border, including the window // frame, any title area, and any connected client edge. diff --git a/chrome/browser/ui/panels/panel_browser_titlebar_gtk.cc b/chrome/browser/ui/panels/panel_browser_titlebar_gtk.cc index 04231a5..bad34c6 100644 --- a/chrome/browser/ui/panels/panel_browser_titlebar_gtk.cc +++ b/chrome/browser/ui/panels/panel_browser_titlebar_gtk.cc @@ -97,11 +97,18 @@ bool PanelBrowserTitlebarGtk::BuildButton(const std::string& button_token, if (button_token != "close" && button_token != "minimize") return false; - // Create unminimze button in order to show it to expand the minimized panel. - if (button_token == "minimize") + if (!BrowserTitlebar::BuildButton(button_token, left_side)) + return false; + + if (button_token == "minimize") { + // Create unminimze button, used to expand the minimized panel. unminimize_button_.reset(CreateTitlebarButton("unminimize", left_side)); - return BrowserTitlebar::BuildButton(button_token, left_side); + // We control visibility of minimize and unminimize buttons. + gtk_widget_set_no_show_all(minimize_button()->widget(), TRUE); + gtk_widget_set_no_show_all(unminimize_button_->widget(), TRUE); + } + return true; } void PanelBrowserTitlebarGtk::GetButtonResources(const std::string& button_name, diff --git a/chrome/browser/ui/panels/panel_browser_view.cc b/chrome/browser/ui/panels/panel_browser_view.cc index 6d37281..9c279dc 100644 --- a/chrome/browser/ui/panels/panel_browser_view.cc +++ b/chrome/browser/ui/panels/panel_browser_view.cc @@ -513,25 +513,6 @@ bool PanelBrowserView::EndDragging(bool cancelled) { return true; } -void PanelBrowserView::SetPanelAppIconVisibility(bool visible) { -#if defined(OS_WIN) && !defined(USE_AURA) - gfx::NativeWindow native_window = GetNativeHandle(); - int style = ::GetWindowLong(native_window, GWL_EXSTYLE); - int new_style = style; - if (visible) - new_style &= (~WS_EX_TOOLWINDOW); - else - new_style |= WS_EX_TOOLWINDOW; - if (style != new_style) { - ::ShowWindow(native_window, SW_HIDE); - ::SetWindowLong(native_window, GWL_EXSTYLE, new_style); - ::ShowWindow(native_window, SW_SHOWNA); - } -#else - NOTIMPLEMENTED(); -#endif -} - void PanelBrowserView::SetPanelAlwaysOnTop(bool on_top) { GetWidget()->SetAlwaysOnTop(on_top); GetWidget()->non_client_view()->Layout(); @@ -545,6 +526,11 @@ bool PanelBrowserView::IsAnimatingBounds() const { void PanelBrowserView::EnableResizeByMouse(bool enable) { } +void PanelBrowserView::UpdatePanelMinimizeRestoreButtonVisibility() { + GetFrameView()->UpdateTitleBarMinimizeRestoreButtonVisibility(); +} + + #if defined(OS_WIN) && !defined(USE_AURA) void PanelBrowserView::UpdateWindowAttribute(int attribute_index, int attribute_value, diff --git a/chrome/browser/ui/panels/panel_browser_view.h b/chrome/browser/ui/panels/panel_browser_view.h index 7cdf79c..ab2aa63 100644 --- a/chrome/browser/ui/panels/panel_browser_view.h +++ b/chrome/browser/ui/panels/panel_browser_view.h @@ -122,9 +122,9 @@ class PanelBrowserView : public BrowserView, virtual Browser* GetPanelBrowser() const OVERRIDE; virtual void DestroyPanelBrowser() OVERRIDE; virtual void EnsurePanelFullyVisible() OVERRIDE; - virtual void SetPanelAppIconVisibility(bool visible) OVERRIDE; virtual void SetPanelAlwaysOnTop(bool on_top) OVERRIDE; virtual void EnableResizeByMouse(bool enable) OVERRIDE; + virtual void UpdatePanelMinimizeRestoreButtonVisibility() OVERRIDE; // Overridden from AnimationDelegate: virtual void AnimationEnded(const ui::Animation* animation) OVERRIDE; diff --git a/chrome/browser/ui/panels/panel_browser_window_cocoa.h b/chrome/browser/ui/panels/panel_browser_window_cocoa.h index 1897bbd..3b23eaf 100644 --- a/chrome/browser/ui/panels/panel_browser_window_cocoa.h +++ b/chrome/browser/ui/panels/panel_browser_window_cocoa.h @@ -62,9 +62,9 @@ class PanelBrowserWindowCocoa : public NativePanel, virtual Browser* GetPanelBrowser() const OVERRIDE; virtual void DestroyPanelBrowser() OVERRIDE; virtual void EnsurePanelFullyVisible() OVERRIDE; - virtual void SetPanelAppIconVisibility(bool visible) OVERRIDE; virtual void SetPanelAlwaysOnTop(bool on_top) OVERRIDE; virtual void EnableResizeByMouse(bool enable) OVERRIDE; + virtual void UpdatePanelMinimizeRestoreButtonVisibility() OVERRIDE; // These sizes are in screen coordinates. virtual gfx::Size WindowSizeFromContentSize( diff --git a/chrome/browser/ui/panels/panel_browser_window_cocoa.mm b/chrome/browser/ui/panels/panel_browser_window_cocoa.mm index 5c71ec1..4cc8918 100644 --- a/chrome/browser/ui/panels/panel_browser_window_cocoa.mm +++ b/chrome/browser/ui/panels/panel_browser_window_cocoa.mm @@ -284,10 +284,6 @@ void PanelBrowserWindowCocoa::EnsurePanelFullyVisible() { [controller_ ensureFullyVisible]; } -void PanelBrowserWindowCocoa::SetPanelAppIconVisibility(bool visible) { - // TODO(dimich): to be implemented. -} - void PanelBrowserWindowCocoa::SetPanelAlwaysOnTop(bool on_top) { [controller_ updateWindowLevel]; } @@ -296,6 +292,10 @@ void PanelBrowserWindowCocoa::EnableResizeByMouse(bool enable) { [controller_ enableResizeByMouse:enable]; } +void PanelBrowserWindowCocoa::UpdatePanelMinimizeRestoreButtonVisibility() { + [controller_ updateTitleBarMinimizeRestoreButtonVisibility]; +} + void PanelBrowserWindowCocoa::DidCloseNativeWindow() { DCHECK(!isClosed()); panel_->OnNativePanelClosed(); diff --git a/chrome/browser/ui/panels/panel_browser_window_gtk.cc b/chrome/browser/ui/panels/panel_browser_window_gtk.cc index 44f0fd3..75f352f 100644 --- a/chrome/browser/ui/panels/panel_browser_window_gtk.cc +++ b/chrome/browser/ui/panels/panel_browser_window_gtk.cc @@ -304,8 +304,6 @@ const gfx::Image* PanelBrowserWindowGtk::GetThemeFrameImage() const { void PanelBrowserWindowGtk::DrawCustomFrame(cairo_t* cr, GtkWidget* widget, GdkEventExpose* event) { - GetPanelTitlebar()->UpdateMinimizeRestoreButtonVisibility(); - gfx::CairoCachedSurface* surface = GetThemeFrameImage()->ToCairo(); surface->SetSource(cr, widget, 0, 0); @@ -501,10 +499,6 @@ void PanelBrowserWindowGtk::EnsurePanelFullyVisible() { gtk_window_present(window()); } -void PanelBrowserWindowGtk::SetPanelAppIconVisibility(bool visible) { - return; -} - void PanelBrowserWindowGtk::SetPanelAlwaysOnTop(bool on_top) { gtk_window_set_keep_above(window(), on_top); } @@ -512,6 +506,10 @@ void PanelBrowserWindowGtk::SetPanelAlwaysOnTop(bool on_top) { void PanelBrowserWindowGtk::EnableResizeByMouse(bool enable) { } +void PanelBrowserWindowGtk::UpdatePanelMinimizeRestoreButtonVisibility() { + GetPanelTitlebar()->UpdateMinimizeRestoreButtonVisibility(); +} + gfx::Size PanelBrowserWindowGtk::WindowSizeFromContentSize( const gfx::Size& content_size) const { return gfx::Size(content_size.width() + frame_size_.width(), diff --git a/chrome/browser/ui/panels/panel_browser_window_gtk.h b/chrome/browser/ui/panels/panel_browser_window_gtk.h index 64928c1..4d4e62c 100644 --- a/chrome/browser/ui/panels/panel_browser_window_gtk.h +++ b/chrome/browser/ui/panels/panel_browser_window_gtk.h @@ -113,9 +113,9 @@ class PanelBrowserWindowGtk : public BrowserWindowGtk, const gfx::Size& window_size) const OVERRIDE; virtual int TitleOnlyHeight() const OVERRIDE; virtual void EnsurePanelFullyVisible() OVERRIDE; - virtual void SetPanelAppIconVisibility(bool visible) OVERRIDE; virtual void SetPanelAlwaysOnTop(bool on_top) OVERRIDE; virtual void EnableResizeByMouse(bool enable) OVERRIDE; + virtual void UpdatePanelMinimizeRestoreButtonVisibility() OVERRIDE; private: friend class NativePanelTestingGtk; diff --git a/chrome/browser/ui/panels/panel_window_controller_cocoa.mm b/chrome/browser/ui/panels/panel_window_controller_cocoa.mm index e436291..cfb5b8d 100644 --- a/chrome/browser/ui/panels/panel_window_controller_cocoa.mm +++ b/chrome/browser/ui/panels/panel_window_controller_cocoa.mm @@ -774,8 +774,6 @@ enum { - (void)setPanelFrame:(NSRect)frame animate:(BOOL)animate { - [self updateTitleBarMinimizeRestoreButtonVisibility]; - BOOL jumpToDestination = (!animateOnBoundsChange_ || !animate); // If no animation is in progress, apply bounds change instantly. |