[rkward-cvs] SF.net SVN: rkward: [2227] branches/KDE4_port/rkward/misc
tfry at users.sourceforge.net
tfry at users.sourceforge.net
Thu Nov 15 21:56:13 UTC 2007
Revision: 2227
http://rkward.svn.sourceforge.net/rkward/?rev=2227&view=rev
Author: tfry
Date: 2007-11-15 13:56:13 -0800 (Thu, 15 Nov 2007)
Log Message:
-----------
Resize object list view columns, when the filter changed
Modified Paths:
--------------
branches/KDE4_port/rkward/misc/rkobjectlistview.cpp
branches/KDE4_port/rkward/misc/rkobjectlistview.h
Modified: branches/KDE4_port/rkward/misc/rkobjectlistview.cpp
===================================================================
--- branches/KDE4_port/rkward/misc/rkobjectlistview.cpp 2007-11-15 21:48:14 UTC (rev 2226)
+++ branches/KDE4_port/rkward/misc/rkobjectlistview.cpp 2007-11-15 21:56:13 UTC (rev 2227)
@@ -118,11 +118,12 @@
setExpanded (olist, true);
setExpanded (genv, true);
setMinimumHeight (rowHeight (genv) * 5);
- resizeColumnToContents (0);
+ resetWidths ();
connect (RObjectList::getObjectList (), SIGNAL (updateComplete ()), this, SLOT (updateComplete ()));
connect (RObjectList::getObjectList (), SIGNAL (updateStarted ()), this, SLOT (updateStarted ()));
connect (selectionModel (), SIGNAL (selectionChanged(const QItemSelection&, const QItemSelection&)), this, SLOT (selectionChanged(const QItemSelection&, const QItemSelection&)));
+ connect (settings, SIGNAL (settingsChanged()), this, SLOT (resetWidths()));
updateComplete ();
}
@@ -139,6 +140,12 @@
setEnabled (false);
}
+void RKObjectListView::resetWidths () {
+ RK_TRACE (APP);
+
+ resizeColumnToContents (0);
+}
+
//////////////////// RKObjectListViewSettings //////////////////////////
RKObjectListViewSettings::RKObjectListViewSettings (QObject* parent) : QSortFilterProxyModel (parent) {
@@ -277,7 +284,6 @@
RK_TRACE (APP);
update_timer->start (0);
- emit (settingsChanged ());
}
void RKObjectListViewSettings::updateSelfNow () {
@@ -286,6 +292,8 @@
for (int i = 0; i < SettingsCount; ++i) actions[i]->setChecked (settings[i]);
invalidateFilter ();
+
+ emit (settingsChanged ());
}
void RKObjectListViewSettings::globalSettingsChanged (RKSettings::SettingsPage page) {
Modified: branches/KDE4_port/rkward/misc/rkobjectlistview.h
===================================================================
--- branches/KDE4_port/rkward/misc/rkobjectlistview.h 2007-11-15 21:48:14 UTC (rev 2226)
+++ branches/KDE4_port/rkward/misc/rkobjectlistview.h 2007-11-15 21:56:13 UTC (rev 2227)
@@ -68,6 +68,7 @@
void updateComplete ();
void updateStarted ();
void selectionChanged (const QItemSelection & selected, const QItemSelection & deselected);
+ void resetWidths ();
virtual void popupConfigure ();
protected:
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the rkward-tracker
mailing list