This source file includes following definitions.
- OnStarted
- Create
#include "chrome/browser/chromeos/ui/screen_capture_notification_ui_chromeos.h"
#include "ash/shell.h"
#include "ash/system/tray/system_tray_notifier.h"
#include "grit/generated_resources.h"
#include "ui/base/l10n/l10n_util.h"
namespace chromeos {
ScreenCaptureNotificationUIChromeOS::ScreenCaptureNotificationUIChromeOS(
const base::string16& text)
: text_(text) {
}
ScreenCaptureNotificationUIChromeOS::~ScreenCaptureNotificationUIChromeOS() {
ash::Shell::GetInstance()->system_tray_notifier()->NotifyScreenCaptureStop();
}
gfx::NativeViewId ScreenCaptureNotificationUIChromeOS::OnStarted(
const base::Closure& stop_callback) {
ash::Shell::GetInstance()->system_tray_notifier()->NotifyScreenCaptureStart(
stop_callback, text_);
return 0;
}
}
scoped_ptr<ScreenCaptureNotificationUI> ScreenCaptureNotificationUI::Create(
const base::string16& text) {
return scoped_ptr<ScreenCaptureNotificationUI>(
new chromeos::ScreenCaptureNotificationUIChromeOS(text));
}