Index: content/browser/renderer_host/render_message_filter.cc |
diff --git a/content/browser/renderer_host/render_message_filter.cc b/content/browser/renderer_host/render_message_filter.cc |
index e7f7ad8263a29535de5fabafcfb657b829589e5f..461650ff15f25377377847700e83aa093f9b71a7 100644 |
--- a/content/browser/renderer_host/render_message_filter.cc |
+++ b/content/browser/renderer_host/render_message_filter.cc |
@@ -43,6 +43,7 @@ |
#include "content/public/browser/browser_thread.h" |
#include "content/public/browser/content_browser_client.h" |
#include "content/public/browser/download_save_info.h" |
+#include "content/public/browser/notification_presenter_permission.h" |
#include "content/public/browser/plugin_service_filter.h" |
#include "content/public/browser/resource_context.h" |
#include "content/public/browser/user_metrics.h" |
@@ -888,6 +889,16 @@ void RenderMessageFilter::OnDownloadUrl(int render_view_id, |
ResourceDispatcherHostImpl::DownloadStartedCallback()); |
} |
+COMPILE_ASSERT(static_cast<int>(NOTIFICATION_PRESENTER_PERMISSION_ALLOWED) |
+ == static_cast<int>(blink::WebNotificationPresenter::PermissionAllowed), |
+ mismatching_enums); |
+COMPILE_ASSERT(static_cast<int>(NOTIFICATION_PRESENTER_PERMISSION_NOT_ALLOWED) |
+ == static_cast<int>(blink::WebNotificationPresenter::PermissionNotAllowed), |
+ mismatching_enums); |
+COMPILE_ASSERT(static_cast<int>(NOTIFICATION_PRESENTER_PERMISSION_DENIED) |
+ == static_cast<int>(blink::WebNotificationPresenter::PermissionDenied), |
+ mismatching_enums); |
+ |
void RenderMessageFilter::OnCheckNotificationPermission( |
const GURL& source_origin, int* result) { |
#if defined(ENABLE_NOTIFICATIONS) |
@@ -895,7 +906,7 @@ void RenderMessageFilter::OnCheckNotificationPermission( |
CheckDesktopNotificationPermission(source_origin, resource_context_, |
render_process_id_); |
#else |
- *result = blink::WebNotificationPresenter::PermissionAllowed; |
+ *result = NOTIFICATION_PRESENTER_PERMISSION_ALLOWED; |
#endif |
} |