| OLD | NEW | 
|---|
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be | 
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. | 
| 4 | 4 | 
| 5 #import "chrome/browser/cocoa/download_shelf_view.h" | 5 #import "chrome/browser/cocoa/download_shelf_view.h" | 
| 6 | 6 | 
| 7 #include "base/scoped_nsobject.h" | 7 #include "base/scoped_nsobject.h" | 
| 8 #include "chrome/browser/browser_theme_provider.h" | 8 #include "chrome/browser/browser_theme_provider.h" | 
| 9 #import "chrome/browser/cocoa/themed_window.h" | 9 #import "chrome/browser/cocoa/themed_window.h" | 
|  | 10 #import "chrome/browser/cocoa/view_id_util.h" | 
| 10 #include "grit/theme_resources.h" | 11 #include "grit/theme_resources.h" | 
| 11 | 12 | 
| 12 @implementation DownloadShelfView | 13 @implementation DownloadShelfView | 
| 13 | 14 | 
| 14 - (NSColor*)strokeColor { | 15 - (NSColor*)strokeColor { | 
| 15   BOOL isKey = [[self window] isKeyWindow]; | 16   BOOL isKey = [[self window] isKeyWindow]; | 
| 16   ThemeProvider* themeProvider = [[self window] themeProvider]; | 17   ThemeProvider* themeProvider = [[self window] themeProvider]; | 
| 17   return themeProvider ? themeProvider->GetNSColor( | 18   return themeProvider ? themeProvider->GetNSColor( | 
| 18       isKey ? BrowserThemeProvider::COLOR_TOOLBAR_STROKE : | 19       isKey ? BrowserThemeProvider::COLOR_TOOLBAR_STROKE : | 
| 19               BrowserThemeProvider::COLOR_TOOLBAR_STROKE_INACTIVE, true) : | 20               BrowserThemeProvider::COLOR_TOOLBAR_STROKE_INACTIVE, true) : | 
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 56   NSDivideRect([self bounds], &borderRect, &contentRect, 1, NSMaxYEdge); | 57   NSDivideRect([self bounds], &borderRect, &contentRect, 1, NSMaxYEdge); | 
| 57   NSRectFillUsingOperation(borderRect, NSCompositeSourceOver); | 58   NSRectFillUsingOperation(borderRect, NSCompositeSourceOver); | 
| 58 } | 59 } | 
| 59 | 60 | 
| 60 // Mouse down events on the download shelf should not allow dragging the parent | 61 // Mouse down events on the download shelf should not allow dragging the parent | 
| 61 // window around. | 62 // window around. | 
| 62 - (BOOL)mouseDownCanMoveWindow { | 63 - (BOOL)mouseDownCanMoveWindow { | 
| 63   return NO; | 64   return NO; | 
| 64 } | 65 } | 
| 65 | 66 | 
|  | 67 - (ViewID)viewID { | 
|  | 68   return VIEW_ID_DOWNLOAD_SHELF; | 
|  | 69 } | 
|  | 70 | 
| 66 @end | 71 @end | 
| OLD | NEW | 
|---|