1 // This file is a part of Simple Launcher
3 // Copyright (C) 2006, 2007, 2008 Mikhail Sobolev <mss@mawhrin.net>
5 // Simple Launcher is free software; you can redistribute it and/or modify it
6 // under the terms of the GNU General Public License version 2 as published by
7 // the Free Software Foundation.
9 // This program is distributed in the hope that it will be useful, but WITHOUT
10 // ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 // FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
14 // You should have received a copy of the GNU General Public License along with
15 // this program; if not, write to the Free Software Foundation, Inc., 51
16 // Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
18 #ifndef _SIMPLE_LAUNCHER_H_
19 #define _SIMPLE_LAUNCHER_H_
23 #include "launcher-item.h"
24 #include "launchable-item.h"
25 #include "settings-dialog.h"
26 #include "gconf-wrapper.h"
28 #define SL_APPLET_GCONF_PATH "/apps/simple-launcher"
30 class SimpleLauncherApplet {
32 SimpleLauncherApplet(const std::string&);
33 ~SimpleLauncherApplet();
37 GtkWidget *settings(GtkWindow *parent);
39 GtkWidget *getWidget() const { return myWidget; }
42 int getHeight() const;
44 void getBackgroundColour(double& red, double& green, double& blue, double alpha) const;
47 static void addItem(LauncherItems&, const std::string&, bool);
52 static void updateItems(LauncherItems&);
53 static void processDirectory(LauncherItems&, const std::string&);
58 void buttonPressed(GtkWidget *button, GdkEventButton *event);
61 static void _button_pressed(GtkWidget *button, GdkEventButton *event, void *self);
62 static void _run_dialog(GtkMenuItem *, void *);
65 // GConfClientWrapper myClient;
66 // GConfKey myMainSettings;
68 osso_context_t *myContext;
73 LauncherItems myItems;
76 GConfBooleanOption myTransparent;
77 // bool myShowInfobanner; // FIXME: to implement
78 GConfIntegerOption myIconSize;
80 static char *ourDirs[];