]> git.saurik.com Git - wxWidgets.git/blobdiff - contrib/utils/wxrcedit/pe_adv.cpp
Better wxFile support, warning fixes and minor source cleaning.
[wxWidgets.git] / contrib / utils / wxrcedit / pe_adv.cpp
index 02b5e5dd6207001d6a64e41c2d53976bb8628da2..e89206d328f1fd009ce801f5b0fbf65ca60a9db2 100644 (file)
@@ -115,9 +115,9 @@ void PropEditCtrlColor::OnDetails()
 
     if (txt.Length() == 7 && txt[0u] == _T('#') &&
         wxSscanf(txt.c_str(), _T("#%lX"), &tmp) == 1)
-        clr = wxColour((tmp & 0xFF0000) >> 16,
-                       (tmp & 0x00FF00) >> 8,
-                       (tmp & 0x0000FF));
+        clr = wxColour((unsigned char)((tmp & 0xFF0000) >> 16),
+                       (unsigned char)((tmp & 0x00FF00) >> 8),
+                       (unsigned char)((tmp & 0x0000FF)));
 
     clr = wxGetColourFromUser(NULL, clr);
     if (clr.Ok())
@@ -151,7 +151,7 @@ void PropEditCtrlFlags::OnDetails()
     wxConfigBase *cfg = wxConfigBase::Get();
 
     wxDialog dlg(m_PropFrame, wxID_ANY, _("Flags"),
-            wxPoint(cfg->Read(_T("flagsdlg_x"), wxDefaultPosition.x), cfg->Read(_T("flagsdlg_y"), wxDefaultPosition.y)),
+            wxPoint(cfg->Read(_T("flagsdlg_x"), wxDefaultCoord), cfg->Read(_T("flagsdlg_y"), wxDefaultCoord)),
             wxSize(cfg->Read(_T("flagsdlg_w"), 300), cfg->Read(_T("flagsdlg_h"), 300)),
             wxDEFAULT_DIALOG_STYLE | wxRESIZE_BORDER);
     wxSizer *sz = new wxBoxSizer(wxVERTICAL);
@@ -186,7 +186,7 @@ void PropEditCtrlFlags::OnDetails()
     for (i = 0; i < arr.GetCount(); i++)
         if (lbox->IsChecked(i))
             txt << arr[i] << _T('|');
-    if (!txt.IsEmpty()) txt.RemoveLast();
+    if (!txt.empty()) txt.RemoveLast();
 
     m_TextCtrl->SetValue(txt);
     WriteValue();