Skip to content

Commit

Permalink
Rewrite apps::SavedDevicesService as extensions::DevicePermissionsMan…
Browse files Browse the repository at this point in the history
…ager.

This service doesn't need any Chrome dependencies after all and so it
can move into //extensions. This will make it possible for the USB
extensions API code to directly depend on it. In the process I have
rewritten the service with a couple improvements:

* C++11 for-each loops are used instead of explicit iterators.
* The DevicePermissions object is no longer an inner class (so it can
  be forward declared) and it is explicitly copied when requested so
  that the ownership of data on the FILE and UI threads is clear.

BUG=

Review URL: https://codereview.chromium.org/606503002

Cr-Commit-Position: refs/heads/master@{#297230}
  • Loading branch information
reillyeon authored and Commit bot committed Sep 29, 2014
1 parent e01e6de commit bc82d3c
Show file tree
Hide file tree
Showing 17 changed files with 596 additions and 576 deletions.
5 changes: 0 additions & 5 deletions apps/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,6 @@ static_library("apps") {
"launcher.cc",
"launcher.h",
"metrics_names.h",
"saved_devices_service.cc",
"saved_devices_service.h",
"saved_devices_service_factory.cc",
"saved_devices_service_factory.h",
"saved_files_service.cc",
"saved_files_service.h",
"saved_files_service_factory.cc",
Expand All @@ -45,7 +41,6 @@ static_library("apps") {
"//chrome/browser/extensions",
"//chrome/common/extensions/api:api",
"//components/web_modal",
"//device/usb",
"//skia",
]

Expand Down
1 change: 0 additions & 1 deletion apps/DEPS
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ include_rules = [
"+components/sessions",
"+components/user_manager",
"+components/web_modal",
"+device/usb",
"+extensions",
"+net/base",
"+skia/ext",
Expand Down
4 changes: 0 additions & 4 deletions apps/apps.gypi
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,6 @@
'launcher.cc',
'launcher.h',
'metrics_names.h',
'saved_devices_service.cc',
'saved_devices_service.h',
'saved_devices_service_factory.cc',
'saved_devices_service_factory.h',
'saved_files_service.cc',
'saved_files_service.h',
'saved_files_service_factory.cc',
Expand Down
316 changes: 0 additions & 316 deletions apps/saved_devices_service.cc

This file was deleted.

Loading

0 comments on commit bc82d3c

Please sign in to comment.