#include "wx/wx.h"
#endif
-#if !wxUSE_RESOURCES
- #error "You should set wxUSE_RESOURCES to 1 to compile this sample"
+#include "wx/deprecated/setup.h"
+
+#if !wxUSE_WX_RESOURCES
+ #error "You should set wxUSE_WX_RESOURCES to 1 to compile this sample"
#endif
#if wxUSE_UNICODE
// #error "This sample can't be compiled in Unicode mode."
#endif // wxUSE_UNICODE
-#include "wx/resource.h"
+#include "wx/deprecated/resource.h"
#include <ctype.h>
#include "resource.h"
// If we wanted to demonstrate total platform independence,
// then we'd use the dynamic file loading form for all platforms.
-// But this shows how to embed the wxWindows resources
+// But this shows how to embed the wxWidgets resources
// in the program code/executable for UNIX and Windows
// platforms.
// Create the main frame window
frame = new MyFrame( (wxFrame *) NULL, -1,
- wxT("wxWindows Resource Sample"),
+ wxT("wxWidgets Resource Sample"),
wxPoint(-1, -1), wxSize(300, 250) );
// Give it a status line
void MyFrame::OnAbout( wxCommandEvent& WXUNUSED(event) )
{
- wxMessageBox(wxT("wxWindows resource sample.\n")
- wxT("(c) Julian Smart"), wxT("About wxWindows sample"),
+ wxMessageBox(wxT("wxWidgets resource sample.\n")
+ wxT("(c) Julian Smart"), wxT("About wxWidgets sample"),
wxICON_INFORMATION | wxOK);
}
{
MyDialog *dialog = new MyDialog;
- if (dialog->LoadFromResource(this, wxT("dialog1")))
+ if (wxLoadFromResource(dialog, this, wxT("dialog1")))
{
wxTextCtrl *text = (wxTextCtrl *)wxFindWindowByName(wxT("multitext3"), dialog);
if (text)
{
- text->SetValue(wxT("wxWindows resource demo"));
+ text->SetValue(wxT("wxWidgets resource demo"));
}
dialog->ShowModal();