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

Side by Side Diff: chrome/browser/extensions/pending_extension_info.cc

Issue 13145003: Rewrite std::string("") to std::string(), Linux edition. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Ugh Created 7 years, 8 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
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 "chrome/browser/extensions/pending_extension_info.h" 5 #include "chrome/browser/extensions/pending_extension_info.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 8
9 namespace extensions { 9 namespace extensions {
10 10
11 PendingExtensionInfo::PendingExtensionInfo( 11 PendingExtensionInfo::PendingExtensionInfo(
12 const std::string& id, 12 const std::string& id,
13 const GURL& update_url, 13 const GURL& update_url,
14 const Version& version, 14 const Version& version,
15 ShouldAllowInstallPredicate should_allow_install, 15 ShouldAllowInstallPredicate should_allow_install,
16 bool is_from_sync, 16 bool is_from_sync,
17 bool install_silently, 17 bool install_silently,
18 Manifest::Location install_source) 18 Manifest::Location install_source)
19 : id_(id), 19 : id_(id),
20 update_url_(update_url), 20 update_url_(update_url),
21 version_(version), 21 version_(version),
22 should_allow_install_(should_allow_install), 22 should_allow_install_(should_allow_install),
23 is_from_sync_(is_from_sync), 23 is_from_sync_(is_from_sync),
24 install_silently_(install_silently), 24 install_silently_(install_silently),
25 install_source_(install_source) {} 25 install_source_(install_source) {}
26 26
27 PendingExtensionInfo::PendingExtensionInfo() 27 PendingExtensionInfo::PendingExtensionInfo()
28 : id_(""), 28 : update_url_(),
29 update_url_(),
30 should_allow_install_(NULL), 29 should_allow_install_(NULL),
31 is_from_sync_(true), 30 is_from_sync_(true),
32 install_silently_(false), 31 install_silently_(false),
33 install_source_(Manifest::INVALID_LOCATION) {} 32 install_source_(Manifest::INVALID_LOCATION) {}
34 33
35 bool PendingExtensionInfo::operator==(const PendingExtensionInfo& rhs) const { 34 bool PendingExtensionInfo::operator==(const PendingExtensionInfo& rhs) const {
36 return id_ == rhs.id_; 35 return id_ == rhs.id_;
37 } 36 }
38 37
39 int PendingExtensionInfo::CompareTo(const PendingExtensionInfo& other) const { 38 int PendingExtensionInfo::CompareTo(const PendingExtensionInfo& other) const {
(...skipping 16 matching lines...) Expand all
56 // Different install sources; |this| has higher precedence if 55 // Different install sources; |this| has higher precedence if
57 // |install_source_| is the higher priority source. 56 // |install_source_| is the higher priority source.
58 Manifest::Location higher_priority_source = 57 Manifest::Location higher_priority_source =
59 Manifest::GetHigherPriorityLocation( 58 Manifest::GetHigherPriorityLocation(
60 install_source_, other.install_source_); 59 install_source_, other.install_source_);
61 60
62 return higher_priority_source == install_source_ ? 1 : -1; 61 return higher_priority_source == install_source_ ? 1 : -1;
63 } 62 }
64 63
65 } // namespace extensions 64 } // namespace extensions
OLDNEW
« no previous file with comments | « chrome/browser/extensions/menu_manager.cc ('k') | chrome/browser/extensions/platform_app_browsertest_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698