OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/panels/panel_browser_view.h" | 5 #include "chrome/browser/ui/panels/panel_browser_view.h" |
6 | 6 |
7 #include "base/logging.h" | 7 #include "base/logging.h" |
8 #include "chrome/browser/ui/panels/panel.h" | 8 #include "chrome/browser/ui/panels/panel.h" |
9 #include "chrome/browser/ui/panels/panel_browser_frame_view.h" | 9 #include "chrome/browser/ui/panels/panel_browser_frame_view.h" |
10 #include "chrome/browser/ui/panels/panel_manager.h" | 10 #include "chrome/browser/ui/panels/panel_manager.h" |
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
47 is_drawing_attention_(false), | 47 is_drawing_attention_(false), |
48 old_focused_view_(NULL) { | 48 old_focused_view_(NULL) { |
49 } | 49 } |
50 | 50 |
51 PanelBrowserView::~PanelBrowserView() { | 51 PanelBrowserView::~PanelBrowserView() { |
52 } | 52 } |
53 | 53 |
54 void PanelBrowserView::Init() { | 54 void PanelBrowserView::Init() { |
55 BrowserView::Init(); | 55 BrowserView::Init(); |
56 | 56 |
57 GetWidget()->SetAlwaysOnTop(true); | |
58 GetWidget()->non_client_view()->SetAccessibleName( | 57 GetWidget()->non_client_view()->SetAccessibleName( |
59 l10n_util::GetStringUTF16(IDS_PRODUCT_NAME)); | 58 l10n_util::GetStringUTF16(IDS_PRODUCT_NAME)); |
60 } | 59 } |
61 | 60 |
62 void PanelBrowserView::Close() { | 61 void PanelBrowserView::Close() { |
63 GetWidget()->RemoveObserver(this); | 62 GetWidget()->RemoveObserver(this); |
64 closed_ = true; | 63 closed_ = true; |
65 | 64 |
66 // Cancel any currently running animation since we're closing down. | 65 // Cancel any currently running animation since we're closing down. |
67 if (bounds_animator_.get()) | 66 if (bounds_animator_.get()) |
(...skipping 393 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
461 panel_browser_view_->mouse_pressed_point_.y() + delta_y)); | 460 panel_browser_view_->mouse_pressed_point_.y() + delta_y)); |
462 } | 461 } |
463 | 462 |
464 void NativePanelTestingWin::CancelDragTitlebar() { | 463 void NativePanelTestingWin::CancelDragTitlebar() { |
465 panel_browser_view_->OnTitlebarMouseCaptureLost(); | 464 panel_browser_view_->OnTitlebarMouseCaptureLost(); |
466 } | 465 } |
467 | 466 |
468 void NativePanelTestingWin::FinishDragTitlebar() { | 467 void NativePanelTestingWin::FinishDragTitlebar() { |
469 panel_browser_view_->OnTitlebarMouseReleased(); | 468 panel_browser_view_->OnTitlebarMouseReleased(); |
470 } | 469 } |
OLD | NEW |