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

Unified Diff: chrome/browser/permissions/permission_request_impl.cc

Issue 2382563003: Remove some more desktop infobar PNGs. (Closed)
Patch Set: this will eventually compile Created 4 years, 2 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
Index: chrome/browser/permissions/permission_request_impl.cc
diff --git a/chrome/browser/permissions/permission_request_impl.cc b/chrome/browser/permissions/permission_request_impl.cc
index 032133457a43bf84b3dbff97da0b5cf67b44284e..c18046bebbd2a93b4173f72a49e57c0bce7c71de 100644
--- a/chrome/browser/permissions/permission_request_impl.cc
+++ b/chrome/browser/permissions/permission_request_impl.cc
@@ -5,6 +5,7 @@
#include "chrome/browser/permissions/permission_request_impl.h"
#include "build/build_config.h"
+#include "chrome/browser/android/android_theme_resources.h"
#include "chrome/browser/permissions/permission_decision_auto_blocker.h"
#include "chrome/browser/permissions/permission_uma_util.h"
#include "chrome/browser/permissions/permission_util.h"
@@ -40,7 +41,7 @@ PermissionRequestImpl::~PermissionRequestImpl() {
}
gfx::VectorIconId PermissionRequestImpl::GetVectorIconId() const {
-#if !defined(OS_MACOSX) && !defined(OS_ANDROID)
+#if !defined(OS_ANDROID)
Peter Kasting 2016/10/05 01:13:13 Nit: Reverse to avoid double-negative in "else":
Evan Stade 2016/10/05 17:42:29 Done.
switch (permission_type_) {
case content::PermissionType::GEOLOCATION:
return gfx::VectorIconId::LOCATION_ON;
@@ -62,24 +63,18 @@ gfx::VectorIconId PermissionRequestImpl::GetVectorIconId() const {
NOTREACHED();
return gfx::VectorIconId::VECTOR_ICON_NONE;
}
-#else // !defined(OS_MACOSX) && !defined(OS_ANDROID)
+#else // !defined(OS_ANDROID)
return gfx::VectorIconId::VECTOR_ICON_NONE;
#endif
}
int PermissionRequestImpl::GetIconId() const {
- int icon_id = IDR_INFOBAR_WARNING;
-#if defined(OS_MACOSX) || defined(OS_ANDROID)
+ int icon_id = 0;
+#if defined(OS_ANDROID)
Peter Kasting 2016/10/05 01:13:13 Nit: Maybe put the entire function (and declaratio
Evan Stade 2016/10/05 17:42:29 done I'm not entirely sure this is even necessary
switch (permission_type_) {
case content::PermissionType::GEOLOCATION:
- icon_id = IDR_INFOBAR_GEOLOCATION;
+ icon_id = IDR_ANDROID_INFOBAR_GEOLOCATION;
break;
-#if defined(ENABLE_NOTIFICATIONS)
- case content::PermissionType::NOTIFICATIONS:
- case content::PermissionType::PUSH_MESSAGING:
- icon_id = IDR_INFOBAR_DESKTOP_NOTIFICATIONS;
- break;
-#endif
case content::PermissionType::MIDI_SYSEX:
icon_id = IDR_ALLOWED_MIDI_SYSEX;
break;

Powered by Google App Engine
This is Rietveld 408576698