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

Side by Side Diff: ash/system/chromeos/network/network_icon_animation.h

Issue 12094072: Use ash NetworkIconAnimation in NetworkMenuIcon code (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 10 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
(Empty)
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef ASH_SYSTEM_CHROMEOS_NETWORK_NETWORK_ICON_ANIMATION_H_
6 #define ASH_SYSTEM_CHROMEOS_NETWORK_NETWORK_ICON_ANIMATION_H_
7
8 #include "ash/ash_export.h"
9 #include "base/observer_list.h"
10 #include "ui/base/animation/animation_delegate.h"
11 #include "ui/base/animation/throb_animation.h"
12
13 namespace ash {
14 namespace network_icon {
15
16 class AnimationObserver;
17
18 // Single instance class to handle icon animations and keep them in sync.
19 class ASH_EXPORT NetworkIconAnimation : public ui::AnimationDelegate {
20 public:
21 NetworkIconAnimation();
22 virtual ~NetworkIconAnimation();
23
24 double GetAnimation();
jennyz 2013/01/31 19:16:50 Please add a comment for GetAnimation method.
25
26 void AddObserver(AnimationObserver* observer);
27 void RemoveObserver(AnimationObserver* observer);
28
29 // ui::AnimationDelegate implementation.
30 virtual void AnimationProgressed(const ui::Animation* animation) OVERRIDE;
31
32 static NetworkIconAnimation* GetInstance();
33
34 private:
35 ui::ThrobAnimation animation_;
36 ObserverList<AnimationObserver> observers_;
37 };
38
39 } // namespace network_icon
40 } // namespace ash
41
42 #endif // ASH_SYSTEM_CHROMEOS_NETWORK_NETWORK_ICON_ANIMATION_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698