| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/message_center/web_notification_tray.h" | 5 #include "chrome/browser/ui/views/message_center/web_notification_tray.h" |
| 6 | 6 |
| 7 #include <windows.h> | 7 #include <windows.h> |
| 8 #include "base/win/windows_version.h" | 8 #include "base/win/windows_version.h" |
| 9 #include "chrome/browser/app_icon_win.h" | 9 #include "chrome/browser/app_icon_win.h" |
| 10 #include "chrome/browser/profiles/profile_manager.h" | 10 #include "chrome/browser/profiles/profile_manager.h" |
| 11 #include "chrome/browser/status_icons/status_icon.h" | 11 #include "chrome/browser/status_icons/status_icon.h" |
| 12 #include "chrome/browser/ui/browser.h" | 12 #include "chrome/browser/ui/browser.h" |
| 13 #include "chrome/browser/ui/host_desktop.h" | 13 #include "chrome/browser/ui/host_desktop.h" |
| 14 #include "chrome/browser/ui/scoped_tabbed_browser_displayer.h" | 14 #include "chrome/browser/ui/scoped_tabbed_browser_displayer.h" |
| 15 #include "chrome/browser/ui/singleton_tabs.h" | 15 #include "chrome/browser/ui/singleton_tabs.h" |
| 16 #include "chrome/common/url_constants.h" | 16 #include "chrome/common/url_constants.h" |
| 17 #include "chrome/grit/chromium_strings.h" | 17 #include "chrome/grit/chromium_strings.h" |
| 18 #include "third_party/skia/include/core/SkBitmap.h" | 18 #include "third_party/skia/include/core/SkBitmap.h" |
| 19 #include "ui/base/l10n/l10n_util.h" | 19 #include "ui/base/l10n/l10n_util.h" |
| 20 #include "ui/gfx/host_desktop_type.h" |
| 20 #include "ui/gfx/image/image_skia.h" | 21 #include "ui/gfx/image/image_skia.h" |
| 21 | 22 |
| 22 namespace message_center { | 23 namespace message_center { |
| 23 void WebNotificationTray::OnBalloonClicked() { | 24 void WebNotificationTray::OnBalloonClicked() { |
| 24 chrome::ScopedTabbedBrowserDisplayer displayer( | 25 chrome::ScopedTabbedBrowserDisplayer displayer( |
| 25 ProfileManager::GetLastUsedProfileAllowedByPolicy(), | 26 ProfileManager::GetLastUsedProfileAllowedByPolicy(), |
| 26 chrome::GetActiveDesktop()); | 27 chrome::GetActiveDesktop()); |
| 27 chrome::ShowSingletonTab(displayer.browser(), | 28 chrome::ShowSingletonTab(displayer.browser(), |
| 28 GURL(chrome::kNotificationsHelpURL)); | 29 GURL(chrome::kNotificationsHelpURL)); |
| 29 } | 30 } |
| (...skipping 24 matching lines...) Expand all Loading... |
| 54 l10n_util::GetStringUTF16(IDS_MESSAGE_CENTER_BALLOON_TITLE), | 55 l10n_util::GetStringUTF16(IDS_MESSAGE_CENTER_BALLOON_TITLE), |
| 55 l10n_util::GetStringUTF16(IDS_MESSAGE_CENTER_BALLOON_TEXT)); | 56 l10n_util::GetStringUTF16(IDS_MESSAGE_CENTER_BALLOON_TEXT)); |
| 56 } | 57 } |
| 57 | 58 |
| 58 void WebNotificationTray::EnforceStatusIconVisible() { | 59 void WebNotificationTray::EnforceStatusIconVisible() { |
| 59 DCHECK(status_icon_); | 60 DCHECK(status_icon_); |
| 60 status_icon_->ForceVisible(); | 61 status_icon_->ForceVisible(); |
| 61 } | 62 } |
| 62 | 63 |
| 63 } // namespace message_center | 64 } // namespace message_center |
| OLD | NEW |