]> git.saurik.com Git - wxWidgets.git/blame - include/wx/cocoa/bmpbuttn.h
Test using wxString::ToCDouble() in wxAny.
[wxWidgets.git] / include / wx / cocoa / bmpbuttn.h
CommitLineData
da0634c1
DE
1/////////////////////////////////////////////////////////////////////////////
2// Name: wx/cocoa/bmpbuttn.h
3// Purpose: wxBitmapButton class
4// Author: David Elliott
5// Modified by:
6// Created: 2003/03/16
1c4e8f38 7// RCS-ID: $Id$
da0634c1 8// Copyright: (c) 2003 David Elliott
1c4e8f38 9// Licence: wxWindows licence
da0634c1
DE
10/////////////////////////////////////////////////////////////////////////////
11
12#ifndef __WX_COCOA_BMPBUTTN_H__
13#define __WX_COCOA_BMPBUTTN_H__
14
15#include "wx/cocoa/NSButton.h"
16
17// ========================================================================
18// wxBitmapButton
19// ========================================================================
53a2db12 20class WXDLLIMPEXP_CORE wxBitmapButton : public wxBitmapButtonBase
da0634c1
DE
21{
22 DECLARE_DYNAMIC_CLASS(wxBitmapButton)
23 DECLARE_EVENT_TABLE()
24 WX_DECLARE_COCOA_OWNER(NSButton,NSControl,NSView)
25// ------------------------------------------------------------------------
26// initialization
27// ------------------------------------------------------------------------
28public:
29 wxBitmapButton() { }
30 wxBitmapButton(wxWindow *parent, wxWindowID winid,
31 const wxBitmap& bitmap,
32 const wxPoint& pos = wxDefaultPosition,
33 const wxSize& size = wxDefaultSize, long style = 0,
34 const wxValidator& validator = wxDefaultValidator,
35 const wxString& name = wxButtonNameStr)
36 {
37 Create(parent, winid, bitmap, pos, size, style, validator, name);
38 }
39
40 bool Create(wxWindow *parent, wxWindowID winid,
41 const wxBitmap& bitmap,
42 const wxPoint& pos = wxDefaultPosition,
43 const wxSize& size = wxDefaultSize, long style = 0,
44 const wxValidator& validator = wxDefaultValidator,
45 const wxString& name = wxButtonNameStr);
46 virtual ~wxBitmapButton();
47
48// ------------------------------------------------------------------------
49// Cocoa callbacks
50// ------------------------------------------------------------------------
51protected:
52 virtual void Cocoa_wxNSButtonAction(void);
53// ------------------------------------------------------------------------
54// Implementation
55// ------------------------------------------------------------------------
56public:
908686c5
DE
57 // The wxButton::DoGetBestSize is not correct for bitmap buttons
58 wxSize DoGetBestSize() const
59 { return wxButtonBase::DoGetBestSize(); }
da0634c1
DE
60};
61
62#endif // __WX_COCOA_BMPBUTTN_H__