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

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: Fix per feedback 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 200 matching lines...) Expand 10 before | Expand all | Expand 10 after
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 void SetPanelBounds(const gfx::Rect& bounds);
220 220
221 // Updates the panel bounds instantly without any animation.
222 void SetPanelBoundsInstantly(const gfx::Rect& bounds);
223
221 // Sets whether the panel will auto resize according to its content. 224 // Sets whether the panel will auto resize according to its content.
222 void SetAutoResizable(bool resizable); 225 void SetAutoResizable(bool resizable);
223 226
224 // Sets minimum and maximum size for the panel. 227 // Sets minimum and maximum size for the panel.
225 void SetSizeRange(const gfx::Size& min_size, const gfx::Size& max_size); 228 void SetSizeRange(const gfx::Size& min_size, const gfx::Size& max_size);
226 229
227 protected: 230 protected:
228 virtual void DestroyBrowser() OVERRIDE; 231 virtual void DestroyBrowser() OVERRIDE;
229 232
230 private: 233 private:
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
275 NativePanel* native_panel_; // Weak, owns us. 278 NativePanel* native_panel_; // Weak, owns us.
276 279
277 ExpansionState expansion_state_; 280 ExpansionState expansion_state_;
278 281
279 content::NotificationRegistrar registrar_; 282 content::NotificationRegistrar registrar_;
280 283
281 DISALLOW_COPY_AND_ASSIGN(Panel); 284 DISALLOW_COPY_AND_ASSIGN(Panel);
282 }; 285 };
283 286
284 #endif // CHROME_BROWSER_UI_PANELS_PANEL_H_ 287 #endif // CHROME_BROWSER_UI_PANELS_PANEL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698