2013-12-18 21:02:49 +00:00
|
|
|
// Copyright (c) 2012 The Chromium Authors. All rights reserved.
|
2013-12-19 05:20:00 +00:00
|
|
|
// Copyright (c) 2013 Patrick Reynolds <piki@github.com>. All rights reserved.
|
2013-12-18 21:02:49 +00:00
|
|
|
// Use of this source code is governed by a BSD-style license that can be
|
|
|
|
// found in the LICENSE-CHROMIUM file.
|
|
|
|
|
2017-05-18 22:58:12 +00:00
|
|
|
#include "brightray/browser/linux/notification_presenter_linux.h"
|
2013-12-18 21:02:49 +00:00
|
|
|
|
2017-05-18 22:58:12 +00:00
|
|
|
#include "brightray/browser/linux/libnotify_notification.h"
|
2015-04-20 20:22:18 +00:00
|
|
|
|
2013-12-18 21:02:49 +00:00
|
|
|
namespace brightray {
|
|
|
|
|
2014-07-27 10:27:41 +00:00
|
|
|
// static
|
2013-12-18 21:02:49 +00:00
|
|
|
NotificationPresenter* NotificationPresenter::Create() {
|
2015-12-25 03:52:19 +00:00
|
|
|
if (!LibnotifyNotification::Initialize())
|
2015-12-24 02:46:08 +00:00
|
|
|
return nullptr;
|
2015-12-25 03:52:19 +00:00
|
|
|
return new NotificationPresenterLinux;
|
2013-12-18 21:02:49 +00:00
|
|
|
}
|
|
|
|
|
2018-04-18 01:56:12 +00:00
|
|
|
NotificationPresenterLinux::NotificationPresenterLinux() {}
|
2013-12-19 05:05:19 +00:00
|
|
|
|
2018-04-18 01:56:12 +00:00
|
|
|
NotificationPresenterLinux::~NotificationPresenterLinux() {}
|
2013-12-18 21:02:49 +00:00
|
|
|
|
2017-04-03 08:38:21 +00:00
|
|
|
Notification* NotificationPresenterLinux::CreateNotificationObject(
|
|
|
|
NotificationDelegate* delegate) {
|
2017-01-10 15:34:41 +00:00
|
|
|
return new LibnotifyNotification(delegate, this);
|
|
|
|
}
|
|
|
|
|
2013-12-19 19:06:05 +00:00
|
|
|
} // namespace brightray
|