diff options
author | George Hazan <ghazan@miranda.im> | 2018-06-17 21:30:32 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2018-06-17 21:30:32 +0300 |
commit | 5d1adca6a83289d3dcc23bc0af82193da69d9d96 (patch) | |
tree | 8ee7d5758389c54a02a5e1d6725d1b9b5cd70364 /plugins/TabSRMM/src/sidebar.cpp | |
parent | ee8fcfa82fa32a1b9a9a8123bf0e220c06779c0c (diff) |
GetTabWindow applied to all another places
Diffstat (limited to 'plugins/TabSRMM/src/sidebar.cpp')
-rw-r--r-- | plugins/TabSRMM/src/sidebar.cpp | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/plugins/TabSRMM/src/sidebar.cpp b/plugins/TabSRMM/src/sidebar.cpp index cf64ff1ad1..27a7e69825 100644 --- a/plugins/TabSRMM/src/sidebar.cpp +++ b/plugins/TabSRMM/src/sidebar.cpp @@ -496,17 +496,14 @@ void CSideBar::populateAll() int iItems = (int)TabCtrl_GetItemCount(hwndTab);
- TCITEM item = {};
- item.mask = TCIF_PARAM;
-
m_iTopButtons = 0;
for (int i = 0; i < iItems; i++) {
- TabCtrl_GetItem(hwndTab, i, &item);
- if (item.lParam == 0 || !IsWindow((HWND)item.lParam))
+ HWND hDlg = GetTabWindow(hwndTab, i);
+ if (hDlg == 0 || !IsWindow(hDlg))
continue;
- CSrmmWindow *dat = (CSrmmWindow*)::GetWindowLongPtr((HWND)item.lParam, GWLP_USERDATA);
+ CSrmmWindow *dat = (CSrmmWindow*)::GetWindowLongPtr(hDlg, GWLP_USERDATA);
if (dat == nullptr)
continue;
|