1. wxDir works for MSW and documented

2. wxDateTime works with dates very close to the Epoch
3. setting font for wxRadioBox works


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@4899 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
1999-12-11 00:43:59 +00:00
parent 6bfd5671b0
commit 4afd752902
10 changed files with 204 additions and 39 deletions

View File

@@ -182,7 +182,7 @@ bool wxRadioBox::Create(wxWindow *parent,
{
// initialize members
m_selectedButton = -1;
m_noItems = n;
m_noItems = 0;
m_majorDim = majorDim == 0 ? n : majorDim;
m_noRowsOrCols = majorDim;
@@ -196,6 +196,7 @@ bool wxRadioBox::Create(wxWindow *parent,
return FALSE;
// and now create the buttons
m_noItems = n;
#if RADIOBTN_PARENT_IS_RADIOBOX
HWND hwndParent = GetHwnd();
#else
@@ -658,7 +659,7 @@ bool wxRadioBox::ContainsHWND(WXHWND hWnd) const
return FALSE;
}
void wxRadioBox::Command (wxCommandEvent & event)
void wxRadioBox::Command(wxCommandEvent & event)
{
SetSelection (event.m_commandInt);
ProcessCommand (event);
@@ -687,6 +688,24 @@ void wxRadioBox::SendNotificationEvent()
ProcessCommand(event);
}
bool wxRadioBox::SetFont(const wxFont& font)
{
if ( !wxControl::SetFont(font) )
{
// nothing to do
return FALSE;
}
// also set the font of our radio buttons
WXHFONT hfont = wxFont(font).GetResourceHandle();
for ( int n = 0; n < m_noItems; n++ )
{
::SendMessage((HWND)m_radioButtons[n], WM_SETFONT, (WPARAM)hfont, 0L);
}
return TRUE;
}
long wxRadioBox::MSWWindowProc(WXUINT nMsg, WXWPARAM wParam, WXLPARAM lParam)
{
// This is required for the radiobox to be sensitive to mouse input,