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

Side by Side Diff: chrome/browser/printing/cloud_print/virtual_driver_install_helper.cc

Issue 7485011: Virtual Cloud Print Driver for Mac. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Created 9 years, 5 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 | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "chrome/browser/printing/cloud_print/virtual_driver_install_helper.h"
6 #include "chrome/browser/service/service_process_control.h"
7 #include "chrome/common/service_messages.h"
8
9 namespace cloud_print {
10 void VirtualDriverInstallHelper::SetUpInstall() {
11 scoped_refptr<VirtualDriverInstallHelper> help =
12 new VirtualDriverInstallHelper();
13 ServiceProcessControl::GetInstance()->Launch(NewRunnableMethod(help.get(),
14 &VirtualDriverInstallHelper::InstallVirtualDriverTask),
15 NULL);
16 }
17
18 void VirtualDriverInstallHelper::SetUpUninstall() {
19 scoped_refptr<VirtualDriverInstallHelper> help =
20 new VirtualDriverInstallHelper();
21 ServiceProcessControl::GetInstance()->Launch(NewRunnableMethod(help.get(),
22 &VirtualDriverInstallHelper::UninstallVirtualDriverTask)
23 , NULL);
24 }
25
26 void VirtualDriverInstallHelper::InstallVirtualDriverTask() {
27 ServiceProcessControl* process_control =
28 ServiceProcessControl::GetInstance();
29 DCHECK(process_control->is_connected());
30 process_control->Send(new ServiceMsg_EnableVirtualDriver());
31 }
32
33 void VirtualDriverInstallHelper::UninstallVirtualDriverTask() {
34 ServiceProcessControl* process_control =
35 ServiceProcessControl::GetInstance();
36 DCHECK(process_control->is_connected());
37 process_control->Send(new ServiceMsg_DisableVirtualDriver());
38 }
39 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698