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

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

Issue 8769016: Use the new base::mac::GetValueFromDictionary<>() method. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: update example comment Created 9 years, 1 month 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 | « base/mac/mac_util_unittest.mm ('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_drag_controller.mm
diff --git a/chrome/browser/ui/cocoa/tabs/tab_strip_drag_controller.mm b/chrome/browser/ui/cocoa/tabs/tab_strip_drag_controller.mm
index fd13ad58d77be6142d6b0c188a331a9dc2435b73..a11b210cf869417e04c15f68b259bc2715c2327a 100644
--- a/chrome/browser/ui/cocoa/tabs/tab_strip_drag_controller.mm
+++ b/chrome/browser/ui/cocoa/tabs/tab_strip_drag_controller.mm
@@ -538,15 +538,16 @@ const NSTimeInterval kTearDuration = 0.333;
DCHECK(CFGetTypeID(dict) == CFDictionaryGetTypeID());
// Sanity check the ID.
- CFNumberRef otherIDRef = (CFNumberRef)base::mac::GetValueFromDictionary(
- dict, kCGWindowNumber, CFNumberGetTypeID());
+ CFNumberRef otherIDRef =
+ base::mac::GetValueFromDictionary<CFNumberRef>(dict, kCGWindowNumber);
CGWindowID otherID;
if (otherIDRef &&
CFNumberGetValue(otherIDRef, kCGWindowIDCFNumberType, &otherID) &&
otherID == windowID) {
// And then get the workspace.
- CFNumberRef workspaceRef = (CFNumberRef)base::mac::GetValueFromDictionary(
- dict, kCGWindowWorkspace, CFNumberGetTypeID());
+ CFNumberRef workspaceRef =
+ base::mac::GetValueFromDictionary<CFNumberRef>(dict,
+ kCGWindowWorkspace);
if (!workspaceRef ||
!CFNumberGetValue(workspaceRef, kCFNumberIntType, &workspace)) {
workspace = -1;
« no previous file with comments | « base/mac/mac_util_unittest.mm ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698