]> git.saurik.com Git - wxWidgets.git/blame_incremental - include/wx/msw/cursor.h
don't test for __WIN95__ which doesn't exist any more; don't do compiler checks here...
[wxWidgets.git] / include / wx / msw / cursor.h
... / ...
CommitLineData
1/////////////////////////////////////////////////////////////////////////////
2// Name: wx/msw/cursor.h
3// Purpose: wxCursor class
4// Author: Julian Smart
5// Modified by:
6// Created: 01/02/97
7// RCS-ID: $Id$
8// Copyright: (c) Julian Smart
9// Licence: wxWindows licence
10/////////////////////////////////////////////////////////////////////////////
11
12#ifndef _WX_CURSOR_H_
13#define _WX_CURSOR_H_
14
15#include "wx/msw/gdiimage.h"
16
17class WXDLLEXPORT wxImage;
18
19// Cursor
20class WXDLLEXPORT wxCursor : public wxGDIImage
21{
22public:
23 // constructors
24 wxCursor();
25 wxCursor(const wxCursor& cursor) : wxGDIImage(cursor) { Ref(cursor); }
26 wxCursor(const wxImage& image);
27 wxCursor(const char bits[], int width, int height,
28 int hotSpotX = -1, int hotSpotY = -1,
29 const char maskBits[] = NULL);
30 wxCursor(const wxString& name,
31 long flags = wxBITMAP_TYPE_CUR_RESOURCE,
32 int hotSpotX = 0, int hotSpotY = 0);
33 wxCursor(int idCursor);
34 virtual ~wxCursor();
35
36 wxCursor& operator=(const wxCursor& cursor)
37 { if (*this == cursor) return (*this); Ref(cursor); return *this; }
38
39 bool operator==(const wxCursor& cursor) const;
40 bool operator!=(const wxCursor& cursor) const
41 { return !(*this == cursor); }
42
43 // implementation only
44 void SetHCURSOR(WXHCURSOR cursor) { SetHandle((WXHANDLE)cursor); }
45 WXHCURSOR GetHCURSOR() const { return (WXHCURSOR)GetHandle(); }
46
47protected:
48 virtual wxGDIImageRefData *CreateData() const;
49
50private:
51 DECLARE_DYNAMIC_CLASS(wxCursor)
52};
53
54#endif
55 // _WX_CURSOR_H_