Commit 0467760e authored by spqchan's avatar spqchan Committed by Commit bot

[Mac] Active state for the security omnibox decoration

Security state decoration is set to active when the WebsiteSettingsBubble is opened

BUG=588377

Review-Url: https://codereview.chromium.org/2538323003
Cr-Commit-Position: refs/heads/master@{#437926}
parent a740f7ec
......@@ -8,7 +8,7 @@
#include "base/mac/scoped_nsobject.h"
#include "base/macros.h"
#import "chrome/browser/ui/cocoa/base_bubble_controller.h"
#import "chrome/browser/ui/cocoa/omnibox_decoration_bubble_controller.h"
#include "chrome/browser/ui/website_settings/website_settings_ui.h"
#include "content/public/browser/web_contents_observer.h"
......@@ -31,7 +31,7 @@ struct SecurityInfo;
//
// TODO(palmer): Normalize all WebsiteSettings*, SiteSettings*, PageInfo*, et c.
// to OriginInfo*.
@interface WebsiteSettingsBubbleController : BaseBubbleController {
@interface WebsiteSettingsBubbleController : OmniboxDecorationBubbleController {
@private
content::WebContents* webContents_;
......
......@@ -235,6 +235,12 @@ bool IsInternalURL(const GURL& url) {
return self;
}
- (LocationBarDecoration*)decorationForBubble {
BrowserWindowController* controller = [[self parentWindow] windowController];
LocationBarViewMac* location_bar = [controller locationBarBridge];
return location_bar ? location_bar->GetPageInfoDecoration() : nullptr;
}
- (Profile*)profile {
return Profile::FromBrowserContext(webContents_->GetBrowserContext());
}
......
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