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

Unified Diff: chrome/browser/ui/cocoa/tabs/tab_strip_background_view.mm

Issue 904503003: Mac: Make more views adopts ThemedWindowDrawing (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@FramedBrowserWindow
Patch Set: Created 5 years, 10 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
« no previous file with comments | « chrome/browser/ui/cocoa/tabs/tab_strip_background_view.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/cocoa/tabs/tab_strip_background_view.mm
diff --git a/chrome/browser/ui/cocoa/tabs/tab_strip_background_view.mm b/chrome/browser/ui/cocoa/tabs/tab_strip_background_view.mm
index d8fba5d570bdd23a5f4588d866e23aaed71ead7e..4b32010d44e65a67c702b90540b9b1f7ec77acf8 100644
--- a/chrome/browser/ui/cocoa/tabs/tab_strip_background_view.mm
+++ b/chrome/browser/ui/cocoa/tabs/tab_strip_background_view.mm
@@ -40,33 +40,13 @@
}
}
-- (void)viewWillMoveToWindow:(NSWindow*)window {
- if ([self window]) {
- [[NSNotificationCenter defaultCenter]
- removeObserver:self
- name:NSWindowDidBecomeMainNotification
- object:[self window]];
- [[NSNotificationCenter defaultCenter]
- removeObserver:self
- name:NSWindowDidResignMainNotification
- object:[self window]];
- }
- if (window) {
- [[NSNotificationCenter defaultCenter]
- addObserver:self
- selector:@selector(windowFocusDidChange:)
- name:NSWindowDidBecomeMainNotification
- object:window];
- [[NSNotificationCenter defaultCenter]
- addObserver:self
- selector:@selector(windowFocusDidChange:)
- name:NSWindowDidResignMainNotification
- object:window];
- }
+// ThemedWindowDrawing implementation.
+
+- (void)windowDidChangeTheme {
+ [self setNeedsDisplay:YES];
}
-- (void)windowFocusDidChange:(NSNotification*)notification {
- // The theme image may depend on the window's active state.
+- (void)windowDidChangeActive {
[self setNeedsDisplay:YES];
}
« no previous file with comments | « chrome/browser/ui/cocoa/tabs/tab_strip_background_view.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698