diff options
author | George Hazan <ghazan@miranda.im> | 2018-05-30 11:16:20 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2018-05-30 11:16:27 +0300 |
commit | 977ec42d71f87ccb93f2ba1ec49bc2e8e812c9f6 (patch) | |
tree | 01ca76746269176fb434537cd525d9d81be6b0bf /src | |
parent | 8966d6491816197e7cd510dd3f5e7c232b03ba68 (diff) |
senseless function removed
Diffstat (limited to 'src')
-rw-r--r-- | src/mir_app/src/ei_options.cpp | 9 | ||||
-rw-r--r-- | src/mir_app/src/ei_services.cpp | 5 | ||||
-rw-r--r-- | src/mir_app/src/extraicons.h | 1 |
3 files changed, 3 insertions, 12 deletions
diff --git a/src/mir_app/src/ei_options.cpp b/src/mir_app/src/ei_options.cpp index 02cec8571f..113c34c67a 100644 --- a/src/mir_app/src/ei_options.cpp +++ b/src/mir_app/src/ei_options.cpp @@ -251,7 +251,7 @@ public: virtual void OnInitDialog() { - int numSlots = GetNumberOfSlots(); + int numSlots = EXTRA_ICON_COUNT; if (numSlots < (int)registeredExtraIcons.getCount()) { HWND label = GetDlgItem(m_hwnd, IDC_MAX_ICONS_L); SetWindowText(label, CMStringW(FORMAT, TranslateT("*only the first %d icons will be shown"), numSlots)); @@ -307,7 +307,7 @@ public: oldSlots[i] = -1; lastUsedSlot = max(lastUsedSlot, registeredExtraIcons[i]->getSlot()); } - lastUsedSlot = min(lastUsedSlot, GetNumberOfSlots()); + lastUsedSlot = min(lastUsedSlot, EXTRA_ICON_COUNT); // Get user data and create new groups LIST<ExtraIconGroup> groups(1); @@ -328,7 +328,7 @@ public: bool enabled = ((tvi.state & INDEXTOSTATEIMAGEMASK(3)) == INDEXTOSTATEIMAGEMASK(2)); int slot = (enabled ? firstEmptySlot++ : -1); - if (slot >= GetNumberOfSlots()) + if (slot >= EXTRA_ICON_COUNT) slot = -1; if (ids->count == 1) { @@ -451,9 +451,6 @@ public: int InitOptionsCallback(WPARAM wParam, LPARAM) { - if (GetNumberOfSlots() < 1) - return 0; - OPTIONSDIALOGPAGE odp = { 0 }; odp.szGroup.a = LPGEN("Contact list"); odp.szTitle.a = LPGEN("Extra icons"); diff --git a/src/mir_app/src/ei_services.cpp b/src/mir_app/src/ei_services.cpp index 645327ad7d..98d53f0c9b 100644 --- a/src/mir_app/src/ei_services.cpp +++ b/src/mir_app/src/ei_services.cpp @@ -57,11 +57,6 @@ int ModulesLoaded(WPARAM, LPARAM) return 0; } -int GetNumberOfSlots() -{ - return EXTRA_ICON_COUNT; -} - int ConvertToClistSlot(int slot) { if (slot < 0) diff --git a/src/mir_app/src/extraicons.h b/src/mir_app/src/extraicons.h index 6df8be8b7d..8b3c50108a 100644 --- a/src/mir_app/src/extraicons.h +++ b/src/mir_app/src/extraicons.h @@ -190,7 +190,6 @@ extern LIST<ExtraIcon> extraIconsByHandle, extraIconsBySlot; void RebuildListsBasedOnGroups(LIST<ExtraIconGroup> &groups);
ExtraIcon * GetExtraIconBySlot(int slot);
-int GetNumberOfSlots();
int ConvertToClistSlot(int slot);
int Clist_SetExtraIcon(MCONTACT hContact, int slot, HANDLE hImage);
|