Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(56)

Side by Side Diff: chrome/browser/extensions/api/image_writer_private/image_writer_private_api.cc

Issue 2152373003: [Extensions] Code Cleanup - Remove redundant smart-ptr get()s (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/logging.h" 5 #include "base/logging.h"
6 #include "chrome/browser/extensions/api/file_handlers/app_file_handler_util.h" 6 #include "chrome/browser/extensions/api/file_handlers/app_file_handler_util.h"
7 #include "chrome/browser/extensions/api/image_writer_private/error_messages.h" 7 #include "chrome/browser/extensions/api/image_writer_private/error_messages.h"
8 #include "chrome/browser/extensions/api/image_writer_private/image_writer_privat e_api.h" 8 #include "chrome/browser/extensions/api/image_writer_private/image_writer_privat e_api.h"
9 #include "chrome/browser/extensions/api/image_writer_private/operation_manager.h " 9 #include "chrome/browser/extensions/api/image_writer_private/operation_manager.h "
10 #include "chrome/browser/profiles/profile.h" 10 #include "chrome/browser/profiles/profile.h"
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after
170 base::Bind( 170 base::Bind(
171 &ImageWriterPrivateListRemovableStorageDevicesFunction::OnDeviceListReady, 171 &ImageWriterPrivateListRemovableStorageDevicesFunction::OnDeviceListReady,
172 this)); 172 this));
173 return true; 173 return true;
174 } 174 }
175 175
176 void ImageWriterPrivateListRemovableStorageDevicesFunction::OnDeviceListReady( 176 void ImageWriterPrivateListRemovableStorageDevicesFunction::OnDeviceListReady(
177 scoped_refptr<StorageDeviceList> device_list, 177 scoped_refptr<StorageDeviceList> device_list,
178 bool success) { 178 bool success) {
179 if (success) { 179 if (success) {
180 results_ = 180 results_ = image_writer_api::ListRemovableStorageDevices::Results::Create(
181 image_writer_api::ListRemovableStorageDevices::Results::Create( 181 device_list->data);
182 device_list.get()->data);
183 SendResponse(true); 182 SendResponse(true);
184 } else { 183 } else {
185 error_ = image_writer::error::kDeviceListError; 184 error_ = image_writer::error::kDeviceListError;
186 SendResponse(false); 185 SendResponse(false);
187 } 186 }
188 } 187 }
189 188
190 } // namespace extensions 189 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698