Changeset View
Changeset View
Standalone View
Standalone View
src/panels/information/filemetadataconfigurationdialog.cpp
Show All 13 Lines | |||||
14 | * You should have received a copy of the GNU General Public License * | 14 | * You should have received a copy of the GNU General Public License * | ||
15 | * along with this program; if not, write to the * | 15 | * along with this program; if not, write to the * | ||
16 | * Free Software Foundation, Inc., * | 16 | * Free Software Foundation, Inc., * | ||
17 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA * | 17 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA * | ||
18 | ***************************************************************************/ | 18 | ***************************************************************************/ | ||
19 | 19 | | |||
20 | #include "filemetadataconfigurationdialog.h" | 20 | #include "filemetadataconfigurationdialog.h" | ||
21 | 21 | | |||
22 | #ifndef HAVE_BALOO | | |||
23 | #include <kfilemetadataconfigurationwidget.h> | | |||
24 | #else | | |||
25 | #include <Baloo/FileMetaDataConfigWidget> | 22 | #include <Baloo/FileMetaDataConfigWidget> | ||
26 | #endif | | |||
27 | #include <KConfigGroup> | 23 | #include <KConfigGroup> | ||
28 | #include <KLocalizedString> | 24 | #include <KLocalizedString> | ||
29 | #include <KSharedConfig> | 25 | #include <KSharedConfig> | ||
30 | #include <KWindowConfig> | 26 | #include <KWindowConfig> | ||
31 | 27 | | |||
32 | #include <QDialogButtonBox> | 28 | #include <QDialogButtonBox> | ||
33 | #include <QLabel> | 29 | #include <QLabel> | ||
34 | #include <QPushButton> | 30 | #include <QPushButton> | ||
Show All 16 Lines | 38 | { | |||
51 | connect(buttonBox, &QDialogButtonBox::rejected, this, &FileMetaDataConfigurationDialog::reject); | 47 | connect(buttonBox, &QDialogButtonBox::rejected, this, &FileMetaDataConfigurationDialog::reject); | ||
52 | buttonBox->button(QDialogButtonBox::Ok)->setDefault(true); | 48 | buttonBox->button(QDialogButtonBox::Ok)->setDefault(true); | ||
53 | 49 | | |||
54 | m_descriptionLabel = new QLabel(i18nc("@label::textbox", | 50 | m_descriptionLabel = new QLabel(i18nc("@label::textbox", | ||
55 | "Select which data should " | 51 | "Select which data should " | ||
56 | "be shown:"), this); | 52 | "be shown:"), this); | ||
57 | m_descriptionLabel->setWordWrap(true); | 53 | m_descriptionLabel->setWordWrap(true); | ||
58 | 54 | | |||
59 | #ifndef HAVE_BALOO | | |||
60 | m_configWidget = new KFileMetaDataConfigurationWidget(this); | | |||
61 | #else | | |||
62 | m_configWidget = new Baloo::FileMetaDataConfigWidget(this); | 55 | m_configWidget = new Baloo::FileMetaDataConfigWidget(this); | ||
63 | #endif | | |||
64 | | ||||
65 | 56 | | |||
66 | QWidget* mainWidget = new QWidget(this); | 57 | QWidget* mainWidget = new QWidget(this); | ||
67 | QVBoxLayout* topLayout = new QVBoxLayout(mainWidget); | 58 | QVBoxLayout* topLayout = new QVBoxLayout(mainWidget); | ||
68 | topLayout->addWidget(m_descriptionLabel); | 59 | topLayout->addWidget(m_descriptionLabel); | ||
69 | topLayout->addWidget(m_configWidget); | 60 | topLayout->addWidget(m_configWidget); | ||
70 | mainLayout->addWidget(mainWidget); | 61 | mainLayout->addWidget(mainWidget); | ||
71 | mainLayout->addWidget(buttonBox); | 62 | mainLayout->addWidget(buttonBox); | ||
72 | 63 | | |||
Show All 39 Lines |