added stub for processing directories with .desktop files
authormishas <mikhail.sobolev@gmail.com>
Wed, 14 Mar 2007 17:42:26 +0000 (17:42 +0000)
committermishas <mikhail.sobolev@gmail.com>
Wed, 14 Mar 2007 17:42:26 +0000 (17:42 +0000)
git-svn-id: file:///svnroot/simple-launcher/trunk@81 3ba93dab-e023-0410-b42a-de7732cf370a

simple-launcher.cc

index cd05b6d..ceddd7c 100644 (file)
@@ -54,6 +54,8 @@ private:
   void loadConfig();
   void saveConfig();
 
+  void processDirectory(const std::string&);
+
   bool initWidget();
   void updateWidget();
 
@@ -130,6 +132,10 @@ bool SimpleLauncherApplet::doInit(void *state_data, int *state_size) {
 
   loadConfig();
 
+  for (int i = 0 ; ourDirs[i] != NULL ; ++i) {
+    processDirectory(ourDirs[i]);
+  }
+
   if (!initWidget()) {
     return false;
   }
@@ -190,17 +196,6 @@ void SimpleLauncherApplet::loadConfig() {
 
     delete buffer;
   }
-#if 0
-  for (int i = 0 ; ourFiles[i] != NULL ; ++i) {
-    LaunchableItem *item = new LaunchableItem();
-
-    if (item->load(ourFiles[i])) {
-      myItems.push_back(std::pair<std::string, LauncherItem *>(ourFiles[i], item));
-    } else {
-      delete item;
-    }
-  }
-#endif
 }
 
 void SimpleLauncherApplet::saveConfig() {
@@ -214,6 +209,9 @@ void SimpleLauncherApplet::saveConfig() {
   }
 }
 
+void SimpleLauncherApplet::processDirectory(const std::string& dirname) {
+}
+
 bool SimpleLauncherApplet::initWidget() {
   myWidget = gtk_frame_new(NULL);