fix warning for mingw32

This commit is contained in:
lsv 2025-10-16 09:24:07 +05:00
parent 7db41df697
commit 0f91ec5e67
12 changed files with 55 additions and 33 deletions

View file

@ -184,8 +184,12 @@ void ctlNavigatePanel::Init(bool reorganization) {
wxString strcolor = indicator["color"].AsString();
wxColour cc(strcolor);
statistics_mark el{0,enable,cc};
if (!reorganization)
if (cc.IsOk()) mark_color.push_back(el); else mark_color.push_back(statistics_mark { 0, false,*wxBLACK });
if (!reorganization) {
if (cc.IsOk())
mark_color.push_back(el);
else
mark_color.push_back(statistics_mark { 0, false,*wxBLACK });
}
//search_rule
wxJSONValue inc = indicator["include"];
wxJSONValue exc = indicator["exclude"];

View file

@ -818,8 +818,10 @@ void ctlSQLBox::OnKeyDown(wxKeyEvent &event)
bool isAddDict = false;
s = GetTextRange(homewordpos, pos);
if (uc != WXK_NONE)
if (uc == 8) s = s.Left(s.length() - 1);
else if (uc >= 'A') s += uc;
{
if (uc == 8) {s = s.Left(s.length() - 1);}
else {if (uc >= 'A') s += uc;}
}
if (uc >= ' ' && uc < 'A') isAddDict = true;
auto it = m_hint_words.lower_bound(s);
wxString strlist;
@ -1459,7 +1461,7 @@ std::pair<int,int> ctlSQLBox::SelectQuery(int startposition)
int pend=endPos;
int pstart=0;
if ((ch == ';')) {
if (ch == ';') {
pend=pos;
pos=pos-1;
} else

View file

@ -315,12 +315,16 @@ wxString ctlSQLGrid::GetExportLine(int row, wxArrayInt cols)
if (text.Length() != 0) {
text.Replace(wxT("'"), wxT("''"));
}
else text = wxT("null");
else
text = wxT("null");
}
if (generatesql == 3) if (text == "null") str.Append(cname).Append(" is "); else
str.Append(cname).Append("=");
if (generatesql == 3) {
if (text == "null")
str.Append(cname).Append(" is ");
else
str.Append(cname).Append("=");
}
if (needQuote)
str.Append(qtsimbol);

View file

@ -130,9 +130,12 @@ void ctlTreeJSON::BuildFind() {
item = nextTreeItem(item);
}
if (findsId.size() > 0)
if (last.IsOk())SelectItem(last);
{
if (last.IsOk())
SelectItem(last);
else
wxBell();
}
}
wxTreeItemId ctlTreeJSON::nextTreeItem(const wxTreeItemId& item) {
wxTreeItemId child;