Introduce wxCursorBase class defining common wxCursor API.

This is done in preparation for adding a new wxCursor method and will allow us
to define it in a single place by default instead of having to provide stubs
for all ports.

See #16539.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@78133 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2014-11-11 01:02:45 +00:00
parent 261e7eac73
commit e737363e6b
9 changed files with 24 additions and 24 deletions

View File

@@ -1,10 +1,10 @@
/////////////////////////////////////////////////////////////////////////////
// Name: wx/cursor.h
// Purpose: wxCursor base header
// Author: Julian Smart
// Modified by:
// Author: Julian Smart, Vadim Zeitlin
// Created:
// Copyright: (c) Julian Smart
// (c) 2014 Vadim Zeitlin (wxCursorBase)
// Licence: wxWindows Licence
/////////////////////////////////////////////////////////////////////////////
@@ -13,12 +13,22 @@
#include "wx/defs.h"
/*
wxCursor classes should have the following public API:
#include "wx/gdiobj.h"
class WXDLLIMPEXP_CORE wxCursor : public wxGDIObject
// Under most ports, wxCursor derives directly from wxGDIObject, but in wxMSW
// there is an intermediate wxGDIImage class.
#ifdef __WXMSW__
#include "wx/msw/gdiimage.h"
#else
typedef wxGDIObject wxGDIImage;
#endif
class WXDLLIMPEXP_CORE wxCursorBase : public wxGDIImage
{
public:
/*
wxCursor classes should provide the following ctors:
wxCursor();
wxCursor(const wxImage& image);
wxCursor(const wxString& name,
@@ -28,10 +38,8 @@ public:
#if WXWIN_COMPATIBILITY_2_8
wxCursor(int id) { InitFromStock((wxStockCursor)id); }
#endif
virtual ~wxCursor();
};
*/
};
#if defined(__WXMSW__)
#define wxCURSOR_DEFAULT_TYPE wxBITMAP_TYPE_CUR_RESOURCE