┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Penz <[email protected]>2010-03-13 19:17:38 +0000
committerPeter Penz <[email protected]>2010-03-13 19:17:38 +0000
commit7b8a3ae8005a1a199b92b564b15f02c884ed7816 (patch)
tree8f452a151c9e8919d440cb6ea8c602c6adcacab6
parent5f542389124512e01ec05a4c939d902a5dcbd5a7 (diff)
Let the custom widgets stay invisible per default after constructing them. This prevent a possible flickering when starting Dolphin.
svn path=/trunk/KDE/kdebase/apps/; revision=1102837
-rw-r--r--src/panels/information/kmetadatawidget.cpp5
-rw-r--r--src/panels/information/kmetadatawidget.h3
2 files changed, 6 insertions, 2 deletions
diff --git a/src/panels/information/kmetadatawidget.cpp b/src/panels/information/kmetadatawidget.cpp
index 5b15b6cef..7d82aef06 100644
--- a/src/panels/information/kmetadatawidget.cpp
+++ b/src/panels/information/kmetadatawidget.cpp
@@ -188,16 +188,19 @@ KMetaDataWidget::Private::Private(KMetaDataWidget* parent) :
m_ratingWidget->setAlignment(align);
connect(m_ratingWidget, SIGNAL(ratingChanged(unsigned int)),
q, SLOT(slotRatingChanged(unsigned int)));
+ m_ratingWidget->setVisible(false);
m_taggingWidget = new KTaggingWidget(parent);
connect(m_taggingWidget, SIGNAL(tagsChanged(const QList<Nepomuk::Tag>&)),
q, SLOT(slotTagsChanged(const QList<Nepomuk::Tag>&)));
connect(m_taggingWidget, SIGNAL(tagActivated(const Nepomuk::Tag&)),
q, SLOT(slotTagActivated(const Nepomuk::Tag&)));
+ m_taggingWidget->setVisible(false);
m_commentWidget = new KCommentWidget(parent);
connect(m_commentWidget, SIGNAL(commentChanged(const QString&)),
q, SLOT(slotCommentChanged(const QString&)));
+ m_commentWidget->setVisible(false);
}
#endif
@@ -398,7 +401,7 @@ void KMetaDataWidget::Private::slotLoadingFinished()
#ifdef HAVE_NEPOMUK
// Show the remaining meta information as text. The number
// of required rows may very. Existing rows are reused to
- // prevent flickering.
+ // prevent flickering and to increase the performance.
int rowIndex = m_fixedRowCount;
const QHash<KUrl, Nepomuk::Variant> data = m_model->data();
diff --git a/src/panels/information/kmetadatawidget.h b/src/panels/information/kmetadatawidget.h
index 27b06a05d..4281b6519 100644
--- a/src/panels/information/kmetadatawidget.h
+++ b/src/panels/information/kmetadatawidget.h
@@ -54,7 +54,8 @@ class KUrl;
* like done already for the rating, tags or comments). The
* following steps are necessary:
* - Derive a custom widget from KMetaDataWidget.
- * - Create the custom widgets in the constructor.
+ * - Create the custom widgets in the constructor and
+ * make them invisible per default.
* - Implement the methods valueWidget(), setValue() and
* (optionally) label() by accessing the custom widgets.
*/