summaryrefslogtreecommitdiffstats
path: root/kded
diff options
context:
space:
mode:
authorMichele Calgaro <michele.calgaro@yahoo.it>2020-12-19 22:55:58 +0900
committerMichele Calgaro <michele.calgaro@yahoo.it>2020-12-19 22:55:58 +0900
commit491e1c72c7e2a19b58772fd285284e974d489501 (patch)
tree2d2658d0c98c0d1a55746a7f9a39fa2344a9874c /kded
parent5cb3ed2e545a03815cdd04ab8666b605a71c44b4 (diff)
downloadtdelibs-491e1c72c7e2a19b58772fd285284e974d489501.tar.gz
tdelibs-491e1c72c7e2a19b58772fd285284e974d489501.zip
Fixed some uncrustify's code formatting offending files.
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
Diffstat (limited to 'kded')
-rw-r--r--kded/vfolder_menu.cpp65
1 files changed, 28 insertions, 37 deletions
diff --git a/kded/vfolder_menu.cpp b/kded/vfolder_menu.cpp
index 2e04965ea..880a17576 100644
--- a/kded/vfolder_menu.cpp
+++ b/kded/vfolder_menu.cpp
@@ -311,25 +311,6 @@ VFolderMenu::~VFolderMenu()
delete m_rootMenu;
}
-#define FOR_ALL_APPLICATIONS(it) \
- for(appsInfo *info = m_appsInfoStack.first(); \
- info; info = m_appsInfoStack.next()) \
- { \
- for(TQDictIterator<KService> it( info->applications ); \
- it.current(); ++it ) \
- {
-#define FOR_ALL_APPLICATIONS_END } }
-
-#define FOR_CATEGORY(category, it) \
- for(appsInfo *info = m_appsInfoStack.first(); \
- info; info = m_appsInfoStack.next()) \
- { \
- KService::List *list = info->dictCategories.find(category); \
- if (list) for(KService::List::ConstIterator it = list->begin(); \
- it != list->end(); ++it) \
- {
-#define FOR_CATEGORY_END } }
-
KService *
VFolderMenu::findApplication(const TQString &relPath)
{
@@ -934,12 +915,14 @@ VFolderMenu::processCondition(TQDomElement &domElem, TQDict<KService> *items)
}
else if (domElem.tagName() == "Not")
{
- FOR_ALL_APPLICATIONS(it)
- {
- KService *s = it.current();
- items->replace(s->menuId(), s);
- }
- FOR_ALL_APPLICATIONS_END
+ for (appsInfo *info = m_appsInfoStack.first(); info; info = m_appsInfoStack.next())
+ {
+ for (TQDictIterator<KService> it( info->applications ); it.current(); ++it )
+ {
+ KService *s = it.current();
+ items->replace(s->menuId(), s);
+ }
+ }
TQDict<KService> notItems;
TQDomNode n = domElem.firstChild();
@@ -955,21 +938,29 @@ VFolderMenu::processCondition(TQDomElement &domElem, TQDict<KService> *items)
}
else if (domElem.tagName() == "Category")
{
- FOR_CATEGORY(domElem.text(), it)
- {
- KService *s = *it;
- items->replace(s->menuId(), s);
- }
- FOR_CATEGORY_END
+ for (appsInfo *info = m_appsInfoStack.first(); info; info = m_appsInfoStack.next())
+ {
+ KService::List *list = info->dictCategories.find(domElem.text());
+ if (list)
+ {
+ for(KService::List::ConstIterator it = list->begin(); it != list->end(); ++it)
+ {
+ KService *s = *it;
+ items->replace(s->menuId(), s);
+ }
+ }
+ }
}
else if (domElem.tagName() == "All")
{
- FOR_ALL_APPLICATIONS(it)
- {
- KService *s = it.current();
- items->replace(s->menuId(), s);
- }
- FOR_ALL_APPLICATIONS_END
+ for (appsInfo *info = m_appsInfoStack.first(); info; info = m_appsInfoStack.next())
+ {
+ for (TQDictIterator<KService> it( info->applications ); it.current(); ++it )
+ {
+ KService *s = it.current();
+ items->replace(s->menuId(), s);
+ }
+ }
}
else if (domElem.tagName() == "Filename")
{