OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 #include "chrome/browser/download/download_started_animation.h" | 5 #include "chrome/browser/download/download_started_animation.h" |
6 | 6 |
7 #include <gtk/gtk.h> | 7 #include <gtk/gtk.h> |
8 | 8 |
9 #include "app/linear_animation.h" | 9 #include "app/linear_animation.h" |
10 #include "app/resource_bundle.h" | 10 #include "app/resource_bundle.h" |
11 #include "base/message_loop.h" | 11 #include "base/message_loop.h" |
12 #include "chrome/browser/tab_contents/tab_contents.h" | 12 #include "chrome/browser/tab_contents/tab_contents.h" |
13 #include "chrome/common/notification_registrar.h" | 13 #include "chrome/common/notification_registrar.h" |
14 #include "chrome/common/notification_service.h" | 14 #include "chrome/common/notification_source.h" |
15 #include "gfx/rect.h" | 15 #include "gfx/rect.h" |
16 #include "grit/theme_resources.h" | 16 #include "grit/theme_resources.h" |
17 | 17 |
18 namespace { | 18 namespace { |
19 | 19 |
20 // How long to spend moving downwards and fading out after waiting. | 20 // How long to spend moving downwards and fading out after waiting. |
21 const int kMoveTimeMs = 600; | 21 const int kMoveTimeMs = 600; |
22 | 22 |
23 // The animation framerate. | 23 // The animation framerate. |
24 const int kFrameRateHz = 60; | 24 const int kFrameRateHz = 60; |
(...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
185 Close(); | 185 Close(); |
186 } | 186 } |
187 | 187 |
188 } // namespace | 188 } // namespace |
189 | 189 |
190 // static | 190 // static |
191 void DownloadStartedAnimation::Show(TabContents* tab_contents) { | 191 void DownloadStartedAnimation::Show(TabContents* tab_contents) { |
192 // The animation will delete itself. | 192 // The animation will delete itself. |
193 new DownloadStartedAnimationGtk(tab_contents); | 193 new DownloadStartedAnimationGtk(tab_contents); |
194 } | 194 } |
OLD | NEW |