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