Commit 2f435c4d authored by groby's avatar groby Committed by Commit bot

[OSX] Handle PermissionBubble coalescing

PermissionBubbleCocoa::CanAcceptRequestUpdate controls request
coalescing. This change allows requests to be added to an existing
permission bubble unless the user has moused over the bubble.

BUG=452931

Review URL: https://codereview.chromium.org/895363007

Cr-Commit-Position: refs/heads/master@{#327365}
parent 646b3185
......@@ -10,6 +10,7 @@
#import "chrome/browser/ui/cocoa/website_settings/permission_bubble_controller.h"
#import "chrome/browser/ui/website_settings/permission_bubble_view.h"
#include "content/public/browser/web_contents.h"
#import "ui/base/cocoa/nsview_additions.h"
PermissionBubbleCocoa::PermissionBubbleCocoa(NSWindow* parent_window)
: parent_window_(parent_window), delegate_(NULL), bubbleController_(nil) {}
......@@ -53,9 +54,7 @@ void PermissionBubbleCocoa::SetDelegate(Delegate* delegate) {
}
bool PermissionBubbleCocoa::CanAcceptRequestUpdate() {
// TODO(gbillock): implement. Should return true if the mouse is not over the
// dialog.
return false;
return ![[[bubbleController_ window] contentView] cr_isMouseInView];
}
void PermissionBubbleCocoa::OnBubbleClosing() {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment