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

Side by Side Diff: chrome/browser/extensions/api/music_manager_private/music_manager_private_api.cc

Issue 22885002: c/b/extensions, json_schema_compiler: Do not use Value::Create*. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Removed C-style casts. Created 7 years, 4 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 unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/extensions/api/music_manager_private/music_manager_priv ate_api.h" 5 #include "chrome/browser/extensions/api/music_manager_private/music_manager_priv ate_api.h"
6 6
7 #include "chrome/browser/extensions/api/music_manager_private/device_id.h" 7 #include "chrome/browser/extensions/api/music_manager_private/device_id.h"
8 8
9 using content::BrowserThread; 9 using content::BrowserThread;
10 10
(...skipping 26 matching lines...) Expand all
37 } 37 }
38 38
39 void MusicManagerPrivateGetDeviceIdFunction::DeviceIdCallback( 39 void MusicManagerPrivateGetDeviceIdFunction::DeviceIdCallback(
40 const std::string& device_id) { 40 const std::string& device_id) {
41 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); 41 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
42 bool response; 42 bool response;
43 if (device_id.empty()) { 43 if (device_id.empty()) {
44 SetError(kDeviceIdNotSupported); 44 SetError(kDeviceIdNotSupported);
45 response = false; 45 response = false;
46 } else { 46 } else {
47 SetResult(Value::CreateStringValue(device_id)); 47 SetResult(new base::StringValue(device_id));
48 response = true; 48 response = true;
49 } 49 }
50 50
51 SendResponse(response); 51 SendResponse(response);
52 } 52 }
53 53
54 } // namespace api 54 } // namespace api
55 } // namespace extensions 55 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698