summaryrefslogtreecommitdiffstats
path: root/chrome/utility
diff options
context:
space:
mode:
authormpcomplete@google.com <mpcomplete@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-22 19:02:19 +0000
committermpcomplete@google.com <mpcomplete@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-22 19:02:19 +0000
commit902f7cd528743a286439cfca87266aa1b723a8bf (patch)
tree986e45ef007fba1dd21436bcf1a00470ca6ae1e4 /chrome/utility
parent5be94dffc6b19e0ed8397879ad60fe06e498cb3a (diff)
downloadchromium_src-902f7cd528743a286439cfca87266aa1b723a8bf.zip
chromium_src-902f7cd528743a286439cfca87266aa1b723a8bf.tar.gz
chromium_src-902f7cd528743a286439cfca87266aa1b723a8bf.tar.bz2
Have the browser process rewrite manifest.json and theme/page action images
that the extension unpacker process parsed. BUG=11680 Review URL: http://codereview.chromium.org/115595 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16768 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/utility')
-rw-r--r--chrome/utility/utility_thread.cc11
1 files changed, 8 insertions, 3 deletions
diff --git a/chrome/utility/utility_thread.cc b/chrome/utility/utility_thread.cc
index 269a86b..2330fd5 100644
--- a/chrome/utility/utility_thread.cc
+++ b/chrome/utility/utility_thread.cc
@@ -4,6 +4,7 @@
#include "chrome/utility/utility_thread.h"
+#include "base/values.h"
#include "chrome/common/child_process.h"
#include "chrome/common/extensions/extension_unpacker.h"
#include "chrome/common/render_messages.h"
@@ -32,9 +33,13 @@ void UtilityThread::OnControlMessageReceived(const IPC::Message& msg) {
void UtilityThread::OnUnpackExtension(const FilePath& extension_path) {
ExtensionUnpacker unpacker(extension_path);
- bool success = unpacker.Run();
- Send(new UtilityHostMsg_UnpackExtension_Reply(success,
- unpacker.error_message()));
+ if (unpacker.Run()) {
+ Send(new UtilityHostMsg_UnpackExtension_Succeeded(
+ *unpacker.parsed_manifest(), unpacker.decoded_images()));
+ } else {
+ Send(new UtilityHostMsg_UnpackExtension_Failed(
+ unpacker.error_message()));
+ }
ChildProcess::current()->ReleaseProcess();
}