File indexing completed on 2024-03-24 15:25:28
0001 /* 0002 This file is part of the KDE project 0003 SPDX-FileCopyrightText: 2007 Matthias Kretz <kretz@kde.org> 0004 0005 SPDX-License-Identifier: LGPL-2.0-only 0006 */ 0007 0008 #ifndef KCMULTIDIALOG_P_H 0009 #define KCMULTIDIALOG_P_H 0010 0011 #include "kcmultidialog.h" 0012 #include <QList> 0013 #include <QStringList> 0014 0015 class KCModuleProxy; 0016 class KPageWidgetItem; 0017 0018 class KCMultiDialogPrivate 0019 { 0020 Q_DECLARE_PUBLIC(KCMultiDialog) 0021 protected: 0022 KCMultiDialogPrivate(KCMultiDialog *parent) 0023 : currentModule(nullptr) 0024 , q_ptr(parent) 0025 { 0026 } 0027 0028 virtual ~KCMultiDialogPrivate() 0029 { 0030 } 0031 0032 KCModuleProxy *currentModule; 0033 0034 struct CreatedModule { 0035 KCModuleProxy *kcm; 0036 KPageWidgetItem *item; 0037 QStringList componentNames; 0038 }; 0039 0040 typedef QList<CreatedModule> ModuleList; 0041 ModuleList modules; 0042 0043 void _k_slotCurrentPageChanged(KPageWidgetItem *current, KPageWidgetItem *previous); 0044 virtual void _k_clientChanged(); 0045 void _k_dialogClosed(); 0046 void _k_updateHeader(bool use, const QString &message); 0047 0048 KCMultiDialog *q_ptr; 0049 0050 private: 0051 void init(); 0052 void apply(); 0053 bool resolveChanges(KCModuleProxy *currentProxy); 0054 bool moduleSave(KCModuleProxy *module); 0055 }; 0056 0057 #endif // KCMULTIDIALOG_P_H