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

Side by Side Diff: chromeos/dbus/cros_disks_client.cc

Issue 2338063002: chromeos: Refactor D-Bus client type enum and stub vs. fake naming (Closed)
Patch Set: review comments Created 4 years, 3 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
« no previous file with comments | « chromeos/dbus/cros_disks_client.h ('k') | chromeos/dbus/dbus_client.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "chromeos/dbus/cros_disks_client.h" 5 #include "chromeos/dbus/cros_disks_client.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <map> 10 #include <map>
(...skipping 616 matching lines...) Expand 10 before | Expand all | Expand 10 after
627 // CrosDisksClient 627 // CrosDisksClient
628 628
629 CrosDisksClient::CrosDisksClient() {} 629 CrosDisksClient::CrosDisksClient() {}
630 630
631 CrosDisksClient::~CrosDisksClient() {} 631 CrosDisksClient::~CrosDisksClient() {}
632 632
633 // static 633 // static
634 CrosDisksClient* CrosDisksClient::Create(DBusClientImplementationType type) { 634 CrosDisksClient* CrosDisksClient::Create(DBusClientImplementationType type) {
635 if (type == REAL_DBUS_CLIENT_IMPLEMENTATION) 635 if (type == REAL_DBUS_CLIENT_IMPLEMENTATION)
636 return new CrosDisksClientImpl(); 636 return new CrosDisksClientImpl();
637 DCHECK_EQ(STUB_DBUS_CLIENT_IMPLEMENTATION, type); 637 DCHECK_EQ(FAKE_DBUS_CLIENT_IMPLEMENTATION, type);
638 return new FakeCrosDisksClient(); 638 return new FakeCrosDisksClient();
639 } 639 }
640 640
641 // static 641 // static
642 base::FilePath CrosDisksClient::GetArchiveMountPoint() { 642 base::FilePath CrosDisksClient::GetArchiveMountPoint() {
643 return base::FilePath(base::SysInfo::IsRunningOnChromeOS() ? 643 return base::FilePath(base::SysInfo::IsRunningOnChromeOS() ?
644 FILE_PATH_LITERAL("/media/archive") : 644 FILE_PATH_LITERAL("/media/archive") :
645 FILE_PATH_LITERAL("/tmp/chromeos/media/archive")); 645 FILE_PATH_LITERAL("/tmp/chromeos/media/archive"));
646 } 646 }
647 647
(...skipping 22 matching lines...) Expand all
670 670
671 if (!mount_label.empty()) { 671 if (!mount_label.empty()) {
672 std::string mount_label_option = 672 std::string mount_label_option =
673 base::StringPrintf("%s=%s", kMountLabelOption, mount_label.c_str()); 673 base::StringPrintf("%s=%s", kMountLabelOption, mount_label.c_str());
674 mount_options.push_back(mount_label_option); 674 mount_options.push_back(mount_label_option);
675 } 675 }
676 return mount_options; 676 return mount_options;
677 } 677 }
678 678
679 } // namespace chromeos 679 } // namespace chromeos
OLDNEW
« no previous file with comments | « chromeos/dbus/cros_disks_client.h ('k') | chromeos/dbus/dbus_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698