// ----------------------------------------------------------------------------
// accessor functions for the bitmaps (may return NULL, check for it!)
// ----------------------------------------------------------------------------
// ----------------------------------------------------------------------------
// accessor functions for the bitmaps (may return NULL, check for it!)
// ----------------------------------------------------------------------------
// Property text edit control
// ----------------------------------------------------------------------------
// Property text edit control
// ----------------------------------------------------------------------------
wxPropertyTextEdit::wxPropertyTextEdit(wxPropertyListView *v, wxWindow *parent,
const wxWindowID id, const wxString& value,
wxPropertyTextEdit::wxPropertyTextEdit(wxPropertyListView *v, wxWindow *parent,
const wxWindowID id, const wxString& value,
// Find the wxListBox index corresponding to this property
int wxPropertyListView::FindListIndexForProperty(wxProperty *property)
{
// Find the wxListBox index corresponding to this property
int wxPropertyListView::FindListIndexForProperty(wxProperty *property)
{
for (int i = 0; i < n; i++)
{
if (property == (wxProperty *)m_propertyScrollingList->wxListBox::GetClientData(i))
for (int i = 0; i < n; i++)
{
if (property == (wxProperty *)m_propertyScrollingList->wxListBox::GetClientData(i))
- wxFont *boringFont = wxTheFontList->FindOrCreateFont(guiFont.GetPointSize(), wxMODERN, wxNORMAL, wxNORMAL, FALSE, "Courier New");
+ wxFont *boringFont =
+ wxTheFontList->FindOrCreateFont(guiFont.GetPointSize(), wxMODERN,
+ wxNORMAL, wxNORMAL, FALSE, _T("Courier New"));
#else
wxFont *boringFont = wxTheFontList->FindOrCreateFont(guiFont.GetPointSize(), wxTELETYPE, wxNORMAL, wxNORMAL);
#endif
#else
wxFont *boringFont = wxTheFontList->FindOrCreateFont(guiFont.GetPointSize(), wxTELETYPE, wxNORMAL, wxNORMAL);
#endif
- m_confirmButton = new wxButton(panel, wxID_PROP_CHECK, ":-)", wxPoint(-1, -1), smallButtonSize );
- m_cancelButton = new wxButton(panel, wxID_PROP_CROSS, "X", wxPoint(-1, -1), smallButtonSize );
+ m_confirmButton = new wxButton(panel, wxID_PROP_CHECK, _T(":-)"), wxPoint(-1, -1), smallButtonSize );
+ m_cancelButton = new wxButton(panel, wxID_PROP_CROSS, _T("X"), wxPoint(-1, -1), smallButtonSize );
}
topsizer->Add( m_confirmButton, 0, wxLEFT|wxTOP|wxBOTTOM | wxEXPAND, buttonborder );
topsizer->Add( m_cancelButton, 0, wxLEFT|wxTOP|wxBOTTOM | wxEXPAND, buttonborder );
}
}
topsizer->Add( m_confirmButton, 0, wxLEFT|wxTOP|wxBOTTOM | wxEXPAND, buttonborder );
topsizer->Add( m_cancelButton, 0, wxLEFT|wxTOP|wxBOTTOM | wxEXPAND, buttonborder );
}
- m_valueText = new wxPropertyTextEdit(this, panel, wxID_PROP_TEXT, "",
+ m_valueText = new wxPropertyTextEdit(this, panel, wxID_PROP_TEXT, _T(""),
wxPoint(-1, -1), wxSize(-1, smallButtonSize.y), wxPROCESS_ENTER);
m_valueText->Enable(FALSE);
topsizer->Add( m_valueText, 1, wxALL | wxEXPAND, buttonborder );
if (m_buttonFlags & wxPROP_PULLDOWN)
{
wxPoint(-1, -1), wxSize(-1, smallButtonSize.y), wxPROCESS_ENTER);
m_valueText->Enable(FALSE);
topsizer->Add( m_valueText, 1, wxALL | wxEXPAND, buttonborder );
if (m_buttonFlags & wxPROP_PULLDOWN)
{
- m_editButton = new wxButton(panel, wxID_PROP_EDIT, "...", wxPoint(-1, -1), smallButtonSize);
+ m_editButton = new wxButton(panel, wxID_PROP_EDIT, _T("..."), wxPoint(-1, -1), smallButtonSize);
m_editButton->Enable(FALSE);
topsizer->Add( m_editButton, 0, wxRIGHT|wxTOP|wxBOTTOM | wxEXPAND, buttonborder );
}
m_editButton->Enable(FALSE);
topsizer->Add( m_editButton, 0, wxRIGHT|wxTOP|wxBOTTOM | wxEXPAND, buttonborder );
}
m_windowCloseButton = new wxButton(panel, wxID_OK, _("OK"), wxPoint(-1, -1), largeButtonSize );
m_windowCloseButton->SetDefault();
m_windowCloseButton->SetFocus();
m_windowCloseButton = new wxButton(panel, wxID_OK, _("OK"), wxPoint(-1, -1), largeButtonSize );
m_windowCloseButton->SetDefault();
m_windowCloseButton->SetFocus();
- bottomsizer->Add( m_windowCloseButton, 0, wxLEFT|wxTOP|wxBOTTOM, buttonborder );
+ bottomsizer->Add( m_windowCloseButton, 0, wxALL, buttonborder );
bottomsizer->Add( m_windowHelpButton, 0, wxALL, buttonborder );
}
bottomsizer->Add( m_windowHelpButton, 0, wxALL, buttonborder );
}
BEGIN_EVENT_TABLE(wxPropertyListDialog, wxDialog)
EVT_BUTTON(wxID_CANCEL, wxPropertyListDialog::OnCancel)
BEGIN_EVENT_TABLE(wxPropertyListDialog, wxDialog)
EVT_BUTTON(wxID_CANCEL, wxPropertyListDialog::OnCancel)
BEGIN_EVENT_TABLE(wxPropertyListPanel, wxPanel)
EVT_SIZE(wxPropertyListPanel::OnSize)
BEGIN_EVENT_TABLE(wxPropertyListPanel, wxPanel)
EVT_SIZE(wxPropertyListPanel::OnSize)
BEGIN_EVENT_TABLE(wxPropertyListFrame, wxFrame)
EVT_CLOSE(wxPropertyListFrame::OnCloseWindow)
BEGIN_EVENT_TABLE(wxPropertyListFrame, wxFrame)
EVT_CLOSE(wxPropertyListFrame::OnCloseWindow)
bool wxPropertyListValidator::OnValueListSelect(wxProperty *property, wxPropertyListView *view, wxWindow *WXUNUSED(parentWindow))
{
wxString s(view->GetValueList()->GetStringSelection());
bool wxPropertyListValidator::OnValueListSelect(wxProperty *property, wxPropertyListView *view, wxWindow *WXUNUSED(parentWindow))
{
wxString s(view->GetValueList()->GetStringSelection());
- wxSprintf(buf, _T("Value %s is not a valid real number!"), value.GetData());
- wxMessageBox(buf, _T("Property value error"), wxOK | wxICON_EXCLAMATION, parentWindow);
+ wxSprintf(buf, wxT("Value %s is not a valid real number!"), value.GetData());
+ wxMessageBox(buf, wxT("Property value error"), wxOK | wxICON_EXCLAMATION, parentWindow);
- wxSprintf(buf, _T("Value %s is not a valid integer!"), value.GetData());
- wxMessageBox(buf, _T("Property value error"), wxOK | wxICON_EXCLAMATION, parentWindow);
+ wxSprintf(buf, wxT("Value %s is not a valid integer!"), value.GetData());
+ wxMessageBox(buf, wxT("Property value error"), wxOK | wxICON_EXCLAMATION, parentWindow);
- wxSprintf(buf, _T("Value must be an integer between %ld and %ld!"), m_integerMin, m_integerMax);
- wxMessageBox(buf, _T("Property value error"), wxOK | wxICON_EXCLAMATION, parentWindow);
+ wxSprintf(buf, wxT("Value must be an integer between %ld and %ld!"), m_integerMin, m_integerMax);
+ wxMessageBox(buf, wxT("Property value error"), wxOK | wxICON_EXCLAMATION, parentWindow);
- wxMessageBox(_T("Value must be True or False!"), _T("Property value error"), wxOK | wxICON_EXCLAMATION, parentWindow);
+ wxMessageBox(wxT("Value must be True or False!"), wxT("Property value error"), wxOK | wxICON_EXCLAMATION, parentWindow);
wxChar *currentString = copystring(view->GetValueText()->GetValue());
view->GetValueList()->SetStringSelection(currentString);
delete[] currentString;
wxChar *currentString = copystring(view->GetValueText()->GetValue());
view->GetValueList()->SetStringSelection(currentString);
delete[] currentString;
title += property->GetName();
if (EditStringList(parentWindow, stringList, title.GetData()))
title += property->GetName();
if (EditStringList(parentWindow, stringList, title.GetData()))
wxNode *node = m_stringList->Add(initialText);
m_listBox->Append(initialText, (void *)node);
m_currentSelection = m_stringList->Number() - 1;
wxNode *node = m_stringList->Add(initialText);
m_listBox->Append(initialText, (void *)node);
m_currentSelection = m_stringList->Number() - 1;
- #if defined(__WXMSW__) || defined(__WXOS2__)
- s_tickBitmap = new wxBitmap("tick_bmp", wxBITMAP_TYPE_RESOURCE);
+ #if defined(__WXMSW__) || defined(__WXPM__)
+ s_tickBitmap = new wxBitmap(_T("tick_bmp"), wxBITMAP_TYPE_RESOURCE);
- #if defined(__WXMSW__) || defined(__WXOS2__)
- s_crossBitmap = new wxBitmap("cross_bmp", wxBITMAP_TYPE_RESOURCE);
+ #if defined(__WXMSW__) || defined(__WXPM__)
+ s_crossBitmap = new wxBitmap(_T("cross_bmp"), wxBITMAP_TYPE_RESOURCE);