X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/43b2d5e7c3b3e3d6b245e279dde73d96e0075911..fa699cbaaf217af186cd04dd10d6ec67c8667136:/samples/sockets/client.cpp diff --git a/samples/sockets/client.cpp b/samples/sockets/client.cpp index c435c1e9cc..b3389bd4eb 100644 --- a/samples/sockets/client.cpp +++ b/samples/sockets/client.cpp @@ -39,7 +39,9 @@ // -------------------------------------------------------------------------- // the application icon -#include "mondrian.xpm" +#ifndef wxHAS_IMAGES_IN_RESOURCES + #include "../sample.xpm" +#endif // -------------------------------------------------------------------------- // classes @@ -188,9 +190,8 @@ bool MyApp::OnInit() // Create the main application window MyFrame *frame = new MyFrame(); - // Show it and tell the application that it's our main window + // Show it frame->Show(true); - SetTopWindow(frame); // success return true; @@ -206,11 +207,11 @@ MyFrame::MyFrame() : wxFrame((wxFrame *)NULL, wxID_ANY, wxDefaultPosition, wxSize(300, 200)) { // Give the frame an icon - SetIcon(wxICON(mondrian)); + SetIcon(wxICON(sample)); // Make menus m_menuFile = new wxMenu(); - m_menuFile->Append(CLIENT_ABOUT, _("&About...\tCtrl-A"), _("Show about dialog")); + m_menuFile->Append(CLIENT_ABOUT, _("&About\tCtrl-A"), _("Show about dialog")); m_menuFile->AppendSeparator(); m_menuFile->Append(CLIENT_QUIT, _("E&xit\tAlt-X"), _("Quit client")); @@ -611,9 +612,9 @@ void MyFrame::OnTestURL(wxCommandEvent& WXUNUSED(event)) } // Print the contents type and file size - wxLogMessage("Contents type: %s\nFile size: %i\nStarting to download...", + wxLogMessage("Contents type: %s\nFile size: %lu\nStarting to download...", url.GetProtocol().GetContentType(), - data->GetSize()); + static_cast( data->GetSize() )); // Get the data wxStringOutputStream sout;