Eliminate a couple more -Wcast-qual warnings
This commit is contained in:
@@ -71,7 +71,7 @@ class wxList_SortFunction
|
|||||||
public:
|
public:
|
||||||
wxList_SortFunction(wxSortCompareFunction f) : m_f(f) { }
|
wxList_SortFunction(wxSortCompareFunction f) : m_f(f) { }
|
||||||
bool operator()(const T& i1, const T& i2)
|
bool operator()(const T& i1, const T& i2)
|
||||||
{ return m_f((T*)&i1, (T*)&i2) < 0; }
|
{ return m_f(&i1, &i2) < 0; }
|
||||||
private:
|
private:
|
||||||
wxSortCompareFunction m_f;
|
wxSortCompareFunction m_f;
|
||||||
};
|
};
|
||||||
|
@@ -552,7 +552,7 @@ methodOverrideMap = {
|
|||||||
ft.chrg.cpMin = minPos;
|
ft.chrg.cpMin = minPos;
|
||||||
ft.chrg.cpMax = maxPos;
|
ft.chrg.cpMax = maxPos;
|
||||||
const wxWX2MBbuf buf = wx2stc(text);
|
const wxWX2MBbuf buf = wx2stc(text);
|
||||||
ft.lpstrText = (char*)(const char*)buf;
|
ft.lpstrText = buf;
|
||||||
|
|
||||||
int pos = SendMsg(%s, flags, (sptr_t)&ft);
|
int pos = SendMsg(%s, flags, (sptr_t)&ft);
|
||||||
if (findEnd) *findEnd=(pos==-1?wxSTC_INVALID_POSITION:ft.chrgText.cpMax);
|
if (findEnd) *findEnd=(pos==-1?wxSTC_INVALID_POSITION:ft.chrgText.cpMax);
|
||||||
|
@@ -1702,7 +1702,7 @@ int wxStyledTextCtrl::FindText(int minPos, int maxPos, const wxString& text,
|
|||||||
ft.chrg.cpMin = minPos;
|
ft.chrg.cpMin = minPos;
|
||||||
ft.chrg.cpMax = maxPos;
|
ft.chrg.cpMax = maxPos;
|
||||||
const wxWX2MBbuf buf = wx2stc(text);
|
const wxWX2MBbuf buf = wx2stc(text);
|
||||||
ft.lpstrText = (char*)(const char*)buf;
|
ft.lpstrText = buf;
|
||||||
|
|
||||||
int pos = SendMsg(SCI_FINDTEXT, flags, (sptr_t)&ft);
|
int pos = SendMsg(SCI_FINDTEXT, flags, (sptr_t)&ft);
|
||||||
if (findEnd) *findEnd=(pos==-1?wxSTC_INVALID_POSITION:ft.chrgText.cpMax);
|
if (findEnd) *findEnd=(pos==-1?wxSTC_INVALID_POSITION:ft.chrgText.cpMax);
|
||||||
|
Reference in New Issue
Block a user