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

Unified Diff: app/mac/nsimage_cache.mm

Issue 5961007: Move nsimage_cache from base to app/mac. Use the app::mac namespace. Update c... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 years 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 | « app/mac/nsimage_cache.h ('k') | app/mac/nsimage_cache_unittest.cc.README » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: app/mac/nsimage_cache.mm
===================================================================
--- app/mac/nsimage_cache.mm (revision 69953)
+++ app/mac/nsimage_cache.mm (working copy)
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "base/nsimage_cache_mac.h"
+#include "app/mac/nsimage_cache.h"
#import <AppKit/AppKit.h>
@@ -18,11 +18,12 @@
#undef try
#undef catch
-namespace nsimage_cache {
+namespace app {
+namespace mac {
static NSMutableDictionary* image_cache = nil;
-NSImage* ImageNamed(NSString* name) {
+NSImage* GetCachedImageWithName(NSString* name) {
DCHECK(name);
// NOTE: to make this thread safe, we'd have to sync on the cache and
@@ -65,9 +66,10 @@
return result;
}
-void Clear(void) {
+void ClearCachedImages(void) {
// NOTE: to make this thread safe, we'd have to sync on the cache.
[image_cache removeAllObjects];
}
-} // namespace nsimage_cache
+} // namespace mac
+} // namespace app
« no previous file with comments | « app/mac/nsimage_cache.h ('k') | app/mac/nsimage_cache_unittest.cc.README » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698