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

Side by Side Diff: chrome/browser/ui/webui/chromeos/emulator/device_emulator_ui.cc

Issue 1258783009: Add functionality to Bluetooth settings UI. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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/ui/webui/chromeos/emulator/device_emulator_ui.h" 5 #include "chrome/browser/ui/webui/chromeos/emulator/device_emulator_ui.h"
6 6
7 #include "base/strings/string_number_conversions.h" 7 #include "base/strings/string_number_conversions.h"
8 #include "base/values.h" 8 #include "base/values.h"
9 #include "chrome/browser/profiles/profile.h" 9 #include "chrome/browser/profiles/profile.h"
10 #include "chrome/browser/ui/webui/chromeos/emulator/device_emulator_message_hand ler.h" 10 #include "chrome/browser/ui/webui/chromeos/emulator/device_emulator_message_hand ler.h"
(...skipping 24 matching lines...) Expand all
35 html->AddResourcePath("bluetooth_settings.js", IDR_BLUETOOTH_SETTINGS_JS); 35 html->AddResourcePath("bluetooth_settings.js", IDR_BLUETOOTH_SETTINGS_JS);
36 html->SetDefaultResource(IDR_DEVICE_EMULATOR_HTML); 36 html->SetDefaultResource(IDR_DEVICE_EMULATOR_HTML);
37 37
38 return html; 38 return html;
39 } 39 }
40 40
41 } // namespace 41 } // namespace
42 42
43 DeviceEmulatorUI::DeviceEmulatorUI(content::WebUI* web_ui) 43 DeviceEmulatorUI::DeviceEmulatorUI(content::WebUI* web_ui)
44 : WebUIController(web_ui) { 44 : WebUIController(web_ui) {
45 DeviceEmulatorMessageHandler* handler = new DeviceEmulatorMessageHandler(); 45 chromeos::DeviceEmulatorMessageHandler* handler =
46 new chromeos::DeviceEmulatorMessageHandler();
46 handler->Init(); 47 handler->Init();
47 web_ui->AddMessageHandler(handler); 48 web_ui->AddMessageHandler(handler);
48 49
49 content::WebUIDataSource::Add(web_ui->GetWebContents()->GetBrowserContext(), 50 content::WebUIDataSource::Add(web_ui->GetWebContents()->GetBrowserContext(),
50 CreateDeviceEmulatorUIDataSource()); 51 CreateDeviceEmulatorUIDataSource());
51 } 52 }
52 53
53 DeviceEmulatorUI::~DeviceEmulatorUI() { 54 DeviceEmulatorUI::~DeviceEmulatorUI() {
54 } 55 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698