X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/a23fd0e1d1329a4a258b4defb3e0b0001b700c6e..b3818fbe8e439bc9af8c20371774520a5a2bc9c7:/src/msw/slider95.cpp diff --git a/src/msw/slider95.cpp b/src/msw/slider95.cpp index f9aa9ea5c1..7bfe7c1a79 100644 --- a/src/msw/slider95.cpp +++ b/src/msw/slider95.cpp @@ -93,14 +93,14 @@ bool wxSlider95::Create(wxWindow *parent, wxWindowID id, bool want3D; WXDWORD exStyle = Determine3DEffects(WS_EX_CLIENTEDGE, &want3D) ; - m_staticValue = (WXHWND) CreateWindowEx(exStyle, "STATIC", NULL, + m_staticValue = (WXHWND) CreateWindowEx(exStyle, _T("STATIC"), NULL, msStyle, 0, 0, 0, 0, (HWND) parent->GetHWND(), (HMENU)NewControlId(), wxGetInstance(), NULL); // Now create min static control - sprintf(wxBuffer, "%d", minValue); - m_staticMin = (WXHWND) CreateWindowEx(0, "STATIC", wxBuffer, + wxSprintf(wxBuffer, _T("%d"), minValue); + m_staticMin = (WXHWND) CreateWindowEx(0, _T("STATIC"), wxBuffer, STATIC_FLAGS, 0, 0, 0, 0, (HWND) parent->GetHWND(), (HMENU)NewControlId(), wxGetInstance(), NULL); @@ -149,15 +149,15 @@ bool wxSlider95::Create(wxWindow *parent, wxWindowID id, SubclassWin(GetHWND()); - SetWindowText((HWND) m_hWnd, ""); + SetWindowText((HWND) m_hWnd, _T("")); SetFont(parent->GetFont()); if ( m_windowStyle & wxSL_LABELS ) { // Finally, create max value static item - sprintf(wxBuffer, "%d", maxValue); - m_staticMax = (WXHWND) CreateWindowEx(0, "STATIC", wxBuffer, + wxSprintf(wxBuffer, _T("%d"), maxValue); + m_staticMax = (WXHWND) CreateWindowEx(0, _T("STATIC"), wxBuffer, STATIC_FLAGS, 0, 0, 0, 0, (HWND) parent->GetHWND(), (HMENU)NewControlId(), wxGetInstance(), NULL); @@ -285,7 +285,7 @@ void wxSlider95::SetValue(int value) ::SendMessage((HWND) GetHWND(), TBM_SETPOS, (WPARAM)TRUE, (LPARAM)value); if (m_staticValue) { - sprintf(wxBuffer, "%d", value); + wxSprintf(wxBuffer, _T("%d"), value); SetWindowText((HWND) m_staticValue, wxBuffer); } } @@ -360,7 +360,7 @@ void wxSlider95::DoSetSize(int x, int y, int width, int height, int sizeFlags) AdjustForParentClientOrigin(x1, y1, sizeFlags); - char buf[300]; + wxChar buf[300]; int x_offset = x; int y_offset = y; @@ -508,16 +508,16 @@ void wxSlider95::SetRange(int minValue, int maxValue) ::SendMessage((HWND) GetHWND(), TBM_SETRANGE, TRUE, MAKELONG(minValue, maxValue)); - char buf[40]; + wxChar buf[40]; if ( m_staticMin ) { - sprintf(buf, "%d", m_rangeMin); + wxSprintf(buf, _T("%d"), m_rangeMin); SetWindowText((HWND) m_staticMin, buf); } if ( m_staticMax ) { - sprintf(buf, "%d", m_rangeMax); + wxSprintf(buf, _T("%d"), m_rangeMax); SetWindowText((HWND) m_staticMax, buf); } }