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

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

Issue 2973004: [Mac]Implement ViewID support. (Closed) Base URL: http://src.chromium.org/git/chromium.git
Patch Set: Turns out that, it's not a good solution. Created 10 years, 5 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/view_id_util.h ('k') | chrome/browser/cocoa/view_id_util_browsertest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/cocoa/view_id_util.mm
diff --git a/chrome/browser/cocoa/view_id_util.mm b/chrome/browser/cocoa/view_id_util.mm
new file mode 100644
index 0000000000000000000000000000000000000000..1f949897f523cfc8a421507d480c9e9d25e423f0
--- /dev/null
+++ b/chrome/browser/cocoa/view_id_util.mm
@@ -0,0 +1,17 @@
+// Copyright (c) 2010 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/view_id_util.h"
+
+#import <Cocoa/Cocoa.h>
+#include "base/logging.h"
+
+namespace view_id_util {
+
+NSView* GetView(NSWindow* window, ViewID viewID) {
+ DCHECK(window);
+ return [[[window contentView] superview] viewWithTag:ViewIDToTag(viewID)];
+}
+
+} // namespace view_id_util
« no previous file with comments | « chrome/browser/cocoa/view_id_util.h ('k') | chrome/browser/cocoa/view_id_util_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698