| Index: components/arc/storage_manager/arc_storage_manager.cc
|
| diff --git a/components/arc/storage_manager/arc_storage_manager.cc b/components/arc/storage_manager/arc_storage_manager.cc
|
| index f8cae30155e9faa45e2fb443bdc72acd4c4abc04..c87a065f91b65ae60a7cbf556e4b27ddf8ad5f30 100644
|
| --- a/components/arc/storage_manager/arc_storage_manager.cc
|
| +++ b/components/arc/storage_manager/arc_storage_manager.cc
|
| @@ -14,8 +14,6 @@ namespace arc {
|
|
|
| namespace {
|
|
|
| -const int kMinInstanceVersion = 1; // See storage_manager.mojom.
|
| -
|
| // This class is owned by ArcServiceManager so that it is safe to use this raw
|
| // pointer as the singleton reference.
|
| ArcStorageManager* g_arc_storage_manager = nullptr;
|
| @@ -40,9 +38,8 @@ ArcStorageManager* ArcStorageManager::Get() {
|
| }
|
|
|
| bool ArcStorageManager::OpenPrivateVolumeSettings() {
|
| - auto* storage_manager_instance =
|
| - arc_bridge_service()->storage_manager()->GetInstanceForMethod(
|
| - "OpenPrivateVolumeSettings", kMinInstanceVersion);
|
| + auto* storage_manager_instance = ARC_GET_INSTANCE_FOR_METHOD(
|
| + arc_bridge_service()->storage_manager(), OpenPrivateVolumeSettings);
|
| if (!storage_manager_instance)
|
| return false;
|
| storage_manager_instance->OpenPrivateVolumeSettings();
|
| @@ -51,9 +48,8 @@ bool ArcStorageManager::OpenPrivateVolumeSettings() {
|
|
|
| bool ArcStorageManager::GetApplicationsSize(
|
| const GetApplicationsSizeCallback& callback) {
|
| - auto* storage_manager_instance =
|
| - arc_bridge_service()->storage_manager()->GetInstanceForMethod(
|
| - "GetApplicationsSize", kMinInstanceVersion);
|
| + auto* storage_manager_instance = ARC_GET_INSTANCE_FOR_METHOD(
|
| + arc_bridge_service()->storage_manager(), GetApplicationsSize);
|
| if (!storage_manager_instance)
|
| return false;
|
| storage_manager_instance->GetApplicationsSize(callback);
|
| @@ -62,9 +58,8 @@ bool ArcStorageManager::GetApplicationsSize(
|
|
|
| bool ArcStorageManager::DeleteApplicationsCache(
|
| const base::Callback<void()>& callback) {
|
| - auto* storage_manager_instance =
|
| - arc_bridge_service()->storage_manager()->GetInstanceForMethod(
|
| - "DeleteApplicationsCache", kMinInstanceVersion);
|
| + auto* storage_manager_instance = ARC_GET_INSTANCE_FOR_METHOD(
|
| + arc_bridge_service()->storage_manager(), DeleteApplicationsCache);
|
| if (!storage_manager_instance)
|
| return false;
|
| storage_manager_instance->DeleteApplicationsCache(callback);
|
|
|