From: Włodzimierz Skiba Date: Mon, 22 Nov 2004 19:32:37 +0000 (+0000) Subject: GCC fixes. X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/f0fb3b3b60ca8c9669107adca2ca2ef28e6455c1 GCC fixes. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@30700 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/samples/db/dbtest.cpp b/samples/db/dbtest.cpp index ef03c41498..c999c7019c 100644 --- a/samples/db/dbtest.cpp +++ b/samples/db/dbtest.cpp @@ -1707,7 +1707,8 @@ void CeditorDlg::OnSelectPict() if (file.IsOpened()) { - wxFileOffset iSize = file.Length(); + // assume not huge file in sample + long iSize = (long)file.Length(); if ((iSize > 0) && (iSize < MAX_PICTURE_SIZE)) { @@ -1721,7 +1722,7 @@ void CeditorDlg::OnSelectPict() wxMessageBox(wxT("Something bad happened while reading..."), wxT("BLOB Loading Error"), wxOK | wxICON_EXCLAMATION); wxString tStr; - tStr.Printf(wxT("%lu"),iSize); + tStr.Printf(wxT("%ld"),iSize); pPictSizeTxt->SetValue(tStr); } else diff --git a/samples/db/listdb.cpp b/samples/db/listdb.cpp index 5714c9125c..ff93287333 100644 --- a/samples/db/listdb.cpp +++ b/samples/db/listdb.cpp @@ -202,7 +202,7 @@ ClookUpDlg::ClookUpDlg(wxWindow *parent, const wxString &windowTitle, const wxSt if (!lookup->Open()) { wxString tStr; - tStr.Printf(wxT("Unable to open the table '%s'."), tableName); + tStr.Printf(wxT("Unable to open the table '%s'."), tableName.c_str()); wxMessageBox(tStr, wxT("ODBC Error...")); Close(); return; @@ -267,7 +267,7 @@ ClookUpDlg::ClookUpDlg(wxWindow *parent, const wxString &windowTitle, const wxSt // in the lookup window. // ClookUpDlg::ClookUpDlg(wxWindow *parent, const wxString &windowTitle, const wxString &tableName, - const wxString &dispCol1, const wxString &dispCol2, + const wxString &dispCol1, const wxString &dispCol2, const wxString &where, const wxString &orderBy, wxDb *pDb, const wxString &defDir, bool distinctValues, const wxString &selectStmt, int maxLenCol1, bool allowOk) @@ -309,7 +309,7 @@ ClookUpDlg::ClookUpDlg(wxWindow *parent, const wxString &windowTitle, const wxSt if (!lookup2->Open()) { wxString tStr; - tStr.Printf(wxT("Unable to open the table '%s'."),tableName); + tStr.Printf(wxT("Unable to open the table '%s'."),tableName.c_str()); tStr += GetExtendedDBErrorMsg2(pDb,__TFILE__,__LINE__); wxMessageBox(tStr,wxT("ODBC Error...")); Close();