diff options
author | Allan Sandfeld Jensen <allan.jensen@qt.io> | 2019-05-20 14:17:47 +0200 |
---|---|---|
committer | Allan Sandfeld Jensen <allan.jensen@qt.io> | 2019-07-10 10:26:38 +0200 |
commit | 9cfde2edf4736ae9533e7e1fac495a23ad905419 (patch) | |
tree | 4eca639f54719a8824a527ee6a40fb13b462b110 /src/core/platform_notification_service_qt.cpp | |
parent | 0a01998411de6a46af8d0b0ae13b8f401cd14a4b (diff) |
Adaptations for Chromium 75
Change-Id: Idad08244e0c749a9f70f5eb9f8cd236039b941b3
Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
Diffstat (limited to 'src/core/platform_notification_service_qt.cpp')
-rw-r--r-- | src/core/platform_notification_service_qt.cpp | 31 |
1 files changed, 18 insertions, 13 deletions
diff --git a/src/core/platform_notification_service_qt.cpp b/src/core/platform_notification_service_qt.cpp index e9829c21f..d8abec17f 100644 --- a/src/core/platform_notification_service_qt.cpp +++ b/src/core/platform_notification_service_qt.cpp @@ -105,12 +105,13 @@ struct PersistentNotificationDelegate : UserNotificationController::Delegate { }; -PlatformNotificationServiceQt::PlatformNotificationServiceQt() {} +PlatformNotificationServiceQt::PlatformNotificationServiceQt(content::BrowserContext *browserContext) + : browser_context(browserContext) +{} PlatformNotificationServiceQt::~PlatformNotificationServiceQt() {} void PlatformNotificationServiceQt::DisplayNotification( - content::BrowserContext *browser_context, const std::string ¬ification_id, const GURL &origin, const blink::PlatformNotificationData ¬ificationData, @@ -131,7 +132,6 @@ void PlatformNotificationServiceQt::DisplayNotification( } void PlatformNotificationServiceQt::DisplayPersistentNotification( - content::BrowserContext *browser_context, const std::string ¬ification_id, const GURL &service_worker_origin, const GURL &origin, @@ -151,9 +151,7 @@ void PlatformNotificationServiceQt::DisplayPersistentNotification( client->showNotification(controller); } -void PlatformNotificationServiceQt::CloseNotification( - content::BrowserContext *browser_context, - const std::string ¬ification_id) +void PlatformNotificationServiceQt::CloseNotification(const std::string ¬ification_id) { Q_ASSERT(content::BrowserThread::CurrentlyOn(content::BrowserThread::UI)); ProfileQt *profile = static_cast<ProfileQt*>(browser_context); @@ -164,9 +162,7 @@ void PlatformNotificationServiceQt::CloseNotification( notificationController->closeNotification(); } -void PlatformNotificationServiceQt::ClosePersistentNotification( - content::BrowserContext *browser_context, - const std::string ¬ification_id) +void PlatformNotificationServiceQt::ClosePersistentNotification(const std::string ¬ification_id) { Q_ASSERT(content::BrowserThread::CurrentlyOn(content::BrowserThread::UI)); ProfileQt *profile = static_cast<ProfileQt*>(browser_context); @@ -177,9 +173,7 @@ void PlatformNotificationServiceQt::ClosePersistentNotification( notificationController->closeNotification(); } -void PlatformNotificationServiceQt::GetDisplayedNotifications( - content::BrowserContext *browser_context, - DisplayedNotificationsCallback callback) +void PlatformNotificationServiceQt::GetDisplayedNotifications(DisplayedNotificationsCallback callback) { Q_ASSERT(content::BrowserThread::CurrentlyOn(content::BrowserThread::UI)); ProfileQt *profile = static_cast<ProfileQt *>(browser_context); @@ -196,7 +190,7 @@ void PlatformNotificationServiceQt::GetDisplayedNotifications( std::move(callback).Run(std::move(movableStdStringSet), true /* supports_synchronization */); } -int64_t PlatformNotificationServiceQt::ReadNextPersistentNotificationId(content::BrowserContext *browser_context) +int64_t PlatformNotificationServiceQt::ReadNextPersistentNotificationId() { Q_ASSERT(content::BrowserThread::CurrentlyOn(content::BrowserThread::UI)); auto prefs = static_cast<ProfileQt *>(browser_context)->GetPrefs(); @@ -205,4 +199,15 @@ int64_t PlatformNotificationServiceQt::ReadNextPersistentNotificationId(content: return nextId; } +void PlatformNotificationServiceQt::ScheduleTrigger(base::Time /*timestamp*/) +{ + Q_UNIMPLEMENTED(); +} + +base::Time PlatformNotificationServiceQt::ReadNextTriggerTimestamp() +{ + Q_UNIMPLEMENTED(); + return base::Time::Max(); +} + } // namespace QtWebEngineCore |