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

Unified Diff: chrome/browser/chromeos/input_method/component_extension_ime_manager_impl.cc

Issue 1880723002: Register IME extension after loading it succesfully. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address shuchen@'s comments. Created 4 years, 8 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chromeos/input_method/component_extension_ime_manager_impl.cc
diff --git a/chrome/browser/chromeos/input_method/component_extension_ime_manager_impl.cc b/chrome/browser/chromeos/input_method/component_extension_ime_manager_impl.cc
index 48fb019b3b951b3d6252ffc6d13ee973c0e20556..52300d936295ab0a1138541410e1926a461f5536 100644
--- a/chrome/browser/chromeos/input_method/component_extension_ime_manager_impl.cc
+++ b/chrome/browser/chromeos/input_method/component_extension_ime_manager_impl.cc
@@ -24,6 +24,8 @@
#include "chrome/grit/browser_resources.h"
#include "chrome/grit/generated_resources.h"
#include "content/public/browser/browser_thread.h"
+#include "extensions/browser/extension_pref_value_map.h"
+#include "extensions/browser/extension_pref_value_map_factory.h"
#include "extensions/browser/extension_system.h"
#include "extensions/common/extension.h"
#include "extensions/common/extension_l10n_util.h"
@@ -105,6 +107,12 @@ void DoLoadExtension(Profile* profile,
return;
const std::string loaded_extension_id =
GetComponentLoader(profile)->Add(manifest, file_path);
+ // Register IME extension with ExtensionPrefValueMap.
+ ExtensionPrefValueMapFactory::GetForBrowserContext(profile)
+ ->RegisterExtension(extension_id,
+ base::Time(), // install_time.
+ true, // is_enabled.
+ true); // is_incognito_enabled.
DCHECK_EQ(loaded_extension_id, extension_id);
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698