diff options
| author | Peter Penz <[email protected]> | 2009-11-06 20:06:00 +0000 |
|---|---|---|
| committer | Peter Penz <[email protected]> | 2009-11-06 20:06:00 +0000 |
| commit | 18a298979492f7305504e2d8ad2d8a5de0f0b2b9 (patch) | |
| tree | 7400477b3d2206dcb1917891c357800367cc6cb2 /src | |
| parent | a9f8714fc1f12f7e044ec9ee091cb5170a7990fe (diff) | |
move the position of the filename below the preview
svn path=/trunk/KDE/kdebase/apps/; revision=1045798
Diffstat (limited to 'src')
| -rw-r--r-- | src/panels/information/informationpanelcontent.cpp | 27 | ||||
| -rw-r--r-- | src/panels/information/informationpanelcontent.h | 3 |
2 files changed, 11 insertions, 19 deletions
diff --git a/src/panels/information/informationpanelcontent.cpp b/src/panels/information/informationpanelcontent.cpp index 40d5c9cbc..31c27d718 100644 --- a/src/panels/information/informationpanelcontent.cpp +++ b/src/panels/information/informationpanelcontent.cpp @@ -58,10 +58,9 @@ InformationPanelContent::InformationPanelContent(QWidget* parent) : m_item(), m_pendingPreview(false), m_outdatedPreviewTimer(0), - m_nameLabel(0), m_preview(0), - m_previewSeparator(0), m_phononWidget(0), + m_nameLabel(0), m_metaDataWidget(0), m_metaDataArea(0) { @@ -79,15 +78,6 @@ InformationPanelContent::InformationPanelContent(QWidget* parent) : QVBoxLayout* layout = new QVBoxLayout; layout->setSpacing(KDialog::spacingHint()); - // name - m_nameLabel = new QLabel(parent); - QFont font = m_nameLabel->font(); - font.setBold(true); - m_nameLabel->setFont(font); - m_nameLabel->setAlignment(Qt::AlignHCenter); - m_nameLabel->setSizePolicy(QSizePolicy::Preferred, QSizePolicy::Fixed); - m_nameLabel->setMaximumWidth(KIconLoader::SizeEnormous); - // preview const int minPreviewWidth = KIconLoader::SizeEnormous + KIconLoader::SizeMedium; @@ -102,11 +92,16 @@ InformationPanelContent::InformationPanelContent(QWidget* parent) : connect(m_phononWidget, SIGNAL(playingStopped()), this, SLOT(slotPlayingStopped())); - m_previewSeparator = new KSeparator(parent); + // name + m_nameLabel = new QLabel(parent); + QFont font = m_nameLabel->font(); + font.setBold(true); + m_nameLabel->setFont(font); + m_nameLabel->setAlignment(Qt::AlignHCenter); + m_nameLabel->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Fixed); const bool showPreview = InformationPanelSettings::showPreview(); m_preview->setVisible(showPreview); - m_previewSeparator->setVisible(showPreview); m_metaDataWidget = new KMetaDataWidget(parent); m_metaDataWidget->setSizePolicy(QSizePolicy::Preferred, QSizePolicy::Minimum); @@ -135,11 +130,10 @@ InformationPanelContent::InformationPanelContent(QWidget* parent) : palette.setColor(viewport->backgroundRole(), QColor(Qt::transparent)); viewport->setPalette(palette); - layout->addWidget(m_nameLabel); - layout->addWidget(new KSeparator(this)); layout->addWidget(m_preview); layout->addWidget(m_phononWidget); - layout->addWidget(m_previewSeparator); + layout->addWidget(m_nameLabel); + layout->addWidget(new KSeparator()); layout->addWidget(m_metaDataArea); parent->setLayout(layout); } @@ -290,7 +284,6 @@ void InformationPanelContent::configureSettings() const bool isChecked = action->isChecked(); if (action == previewAction) { m_preview->setVisible(isChecked); - m_previewSeparator->setVisible(isChecked); InformationPanelSettings::setShowPreview(isChecked); } else if (action == configureAction) { QPointer<KMetaDataConfigurationDialog> dialog = new KMetaDataConfigurationDialog(m_metaDataWidget, this, Qt::Dialog); diff --git a/src/panels/information/informationpanelcontent.h b/src/panels/information/informationpanelcontent.h index 9c17b9397..6c08e50d2 100644 --- a/src/panels/information/informationpanelcontent.h +++ b/src/panels/information/informationpanelcontent.h @@ -115,11 +115,10 @@ private: bool m_pendingPreview; QTimer* m_outdatedPreviewTimer; - QLabel* m_nameLabel; PixmapViewer* m_preview; - KSeparator* m_previewSeparator; PhononWidget* m_phononWidget; + QLabel* m_nameLabel; KMetaDataWidget* m_metaDataWidget; QScrollArea* m_metaDataArea; }; |
