Delete tmpfile after use.

SVN revision: 24065
This commit is contained in:
sebastid 2006-07-20 11:19:08 +00:00 committed by sebastid
parent f765174ec5
commit 73a6413bb0
4 changed files with 5 additions and 1 deletions

View File

@ -62,9 +62,11 @@ struct _E_App
unsigned char deleted : 1; /* this app's file is deleted from disk */
/* used for eap edit */
const char *image; /* used when we're saving a image into the eap */
int width; /* used for saving eap's image width in edje */
int height; /* used for saving eap's image height in edje */
unsigned char tmpfile : 1;
};
struct _E_App_Instance

View File

@ -136,6 +136,8 @@ _e_eap_edit_free_data(E_Config_Dialog *cfd, E_Config_Dialog_Data *data)
E_FREE(data->wrole);
E_FREE(data->iclass);
E_FREE(data->image);
if (data->editor->eap->tmpfile) ecore_file_unlink(data->editor->eap->image);
data->editor->eap->tmpfile = 0;
if (data->editor->eap->image) evas_stringshare_del(data->editor->eap->image);
data->editor->eap->width = 0;
data->editor->eap->height = 0;

View File

@ -573,6 +573,7 @@ _e_border_menu_cb_icon_edit(void *data, E_Menu *m, E_Menu_Item *mi)
a->image = evas_stringshare_add(path);
a->width = bd->client.netwm.icons[0].width;
a->height = bd->client.netwm.icons[0].height;
a->tmpfile = 1;
}
else
{

View File

@ -199,7 +199,6 @@ _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cf
{
Evas_Object *o, *of, *ob, *oi;
Evas_Coord wmw, wmh;
Evas_List *l, *l2;
o = e_widget_list_add(evas, 0, 1);