CtrlLib: HeaderCtrl: AutoHideSb, HideSb, ArrayCtrl: AutoHideHorzSb

git-svn-id: svn://ultimatepp.org/upp/trunk@3031 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
cxl 2011-01-17 19:14:25 +00:00
parent 8b525b177d
commit 73bd9c7ce0
2 changed files with 8 additions and 1 deletions

View file

@ -602,7 +602,10 @@ public:
ArrayCtrl& NoMouseMoveCursor() { return MouseMoveCursor(false); }
ArrayCtrl& AutoHideSb(bool b = true) { sb.AutoHide(b); return *this; }
ArrayCtrl& NoAutoHideSb() { return AutoHideSb(false); }
ArrayCtrl& HideSb(bool b = true) { sb.Show(!b); return *this; }
ArrayCtrl& AutoHideHorzSb(bool b = true) { header.AutoHideSb(b); return *this; }
ArrayCtrl& NoAutoHideHorzSb() { return AutoHideHorzSb(false); }
ArrayCtrl& HideSb(bool b = true) { sb.Show(!b); header.HideSb(b); return *this; }
ArrayCtrl& MultiSelect(bool b = true) { multiselect = b; return *this; }
bool IsMultiSelect() const { return multiselect; }
ArrayCtrl& NoBackground(bool b = true) { nobg = b; Transparent(); Refresh(); return *this; }

View file

@ -87,6 +87,7 @@ protected:
int light;
int height;
const Style *style;
bool autohidesb;
double Denominator() const;
void Reduce(int q, double& delta, double rs, int szcx, bool checkmin);
@ -157,6 +158,9 @@ public:
HeaderCtrl& Fixed();
HeaderCtrl& SetStyle(const Style& s) { style = &s; Refresh(); return *this; }
HeaderCtrl& Moving(bool b = true) { moving = b; return *this; }
HeaderCtrl& AutoHideSb(bool b = true) { sb.AutoHide(sb); return *this; }
HeaderCtrl& NoAutoHideSb() { return AutoHideSb(false); }
HeaderCtrl& HideSb(bool b = true) { sb.Show(!b); return *this; }
HeaderCtrl& SetScrollBarStyle(const ScrollBar::Style& s) { sb.SetStyle(s); return *this; }