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

Unified Diff: chrome/browser/cocoa/cocoa_test_helper.mm

Issue 192031: [Mac] Add testing code to expose an NSColor memory leak. (Closed)
Patch Set: Remove egregious s/private/public/ leftover from prototyping. Created 11 years, 3 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/cocoa/cocoa_test_helper.h ('k') | chrome/chrome.gyp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/cocoa/cocoa_test_helper.mm
diff --git a/chrome/browser/cocoa/cocoa_test_helper.mm b/chrome/browser/cocoa/cocoa_test_helper.mm
new file mode 100644
index 0000000000000000000000000000000000000000..efe5c5cec2694673324731f6aaeb805535936fef
--- /dev/null
+++ b/chrome/browser/cocoa/cocoa_test_helper.mm
@@ -0,0 +1,28 @@
+// Copyright (c) 2009 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#import "chrome/browser/cocoa/cocoa_test_helper.h"
+
+@implementation CocoaTestHelperWindow
+
+- (id)initWithContentRect:(NSRect)contentRect {
+ return [self initWithContentRect:contentRect
+ styleMask:NSBorderlessWindowMask
+ backing:NSBackingStoreBuffered
+ defer:NO];
+}
+
+- (id)init {
+ return [self initWithContentRect:NSMakeRect(0, 0, 800, 600)];
+}
+
+- (void)setPretendIsKeyWindow:(BOOL)flag {
+ pretendIsKeyWindow_ = flag;
+}
+
+- (BOOL)isKeyWindow {
+ return pretendIsKeyWindow_;
+}
+
+@end
« no previous file with comments | « chrome/browser/cocoa/cocoa_test_helper.h ('k') | chrome/chrome.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698