2016-12-27 19:08:04 +00:00
|
|
|
/*
|
|
|
|
* this file is part of the "wmtrash" project
|
|
|
|
* Copyright (C) 2004 by Jean Philippe GUILLEMIN <jp.guillemin@free.fr>
|
|
|
|
* license: This software is under GPL license
|
|
|
|
* rev: 0.2
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#ifndef __CONFPATH
|
|
|
|
#define __CONFPATH "/etc/wmtrash/"
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __CONFFILE
|
|
|
|
#define __CONFFILE "default.cf"
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __ICONPATH
|
|
|
|
#define __ICONPATH "/usr/share/wmtrash/"
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#define SHORT_STRING 64
|
|
|
|
#define MEDIUM_STRING 128
|
|
|
|
#define BIG_STRING 256
|
|
|
|
#define LONG_STRING 1024
|
|
|
|
#define EXTRALONG_STRING 4096
|
|
|
|
|
|
|
|
// Prototypes ************************************************************
|
|
|
|
|
|
|
|
struct wmtrash {
|
|
|
|
char configfile[MEDIUM_STRING];
|
|
|
|
char param_fm[MEDIUM_STRING];
|
|
|
|
char fm[BIG_STRING];
|
|
|
|
char param_img[MEDIUM_STRING];
|
|
|
|
char imagefile[BIG_STRING];
|
|
|
|
char param_path[MEDIUM_STRING];
|
|
|
|
char path[BIG_STRING];
|
|
|
|
};
|
|
|
|
|
|
|
|
GtkWidget * build_dockapp(char *configfile);
|
|
|
|
|
|
|
|
GtkWidget *create_main_dockapp_icon_window
|
|
|
|
(GtkWidget *main_window,
|
|
|
|
unsigned int size);
|
|
|
|
|
|
|
|
void launchonclick
|
2016-12-27 19:08:06 +00:00
|
|
|
(GtkWidget *event_box,
|
2016-12-27 19:08:04 +00:00
|
|
|
GdkEventButton *event,
|
|
|
|
struct wmtrash *data);
|
|
|
|
|
|
|
|
int parse_from_config
|
2016-12-27 19:08:06 +00:00
|
|
|
(char *filename,
|
2016-12-27 19:08:04 +00:00
|
|
|
char *param,
|
|
|
|
char *value);
|
|
|
|
|
|
|
|
int replace_value_in_config
|
2016-12-27 19:08:06 +00:00
|
|
|
(char *filename,
|
|
|
|
char *param,
|
2016-12-27 19:08:04 +00:00
|
|
|
char *new_value);
|
2016-12-27 19:08:06 +00:00
|
|
|
|
|
|
|
void enter_callback1(
|
2016-12-27 19:08:04 +00:00
|
|
|
GtkWidget *entry1,
|
|
|
|
struct wmtrash *data);
|
2016-12-27 19:08:06 +00:00
|
|
|
|
|
|
|
void enter_callback2(
|
2016-12-27 19:08:04 +00:00
|
|
|
GtkWidget *entry1,
|
|
|
|
struct wmtrash *data);
|
|
|
|
|
2016-12-27 19:08:06 +00:00
|
|
|
void close_callback(
|
2016-12-27 19:08:04 +00:00
|
|
|
GtkWidget *entry,
|
|
|
|
struct wmtrash *data);
|
|
|
|
|
|
|
|
int usage(char *homecf, char *defaultcf);
|
|
|
|
|
2016-12-27 19:08:06 +00:00
|
|
|
int fcopy( char *sfile,
|
2016-12-27 19:08:04 +00:00
|
|
|
char *dfile);
|
|
|
|
|
|
|
|
|