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

Side by Side Diff: chrome/browser/views/info_bubble.h

Issue 7344: Convert GetPreferredSize from:... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 12 years, 2 months 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) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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_VIEWS_INFO_BUBBLE_H_ 5 #ifndef CHROME_BROWSER_VIEWS_INFO_BUBBLE_H_
6 #define CHROME_BROWSER_VIEWS_INFO_BUBBLE_H_ 6 #define CHROME_BROWSER_VIEWS_INFO_BUBBLE_H_
7 7
8 #include "chrome/common/slide_animation.h" 8 #include "chrome/common/slide_animation.h"
9 #include "chrome/views/hwnd_view_container.h" 9 #include "chrome/views/hwnd_view_container.h"
10 #include "chrome/views/view.h" 10 #include "chrome/views/view.h"
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 // the arrow edge is adjusted. 100 // the arrow edge is adjusted.
101 virtual gfx::Rect CalculateWindowBounds( 101 virtual gfx::Rect CalculateWindowBounds(
102 HWND parent_hwnd, 102 HWND parent_hwnd,
103 const gfx::Rect& position_relative_to); 103 const gfx::Rect& position_relative_to);
104 104
105 // Sets the edge the arrow is rendered at. 105 // Sets the edge the arrow is rendered at.
106 void SetArrowEdge(ArrowEdge arrow_edge) { arrow_edge_ = arrow_edge; } 106 void SetArrowEdge(ArrowEdge arrow_edge) { arrow_edge_ = arrow_edge; }
107 107
108 // Returns the preferred size, which is the sum of the preferred size of 108 // Returns the preferred size, which is the sum of the preferred size of
109 // the content and the border/arrow. 109 // the content and the border/arrow.
110 virtual void GetPreferredSize(CSize* pref); 110 virtual gfx::Size GetPreferredSize();
111 111
112 // Positions the content relative to the border. 112 // Positions the content relative to the border.
113 virtual void Layout(); 113 virtual void Layout();
114 114
115 virtual void DidChangeBounds(const CRect& previous, const CRect& current) { 115 virtual void DidChangeBounds(const CRect& previous, const CRect& current) {
116 Layout(); 116 Layout();
117 } 117 }
118 118
119 // Return the mask for the content view. 119 // Return the mask for the content view.
120 HRGN GetMask(const CSize& size); 120 HRGN GetMask(const CSize& size);
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
160 ContentView* content_view_; 160 ContentView* content_view_;
161 161
162 // The fade-in animation. 162 // The fade-in animation.
163 scoped_ptr<SlideAnimation> fade_animation_; 163 scoped_ptr<SlideAnimation> fade_animation_;
164 164
165 DISALLOW_COPY_AND_ASSIGN(InfoBubble); 165 DISALLOW_COPY_AND_ASSIGN(InfoBubble);
166 }; 166 };
167 167
168 #endif // CHROME_BROWSER_VIEWS_INFO_BUBBLE_H_ 168 #endif // CHROME_BROWSER_VIEWS_INFO_BUBBLE_H_
169 169
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698