From bd408d296ccfa16dba379f3820a2007ff6963a6a Mon Sep 17 00:00:00 2001 From: George Hazan Date: Thu, 1 Dec 2016 13:44:43 +0300 Subject: CCtrlSpin::SetPosition - method for a spin control initialization --- bin10/lib/mir_core.lib | Bin 312968 -> 313254 bytes bin10/lib/mir_core64.lib | Bin 313986 -> 314278 bytes bin12/lib/mir_core.lib | Bin 312968 -> 313254 bytes bin12/lib/mir_core64.lib | Bin 313986 -> 314278 bytes bin14/lib/mir_core.lib | Bin 312968 -> 313254 bytes bin14/lib/mir_core64.lib | Bin 313986 -> 314278 bytes include/m_gui.h | 1 + src/mir_core/src/mir_core.def | 1 + src/mir_core/src/mir_core64.def | 1 + src/mir_core/src/ui_utils.cpp | 5 +++++ 10 files changed, 8 insertions(+) diff --git a/bin10/lib/mir_core.lib b/bin10/lib/mir_core.lib index 45e00cbb72..443580479c 100644 Binary files a/bin10/lib/mir_core.lib and b/bin10/lib/mir_core.lib differ diff --git a/bin10/lib/mir_core64.lib b/bin10/lib/mir_core64.lib index 406f09f04d..29589f1c2d 100644 Binary files a/bin10/lib/mir_core64.lib and b/bin10/lib/mir_core64.lib differ diff --git a/bin12/lib/mir_core.lib b/bin12/lib/mir_core.lib index 45e00cbb72..443580479c 100644 Binary files a/bin12/lib/mir_core.lib and b/bin12/lib/mir_core.lib differ diff --git a/bin12/lib/mir_core64.lib b/bin12/lib/mir_core64.lib index 406f09f04d..29589f1c2d 100644 Binary files a/bin12/lib/mir_core64.lib and b/bin12/lib/mir_core64.lib differ diff --git a/bin14/lib/mir_core.lib b/bin14/lib/mir_core.lib index 45e00cbb72..443580479c 100644 Binary files a/bin14/lib/mir_core.lib and b/bin14/lib/mir_core.lib differ diff --git a/bin14/lib/mir_core64.lib b/bin14/lib/mir_core64.lib index 406f09f04d..29589f1c2d 100644 Binary files a/bin14/lib/mir_core64.lib and b/bin14/lib/mir_core64.lib differ diff --git a/include/m_gui.h b/include/m_gui.h index 977939bba2..322994b895 100644 --- a/include/m_gui.h +++ b/include/m_gui.h @@ -762,6 +762,7 @@ class MIR_CORE_EXPORT CCtrlSpin : public CCtrlBase public: CCtrlSpin(CDlgBase *dlg, int ctrlId); + void SetPosition(WORD max, WORD min = 0); void SetRange(WORD max, WORD min = 0); }; diff --git a/src/mir_core/src/mir_core.def b/src/mir_core/src/mir_core.def index c4c4a7f637..c1f420f5cc 100644 --- a/src/mir_core/src/mir_core.def +++ b/src/mir_core/src/mir_core.def @@ -1036,3 +1036,4 @@ CallFunctionSync @1170 ?GetItemRect@CCtrlListBox@@QAEHHPAUtagRECT@@@Z @1193 NONAME ?SetItemHeight@CCtrlListBox@@QAEXHH@Z @1194 NONAME ?UseSystemColors@CCtrlBase@@QAEXXZ @1195 NONAME +?SetPosition@CCtrlSpin@@QAEXGG@Z @1196 NONAME diff --git a/src/mir_core/src/mir_core64.def b/src/mir_core/src/mir_core64.def index 299eac88c3..c7d937c248 100644 --- a/src/mir_core/src/mir_core64.def +++ b/src/mir_core/src/mir_core64.def @@ -1036,3 +1036,4 @@ CallFunctionSync @1170 ?GetItemRect@CCtrlListBox@@QEAAHHPEAUtagRECT@@@Z @1193 NONAME ?SetItemHeight@CCtrlListBox@@QEAAXHH@Z @1194 NONAME ?UseSystemColors@CCtrlBase@@QEAAXXZ @1195 NONAME +?SetPosition@CCtrlSpin@@QEAAXGG@Z @1196 NONAME diff --git a/src/mir_core/src/ui_utils.cpp b/src/mir_core/src/ui_utils.cpp index 960393eba9..9ffb4b1217 100644 --- a/src/mir_core/src/ui_utils.cpp +++ b/src/mir_core/src/ui_utils.cpp @@ -676,6 +676,11 @@ CCtrlSpin::CCtrlSpin(CDlgBase *dlg, int ctrlId) : CCtrlBase(dlg, ctrlId) {} +void CCtrlSpin::SetPosition(WORD max, WORD min) +{ + SendMsg(UDM_GETPOS, 0, MAKELONG(min, max)); +} + void CCtrlSpin::SetRange(WORD max, WORD min) { SendMsg(UDM_SETRANGE, 0, MAKELONG(min, max)); -- cgit v1.2.3