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

Side by Side Diff: ui/views/controls/throbber.h

Issue 273223002: views: Make view::Views::GetPreferredSize() const. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: More compile fix for ToT Created 6 years, 7 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
« no previous file with comments | « ui/views/controls/textfield/textfield.cc ('k') | ui/views/controls/throbber.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 UI_VIEWS_CONTROLS_THROBBER_H_ 5 #ifndef UI_VIEWS_CONTROLS_THROBBER_H_
6 #define UI_VIEWS_CONTROLS_THROBBER_H_ 6 #define UI_VIEWS_CONTROLS_THROBBER_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/time/time.h" 10 #include "base/time/time.h"
(...skipping 19 matching lines...) Expand all
30 virtual ~Throbber(); 30 virtual ~Throbber();
31 31
32 // Start and stop the throbber animation 32 // Start and stop the throbber animation
33 virtual void Start(); 33 virtual void Start();
34 virtual void Stop(); 34 virtual void Stop();
35 35
36 // Set custom throbber frames. Otherwise IDR_THROBBER is loaded. 36 // Set custom throbber frames. Otherwise IDR_THROBBER is loaded.
37 void SetFrames(const gfx::ImageSkia* frames); 37 void SetFrames(const gfx::ImageSkia* frames);
38 38
39 // Overridden from View: 39 // Overridden from View:
40 virtual gfx::Size GetPreferredSize() OVERRIDE; 40 virtual gfx::Size GetPreferredSize() const OVERRIDE;
41 virtual void OnPaint(gfx::Canvas* canvas) OVERRIDE; 41 virtual void OnPaint(gfx::Canvas* canvas) OVERRIDE;
42 42
43 protected: 43 protected:
44 // Specifies whether the throbber is currently animating or not 44 // Specifies whether the throbber is currently animating or not
45 bool running_; 45 bool running_;
46 46
47 private: 47 private:
48 void Run(); 48 void Run();
49 49
50 bool paint_while_stopped_; 50 bool paint_while_stopped_;
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
118 118
119 // The checkmark image. 119 // The checkmark image.
120 const gfx::ImageSkia* checkmark_; 120 const gfx::ImageSkia* checkmark_;
121 121
122 DISALLOW_COPY_AND_ASSIGN(CheckmarkThrobber); 122 DISALLOW_COPY_AND_ASSIGN(CheckmarkThrobber);
123 }; 123 };
124 124
125 } // namespace views 125 } // namespace views
126 126
127 #endif // UI_VIEWS_CONTROLS_THROBBER_H_ 127 #endif // UI_VIEWS_CONTROLS_THROBBER_H_
OLDNEW
« no previous file with comments | « ui/views/controls/textfield/textfield.cc ('k') | ui/views/controls/throbber.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698