[Metrics] Make MetricsStateManager take a callback param to check if UMA is enabled.
[chromium-blink-merge.git] / chrome / browser / ui / cocoa / drag_util.h
blobc71d8914792ec01859cf5b1179df15abf0d24787
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef CHROME_BROWSER_UI_COCOA_DRAG_UTIL_H_
6 #define CHROME_BROWSER_UI_COCOA_DRAG_UTIL_H_
8 #import <Cocoa/Cocoa.h>
10 class GURL;
11 class Profile;
13 namespace drag_util {
15 // Returns the first file URL from |info|, if there is one. If |info| doesn't
16 // contain any file URLs, an empty |GURL| is returned.
17 GURL GetFileURLFromDropData(id<NSDraggingInfo> info);
19 // Determines whether the given drag and drop operation contains content that
20 // is supported by the web view. In particular, if the content is a local file
21 // URL, this checks if it is of a type that can be shown in the tab contents.
22 BOOL IsUnsupportedDropData(Profile* profile, id<NSDraggingInfo> info);
24 } // namespace drag_util
26 #endif // CHROME_BROWSER_UI_COCOA_DRAG_UTIL_H_