Added more original works and stubs
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@19677 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
26
include/wx/cocoa/NSBox.h
Normal file
26
include/wx/cocoa/NSBox.h
Normal file
@@ -0,0 +1,26 @@
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
// Name: wx/cocoa/NSBox.h
|
||||
// Purpose: wxCocoaNSBox class
|
||||
// Author: David Elliott
|
||||
// Modified by:
|
||||
// Created: 2003/03/19
|
||||
// RCS-ID: $Id:
|
||||
// Copyright: (c) 2003 David Elliott
|
||||
// Licence: wxWindows license
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef __WX_COCOA_NSBOX_H__
|
||||
#define __WX_COCOA_NSBOX_H__
|
||||
|
||||
#include "wx/hashmap.h"
|
||||
#include "wx/cocoa/ObjcPose.h"
|
||||
|
||||
WX_DECLARE_OBJC_HASHMAP(NSBox);
|
||||
class wxCocoaNSBox
|
||||
{
|
||||
WX_DECLARE_OBJC_INTERFACE(NSBox)
|
||||
protected:
|
||||
// virtual void Cocoa_didChangeText(void) = 0;
|
||||
};
|
||||
|
||||
#endif // _WX_COCOA_NSBOX_H_
|
25
include/wx/cocoa/NSPanel.h
Normal file
25
include/wx/cocoa/NSPanel.h
Normal file
@@ -0,0 +1,25 @@
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
// Name: wx/cocoa/NSPanel.h
|
||||
// Purpose: wxCocoaNSPanel class
|
||||
// Author: David Elliott
|
||||
// Modified by:
|
||||
// Created: 2003/03/16
|
||||
// RCS-ID: $Id:
|
||||
// Copyright: (c) 2003 David Elliott
|
||||
// Licence: wxWindows license
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef __WX_COCOA_NSPANEL_H__
|
||||
#define __WX_COCOA_NSPANEL_H__
|
||||
|
||||
#include "wx/hashmap.h"
|
||||
#include "wx/cocoa/ObjcPose.h"
|
||||
|
||||
WX_DECLARE_OBJC_HASHMAP(NSPanel);
|
||||
|
||||
class wxCocoaNSPanel
|
||||
{
|
||||
WX_DECLARE_OBJC_INTERFACE(NSPanel)
|
||||
};
|
||||
|
||||
#endif // _WX_COCOA_NSPANEL_H_
|
59
include/wx/cocoa/bmpbuttn.h
Normal file
59
include/wx/cocoa/bmpbuttn.h
Normal file
@@ -0,0 +1,59 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: wx/cocoa/bmpbuttn.h
|
||||
// Purpose: wxBitmapButton class
|
||||
// Author: David Elliott
|
||||
// Modified by:
|
||||
// Created: 2003/03/16
|
||||
// RCS-ID: $Id:
|
||||
// Copyright: (c) 2003 David Elliott
|
||||
// Licence: wxWindows license
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef __WX_COCOA_BMPBUTTN_H__
|
||||
#define __WX_COCOA_BMPBUTTN_H__
|
||||
|
||||
#include "wx/cocoa/NSButton.h"
|
||||
|
||||
// ========================================================================
|
||||
// wxBitmapButton
|
||||
// ========================================================================
|
||||
class WXDLLEXPORT wxBitmapButton : public wxBitmapButtonBase
|
||||
{
|
||||
DECLARE_DYNAMIC_CLASS(wxBitmapButton)
|
||||
DECLARE_EVENT_TABLE()
|
||||
WX_DECLARE_COCOA_OWNER(NSButton,NSControl,NSView)
|
||||
// ------------------------------------------------------------------------
|
||||
// initialization
|
||||
// ------------------------------------------------------------------------
|
||||
public:
|
||||
wxBitmapButton() { }
|
||||
wxBitmapButton(wxWindow *parent, wxWindowID winid,
|
||||
const wxBitmap& bitmap,
|
||||
const wxPoint& pos = wxDefaultPosition,
|
||||
const wxSize& size = wxDefaultSize, long style = 0,
|
||||
const wxValidator& validator = wxDefaultValidator,
|
||||
const wxString& name = wxButtonNameStr)
|
||||
{
|
||||
Create(parent, winid, bitmap, pos, size, style, validator, name);
|
||||
}
|
||||
|
||||
bool Create(wxWindow *parent, wxWindowID winid,
|
||||
const wxBitmap& bitmap,
|
||||
const wxPoint& pos = wxDefaultPosition,
|
||||
const wxSize& size = wxDefaultSize, long style = 0,
|
||||
const wxValidator& validator = wxDefaultValidator,
|
||||
const wxString& name = wxButtonNameStr);
|
||||
virtual ~wxBitmapButton();
|
||||
|
||||
// ------------------------------------------------------------------------
|
||||
// Cocoa callbacks
|
||||
// ------------------------------------------------------------------------
|
||||
protected:
|
||||
virtual void Cocoa_wxNSButtonAction(void);
|
||||
// ------------------------------------------------------------------------
|
||||
// Implementation
|
||||
// ------------------------------------------------------------------------
|
||||
public:
|
||||
};
|
||||
|
||||
#endif // __WX_COCOA_BMPBUTTN_H__
|
63
include/wx/cocoa/checkbox.h
Normal file
63
include/wx/cocoa/checkbox.h
Normal file
@@ -0,0 +1,63 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: wx/cocoa/checkbox.h
|
||||
// Purpose: wxCheckBox class
|
||||
// Author: David Elliott
|
||||
// Modified by:
|
||||
// Created: 2003/03/16
|
||||
// RCS-ID: $Id:
|
||||
// Copyright: (c) 2003 David Elliott
|
||||
// Licence: wxWindows license
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef __WX_COCOA_CHECKBOX_H__
|
||||
#define __WX_COCOA_CHECKBOX_H__
|
||||
|
||||
#include "wx/cocoa/NSButton.h"
|
||||
|
||||
// ========================================================================
|
||||
// wxCheckBox
|
||||
// ========================================================================
|
||||
class WXDLLEXPORT wxCheckBox: public wxCheckBoxBase , protected wxCocoaNSButton
|
||||
{
|
||||
DECLARE_DYNAMIC_CLASS(wxCheckBox)
|
||||
DECLARE_EVENT_TABLE()
|
||||
WX_DECLARE_COCOA_OWNER(NSButton,NSControl,NSView)
|
||||
// ------------------------------------------------------------------------
|
||||
// initialization
|
||||
// ------------------------------------------------------------------------
|
||||
public:
|
||||
wxCheckBox() { }
|
||||
wxCheckBox(wxWindow *parent, wxWindowID winid,
|
||||
const wxString& label,
|
||||
const wxPoint& pos = wxDefaultPosition,
|
||||
const wxSize& size = wxDefaultSize,
|
||||
long style = 0,
|
||||
const wxValidator& validator = wxDefaultValidator,
|
||||
const wxString& name = wxCheckBoxNameStr)
|
||||
{
|
||||
Create(parent, winid, label, pos, size, style, validator, name);
|
||||
}
|
||||
|
||||
bool Create(wxWindow *parent, wxWindowID winid,
|
||||
const wxString& label,
|
||||
const wxPoint& pos = wxDefaultPosition,
|
||||
const wxSize& size = wxDefaultSize,
|
||||
long style = 0,
|
||||
const wxValidator& validator = wxDefaultValidator,
|
||||
const wxString& name = wxCheckBoxNameStr);
|
||||
virtual ~wxCheckBox();
|
||||
|
||||
// ------------------------------------------------------------------------
|
||||
// Cocoa callbacks
|
||||
// ------------------------------------------------------------------------
|
||||
protected:
|
||||
virtual void Cocoa_wxNSButtonAction(void);
|
||||
// ------------------------------------------------------------------------
|
||||
// Implementation
|
||||
// ------------------------------------------------------------------------
|
||||
public:
|
||||
virtual void SetValue(bool);
|
||||
virtual bool GetValue() const;
|
||||
};
|
||||
|
||||
#endif // __WX_COCOA_CHECKBOX_H__
|
73
include/wx/cocoa/choice.h
Normal file
73
include/wx/cocoa/choice.h
Normal file
@@ -0,0 +1,73 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: wx/cocoa/choice.h
|
||||
// Purpose: wxChoice class
|
||||
// Author: David Elliott
|
||||
// Modified by:
|
||||
// Created: 2003/03/16
|
||||
// RCS-ID: $Id:
|
||||
// Copyright: (c) 2003 David Elliott
|
||||
// Licence: wxWindows license
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef __WX_COCOA_CHOICE_H__
|
||||
#define __WX_COCOA_CHOICE_H__
|
||||
|
||||
//#include "wx/cocoa/NSTableView.h"
|
||||
|
||||
// ========================================================================
|
||||
// wxChoice
|
||||
// ========================================================================
|
||||
class WXDLLEXPORT wxChoice: public wxChoiceBase //, protected wxCocoaNSTableView
|
||||
{
|
||||
DECLARE_DYNAMIC_CLASS(wxChoice)
|
||||
DECLARE_EVENT_TABLE()
|
||||
// WX_DECLARE_COCOA_OWNER(NSTableView,NSControl,NSView)
|
||||
// ------------------------------------------------------------------------
|
||||
// initialization
|
||||
// ------------------------------------------------------------------------
|
||||
public:
|
||||
wxChoice() { }
|
||||
wxChoice(wxWindow *parent, wxWindowID winid,
|
||||
const wxPoint& pos = wxDefaultPosition,
|
||||
const wxSize& size = wxDefaultSize,
|
||||
int n = 0, const wxString choices[] = NULL,
|
||||
long style = 0,
|
||||
const wxValidator& validator = wxDefaultValidator,
|
||||
const wxString& name = wxChoiceNameStr)
|
||||
{
|
||||
Create(parent, winid, pos, size, n, choices, style, validator, name);
|
||||
}
|
||||
|
||||
bool Create(wxWindow *parent, wxWindowID winid,
|
||||
const wxPoint& pos = wxDefaultPosition,
|
||||
const wxSize& size = wxDefaultSize,
|
||||
int n = 0, const wxString choices[] = NULL,
|
||||
long style = 0,
|
||||
const wxValidator& validator = wxDefaultValidator,
|
||||
const wxString& name = wxChoiceNameStr);
|
||||
virtual ~wxChoice();
|
||||
|
||||
// ------------------------------------------------------------------------
|
||||
// Cocoa callbacks
|
||||
// ------------------------------------------------------------------------
|
||||
protected:
|
||||
// ------------------------------------------------------------------------
|
||||
// Implementation
|
||||
// ------------------------------------------------------------------------
|
||||
public:
|
||||
virtual void Clear();
|
||||
virtual void Delete(int);
|
||||
virtual int GetCount() const;
|
||||
virtual wxString GetString(int) const;
|
||||
virtual void SetString(int, const wxString&);
|
||||
virtual int FindString(const wxString&) const;
|
||||
virtual int GetSelection() const;
|
||||
virtual int DoAppend(const wxString&);
|
||||
virtual void DoSetItemClientData(int, void*);
|
||||
virtual void* DoGetItemClientData(int) const;
|
||||
virtual void DoSetItemClientObject(int, wxClientData*);
|
||||
virtual wxClientData* DoGetItemClientObject(int) const;
|
||||
virtual void SetSelection(int);
|
||||
};
|
||||
|
||||
#endif // __WX_COCOA_CHOICE_H__
|
77
include/wx/cocoa/radiobox.h
Normal file
77
include/wx/cocoa/radiobox.h
Normal file
@@ -0,0 +1,77 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: wx/cocoa/radiobox.h
|
||||
// Purpose: wxRadioBox class
|
||||
// Author: David Elliott
|
||||
// Modified by:
|
||||
// Created: 2003/03/18
|
||||
// RCS-ID: $Id:
|
||||
// Copyright: (c) 2003 David Elliott
|
||||
// Licence: wxWindows license
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef __WX_COCOA_RADIOBOX_H__
|
||||
#define __WX_COCOA_RADIOBOX_H__
|
||||
|
||||
// #include "wx/cocoa/NSButton.h"
|
||||
|
||||
// ========================================================================
|
||||
// wxRadioBox
|
||||
// ========================================================================
|
||||
class WXDLLEXPORT wxRadioBox: public wxControl, public wxRadioBoxBase// , protected wxCocoaNSButton
|
||||
{
|
||||
DECLARE_DYNAMIC_CLASS(wxRadioBox)
|
||||
DECLARE_EVENT_TABLE()
|
||||
// WX_DECLARE_COCOA_OWNER(NSButton,NSControl,NSView)
|
||||
// ------------------------------------------------------------------------
|
||||
// initialization
|
||||
// ------------------------------------------------------------------------
|
||||
public:
|
||||
wxRadioBox() { }
|
||||
wxRadioBox(wxWindow *parent, wxWindowID winid,
|
||||
const wxString& title,
|
||||
const wxPoint& pos = wxDefaultPosition,
|
||||
const wxSize& size = wxDefaultSize,
|
||||
int n = 0, const wxString choices[] = NULL,
|
||||
int majorDim = 0,
|
||||
long style = 0, const wxValidator& validator = wxDefaultValidator,
|
||||
const wxString& name = wxRadioBoxNameStr)
|
||||
{
|
||||
Create(parent, winid, title, pos, size, n, choices, majorDim, style, validator, name);
|
||||
}
|
||||
|
||||
bool Create(wxWindow *parent, wxWindowID winid,
|
||||
const wxString& title,
|
||||
const wxPoint& pos = wxDefaultPosition,
|
||||
const wxSize& size = wxDefaultSize,
|
||||
int n = 0, const wxString choices[] = NULL,
|
||||
int majorDim = 0,
|
||||
long style = 0,
|
||||
const wxValidator& validator = wxDefaultValidator,
|
||||
const wxString& name = wxRadioBoxNameStr);
|
||||
virtual ~wxRadioBox();
|
||||
|
||||
// ------------------------------------------------------------------------
|
||||
// Cocoa callbacks
|
||||
// ------------------------------------------------------------------------
|
||||
protected:
|
||||
// ------------------------------------------------------------------------
|
||||
// Implementation
|
||||
// ------------------------------------------------------------------------
|
||||
public:
|
||||
// Pure virtuals
|
||||
// selection
|
||||
virtual void SetSelection(int n);
|
||||
virtual int GetSelection() const;
|
||||
// string access
|
||||
virtual int GetCount() const;
|
||||
virtual wxString GetString(int n) const;
|
||||
virtual void SetString(int n, const wxString& label);
|
||||
// change the individual radio button state
|
||||
virtual void Enable(int n, bool enable = TRUE);
|
||||
virtual void Show(int n, bool show = TRUE);
|
||||
// layout parameters
|
||||
virtual int GetColumnCount() const;
|
||||
virtual int GetRowCount() const;
|
||||
};
|
||||
|
||||
#endif // __WX_COCOA_RADIOBOX_H__
|
63
include/wx/cocoa/radiobut.h
Normal file
63
include/wx/cocoa/radiobut.h
Normal file
@@ -0,0 +1,63 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: wx/cocoa/radiobut.h
|
||||
// Purpose: wxRadioButton class
|
||||
// Author: David Elliott
|
||||
// Modified by:
|
||||
// Created: 2003/03/18
|
||||
// RCS-ID: $Id:
|
||||
// Copyright: (c) 2003 David Elliott
|
||||
// Licence: wxWindows license
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef __WX_COCOA_RADIOBUT_H__
|
||||
#define __WX_COCOA_RADIOBUT_H__
|
||||
|
||||
#include "wx/cocoa/NSButton.h"
|
||||
|
||||
// ========================================================================
|
||||
// wxRadioButton
|
||||
// ========================================================================
|
||||
class WXDLLEXPORT wxRadioButton: public wxControl, protected wxCocoaNSButton
|
||||
{
|
||||
DECLARE_DYNAMIC_CLASS(wxRadioButton)
|
||||
DECLARE_EVENT_TABLE()
|
||||
WX_DECLARE_COCOA_OWNER(NSButton,NSControl,NSView)
|
||||
// ------------------------------------------------------------------------
|
||||
// initialization
|
||||
// ------------------------------------------------------------------------
|
||||
public:
|
||||
wxRadioButton() { }
|
||||
wxRadioButton(wxWindow *parent, wxWindowID winid,
|
||||
const wxString& label,
|
||||
const wxPoint& pos = wxDefaultPosition,
|
||||
const wxSize& size = wxDefaultSize,
|
||||
long style = 0,
|
||||
const wxValidator& validator = wxDefaultValidator,
|
||||
const wxString& name = wxRadioButtonNameStr)
|
||||
{
|
||||
Create(parent, winid, label, pos, size, style, validator, name);
|
||||
}
|
||||
|
||||
bool Create(wxWindow *parent, wxWindowID winid,
|
||||
const wxString& label,
|
||||
const wxPoint& pos = wxDefaultPosition,
|
||||
const wxSize& size = wxDefaultSize,
|
||||
long style = 0,
|
||||
const wxValidator& validator = wxDefaultValidator,
|
||||
const wxString& name = wxRadioButtonNameStr);
|
||||
virtual ~wxRadioButton();
|
||||
|
||||
// ------------------------------------------------------------------------
|
||||
// Cocoa callbacks
|
||||
// ------------------------------------------------------------------------
|
||||
protected:
|
||||
virtual void Cocoa_wxNSButtonAction(void);
|
||||
// ------------------------------------------------------------------------
|
||||
// Implementation
|
||||
// ------------------------------------------------------------------------
|
||||
public:
|
||||
virtual void SetValue(bool);
|
||||
virtual bool GetValue() const;
|
||||
};
|
||||
|
||||
#endif // __WX_COCOA_RADIOBUT_H__
|
57
include/wx/cocoa/statbmp.h
Normal file
57
include/wx/cocoa/statbmp.h
Normal file
@@ -0,0 +1,57 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: wx/cocoa/statbmp.h
|
||||
// Purpose: wxStaticBitmap class
|
||||
// Author: David Elliott
|
||||
// Modified by:
|
||||
// Created: 2003/03/16
|
||||
// RCS-ID: $Id:
|
||||
// Copyright: (c) 2003 David Elliott
|
||||
// Licence: wxWindows license
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef __WX_COCOA_STATBMP_H__
|
||||
#define __WX_COCOA_STATBMP_H__
|
||||
|
||||
// #include "wx/cocoa/NSxxx.h"
|
||||
|
||||
// ========================================================================
|
||||
// wxStaticBitmap
|
||||
// ========================================================================
|
||||
class WXDLLEXPORT wxStaticBitmap : public wxStaticBitmapBase //, protected wxCocoaNSxxx
|
||||
{
|
||||
DECLARE_DYNAMIC_CLASS(wxStaticBitmap)
|
||||
DECLARE_EVENT_TABLE()
|
||||
// WX_DECLARE_COCOA_OWNER(NSxxx,NSControl,NSView)
|
||||
// ------------------------------------------------------------------------
|
||||
// initialization
|
||||
// ------------------------------------------------------------------------
|
||||
public:
|
||||
wxStaticBitmap() {}
|
||||
wxStaticBitmap(wxWindow *parent, wxWindowID winid,
|
||||
const wxBitmap& bitmap,
|
||||
const wxPoint& pos = wxDefaultPosition,
|
||||
const wxSize& size = wxDefaultSize, long style = 0,
|
||||
const wxString& name = wxStaticBitmapNameStr)
|
||||
{
|
||||
Create(parent, winid, bitmap, pos, size, style, name);
|
||||
}
|
||||
|
||||
bool Create(wxWindow *parent, wxWindowID winid,
|
||||
const wxBitmap& bitmap,
|
||||
const wxPoint& pos = wxDefaultPosition,
|
||||
const wxSize& size = wxDefaultSize, long style = 0,
|
||||
const wxString& name = wxStaticBitmapNameStr);
|
||||
virtual ~wxStaticBitmap();
|
||||
|
||||
// ------------------------------------------------------------------------
|
||||
// Cocoa specifics
|
||||
// ------------------------------------------------------------------------
|
||||
// ------------------------------------------------------------------------
|
||||
// Implementation
|
||||
// ------------------------------------------------------------------------
|
||||
virtual void SetIcon(const wxIcon& icon);
|
||||
virtual void SetBitmap(const wxBitmap& bitmap);
|
||||
virtual wxBitmap GetBitmap() const;
|
||||
};
|
||||
|
||||
#endif // __WX_COCOA_STATBMP_H__
|
59
include/wx/cocoa/statbox.h
Normal file
59
include/wx/cocoa/statbox.h
Normal file
@@ -0,0 +1,59 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: wx/cocoa/statbox.h
|
||||
// Purpose: wxStaticBox class
|
||||
// Author: David Elliott
|
||||
// Modified by:
|
||||
// Created: 2003/03/18
|
||||
// RCS-ID: $Id:
|
||||
// Copyright: (c) 2003 David Elliott
|
||||
// Licence: wxWindows license
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef __WX_COCOA_STATBOX_H__
|
||||
#define __WX_COCOA_STATBOX_H__
|
||||
|
||||
#include "wx/cocoa/NSBox.h"
|
||||
|
||||
// ========================================================================
|
||||
// wxStaticBox
|
||||
// ========================================================================
|
||||
class WXDLLEXPORT wxStaticBox: public wxStaticBoxBase, protected wxCocoaNSBox
|
||||
{
|
||||
DECLARE_DYNAMIC_CLASS(wxStaticBox)
|
||||
DECLARE_EVENT_TABLE()
|
||||
WX_DECLARE_COCOA_OWNER(NSBox,NSView,NSView)
|
||||
// ------------------------------------------------------------------------
|
||||
// initialization
|
||||
// ------------------------------------------------------------------------
|
||||
public:
|
||||
wxStaticBox() { }
|
||||
wxStaticBox(wxWindow *parent, wxWindowID winid,
|
||||
const wxString& title,
|
||||
const wxPoint& pos = wxDefaultPosition,
|
||||
const wxSize& size = wxDefaultSize,
|
||||
long style = 0, const wxValidator& validator = wxDefaultValidator,
|
||||
const wxString& name = wxStaticBoxNameStr)
|
||||
{
|
||||
Create(parent, winid, title, pos, size, style, validator, name);
|
||||
}
|
||||
|
||||
bool Create(wxWindow *parent, wxWindowID winid,
|
||||
const wxString& title,
|
||||
const wxPoint& pos = wxDefaultPosition,
|
||||
const wxSize& size = wxDefaultSize,
|
||||
long style = 0,
|
||||
const wxValidator& validator = wxDefaultValidator,
|
||||
const wxString& name = wxStaticBoxNameStr);
|
||||
virtual ~wxStaticBox();
|
||||
|
||||
// ------------------------------------------------------------------------
|
||||
// Cocoa callbacks
|
||||
// ------------------------------------------------------------------------
|
||||
protected:
|
||||
// ------------------------------------------------------------------------
|
||||
// Implementation
|
||||
// ------------------------------------------------------------------------
|
||||
public:
|
||||
};
|
||||
|
||||
#endif // __WX_COCOA_STATBOX_H__
|
54
include/wx/cocoa/statline.h
Normal file
54
include/wx/cocoa/statline.h
Normal file
@@ -0,0 +1,54 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: wx/cocoa/statline.h
|
||||
// Purpose: wxStaticLine class
|
||||
// Author: David Elliott
|
||||
// Modified by:
|
||||
// Created: 2003/03/18
|
||||
// RCS-ID: $Id:
|
||||
// Copyright: (c) 2003 David Elliott
|
||||
// Licence: wxWindows license
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef __WX_COCOA_STATLINE_H__
|
||||
#define __WX_COCOA_STATLINE_H__
|
||||
|
||||
// #include "wx/cocoa/NSButton.h"
|
||||
|
||||
// ========================================================================
|
||||
// wxStaticLine
|
||||
// ========================================================================
|
||||
class WXDLLEXPORT wxStaticLine: public wxStaticLineBase// , protected wxCocoaNSButton
|
||||
{
|
||||
DECLARE_DYNAMIC_CLASS(wxStaticLine)
|
||||
DECLARE_EVENT_TABLE()
|
||||
// WX_DECLARE_COCOA_OWNER(NSButton,NSControl,NSView)
|
||||
// ------------------------------------------------------------------------
|
||||
// initialization
|
||||
// ------------------------------------------------------------------------
|
||||
public:
|
||||
wxStaticLine() { }
|
||||
wxStaticLine(wxWindow *parent, wxWindowID winid,
|
||||
const wxPoint& pos = wxDefaultPosition,
|
||||
const wxSize& size = wxDefaultSize,
|
||||
long style = 0, const wxString& name = wxStaticTextNameStr)
|
||||
{
|
||||
Create(parent, winid, pos, size, style, name);
|
||||
}
|
||||
|
||||
bool Create(wxWindow *parent, wxWindowID winid,
|
||||
const wxPoint& pos = wxDefaultPosition,
|
||||
const wxSize& size = wxDefaultSize,
|
||||
long style = 0, const wxString& name = wxStaticTextNameStr);
|
||||
virtual ~wxStaticLine();
|
||||
|
||||
// ------------------------------------------------------------------------
|
||||
// Cocoa callbacks
|
||||
// ------------------------------------------------------------------------
|
||||
protected:
|
||||
// ------------------------------------------------------------------------
|
||||
// Implementation
|
||||
// ------------------------------------------------------------------------
|
||||
public:
|
||||
};
|
||||
|
||||
#endif // __WX_COCOA_STATLINE_H__
|
30
src/cocoa/NSBox.mm
Normal file
30
src/cocoa/NSBox.mm
Normal file
@@ -0,0 +1,30 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: cocoa/NSBox.mm
|
||||
// Purpose: wxCocoaNSBox
|
||||
// Author: David Elliott
|
||||
// Modified by:
|
||||
// Created: 2003/03/19
|
||||
// RCS-ID: $Id:
|
||||
// Copyright: (c) 2003 David Elliott
|
||||
// Licence: wxWindows license
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
// ============================================================================
|
||||
// declarations
|
||||
// ============================================================================
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// headers
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
#include "wx/wxprec.h"
|
||||
#ifndef WX_PRECOMP
|
||||
#endif // WX_PRECOMP
|
||||
|
||||
#include "wx/cocoa/NSBox.h"
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// globals
|
||||
// ----------------------------------------------------------------------------
|
||||
WX_IMPLEMENT_OBJC_INTERFACE(NSBox)
|
||||
|
33
src/cocoa/NSPanel.mm
Normal file
33
src/cocoa/NSPanel.mm
Normal file
@@ -0,0 +1,33 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: cocoa/NSPanel.mm
|
||||
// Purpose: wxCocoaNSPanel
|
||||
// Author: David Elliott
|
||||
// Modified by:
|
||||
// Created: 2003/03/16
|
||||
// RCS-ID: $Id:
|
||||
// Copyright: (c) 2003 David Elliott
|
||||
// Licence: wxWindows license
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
// ============================================================================
|
||||
// declarations
|
||||
// ============================================================================
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// headers
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
#include "wx/wxprec.h"
|
||||
#ifndef WX_PRECOMP
|
||||
#include "wx/log.h"
|
||||
#endif // WX_PRECOMP
|
||||
|
||||
#include "wx/cocoa/NSPanel.h"
|
||||
|
||||
#import <Appkit/NSPanel.h>
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// globals
|
||||
// ----------------------------------------------------------------------------
|
||||
WX_IMPLEMENT_OBJC_INTERFACE_HASHMAP(NSPanel)
|
||||
|
66
src/cocoa/bmpbuttn.mm
Normal file
66
src/cocoa/bmpbuttn.mm
Normal file
@@ -0,0 +1,66 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: cocoa/bmpbuttn.mm
|
||||
// Purpose: wxBitmapButton
|
||||
// Author: David Elliott
|
||||
// Modified by:
|
||||
// Created: 2003/03/16
|
||||
// RCS-ID: $Id:
|
||||
// Copyright: (c) 2003 David Elliott
|
||||
// Licence: wxWindows license
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include "wx/wxprec.h"
|
||||
#ifndef WX_PRECOMP
|
||||
#include "wx/defs.h"
|
||||
#include "wx/bmpbuttn.h"
|
||||
#include "wx/log.h"
|
||||
#endif
|
||||
|
||||
#import <AppKit/NSButton.h>
|
||||
#import <Foundation/NSString.h>
|
||||
|
||||
IMPLEMENT_DYNAMIC_CLASS(wxBitmapButton, wxControl)
|
||||
BEGIN_EVENT_TABLE(wxBitmapButton, wxBitmapButtonBase)
|
||||
END_EVENT_TABLE()
|
||||
WX_IMPLEMENT_COCOA_OWNER(wxBitmapButton,NSButton,NSControl,NSView)
|
||||
|
||||
bool wxBitmapButton::Create(wxWindow *parent, wxWindowID winid,
|
||||
const wxBitmap& bitmap, const wxPoint& pos,
|
||||
const wxSize& size, long style,
|
||||
const wxValidator& validator, const wxString& name)
|
||||
{
|
||||
wxLogDebug("Creating control with id=%d",winid);
|
||||
if(!CreateControl(parent,winid,pos,size,style,validator,name))
|
||||
return false;
|
||||
wxLogDebug("Created control with id=%d",GetId());
|
||||
NSRect cocoaRect = NSMakeRect(10,10,20,20);
|
||||
m_cocoaNSView = NULL;
|
||||
SetNSButton([[NSButton alloc] initWithFrame: cocoaRect]);
|
||||
// NOTE: YES we want to release this (to match the alloc).
|
||||
// DoAddChild(this) will retain us again since addSubView doesn't.
|
||||
[m_cocoaNSView release];
|
||||
|
||||
[GetNSButton() setBezelStyle:NSRoundedBezelStyle];
|
||||
[GetNSButton() setTitle:@"Bitmap Button"];
|
||||
[GetNSControl() sizeToFit];
|
||||
|
||||
if(m_parent)
|
||||
m_parent->CocoaAddChild(this);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
wxBitmapButton::~wxBitmapButton()
|
||||
{
|
||||
CocoaRemoveFromParent();
|
||||
SetNSButton(NULL);
|
||||
}
|
||||
|
||||
void wxBitmapButton::Cocoa_wxNSButtonAction(void)
|
||||
{
|
||||
wxLogDebug("YAY!");
|
||||
wxCommandEvent event(wxEVT_COMMAND_BUTTON_CLICKED, GetId());
|
||||
InitCommandEvent(event); // event.SetEventObject(this);
|
||||
Command(event);
|
||||
}
|
||||
|
66
src/cocoa/checkbox.mm
Normal file
66
src/cocoa/checkbox.mm
Normal file
@@ -0,0 +1,66 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: cocoa/checkbox.mm
|
||||
// Purpose: wxCheckBox
|
||||
// Author: David Elliott
|
||||
// Modified by:
|
||||
// Created: 2003/03/16
|
||||
// RCS-ID: $Id:
|
||||
// Copyright: (c) 2003 David Elliott
|
||||
// Licence: wxWindows license
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include "wx/app.h"
|
||||
#include "wx/checkbox.h"
|
||||
#include "wx/log.h"
|
||||
|
||||
#import <AppKit/NSButton.h>
|
||||
#import <Foundation/NSString.h>
|
||||
|
||||
IMPLEMENT_DYNAMIC_CLASS(wxCheckBox, wxControl)
|
||||
BEGIN_EVENT_TABLE(wxCheckBox, wxCheckBoxBase)
|
||||
END_EVENT_TABLE()
|
||||
WX_IMPLEMENT_COCOA_OWNER(wxCheckBox,NSButton,NSControl,NSView)
|
||||
|
||||
bool wxCheckBox::Create(wxWindow *parent, wxWindowID winid,
|
||||
const wxString& label,
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
long style,
|
||||
const wxValidator& validator,
|
||||
const wxString& name)
|
||||
{
|
||||
if(!CreateControl(parent,winid,pos,size,style,validator,name))
|
||||
return false;
|
||||
m_cocoaNSView = NULL;
|
||||
NSRect cocoaRect = NSMakeRect(10,10,20,20);
|
||||
SetNSButton([[NSButton alloc] initWithFrame: cocoaRect]);
|
||||
[m_cocoaNSView release];
|
||||
[GetNSButton() setButtonType: NSSwitchButton];
|
||||
[GetNSButton() setTitle:[NSString stringWithCString: label.c_str()]];
|
||||
[GetNSControl() sizeToFit];
|
||||
|
||||
if(m_parent)
|
||||
m_parent->CocoaAddChild(this);
|
||||
return true;
|
||||
}
|
||||
|
||||
wxCheckBox::~wxCheckBox()
|
||||
{
|
||||
CocoaRemoveFromParent();
|
||||
SetNSButton(NULL);
|
||||
}
|
||||
|
||||
void wxCheckBox::SetValue(bool)
|
||||
{
|
||||
}
|
||||
|
||||
bool wxCheckBox::GetValue() const
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
void wxCheckBox::Cocoa_wxNSButtonAction(void)
|
||||
{
|
||||
wxLogDebug("Checkbox");
|
||||
}
|
||||
|
51
src/cocoa/checklst.mm
Normal file
51
src/cocoa/checklst.mm
Normal file
@@ -0,0 +1,51 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: cocoa/checklst.mm
|
||||
// Purpose: wxCheckListBox
|
||||
// Author: David Elliott
|
||||
// Modified by:
|
||||
// Created: 2003/03/18
|
||||
// RCS-ID: $Id:
|
||||
// Copyright: (c) 2003 David Elliott
|
||||
// Licence: wxWindows license
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include "wx/app.h"
|
||||
#include "wx/checklst.h"
|
||||
#include "wx/log.h"
|
||||
|
||||
IMPLEMENT_DYNAMIC_CLASS(wxCheckListBox, wxListBox)
|
||||
BEGIN_EVENT_TABLE(wxCheckListBox, wxCheckListBoxBase)
|
||||
END_EVENT_TABLE()
|
||||
// WX_IMPLEMENT_COCOA_OWNER(wxCheckListBox,NSButton,NSControl,NSView)
|
||||
|
||||
bool wxCheckListBox::Create(wxWindow *parent, wxWindowID winid,
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
int n, const wxString choices[],
|
||||
long style,
|
||||
const wxValidator& validator,
|
||||
const wxString& name)
|
||||
{
|
||||
if(!CreateControl(parent,winid,pos,size,style,validator,name))
|
||||
return false;
|
||||
|
||||
if(m_parent)
|
||||
m_parent->CocoaAddChild(this);
|
||||
return true;
|
||||
}
|
||||
|
||||
wxCheckListBox::~wxCheckListBox()
|
||||
{
|
||||
CocoaRemoveFromParent();
|
||||
}
|
||||
|
||||
bool wxCheckListBox::IsChecked(size_t item) const
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
void wxCheckListBox::Check(size_t item, bool check)
|
||||
{
|
||||
}
|
||||
|
100
src/cocoa/choice.mm
Normal file
100
src/cocoa/choice.mm
Normal file
@@ -0,0 +1,100 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: cocoa/choice.mm
|
||||
// Purpose: wxChoice
|
||||
// Author: David Elliott
|
||||
// Modified by:
|
||||
// Created: 2003/03/16
|
||||
// RCS-ID: $Id:
|
||||
// Copyright: (c) 2003 David Elliott
|
||||
// Licence: wxWindows license
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include "wx/app.h"
|
||||
#include "wx/choice.h"
|
||||
#include "wx/log.h"
|
||||
|
||||
IMPLEMENT_DYNAMIC_CLASS(wxChoice, wxControl)
|
||||
BEGIN_EVENT_TABLE(wxChoice, wxChoiceBase)
|
||||
END_EVENT_TABLE()
|
||||
// WX_IMPLEMENT_COCOA_OWNER(wxChoice,NSButton,NSControl,NSView)
|
||||
|
||||
bool wxChoice::Create(wxWindow *parent, wxWindowID winid,
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
int n, const wxString choices[],
|
||||
long style,
|
||||
const wxValidator& validator,
|
||||
const wxString& name)
|
||||
{
|
||||
if(!CreateControl(parent,winid,pos,size,style,validator,name))
|
||||
return false;
|
||||
|
||||
if(m_parent)
|
||||
m_parent->CocoaAddChild(this);
|
||||
return true;
|
||||
}
|
||||
|
||||
wxChoice::~wxChoice()
|
||||
{
|
||||
CocoaRemoveFromParent();
|
||||
}
|
||||
|
||||
void wxChoice::Clear()
|
||||
{
|
||||
}
|
||||
|
||||
void wxChoice::Delete(int)
|
||||
{
|
||||
}
|
||||
|
||||
int wxChoice::GetCount() const
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
wxString wxChoice::GetString(int) const
|
||||
{
|
||||
return wxEmptyString;
|
||||
}
|
||||
|
||||
void wxChoice::SetString(int, const wxString&)
|
||||
{
|
||||
}
|
||||
|
||||
int wxChoice::FindString(const wxString&) const
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
int wxChoice::GetSelection() const
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
int wxChoice::DoAppend(const wxString&)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
void wxChoice::DoSetItemClientData(int, void*)
|
||||
{
|
||||
}
|
||||
|
||||
void* wxChoice::DoGetItemClientData(int) const
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void wxChoice::DoSetItemClientObject(int, wxClientData*)
|
||||
{
|
||||
}
|
||||
|
||||
wxClientData* wxChoice::DoGetItemClientObject(int) const
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void wxChoice::SetSelection(int)
|
||||
{
|
||||
}
|
||||
|
86
src/cocoa/radiobox.mm
Normal file
86
src/cocoa/radiobox.mm
Normal file
@@ -0,0 +1,86 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: cocoa/radiobox.mm
|
||||
// Purpose: wxRadioBox
|
||||
// Author: David Elliott
|
||||
// Modified by:
|
||||
// Created: 2003/02/15
|
||||
// RCS-ID: $Id:
|
||||
// Copyright: (c) 2003 David Elliott
|
||||
// Licence: wxWindows license
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include "wx/app.h"
|
||||
#include "wx/radiobox.h"
|
||||
|
||||
IMPLEMENT_DYNAMIC_CLASS(wxRadioBox, wxControl)
|
||||
BEGIN_EVENT_TABLE(wxRadioBox, wxControl)
|
||||
END_EVENT_TABLE()
|
||||
// WX_IMPLEMENT_COCOA_OWNER(wxRadioBox,NSTextField,NSControl,NSView)
|
||||
|
||||
bool wxRadioBox::Create(wxWindow *parent, wxWindowID winid,
|
||||
const wxString& title,
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
int n, const wxString choices[],
|
||||
int majorDim,
|
||||
long style, const wxValidator& validator,
|
||||
const wxString& name)
|
||||
{
|
||||
if(!CreateControl(parent,winid,pos,size,style,validator,name))
|
||||
return false;
|
||||
m_cocoaNSView = NULL;
|
||||
if(m_parent)
|
||||
m_parent->CocoaAddChild(this);
|
||||
return true;
|
||||
}
|
||||
|
||||
wxRadioBox::~wxRadioBox()
|
||||
{
|
||||
CocoaRemoveFromParent();
|
||||
}
|
||||
|
||||
// selection
|
||||
void wxRadioBox::SetSelection(int n)
|
||||
{
|
||||
}
|
||||
|
||||
int wxRadioBox::GetSelection() const
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
// string access
|
||||
int wxRadioBox::GetCount() const
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
wxString wxRadioBox::GetString(int n) const
|
||||
{
|
||||
return wxEmptyString;
|
||||
}
|
||||
|
||||
void wxRadioBox::SetString(int n, const wxString& label)
|
||||
{
|
||||
}
|
||||
|
||||
// change the individual radio button state
|
||||
void wxRadioBox::Enable(int n, bool enable)
|
||||
{
|
||||
}
|
||||
|
||||
void wxRadioBox::Show(int n, bool show)
|
||||
{
|
||||
}
|
||||
|
||||
// layout parameters
|
||||
int wxRadioBox::GetColumnCount() const
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
int wxRadioBox::GetRowCount() const
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
67
src/cocoa/radiobut.mm
Normal file
67
src/cocoa/radiobut.mm
Normal file
@@ -0,0 +1,67 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: cocoa/radiobut.mm
|
||||
// Purpose: wxRadioButton
|
||||
// Author: David Elliott
|
||||
// Modified by:
|
||||
// Created: 2003/03/16
|
||||
// RCS-ID: $Id:
|
||||
// Copyright: (c) 2003 David Elliott
|
||||
// Licence: wxWindows license
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include "wx/app.h"
|
||||
#include "wx/radiobut.h"
|
||||
#include "wx/log.h"
|
||||
|
||||
#import <AppKit/NSButton.h>
|
||||
#import <Foundation/NSString.h>
|
||||
|
||||
IMPLEMENT_DYNAMIC_CLASS(wxRadioButton, wxControl)
|
||||
// wxRadioButtonBase == wxControl
|
||||
BEGIN_EVENT_TABLE(wxRadioButton, wxControl)
|
||||
END_EVENT_TABLE()
|
||||
WX_IMPLEMENT_COCOA_OWNER(wxRadioButton,NSButton,NSControl,NSView)
|
||||
|
||||
bool wxRadioButton::Create(wxWindow *parent, wxWindowID winid,
|
||||
const wxString& label,
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
long style,
|
||||
const wxValidator& validator,
|
||||
const wxString& name)
|
||||
{
|
||||
if(!CreateControl(parent,winid,pos,size,style,validator,name))
|
||||
return false;
|
||||
m_cocoaNSView = NULL;
|
||||
NSRect cocoaRect = NSMakeRect(10,10,20,20);
|
||||
SetNSButton([[NSButton alloc] initWithFrame: cocoaRect]);
|
||||
[m_cocoaNSView release];
|
||||
[GetNSButton() setButtonType: NSRadioButton];
|
||||
[GetNSButton() setTitle:[NSString stringWithCString: label.c_str()]];
|
||||
[GetNSControl() sizeToFit];
|
||||
|
||||
if(m_parent)
|
||||
m_parent->CocoaAddChild(this);
|
||||
return true;
|
||||
}
|
||||
|
||||
wxRadioButton::~wxRadioButton()
|
||||
{
|
||||
CocoaRemoveFromParent();
|
||||
SetNSButton(NULL);
|
||||
}
|
||||
|
||||
void wxRadioButton::SetValue(bool)
|
||||
{
|
||||
}
|
||||
|
||||
bool wxRadioButton::GetValue() const
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
void wxRadioButton::Cocoa_wxNSButtonAction(void)
|
||||
{
|
||||
wxLogDebug("wxRadioButton");
|
||||
}
|
||||
|
52
src/cocoa/statbmp.mm
Normal file
52
src/cocoa/statbmp.mm
Normal file
@@ -0,0 +1,52 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: cocoa/statbmp.mm
|
||||
// Purpose: wxStaticBitmap
|
||||
// Author: David Elliott
|
||||
// Modified by:
|
||||
// Created: 2003/02/15
|
||||
// RCS-ID: $Id:
|
||||
// Copyright: (c) 2003 David Elliott
|
||||
// Licence: wxWindows license
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include "wx/app.h"
|
||||
#include "wx/statbmp.h"
|
||||
|
||||
IMPLEMENT_DYNAMIC_CLASS(wxStaticBitmap, wxControl)
|
||||
BEGIN_EVENT_TABLE(wxStaticBitmap, wxControl)
|
||||
END_EVENT_TABLE()
|
||||
// WX_IMPLEMENT_COCOA_OWNER(wxStaticBitmap,NSTextField,NSControl,NSView)
|
||||
|
||||
bool wxStaticBitmap::Create(wxWindow *parent, wxWindowID winid,
|
||||
const wxBitmap& bitmap,
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
long style,
|
||||
const wxString& name)
|
||||
{
|
||||
if(!CreateControl(parent,winid,pos,size,style,wxDefaultValidator,name))
|
||||
return false;
|
||||
m_cocoaNSView = NULL;
|
||||
if(m_parent)
|
||||
m_parent->CocoaAddChild(this);
|
||||
return true;
|
||||
}
|
||||
|
||||
wxStaticBitmap::~wxStaticBitmap()
|
||||
{
|
||||
CocoaRemoveFromParent();
|
||||
}
|
||||
|
||||
void wxStaticBitmap::SetIcon(const wxIcon& icon)
|
||||
{
|
||||
}
|
||||
|
||||
void wxStaticBitmap::SetBitmap(const wxBitmap& bitmap)
|
||||
{
|
||||
}
|
||||
|
||||
wxBitmap wxStaticBitmap::GetBitmap() const
|
||||
{
|
||||
return wxNullBitmap;
|
||||
}
|
||||
|
45
src/cocoa/statbox.mm
Normal file
45
src/cocoa/statbox.mm
Normal file
@@ -0,0 +1,45 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: cocoa/statbox.mm
|
||||
// Purpose: wxStaticBox
|
||||
// Author: David Elliott
|
||||
// Modified by:
|
||||
// Created: 2003/02/15
|
||||
// RCS-ID: $Id:
|
||||
// Copyright: (c) 2003 David Elliott
|
||||
// Licence: wxWindows license
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include "wx/app.h"
|
||||
#include "wx/statbox.h"
|
||||
|
||||
#import <AppKit/NSBox.h>
|
||||
#import <Foundation/NSString.h>
|
||||
|
||||
IMPLEMENT_DYNAMIC_CLASS(wxStaticBox, wxControl)
|
||||
BEGIN_EVENT_TABLE(wxStaticBox, wxStaticBoxBase)
|
||||
END_EVENT_TABLE()
|
||||
WX_IMPLEMENT_COCOA_OWNER(wxStaticBox,NSBox,NSView,NSView)
|
||||
|
||||
bool wxStaticBox::Create(wxWindow *parent, wxWindowID winid,
|
||||
const wxString& title,
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
long style, const wxValidator& validator,
|
||||
const wxString& name)
|
||||
{
|
||||
if(!CreateControl(parent,winid,pos,size,style,validator,name))
|
||||
return false;
|
||||
m_cocoaNSView = NULL;
|
||||
SetNSBox([[NSBox alloc] initWithFrame:NSMakeRect(0,0,30,30)]);
|
||||
[GetNSBox() setTitle:[NSString stringWithCString:title.c_str()]];
|
||||
if(m_parent)
|
||||
m_parent->CocoaAddChild(this);
|
||||
return true;
|
||||
}
|
||||
|
||||
wxStaticBox::~wxStaticBox()
|
||||
{
|
||||
CocoaRemoveFromParent();
|
||||
SetNSBox(NULL);
|
||||
}
|
||||
|
38
src/cocoa/statline2.mm
Normal file
38
src/cocoa/statline2.mm
Normal file
@@ -0,0 +1,38 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: cocoa/statline.mm
|
||||
// Purpose: wxStaticLine
|
||||
// Author: David Elliott
|
||||
// Modified by:
|
||||
// Created: 2003/02/15
|
||||
// RCS-ID: $Id:
|
||||
// Copyright: (c) 2003 David Elliott
|
||||
// Licence: wxWindows license
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include "wx/app.h"
|
||||
#include "wx/statline.h"
|
||||
|
||||
IMPLEMENT_DYNAMIC_CLASS(wxStaticLine, wxControl)
|
||||
BEGIN_EVENT_TABLE(wxStaticLine, wxStaticLineBase)
|
||||
END_EVENT_TABLE()
|
||||
// WX_IMPLEMENT_COCOA_OWNER(wxStaticLine,NSTextField,NSControl,NSView)
|
||||
|
||||
bool wxStaticLine::Create(wxWindow *parent, wxWindowID winid,
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
long style,
|
||||
const wxString& name)
|
||||
{
|
||||
if(!CreateControl(parent,winid,pos,size,style,wxDefaultValidator,name))
|
||||
return false;
|
||||
m_cocoaNSView = NULL;
|
||||
if(m_parent)
|
||||
m_parent->CocoaAddChild(this);
|
||||
return true;
|
||||
}
|
||||
|
||||
wxStaticLine::~wxStaticLine()
|
||||
{
|
||||
CocoaRemoveFromParent();
|
||||
}
|
||||
|
Reference in New Issue
Block a user