diff options
author | George Hazan <george.hazan@gmail.com> | 2023-09-24 13:43:48 +0300 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2023-09-24 13:43:48 +0300 |
commit | 0b4b240c8c0974b8f7b1a830df2d14d3d30cb08a (patch) | |
tree | 63464ba6269a9c61fc3cbb942f17cf53c1bff3d6 /plugins/SmileyAdd/src | |
parent | 1baa7a1a29c0af4b3c4744b05cb91b4fb41831a5 (diff) |
more cleaning
Diffstat (limited to 'plugins/SmileyAdd/src')
-rw-r--r-- | plugins/SmileyAdd/src/options.cpp | 8 | ||||
-rw-r--r-- | plugins/SmileyAdd/src/services.cpp | 2 | ||||
-rw-r--r-- | plugins/SmileyAdd/src/smileys.h | 2 |
3 files changed, 6 insertions, 6 deletions
diff --git a/plugins/SmileyAdd/src/options.cpp b/plugins/SmileyAdd/src/options.cpp index bcd1b16574..6d2049647b 100644 --- a/plugins/SmileyAdd/src/options.cpp +++ b/plugins/SmileyAdd/src/options.cpp @@ -257,7 +257,7 @@ class CGategoriesOptions : public COptionsBaseDialog tvi.item.mask = TVIF_TEXT | TVIF_IMAGE | TVIF_STATE | TVIF_SELECTEDIMAGE | TVIF_PARAM;
tvi.item.stateMask = TVIS_STATEIMAGEMASK | TVIS_SELECTED;
- auto &smc = *tmpsmcat.GetSmileyCategoryList();
+ auto &smc = tmpsmcat.GetSmileyCategoryList();
for (int i = 0; i < smc.getCount(); i++) {
if (smc[i].IsVisible()) {
tvi.item.pszText = (wchar_t *)smc[i].GetDisplayName().c_str();
@@ -303,7 +303,7 @@ class CGategoriesOptions : public COptionsBaseDialog bool useOne = !chkStdPack.GetState();
bool usePhysProto = chkUsePhys.GetState();
- auto &smc = *tmpsmcat.GetSmileyCategoryList();
+ auto &smc = tmpsmcat.GetSmileyCategoryList();
for (auto &it : smc) {
bool visiblecat = usePhysProto ? !it->IsAcc() : !it->IsPhysProto();
bool visible = useOne ? !it->IsProto() : visiblecat;
@@ -388,7 +388,7 @@ public: tmpsmcat = g_SmileyCategories;
- auto &smc = *g_SmileyCategories.GetSmileyCategoryList();
+ auto &smc = g_SmileyCategories.GetSmileyCategoryList();
for (auto &it : smc) {
HICON hIcon = nullptr;
if (it->IsProto()) {
@@ -416,7 +416,7 @@ public: // Cleanup database
CMStringW empty;
- auto &smc = *g_SmileyCategories.GetSmileyCategoryList();
+ auto &smc = g_SmileyCategories.GetSmileyCategoryList();
for (auto &it : smc)
if (tmpsmcat.GetSmileyCategory(it->GetName()) == nullptr)
opt.WritePackFileName(empty, it->GetName());
diff --git a/plugins/SmileyAdd/src/services.cpp b/plugins/SmileyAdd/src/services.cpp index f14cef58ae..bd8dcf2b4e 100644 --- a/plugins/SmileyAdd/src/services.cpp +++ b/plugins/SmileyAdd/src/services.cpp @@ -230,7 +230,7 @@ INT_PTR CustomCatMenu(WPARAM hContact, LPARAM lParam) int RebuildContactMenu(WPARAM wParam, LPARAM)
{
- auto &smc = *g_SmileyCategories.GetSmileyCategoryList();
+ auto &smc = g_SmileyCategories.GetSmileyCategoryList();
char *protnam = Proto_GetBaseAccountName(wParam);
bool haveMenu = IsSmileyProto(protnam);
diff --git a/plugins/SmileyAdd/src/smileys.h b/plugins/SmileyAdd/src/smileys.h index da80c4b924..334b6236f6 100644 --- a/plugins/SmileyAdd/src/smileys.h +++ b/plugins/SmileyAdd/src/smileys.h @@ -286,7 +286,7 @@ public: SmileyCategoryType* GetSmileyCategory(const CMStringW &name);
SmileyCategoryType* GetSmileyCategory(unsigned index);
SmileyPackType* GetSmileyPack(const CMStringW &name);
- SmileyCategoryVectorType* GetSmileyCategoryList(void) { return &m_SmileyCategories; };
+ SmileyCategoryVectorType& GetSmileyCategoryList(void) { return m_SmileyCategories; }
int NumberOfSmileyCategories(void) { return m_SmileyCategories.getCount(); }
|