2018-10-17 18:01:11 +00:00
|
|
|
// Copyright (c) 2015 GitHub, Inc.
|
|
|
|
// Use of this source code is governed by the MIT license that can be
|
|
|
|
// found in the LICENSE file.
|
|
|
|
|
2019-06-19 20:56:58 +00:00
|
|
|
#ifndef SHELL_BROWSER_NOTIFICATIONS_WIN_NOTIFICATION_PRESENTER_WIN7_H_
|
|
|
|
#define SHELL_BROWSER_NOTIFICATIONS_WIN_NOTIFICATION_PRESENTER_WIN7_H_
|
2018-10-17 18:01:11 +00:00
|
|
|
|
|
|
|
#include <string>
|
|
|
|
|
2019-06-19 20:46:59 +00:00
|
|
|
#include "shell/browser/notifications/notification_presenter.h"
|
|
|
|
#include "shell/browser/notifications/win/win32_desktop_notifications/desktop_notification_controller.h"
|
2018-10-17 18:01:11 +00:00
|
|
|
|
2019-06-19 21:23:04 +00:00
|
|
|
namespace electron {
|
2018-10-17 18:01:11 +00:00
|
|
|
|
|
|
|
class Win32Notification;
|
|
|
|
|
|
|
|
class NotificationPresenterWin7 : public NotificationPresenter,
|
|
|
|
public DesktopNotificationController {
|
|
|
|
public:
|
|
|
|
NotificationPresenterWin7() = default;
|
|
|
|
|
|
|
|
Win32Notification* GetNotificationObjectByRef(
|
|
|
|
const DesktopNotificationController::Notification& ref);
|
|
|
|
|
|
|
|
Win32Notification* GetNotificationObjectByTag(const std::string& tag);
|
|
|
|
|
|
|
|
private:
|
2019-06-19 21:23:04 +00:00
|
|
|
electron::Notification* CreateNotificationObject(
|
2018-10-17 18:01:11 +00:00
|
|
|
NotificationDelegate* delegate) override;
|
|
|
|
|
|
|
|
void OnNotificationClicked(const Notification& notification) override;
|
|
|
|
void OnNotificationDismissed(const Notification& notification) override;
|
|
|
|
|
|
|
|
DISALLOW_COPY_AND_ASSIGN(NotificationPresenterWin7);
|
|
|
|
};
|
|
|
|
|
2019-06-19 21:23:04 +00:00
|
|
|
} // namespace electron
|
2018-10-17 18:01:11 +00:00
|
|
|
|
2019-06-19 20:56:58 +00:00
|
|
|
#endif // SHELL_BROWSER_NOTIFICATIONS_WIN_NOTIFICATION_PRESENTER_WIN7_H_
|