Fixed stupid braces bug, left double is working again on the popup

git-svn-id: svn://ultimatepp.org/upp/trunk@2081 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
unodgs 2010-02-15 20:42:09 +00:00
parent 4d5386e1e6
commit 12c2090143
2 changed files with 8 additions and 4 deletions

View file

@ -1988,7 +1988,10 @@ void GridCtrl::SyncPopup()
int lines = popup.gd->GetLinesCount(cx - margin - 2, WString(val), StdFont(), true);
int cy = max(lines * Draw::GetStdFontCy() + popup.gd->tm + popup.gd->bm + 2, vi.nsize + 1);
if(fr && r == 0)
y++; cy--;
{
y++;
cy--;
}
popup.PopUp(this, x, y, cx, cy);
if(!close)
popup.Refresh();
@ -5435,7 +5438,7 @@ void GridCtrl::MouseLeave()
UpdateHighlighting(GS_BORDER, Point(0, 0));
oldSplitCol = -1;
oldSplitRow = -1;
popup.Close();
//popup.Close();
}
void GridCtrl::MouseWheel(Point p, int zdelta, dword keyflags)
@ -6283,8 +6286,7 @@ bool GridCtrl::StartEdit(bool mouse)
if(!valid_cursor || !IsRowEditable())
return false;
ctrls = true;
//ctrls = true;
WhenStartEdit();
SetCtrlsData();

View file

@ -79,6 +79,8 @@ class GridDisplay
void SetVertMargin(int top = 0, int bottom = 0) { tm = top; bm = bottom; }
void SetTheme(int th = 6) { theme = th; }
int GetThemeCount() { return 7; }
bool IsFixedRow() { return row < 0; }
bool IsFixedCol() { return col < 0; }
WString GetStdConvertedValue(const Value &v) const;
int GetLinesCount(int cx, const wchar* s, const Font& font, bool wrap);