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

Unified Diff: chrome/common/extensions/extension.cc

Issue 10837060: Don't show host permission warnings for platform apps. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/common/extensions/extension.h ('k') | chrome/common/extensions/extension_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/extensions/extension.cc
diff --git a/chrome/common/extensions/extension.cc b/chrome/common/extensions/extension.cc
index 231445b197bf1bde9d68646ec0520334b59e83d7..d12bca813b38dac49f5e056d2989c0753ec0f07d 100644
--- a/chrome/common/extensions/extension.cc
+++ b/chrome/common/extensions/extension.cc
@@ -38,6 +38,7 @@
#include "chrome/common/extensions/file_browser_handler.h"
#include "chrome/common/extensions/manifest.h"
#include "chrome/common/extensions/permissions/permissions_info.h"
+#include "chrome/common/extensions/permissions/permission_set.h"
#include "chrome/common/extensions/url_pattern_set.h"
#include "chrome/common/extensions/user_script.h"
#include "chrome/common/url_constants.h"
@@ -3519,10 +3520,12 @@ bool Extension::HasFullPermissions() const {
PermissionMessages Extension::GetPermissionMessages() const {
base::AutoLock auto_lock(runtime_data_lock_);
- if (IsTrustedId(id()))
+ if (IsTrustedId(id())) {
return PermissionMessages();
- else
- return runtime_data_.GetActivePermissions()->GetPermissionMessages();
+ } else {
+ return runtime_data_.GetActivePermissions()->GetPermissionMessages(
+ GetType());
+ }
}
std::vector<string16> Extension::GetPermissionMessageStrings() const {
@@ -3530,7 +3533,7 @@ std::vector<string16> Extension::GetPermissionMessageStrings() const {
if (IsTrustedId(id()))
return std::vector<string16>();
else
- return runtime_data_.GetActivePermissions()->GetWarningMessages();
+ return runtime_data_.GetActivePermissions()->GetWarningMessages(GetType());
}
void Extension::SetActivePermissions(
« no previous file with comments | « chrome/common/extensions/extension.h ('k') | chrome/common/extensions/extension_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698