summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--plugins/SmileyAdd/src/options.cpp10
-rw-r--r--plugins/SmileyAdd/src/smileys.cpp2
-rw-r--r--plugins/SmileyAdd/src/smileys.h4
3 files changed, 10 insertions, 6 deletions
diff --git a/plugins/SmileyAdd/src/options.cpp b/plugins/SmileyAdd/src/options.cpp
index 7ce4e8ec15..6d388c6679 100644
--- a/plugins/SmileyAdd/src/options.cpp
+++ b/plugins/SmileyAdd/src/options.cpp
@@ -343,10 +343,12 @@ void OptionsDialogType::UpdateVisibleSmPackList(void)
CMString FileName;
if (!ProtoName.IsEmpty()) {
- PhysProtoName += ProtoName;
- FileName = tmpsmcat.GetSmileyCategory(PhysProtoName) ? tmpsmcat.GetSmileyCategory(PhysProtoName)->GetFilename() : _T("");
- if (FileName.IsEmpty())
- visible = true;
+ PhysProtoName += ProtoName;
+ SmileyCategoryType* scm = tmpsmcat.GetSmileyCategory(PhysProtoName);
+ if (scm == NULL)
+ visible = false;
+ else if (scm->GetFilename().IsEmpty())
+ visible = true;
}
}
diff --git a/plugins/SmileyAdd/src/smileys.cpp b/plugins/SmileyAdd/src/smileys.cpp
index 10ca0bc2dd..c4afe2e8d3 100644
--- a/plugins/SmileyAdd/src/smileys.cpp
+++ b/plugins/SmileyAdd/src/smileys.cpp
@@ -866,7 +866,7 @@ void SmileyCategoryListType::AddAccountAsCategory(PROTOACCOUNT *acc, const CMStr
}
CMString tname(A2T_SM(acc->szModuleName));
- AddCategory(tname, displayName, smcProto, paths);
+ AddCategory(tname, displayName, acc->bIsVirtual ? smcVirtualProto : smcProto, paths);
}
}
diff --git a/plugins/SmileyAdd/src/smileys.h b/plugins/SmileyAdd/src/smileys.h
index 5a27cd37c0..ce1bf0a867 100644
--- a/plugins/SmileyAdd/src/smileys.h
+++ b/plugins/SmileyAdd/src/smileys.h
@@ -225,6 +225,7 @@ typedef enum
smcNone,
smcStd,
smcProto,
+ smcVirtualProto,
smcTransportProto,
smcPhysProto,
smcCustom,
@@ -255,8 +256,9 @@ public:
const CMString& GetFilename(void) const { return m_Filename; }
bool IsCustom(void) { return type == smcCustom; }
- bool IsProto(void) { return type == smcProto || type == smcPhysProto || type == smcTransportProto; }
+ bool IsProto(void) { return type == smcProto || type == smcPhysProto || type == smcTransportProto || type == smcVirtualProto; }
bool IsAcc(void) { return type == smcProto; }
+ bool IsVirtual(void) { return type == smcProto; }
bool IsPhysProto(void) { return type == smcPhysProto; }
bool IsTransportProto(void) { return type == smcTransportProto; }
bool IsExt(void) { return type == smcExt; }