Chromium Code Reviews| Index: chrome/browser/ui/panels/panel_manager.cc |
| diff --git a/chrome/browser/ui/panels/panel_manager.cc b/chrome/browser/ui/panels/panel_manager.cc |
| index 22195b606c1c80206c556c8db69655958b77c525..5d64f612e52b30168344c0ddb04e2ca5e3c1e5ea 100644 |
| --- a/chrome/browser/ui/panels/panel_manager.cc |
| +++ b/chrome/browser/ui/panels/panel_manager.cc |
| @@ -174,16 +174,22 @@ void PanelManager::EndDragging(bool cancelled) { |
| } |
| void PanelManager::OnPanelExpansionStateChanged(Panel* panel) { |
| - docked_strip_->OnPanelExpansionStateChanged(panel); |
| + // For panels outside of the docked strip changing state is a no-op |
|
jennb
2012/03/12 18:26:27
Maybe reword to say "...but this method may be cal
|
| + // but we still allow it to be called because panels can |
| + // jump from strip to strip virtually at any moment. |
|
jianli
2012/03/12 18:08:56
Your comment seems not to be consistent with if ch
|
| + if (panel->panel_strip() == docked_strip_.get()) |
| + docked_strip_->OnPanelExpansionStateChanged(panel); |
| } |
| void PanelManager::OnWindowAutoResized(Panel* panel, |
| const gfx::Size& preferred_window_size) { |
| DCHECK(auto_sizing_enabled_); |
| + // DCHECK(panel->panel_strip() == docked_strip_.get()); |
|
jianli
2012/03/12 18:08:56
Why is DCHECK commented out?
|
| docked_strip_->ResizePanelWindow(panel, preferred_window_size); |
| } |
| void PanelManager::ResizePanel(Panel* panel, const gfx::Size& new_size) { |
| + // DCHECK(panel->panel_strip() == docked_strip_.get()); |
|
jianli
2012/03/12 18:08:56
ditto.
|
| docked_strip_->ResizePanelWindow(panel, new_size); |
| panel->SetAutoResizable(false); |
| } |