]> git.saurik.com Git - wxWidgets.git/blob - include/wx/osx/carbon/statbmp.h
Add "OSX" prefix to wxCFEventLoop::DoRun() and DoStop() methods.
[wxWidgets.git] / include / wx / osx / carbon / statbmp.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/osx/carbon/statbmp.h
3 // Purpose: wxStaticBitmap class
4 // Author: Stefan Csomor
5 // Modified by:
6 // Created: 1998-01-01
7 // RCS-ID: $Id$
8 // Copyright: (c) Stefan Csomor
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
11
12 #ifndef _WX_STATBMP_H_
13 #define _WX_STATBMP_H_
14
15 #include "wx/icon.h"
16
17 class WXDLLIMPEXP_CORE wxStaticBitmap: public wxStaticBitmapBase
18 {
19 DECLARE_DYNAMIC_CLASS(wxStaticBitmap)
20 public:
21 wxStaticBitmap() { }
22
23 wxStaticBitmap(wxWindow *parent, wxWindowID id,
24 const wxBitmap& label,
25 const wxPoint& pos = wxDefaultPosition,
26 const wxSize& size = wxDefaultSize,
27 long style = 0,
28 const wxString& name = wxStaticBitmapNameStr)
29 {
30 Create(parent, id, label, pos, size, style, name);
31 }
32
33 bool Create(wxWindow *parent, wxWindowID id,
34 const wxBitmap& label,
35 const wxPoint& pos = wxDefaultPosition,
36 const wxSize& size = wxDefaultSize,
37 long style = 0,
38 const wxString& name = wxStaticBitmapNameStr);
39
40 virtual void SetBitmap(const wxBitmap& bitmap);
41
42 virtual void Command(wxCommandEvent& WXUNUSED(event)) {}
43 virtual void ProcessCommand(wxCommandEvent& WXUNUSED(event)) {}
44 void OnPaint( wxPaintEvent &event ) ;
45
46 wxBitmap GetBitmap() const { return m_bitmap; }
47 wxIcon GetIcon() const
48 {
49 // icons and bitmaps are really the same thing in wxMac
50 return (const wxIcon &)m_bitmap;
51 }
52 void SetIcon(const wxIcon& icon) { SetBitmap( (const wxBitmap &)icon ) ; }
53
54 // overridden base class virtuals
55 virtual bool AcceptsFocus() const { return false; }
56
57 protected:
58 virtual wxSize DoGetBestSize() const;
59
60 wxBitmap m_bitmap;
61 DECLARE_EVENT_TABLE()
62 };
63
64 #endif
65 // _WX_STATBMP_H_