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

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

Issue 6622002: Do all OOLing in the views code. linux_views now builds clean with the clang plugin. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 9 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 // Throbbers display an animation, usually used as a status indicator. 5 // Throbbers display an animation, usually used as a status indicator.
6 6
7 #ifndef VIEWS_CONTROLS_THROBBER_H_ 7 #ifndef VIEWS_CONTROLS_THROBBER_H_
8 #define VIEWS_CONTROLS_THROBBER_H_ 8 #define VIEWS_CONTROLS_THROBBER_H_
9 #pragma once 9 #pragma once
10 10
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 }; 56 };
57 57
58 // A SmoothedThrobber is a throbber that is representing potentially short 58 // A SmoothedThrobber is a throbber that is representing potentially short
59 // and nonoverlapping bursts of work. SmoothedThrobber ignores small 59 // and nonoverlapping bursts of work. SmoothedThrobber ignores small
60 // pauses in the work stops and starts, and only starts its throbber after 60 // pauses in the work stops and starts, and only starts its throbber after
61 // a small amount of work time has passed. 61 // a small amount of work time has passed.
62 class SmoothedThrobber : public Throbber { 62 class SmoothedThrobber : public Throbber {
63 public: 63 public:
64 SmoothedThrobber(int frame_delay_ms); 64 SmoothedThrobber(int frame_delay_ms);
65 SmoothedThrobber(int frame_delay_ms, SkBitmap* frames); 65 SmoothedThrobber(int frame_delay_ms, SkBitmap* frames);
66 virtual ~SmoothedThrobber();
66 67
67 virtual void Start(); 68 virtual void Start();
68 virtual void Stop(); 69 virtual void Stop();
69 70
70 void set_start_delay_ms(int value) { start_delay_ms_ = value; } 71 void set_start_delay_ms(int value) { start_delay_ms_ = value; }
71 void set_stop_delay_ms(int value) { stop_delay_ms_ = value; } 72 void set_stop_delay_ms(int value) { stop_delay_ms_ = value; }
72 73
73 private: 74 private:
74 // Called when the startup-delay timer fires 75 // Called when the startup-delay timer fires
75 // This function starts the actual throbbing. 76 // This function starts the actual throbbing.
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
117 118
118 // The checkmark image. 119 // The checkmark image.
119 static SkBitmap* checkmark_; 120 static SkBitmap* checkmark_;
120 121
121 DISALLOW_COPY_AND_ASSIGN(CheckmarkThrobber); 122 DISALLOW_COPY_AND_ASSIGN(CheckmarkThrobber);
122 }; 123 };
123 124
124 } // namespace views 125 } // namespace views
125 126
126 #endif // VIEWS_CONTROLS_THROBBER_H_ 127 #endif // VIEWS_CONTROLS_THROBBER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698