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

Unified Diff: chrome/browser/ui/cocoa/browser_window_controller.mm

Issue 10885024: Integrate Chrome To Mobile with Action Box UI. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix nil/NULL checks in ChromeToMobileBubbleController. Created 8 years, 4 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/ui/cocoa/browser_window_controller.mm
diff --git a/chrome/browser/ui/cocoa/browser_window_controller.mm b/chrome/browser/ui/cocoa/browser_window_controller.mm
index c650777b21fcce8d1dc245f41ec27180e2aa593d..a5dbbcd39b1b48241e964fdbd2c269241600fa3c 100644
--- a/chrome/browser/ui/cocoa/browser_window_controller.mm
+++ b/chrome/browser/ui/cocoa/browser_window_controller.mm
@@ -1648,10 +1648,6 @@ enum {
bookmarkBubbleController_ = nil;
}
-- (NSPoint)chromeToMobileBubblePoint {
- return [toolbarController_ chromeToMobileBubblePoint];
-}
-
// Show the Chrome To Mobile bubble (e.g. user just clicked on the icon).
- (void)showChromeToMobileBubble {
// Do nothing if the bubble is already showing.
@@ -1663,27 +1659,11 @@ enum {
initWithParentWindow:[self window]
browser:browser_.get()];
[chromeToMobileBubbleController_ showWindow:self];
-
- NSNotificationCenter* center = [NSNotificationCenter defaultCenter];
- [center addObserver:self
- selector:@selector(chromeToMobileBubbleWindowWillClose:)
- name:NSWindowWillCloseNotification
- object:[chromeToMobileBubbleController_ window]];
- // Show the lit Chrome To Mobile icon while the bubble is visible.
- [self locationBarBridge]->SetChromeToMobileDecorationLit(true);
}
// Nil out the weak Chrome To Mobile bubble controller reference.
-- (void)chromeToMobileBubbleWindowWillClose:(NSNotification*)notification {
- DCHECK_EQ([notification object], [chromeToMobileBubbleController_ window]);
-
- NSNotificationCenter* center = [NSNotificationCenter defaultCenter];
- [center removeObserver:self
- name:NSWindowWillCloseNotification
- object:[chromeToMobileBubbleController_ window]];
+- (void)chromeToMobileBubbleWindowWillClose {
chromeToMobileBubbleController_ = nil;
- // Restore the dimmed Chrome To Mobile icon when the bubble closes.
- [self locationBarBridge]->SetChromeToMobileDecorationLit(false);
}
// Handle the editBookmarkNode: action sent from bookmark bubble controllers.
« no previous file with comments | « chrome/browser/ui/cocoa/browser_window_controller.h ('k') | chrome/browser/ui/cocoa/chrome_to_mobile_bubble_controller.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698