X-Git-Url: https://vcs.maemo.org/git/?a=blobdiff_plain;f=src%2Fcl-utils.h;fp=src%2Fcl-utils.h;h=aabb3ab46a37f69b867cfe44a3aacb0ee4c6547e;hb=9ff94de5585c86d4a7e6dc00640fa923d8b68479;hp=0000000000000000000000000000000000000000;hpb=c00fd0d00e89489abab6d6028fb34fce43dec8f2;p=cl-launcher diff --git a/src/cl-utils.h b/src/cl-utils.h new file mode 100644 index 0000000..aabb3ab --- /dev/null +++ b/src/cl-utils.h @@ -0,0 +1,65 @@ +/* + * Camera Launcher for Maemo. + * Copyright (C) 2009 Roman Moravcik + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + +#ifndef CL_UTILS_H +#define CL_UTILS_H + +#ifdef HAVE_CONFIG_H +#include +#endif + +#include +#include +#include + +#include +#include + +#include +#include + +#define GCONF_CL_LAUNCHER "/apps/maemo/cl-launcher" +#define CL_LAUNCHER_DESKTOP_DATADIR "/usr/share/applications/cl-launcher" + +typedef enum { + CL_LAUNCHER_ACTION_DO_NOTHING = 0, + CL_LAUNCHER_ACTION_RUN_PREFERED_APPLICATION, + CL_LAUNCHER_ACTION_SHOW_SELECTOR_POPUP +} CLLauncherAction; + +enum { + SELECTOR_COLUMN_ICON = 0, + SELECTOR_COLUMN_NAME, + SELECTOR_COLUMN_OSSO_SERVICE, + SELECTOR_COLUMN_EXEC, + NUM_COLS +}; + +typedef struct { + gchar *icon; + gchar *name; + gchar *osso_service; + gchar *exec; +} DesktopFileInfo; + +gboolean get_application_list (GtkListStore *list); + +DesktopFileInfo *get_desktop_file_info (const gchar *desktop_file); + +#endif /* CL_UTILS_H */