summaryrefslogtreecommitdiff
path: root/plugins/SmileyAdd
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2024-02-04 21:04:16 +0300
committerGeorge Hazan <george.hazan@gmail.com>2024-02-04 21:04:16 +0300
commit2d15bd30d76e1913d0d52d84cf654e4133605169 (patch)
tree74864158579b4e6426ee4b49bf356e43d74212da /plugins/SmileyAdd
parent2cea992a66689b940daaab17259a053af7d229e1 (diff)
SmileyAdd: we don't call ME_SMILEYADD_OPTIONSCHANGED when nothing was really changed
Diffstat (limited to 'plugins/SmileyAdd')
-rw-r--r--plugins/SmileyAdd/src/customsmiley.cpp2
-rw-r--r--plugins/SmileyAdd/src/services.cpp4
2 files changed, 3 insertions, 3 deletions
diff --git a/plugins/SmileyAdd/src/customsmiley.cpp b/plugins/SmileyAdd/src/customsmiley.cpp
index 29cbc02de8..40a76c7123 100644
--- a/plugins/SmileyAdd/src/customsmiley.cpp
+++ b/plugins/SmileyAdd/src/customsmiley.cpp
@@ -120,7 +120,7 @@ bool SmileyPackCType::LoadSmiley(const wchar_t *path)
for (auto &it : m_SmileyList)
if (it->GetTriggerText() == name) {
it->LoadFromResource(dirs, 0);
- return true;
+ return false;
}
m_SmileyList.insert(new SmileyCType(dirs, (wchar_t*)name.c_str()));
diff --git a/plugins/SmileyAdd/src/services.cpp b/plugins/SmileyAdd/src/services.cpp
index 123135259e..efc8e2cb10 100644
--- a/plugins/SmileyAdd/src/services.cpp
+++ b/plugins/SmileyAdd/src/services.cpp
@@ -344,8 +344,8 @@ static INT_PTR LoadContactSmileys(WPARAM, LPARAM lParam)
break;
case SMADD_FILE:
- g_SmileyPackCStore.AddSmiley(cont->pszModule, cont->path);
- NotifyEventHooks(g_hevOptionsChanged, 0, (WPARAM)cont->pszModule);
+ if (g_SmileyPackCStore.AddSmiley(cont->pszModule, cont->path))
+ NotifyEventHooks(g_hevOptionsChanged, 0, (WPARAM)cont->pszModule);
break;
case SMADD_FOLDER: