Commits

flupp  committed 33e4582

fixed launcher loading; restructured config loading

  • Participants
  • Parent commits 6ebffd6

Comments (0)

Files changed (2)

File applet/SmoothTasks/Applet.cpp

 		this, SLOT(reload()));
 
 	connect(
-		this, SIGNAL(settingsChanged()),
-		this, SLOT(configuration()));
-
-	connect(
 		KWindowSystem::self(), SIGNAL(currentDesktopChanged(int)),
 		this, SLOT(currentDesktopChanged()));
 
 	connect(
 		m_layout, SIGNAL(sizeHintChanged(Qt::SizeHint)),
 		this, SIGNAL(sizeHintChanged(Qt::SizeHint)));
-	emit settingsChanged();
+	configChanged();
 	setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
 	setMaximumSize(INT_MAX, INT_MAX);
 }
 	}
 
 
-	if (changed) {
-		emit settingsChanged();
+	if (changed)
 		emit configNeedsSaving();
-	}
 }
 
 void Applet::widgetValueChanged() {
 //	}
 }
 
-void Applet::configuration() {	
+void Applet::configChanged() {
 	KConfigGroup cg = config();
 
 	m_taskSpacing  = cg.readEntry("taskSpacing", 5);
 	m_groupManager->setShowOnlyMinimized(cg.readEntry("showOnlyMinimized", false));
 	m_groupManager->reconnect();
 
-	for (int i = 0; i < m_layout->count(); ++ i) {
-		m_layout->itemAt(i)->settingsChanged();
-	}
+	m_groupManager->readLauncherConfig();
+
+	emit settingsChanged();
 	
 	updateFullLimit();
 }

File applet/SmoothTasks/Applet.h

 	void   dragLeaveEvent(QGraphicsSceneDragDropEvent *event);
 
 public slots:
+	virtual void configChanged();
 	void updateActiveIconIndex(TaskItem *item);
 	void reload();
 
 	void reconnectGroupManager();
 	void updateFullLimit();
 	void widgetValueChanged();
-	void configuration();
 	void loadDefaults();
 	void itemAdded(AbstractGroupableItem *groupableItem);
 	void itemRemoved(AbstractGroupableItem *groupableItem);