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

Unified Diff: remoting/webapp/crd/js/options_export.js

Issue 2671103002: Implement host settings migration. (Closed)
Patch Set: Created 3 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « remoting/webapp/crd/js/background.js ('k') | remoting/webapp/crd/manifest.json.jinja2 » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/webapp/crd/js/options_export.js
diff --git a/remoting/webapp/crd/js/options_export.js b/remoting/webapp/crd/js/options_export.js
new file mode 100644
index 0000000000000000000000000000000000000000..dbd3a25560c96d3e8fa94fe1fceecc06561bc31e
--- /dev/null
+++ b/remoting/webapp/crd/js/options_export.js
@@ -0,0 +1,30 @@
+// Copyright 2017 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+/** @suppress {duplicate} */
+var remoting = remoting || {};
+
+(function(){
+
+'use strict';
+
+/**
+ * @constructor
+ */
+remoting.OptionsExporter = function() {
+ base.Ipc.getInstance().register('getSettings',
+ remoting.OptionsExporter.migrateSettings_,
+ true);
+};
+
+remoting.OptionsExporter.migrateSettings_ = function() {
+ var result = new base.Deferred();
+ chrome.storage.local.get('remoting-host-options', function(options) {
+ result.resolve(options);
+ })
+ return result.promise();
+};
+
+
+}());
« no previous file with comments | « remoting/webapp/crd/js/background.js ('k') | remoting/webapp/crd/manifest.json.jinja2 » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698