\membersection{wxPropertySheet::wxPropertySheet}
-\func{void}{wxPropertySheet}{\void}
+\func{void}{wxPropertySheet}{\param{const wxString}{ name = ""}}
-Constructor.
+Constructor. Sets property sheet's name to name if present.
\membersection{wxPropertySheet::\destruct{wxPropertySheet}}
Clears all the properties from the sheet (deleting them).
+\membersection{wxPropertySheet::GetName}\label{wxpropertysheetgetname}
+
+\func{wxString}{GetName}{\void}
+
+Gets the sheet's name.
+
+\membersection{wxPropertySheet::GetProperty}\label{wxpropertysheetgetproperty}
+
+\func{wxProperty *}{GetProperty}{\param{wxString}{ name}}
+
+Gets a property by name.
+
\membersection{wxPropertySheet::GetProperties}\label{wxpropertysheetgetproperties}
\func{wxList\&}{GetProperties}{\void}
Returns a reference to the internal list of properties.
-\membersection{wxPropertySheet::GetProperty}\label{wxpropertysheetgetproperty}
+\membersection{wxPropertySheet::HasProperty}\label{wxpropertysheethasproperty}
-\func{wxProperty *}{GetProperty}{\param{char *}{name}}
+\func{bool}{HasProperty}{\param{wxString}{ propname}}
-Gets a property by name.
+Returns true if sheet contains property propname.
+
+\membersection{wxPropertySheet::RemoveProperty}\label{wxpropertysheetremoveproperty}
+
+\func{void}{RemoveProperty}{\param{wxString}{ propname}}
+
+Removes property propname from sheet, deleting it.
+
+\membersection{wxPropertySheet::SetName}\label{wxpropertysheetsetname}
+
+\func{void}{SetName}{\param{wxString}{ sheetname}}
+
+Set the sheet's name to sheetname
+
+\membersection{wxPropertySheet::SetProperty}\label{wxpropertysheetsetproperty}
+
+\func{bool}{SetProperty}{\param{wxString}{ propname}, \param{wxPropertyValue}{ value}}
+
+Sets property propname to value. Returns false if property is not a member of sheet.
\membersection{wxPropertySheet::SetAllModified}
...
- wxNode *node = SomeList.First();
+ wxNode *node = SomeList.GetFirst();
while (node)
{
wxPoint *point = (wxPoint *)node->Data();
...
delete point;
delete node;
- node = SomeList.First();
+ node = SomeList.GetFirst();
...
\end{verbatim}
Returns the node whose stored key matches {\it key}. Use on a keyed list only.
-\membersection{wxList::First}
+\membersection{wxList::GetFirst}
-\func{wxNode *}{First}{\void}
+\func{wxNode *}{GetFirst}{\void}
Returns the first node in the list (NULL if the list is empty).
Insert object before {\it position}.
-\membersection{wxList::Last}
+\membersection{wxList::GetLast}
-\func{wxNode *}{Last}{\void}
+\func{wxNode *}{GetLast}{\void}
Returns the last node in the list (NULL if the list is empty).
inline WXHWND GetEditValue() const { return m_staticValue; }
virtual bool ContainsHWND(WXHWND hWnd) const;
- // Backward compatibility: translate to familiar wxEVT_COMMAND_SLIDER_UPDATED
-#if WXWIN_COMPATIBILITY
- void OnScroll(wxScrollEvent& event);
-#endif
-
void Command(wxCommandEvent& event);
virtual WXHBRUSH OnCtlColor(WXHDC pDC, WXHWND pWnd, WXUINT nCtlColor,
WXUINT message, WXWPARAM wParam, WXLPARAM lParam);
int m_pageSize;
int m_lineSize;
int m_tickFreq;
-DECLARE_EVENT_TABLE()
};
#endif
inline WXHWND GetEditValue() const { return m_staticValue; }
virtual bool ContainsHWND(WXHWND hWnd) const;
- // Backward compatibility: translate to familiar wxEVT_COMMAND_SLIDER_UPDATED
-#if WXWIN_COMPATIBILITY
- void OnScroll(wxScrollEvent& event);
-#endif
-
void Command(wxCommandEvent& event);
virtual WXHBRUSH OnCtlColor(WXHDC pDC, WXHWND pWnd, WXUINT nCtlColor,
WXUINT message, WXWPARAM wParam, WXLPARAM lParam);
int m_pageSize;
int m_lineSize;
int m_tickFreq;
-#if WXWIN_COMPATIBILITY
-DECLARE_EVENT_TABLE()
-#endif
};
#endif
{
DECLARE_DYNAMIC_CLASS(wxPropertySheet)
public:
- wxPropertySheet(void);
+ wxPropertySheet(wxString name = "");
~wxPropertySheet(void);
+ // Set the name of the sheet
+ inline virtual void SetName(wxString name) { m_name=name; }
+ inline virtual wxString GetName() { return m_name; }
+ // Does this sheet contain a property with this name
+ virtual bool HasProperty(wxString name);
+
+ // Set property name to value
+ virtual bool SetProperty(const wxString name, wxPropertyValue value);
+
+ // Remove property from sheet by name, deleting it
+ virtual void RemoveProperty(wxString name);
+
+ // Get the name of the sheet
// Add a property
virtual void AddProperty(wxProperty *property);
wxObject* m_viewedObject;
wxList m_properties;
wxPropertyView* m_propertyView;
-
+ wxString m_name;
};
IMPLEMENT_DYNAMIC_CLASS(wxPropertySheet, wxObject)
-wxPropertySheet::wxPropertySheet(void):m_properties(wxKEY_STRING)
+wxPropertySheet::wxPropertySheet(wxString name)
+:m_properties(wxKEY_STRING),m_name(name)
{
}
else
return (wxProperty *)node->Data();
}
-
+bool wxPropertySheet::SetProperty(const wxString name, wxPropertyValue value)
+{
+ wxProperty* prop = GetProperty(name);
+ if(prop){
+ prop->SetValue(value);
+ return true;
+ }else{
+ return false;
+ }
+}
+void wxPropertySheet::RemoveProperty(wxString name)
+{
+ wxNode *node = m_properties.Find(name);
+ if(node)
+ {
+ wxProperty *prop = (wxProperty *)node->Data();
+ delete prop;
+ m_properties.DeleteNode(node);
+ }
+}
+bool wxPropertySheet::HasProperty(wxString name)
+{
+ return (GetProperty(name)?true:false);
+}
// Clear all properties
void wxPropertySheet::Clear(void)
{
choice.cpp \
clipbrd.cpp \
colour.cpp \
- colordlg.cpp \
control.cpp \
combobox.cpp \
cursor.cpp \
dnd.cpp \
filedlg.cpp \
font.cpp \
- fontdlg.cpp \
frame.cpp \
gauge.cpp \
gdiobj.cpp \
mdi.cpp \
menu.cpp \
menuitem.cpp \
- metafile.cpp \
minifram.cpp \
msgdlg.cpp \
palette.cpp \
pen.cpp \
- print.cpp \
radiobox.cpp \
radiobut.cpp \
region.cpp \
../generic/dirdlgg.cpp \
../generic/fontdlgg.cpp \
../generic/gridg.cpp \
+ ../generic/helphtml.cpp \
../generic/helpext.cpp \
../generic/imaglist.cpp \
../generic/listctrl.cpp \
alldocs: docs
hlp: wxhlp portinghlp # faqhlp
wxhlp: $(DOCDIR)/winhelp/wx.hlp
-wxprophlp: $(DOCDIR)/winhelp/wxprop.hlp
+prophlp: $(DOCDIR)/winhelp/prop.hlp
faqhlp: $(DOCDIR)/winhelp/faq.hlp
refhlp: $(DOCDIR)/winhelp/techref.hlp
rtf: $(DOCDIR)/winhelp/wx.rtf
faqrtf: $(DOCDIR)/winhelp/faq.rtf
-wxproprtf: $(DOCDIR)/winhelp/wxprop.rtf
+proprtf: $(DOCDIR)/winhelp/prop.rtf
pdfrtf: $(DOCDIR)/pdf/wx.rtf
faqpdfrtf: $(DOCDIR)/pdf/faq.rtf
-wxproppdfrtf: $(DOCDIR)/pdf/wxprop.rtf
+proppdfrtf: $(DOCDIR)/pdf/prop.rtf
refpdfrtf: $(DOCDIR)/pdf/techref.rtf
html: wxhtml # faqhtml
wxhtml: $(DOCDIR)\html\wx\wx.htm
faqhtml: $(DOCDIR)\html\faq\faq.htm
-wxprophtml: $(DOCDIR)\html\proplist\prop.htm
+prophtml: $(DOCDIR)\html\proplist\prop.htm
ps: wxps referencps # faqps
wxps: $(WXDIR)\docs\ps\wx.ps
-wxpropps: $(WXDIR)\docs\ps\wxprop.ps
+propps: $(WXDIR)\docs\ps\prop.ps
faqps: $(WXDIR)\docs\ps\faq.ps
referencps: $(WXDIR)\docs\ps\referenc.ps
portingpdfrtf: $(DOCDIR)/pdf/porting.rtf
portingps: $(WXDIR)\docs\ps\porting.ps
-allhlp: wxhlp portinghlp wxprop # faqhlp
+allhlp: wxhlp portinghlp prop # faqhlp
cd $(WXDIR)\utils\dialoged\src
nmake -f makefile.nt hlp
cd $(THISDIR)
# cd $(WXDIR)\utils\clips2c\src
# nmake -f makefile.nt hlp
-allhtml: wxhtml portinghtml wxprophtml # faqhtml
+allhtml: wxhtml portinghtml prophtml # faqhtml
cd $(WXDIR)\utils\dialoged\src
nmake -f makefile.nt html
cd $(THISDIR)
# cd $(WXDIR)\utils\clips2c\src
# nmake -f makefile.nt html
-allps: wxps referencps portingps wxpropps # faqps
+allps: wxps referencps portingps propps # faqps
cd $(WXDIR)\utils\dialoged\src
nmake -f makefile.nt ps
cd $(THISDIR)
-allpdfrtf: pdfrtf portingpdfrtf wxproppdfrtf # faqpdfrtf
+allpdfrtf: pdfrtf portingpdfrtf proppdfrtf # faqpdfrtf
cd $(WXDIR)\utils\dialoged\src
nmake -f makefile.nt pdfrtf
cd $(THISDIR)
move faq.cnt $(DOCDIR)\winhelp\faq.cnt
cd $(THISDIR)
-$(DOCDIR)/winhelp/wxprop.hlp: $(DOCDIR)/latex/proplist/wxprop.rtf $(DOCDIR)/latex/proplist/wxprop.hpj
+$(DOCDIR)/winhelp/prop.hlp: $(DOCDIR)/latex/proplist/prop.rtf $(DOCDIR)/latex/proplist/prop.hpj
cd $(DOCDIR)/latex/proplist
- -erase wxprop.ph
- hc wxprop
- move wxprop.hlp $(DOCDIR)\winhelp\wxprop.hlp
- move wxprop.cnt $(DOCDIR)\winhelp\wxprop.cnt
+ -erase prop.ph
+ hc prop
+ move prop.hlp $(DOCDIR)\winhelp\prop.hlp
+ move prop.cnt $(DOCDIR)\winhelp\prop.cnt
cd $(THISDIR)
$(DOCDIR)/winhelp/techref.hlp: $(DOCDIR)/latex/techref/techref.rtf $(DOCDIR)/latex/techref/techref.hpj
-start /w tex2rtf $(DOCDIR)/latex/faq/faq.tex $(DOCDIR)/latex/faq/faq.rtf -twice -winhelp
cd $(THISDIR)
-$(DOCDIR)/latex/proplist/wxprop.rtf: $(DOCDIR)/latex/proplist/prop.tex $(DOCDIR)/latex/proplist/body.tex $(DOCDIR)/latex/proplist/classes.tex $(DOCDIR)/latex/proplist/changes.tex
+$(DOCDIR)/latex/proplist/prop.rtf: $(DOCDIR)/latex/proplist/prop.tex $(DOCDIR)/latex/proplist/body.tex $(DOCDIR)/latex/proplist/classes.tex $(DOCDIR)/latex/proplist/changes.tex
cd $(DOCDIR)\latex\proplist
- -start /w tex2rtf $(DOCDIR)/latex/proplist/prop.tex $(DOCDIR)/latex/proplist/wxprop.rtf -twice -winhelp
+ -start /w tex2rtf $(DOCDIR)/latex/proplist/prop.tex $(DOCDIR)/latex/proplist/prop.rtf -twice -winhelp
cd $(THISDIR)
$(DOCDIR)/latex/techref/techref.rtf: $(DOCDIR)/latex/techref/techref.tex
-start /w tex2rtf $(DOCDIR)/latex/faq/faq.tex $(DOCDIR)/pdf/faq.rtf -twice -rtf
cd $(THISDIR)
-$(DOCDIR)/pdf/wxprop.rtf: $(DOCDIR)/latex/proplist/proplist.tex $(DOCDIR)/latex/proplist/body.tex $(DOCDIR)/latex/proplist/classes.tex $(DOCDIR)/latex/proplist/changes.tex
+$(DOCDIR)/pdf/prop.rtf: $(DOCDIR)/latex/proplist/proplist.tex $(DOCDIR)/latex/proplist/body.tex $(DOCDIR)/latex/proplist/classes.tex $(DOCDIR)/latex/proplist/changes.tex
cd $(DOCDIR)\latex\proplist
-copy *.bmp *.wmf $(DOCDIR)\pdf
- -start /w tex2rtf $(DOCDIR)/latex/proplist/wxprop.tex $(DOCDIR)/pdf/wxprop.rtf -twice -rtf
+ -start /w tex2rtf $(DOCDIR)/latex/proplist/prop.tex $(DOCDIR)/pdf/prop.rtf -twice -rtf
cd $(THISDIR)
$(DOCDIR)/pdf/techref.rtf: $(DOCDIR)/latex/techref/techref.tex
$(DOCDIR)\html\proplist\prop.htm: $(DOCDIR)\latex\proplist\prop.tex $(DOCDIR)\latex\proplist\body.tex $(DOCDIR)\latex\proplist\classes.tex $(DOCDIR)\latex\proplist\changes.tex
cd $(DOCDIR)\latex\proplist
-mkdir $(DOCDIR)\html\proplist
- -start /w tex2rtf $(DOCDIR)\latex\proplist\wxprop.tex $(DOCDIR)\html\proplist\prop.htm -twice -html
+ -start /w tex2rtf $(DOCDIR)\latex\proplist\prop.tex $(DOCDIR)\html\proplist\prop.htm -twice -html
-erase $(DOCDIR)\html\proplist\*.con
-erase $(DOCDIR)\html\proplist\*.ref
-erase $(DOCDIR)\latex\proplist\*.con
#if !USE_SHARED_LIBRARY
IMPLEMENT_DYNAMIC_CLASS(wxSlider95, wxControl)
-
-BEGIN_EVENT_TABLE(wxSlider95, wxControl)
-#if WXWIN_COMPATIBILITY
- EVT_SCROLL(wxSlider95::OnScroll)
-#endif
-END_EVENT_TABLE()
-
#endif
// Slider
event.SetPosition(newPos);
event.SetEventObject( this );
GetEventHandler()->ProcessEvent(event);
+
+ wxCommandEvent cevent( wxEVT_COMMAND_SLIDER_UPDATED, GetId() );
+ cevent.SetEventObject( this );
+ GetEventHandler()->ProcessEvent( cevent );
+
}
}
}
return ( hWnd == GetStaticMin() || hWnd == GetStaticMax() || hWnd == GetEditValue() );
}
-#if WXWIN_COMPATIBILITY
-// Backward compatibility
-void wxSlider95::OnScroll(wxScrollEvent& event)
-{
- wxEventType oldEvent = event.GetEventType();
- event.SetEventType( wxEVT_COMMAND_SLIDER_UPDATED );
- if ( !GetEventHandler()->ProcessEvent(event) )
- {
- event.SetEventType( oldEvent );
- if (!GetParent()->GetEventHandler()->ProcessEvent(event))
- event.Skip();
- }
-}
-#endif
-
void wxSlider95::Command (wxCommandEvent & event)
{
SetValue (event.GetInt());
#if !USE_SHARED_LIBRARY
IMPLEMENT_DYNAMIC_CLASS(wxSliderMSW, wxControl)
-
-#if WXWIN_COMPATIBILITY
-BEGIN_EVENT_TABLE(wxSliderMSW, wxControl)
- EVT_SCROLL(wxSliderMSW::OnScroll)
-END_EVENT_TABLE()
-#endif
-
#endif
// Slider
event.SetPosition(newPos);
event.SetEventObject( this );
GetEventHandler()->ProcessEvent(event);
+
+ wxCommandEvent cevent( wxEVT_COMMAND_SLIDER_UPDATED, GetId() );
+ cevent.SetEventObject( this );
+ GetEventHandler()->ProcessEvent( cevent );
}
}
}
return ( hWnd == GetStaticMin() || hWnd == GetStaticMax() || hWnd == GetEditValue() );
}
-#if WXWIN_COMPATIBILITY
-// Backward compatibility
-void wxSliderMSW::OnScroll(wxScrollEvent& event)
-{
- wxEventType oldEvent = event.GetEventType();
- event.SetEventType( wxEVT_COMMAND_SLIDER_UPDATED );
- if ( !GetEventHandler()->ProcessEvent(event) )
- {
- event.SetEventType( oldEvent );
- if (!GetParent()->GetEventHandler()->ProcessEvent(event))
- event.Skip();
- }
-}
-#endif
-
void wxSliderMSW::Command (wxCommandEvent & event)
{
SetValue (event.GetInt());