| Index: chrome/browser/extensions/api/idle/idle_api.cc
|
| diff --git a/chrome/browser/extensions/api/idle/idle_api.cc b/chrome/browser/extensions/api/idle/idle_api.cc
|
| index eda6bfba0b04cf47573bbf51544b7e0e0576a494..03a118f5d623522d8d0a39b2a8634519b4045e71 100644
|
| --- a/chrome/browser/extensions/api/idle/idle_api.cc
|
| +++ b/chrome/browser/extensions/api/idle/idle_api.cc
|
| @@ -144,13 +144,11 @@ int CheckThresholdBounds(int timeout) {
|
| void ExtensionIdleEventRouter::OnIdleStateChange(Profile* profile,
|
| IdleState state) {
|
| // Prepare the single argument of the current state.
|
| - ListValue args;
|
| - args.Append(CreateIdleValue(state));
|
| - std::string json_args;
|
| - base::JSONWriter::Write(&args, &json_args);
|
| + scoped_ptr<ListValue> args(new ListValue());
|
| + args->Append(CreateIdleValue(state));
|
|
|
| profile->GetExtensionEventRouter()->DispatchEventToRenderers(
|
| - keys::kOnStateChanged, json_args, profile,
|
| + keys::kOnStateChanged, args.Pass(), profile,
|
| GURL(), extensions::EventFilteringInfo());
|
| }
|
|
|
|
|