diff options
author | George Hazan <ghazan@miranda.im> | 2020-05-05 19:03:57 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2020-05-05 19:03:57 +0300 |
commit | 01e2e633ef9c613464b84d8065d103d1112d4156 (patch) | |
tree | 367fc5552a313fbbdc25c5cb58a49b234a08507b /plugins/NewStory/src/history_control.cpp | |
parent | cfc04a114e5d83318f26e0641cfd36ed26736196 (diff) |
NewStory: option to hide scrollbar
Diffstat (limited to 'plugins/NewStory/src/history_control.cpp')
-rw-r--r-- | plugins/NewStory/src/history_control.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/plugins/NewStory/src/history_control.cpp b/plugins/NewStory/src/history_control.cpp index f7225ef153..e851c0b768 100644 --- a/plugins/NewStory/src/history_control.cpp +++ b/plugins/NewStory/src/history_control.cpp @@ -242,7 +242,8 @@ struct NewstoryListData : public MZeroedObject scrollTopPixel = cachedMaxTopPixel; } - RecalcScrollBar(); + if (g_plugin.bOptVScroll) + RecalcScrollBar(); } int LayoutItem(int index) @@ -505,7 +506,10 @@ LRESULT CALLBACK NewstoryListWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM case WM_CREATE: data = new NewstoryListData(hwnd); SetWindowLongPtr(hwnd, 0, (LONG_PTR)data); - data->RecalcScrollBar(); + if (!g_plugin.bOptVScroll) + SetWindowLong(hwnd, GWL_STYLE, GetWindowLong(hwnd, GWL_STYLE) & ~WS_VSCROLL); + else + data->RecalcScrollBar(); break; // History list control messages |