sources += [
"autofill_popup_view_efl.cc",
"autofill_popup_view_efl.h",
+ "browser/background_sync_controller_efl.cc",
+ "browser/background_sync_controller_efl.h",
"browser/browsing_data_remover_efl.cc",
"browser/browsing_data_remover_efl.h",
"browser/download_manager_delegate_efl.cc",
--- /dev/null
+// Copyright 2020 Samsung Electronics. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "background_sync_controller_efl.h"
+
+base::TimeDelta BackgroundSyncControllerEfl::GetNextEventDelay(
+ const content::BackgroundSyncRegistration& registration,
+ content::BackgroundSyncParameters* parameters,
+ base::TimeDelta time_till_soonest_scheduled_event_for_origin) {
+ NOTIMPLEMENTED();
+ return base::TimeDelta::Max();
+}
+
+std::unique_ptr<content::BackgroundSyncController::BackgroundSyncEventKeepAlive>
+BackgroundSyncControllerEfl::CreateBackgroundSyncEventKeepAlive() {
+ NOTIMPLEMENTED();
+ return nullptr;
+}
--- /dev/null
+// Copyright 2020 Samsung Electronics. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef BACKGROUND_SYNC_CONTROLLER_EFL_H_
+#define BACKGROUND_SYNC_CONTROLLER_EFL_H_
+
+#include "content/public/browser/background_sync_controller.h"
+
+class BackgroundSyncControllerEfl : public content::BackgroundSyncController {
+ public:
+ BackgroundSyncControllerEfl() = default;
+ ~BackgroundSyncControllerEfl() override = default;
+
+ private:
+ // content::BackgroundSyncController overrides.
+ base::TimeDelta GetNextEventDelay(
+ const content::BackgroundSyncRegistration& registration,
+ content::BackgroundSyncParameters* parameters,
+ base::TimeDelta time_till_soonest_scheduled_event_for_origin) override;
+ std::unique_ptr<BackgroundSyncController::BackgroundSyncEventKeepAlive>
+ CreateBackgroundSyncEventKeepAlive() override;
+ void NoteSuspendedPeriodicSyncOrigins(
+ std::set<url::Origin> suspended_origins) override {}
+ void NoteRegisteredPeriodicSyncOrigins(
+ std::set<url::Origin> registered_origins) override {}
+ void AddToTrackedOrigins(const url::Origin& origin) override {}
+ void RemoveFromTrackedOrigins(const url::Origin& origin) override {}
+};
+
+#endif // BACKGROUND_SYNC_CONTROLLER_EFL_H_
#include "base/path_service.h"
#include "base/synchronization/waitable_event.h"
#include "browser/autofill/personal_data_manager_factory.h"
+#include "browser/background_sync_controller_efl.h"
#include "browser/geolocation/geolocation_permission_context_efl.h"
#include "browser/webdata/web_data_service_factory.h"
#include "components/autofill/core/browser/personal_data_manager.h"
}
BackgroundSyncController* BrowserContextEfl::GetBackgroundSyncController() {
- return nullptr;
+ if (!background_sync_controller_)
+ background_sync_controller_.reset(new BackgroundSyncControllerEfl());
+ return background_sync_controller_.get();
}
void BrowserContextEfl::CreateNetworkDelegate() {
const bool incognito_;
std::unique_ptr<net::NetworkDelegate> network_delegate_for_getter_;
std::unique_ptr<SSLHostStateDelegateEfl> ssl_host_state_delegate_;
+ std::unique_ptr<BackgroundSyncController> background_sync_controller_;
std::unique_ptr<PermissionControllerDelegate> permission_controller_delegate_;
DISALLOW_COPY_AND_ASSIGN(BrowserContextEfl);
const GURL& requesting_origin,
const GURL& embedding_origin) {
switch (permission) {
+ case PermissionType::BACKGROUND_SYNC:
#if defined(ENABLE_NOTIFICATIONS)
case PermissionType::NOTIFICATIONS: {
// requesting_origin should be the same as embedding_origin