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/ui/views/location_bar/content_setting_image_view.h" | 5 #include "chrome/browser/ui/views/location_bar/content_setting_image_view.h" |
6 | 6 |
7 #include "app/l10n_util.h" | 7 #include "app/l10n_util.h" |
8 #include "app/resource_bundle.h" | 8 #include "app/resource_bundle.h" |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/utf_string_conversions.h" | 10 #include "base/utf_string_conversions.h" |
11 #include "chrome/browser/content_setting_bubble_model.h" | 11 #include "chrome/browser/content_setting_bubble_model.h" |
12 #include "chrome/browser/content_setting_image_model.h" | 12 #include "chrome/browser/content_setting_image_model.h" |
13 #include "chrome/browser/tab_contents/tab_contents.h" | 13 #include "chrome/browser/tab_contents/tab_contents.h" |
14 #include "chrome/browser/tab_contents_wrapper.h" | 14 #include "chrome/browser/ui/tab_contents/tab_contents_wrapper.h" |
15 #include "chrome/browser/views/content_setting_bubble_contents.h" | 15 #include "chrome/browser/ui/views/content_setting_bubble_contents.h" |
16 #include "chrome/browser/views/location_bar/location_bar_view.h" | 16 #include "chrome/browser/ui/views/location_bar/location_bar_view.h" |
17 #include "chrome/common/chrome_switches.h" | 17 #include "chrome/common/chrome_switches.h" |
18 #include "gfx/canvas.h" | 18 #include "gfx/canvas.h" |
19 #include "gfx/canvas_skia.h" | 19 #include "gfx/canvas_skia.h" |
20 #include "gfx/skia_util.h" | 20 #include "gfx/skia_util.h" |
21 #include "third_party/skia/include/core/SkShader.h" | 21 #include "third_party/skia/include/core/SkShader.h" |
22 #include "views/border.h" | 22 #include "views/border.h" |
23 | 23 |
24 namespace { | 24 namespace { |
25 // Animation parameters. | 25 // Animation parameters. |
26 const int kOpenTimeMs = 150; | 26 const int kOpenTimeMs = 150; |
(...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
235 } else if (state > (1.0 - kAnimatingFraction)) { | 235 } else if (state > (1.0 - kAnimatingFraction)) { |
236 visible_text_size_ = static_cast<int>(text_size_ * (1.0 - state) / | 236 visible_text_size_ = static_cast<int>(text_size_ * (1.0 - state) / |
237 kAnimatingFraction); | 237 kAnimatingFraction); |
238 } else { | 238 } else { |
239 visible_text_size_ = text_size_; | 239 visible_text_size_ = text_size_; |
240 } | 240 } |
241 parent_->Layout(); | 241 parent_->Layout(); |
242 parent_->SchedulePaint(); | 242 parent_->SchedulePaint(); |
243 } | 243 } |
244 | 244 |
OLD | NEW |