OLD | NEW |
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 #include "chrome/browser/views/info_bubble.h" | 5 #include "chrome/browser/views/info_bubble.h" |
6 | 6 |
7 #include "base/win_util.h" | 7 #include "base/win_util.h" |
8 #include "chrome/app/theme/theme_resources.h" | 8 #include "grit/theme_resources.h" |
9 #include "chrome/browser/browser_window.h" | 9 #include "chrome/browser/browser_window.h" |
10 #include "chrome/browser/views/frame/browser_view.h" | 10 #include "chrome/browser/views/frame/browser_view.h" |
11 #include "chrome/common/gfx/chrome_canvas.h" | 11 #include "chrome/common/gfx/chrome_canvas.h" |
12 #include "chrome/common/gfx/path.h" | 12 #include "chrome/common/gfx/path.h" |
13 #include "chrome/common/resource_bundle.h" | 13 #include "chrome/common/resource_bundle.h" |
14 #include "chrome/common/win_util.h" | 14 #include "chrome/common/win_util.h" |
15 #include "chrome/views/root_view.h" | 15 #include "chrome/views/root_view.h" |
16 #include "chrome/views/window.h" | 16 #include "chrome/views/window.h" |
17 | 17 |
18 using views::View; | 18 using views::View; |
(...skipping 398 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
417 x -= kArrowXOffset; | 417 x -= kArrowXOffset; |
418 else | 418 else |
419 x = x + kArrowXOffset - pref.width(); | 419 x = x + kArrowXOffset - pref.width(); |
420 if (IsTop()) { | 420 if (IsTop()) { |
421 y = position_relative_to.bottom() + kArrowToContentPadding; | 421 y = position_relative_to.bottom() + kArrowToContentPadding; |
422 } else { | 422 } else { |
423 y = position_relative_to.y() - kArrowToContentPadding - pref.height(); | 423 y = position_relative_to.y() - kArrowToContentPadding - pref.height(); |
424 } | 424 } |
425 return gfx::Rect(x, y, pref.width(), pref.height()); | 425 return gfx::Rect(x, y, pref.width(), pref.height()); |
426 } | 426 } |
OLD | NEW |