c++11: Add discussion thread links, ban things that don't work with MSVS.
[chromium-blink-merge.git] / ui / base / cursor / cursors_aura.h
blobe8eae0ab2deeaae6aa22e9df7bf1695e70886b35
1 // Copyright (c) 2013 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 UI_BASE_CURSOR_CURSORS_AURA_H_
6 #define UI_BASE_CURSOR_CURSORS_AURA_H_
8 #include "ui/base/cursor/cursor.h"
9 #include "ui/base/ui_base_export.h"
11 class SkBitmap;
13 namespace gfx {
14 class Point;
17 namespace ui {
19 const int kAnimatedCursorFrameDelayMs = 25;
21 // Returns data about |id|, where id is a cursor constant like
22 // ui::kCursorHelp. The IDR will be placed in |resource_id| and the hotspots
23 // for the different DPIs will be placed in |hot_1x| and |hot_2x|. Returns
24 // false if |id| is invalid.
25 bool UI_BASE_EXPORT GetCursorDataFor(CursorSetType cursor_set_id,
26 int id,
27 float scale_factor,
28 int* resource_id,
29 gfx::Point* point);
31 // Like above, but for animated cursors.
32 bool UI_BASE_EXPORT GetAnimatedCursorDataFor(CursorSetType cursor_set_id,
33 int id,
34 float scale_factor,
35 int* resource_id,
36 gfx::Point* point);
38 // Returns the cursor bitmap for |cursor|. Returns false if |cursor| is invalid.
39 // The cursor hot point location is set in |point|.
40 bool UI_BASE_EXPORT
41 GetCursorBitmap(const Cursor& cursor, SkBitmap* bitmap, gfx::Point* point);
43 } // namespace ui
45 #endif // UI_BASE_CURSOR_CURSORS_AURA_H_