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

Side by Side Diff: chrome/browser/ui/panels/panel.h

Issue 8775022: Add Panel::SetPanelBoundsInstantly for all platforms. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #ifndef CHROME_BROWSER_UI_PANELS_PANEL_H_ 5 #ifndef CHROME_BROWSER_UI_PANELS_PANEL_H_
6 #define CHROME_BROWSER_UI_PANELS_PANEL_H_ 6 #define CHROME_BROWSER_UI_PANELS_PANEL_H_
7 #pragma once 7 #pragma once
8 8
9 #include "chrome/browser/ui/browser_window.h" 9 #include "chrome/browser/ui/browser_window.h"
10 10
(...skipping 198 matching lines...) Expand 10 before | Expand all | Expand 10 after
209 209
210 // Panel must be initialized to be "fully created" and ready for use. 210 // Panel must be initialized to be "fully created" and ready for use.
211 // Only called by PanelManager. 211 // Only called by PanelManager.
212 bool initialized() const { return initialized_; } 212 bool initialized() const { return initialized_; }
213 void Initialize(const gfx::Rect& bounds); 213 void Initialize(const gfx::Rect& bounds);
214 214
215 // This is different from BrowserWindow::SetBounds(): 215 // This is different from BrowserWindow::SetBounds():
216 // * SetPanelBounds() is only called by PanelManager to manage its position. 216 // * SetPanelBounds() is only called by PanelManager to manage its position.
217 // * SetBounds() is called by the API to try to change the bounds, which is 217 // * SetBounds() is called by the API to try to change the bounds, which is
218 // not allowed for Panel. 218 // not allowed for Panel.
219 void SetPanelBounds(const gfx::Rect& bounds); 219 // Passing true to |animate| if bounds animation is required.
Dmitry Titov 2011/12/01 19:59:51 I think this comment says as much as the type and
jianli 2011/12/01 20:24:08 Done.
220 void SetPanelBounds(const gfx::Rect& bounds, bool animate);
220 221
221 // Sets whether the panel will auto resize according to its content. 222 // Sets whether the panel will auto resize according to its content.
222 void SetAutoResizable(bool resizable); 223 void SetAutoResizable(bool resizable);
223 224
224 // Sets minimum and maximum size for the panel. 225 // Sets minimum and maximum size for the panel.
225 void SetSizeRange(const gfx::Size& min_size, const gfx::Size& max_size); 226 void SetSizeRange(const gfx::Size& min_size, const gfx::Size& max_size);
226 227
227 protected: 228 protected:
228 virtual void DestroyBrowser() OVERRIDE; 229 virtual void DestroyBrowser() OVERRIDE;
229 230
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
275 NativePanel* native_panel_; // Weak, owns us. 276 NativePanel* native_panel_; // Weak, owns us.
276 277
277 ExpansionState expansion_state_; 278 ExpansionState expansion_state_;
278 279
279 content::NotificationRegistrar registrar_; 280 content::NotificationRegistrar registrar_;
280 281
281 DISALLOW_COPY_AND_ASSIGN(Panel); 282 DISALLOW_COPY_AND_ASSIGN(Panel);
282 }; 283 };
283 284
284 #endif // CHROME_BROWSER_UI_PANELS_PANEL_H_ 285 #endif // CHROME_BROWSER_UI_PANELS_PANEL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698