Enlightenment CVS committal
Author : kwo
Project : e16
Module : e
Dir : e16/e/src
Modified Files:
E.h actions.c borders.c buttons.c cmclass.c comms.c cursors.c
desktops.c dialog.c groups.c iclass.c ipc.c session.c
settings.c snaps.c sound.c tclass.c theme.c tooltips.c
Log Message:
Trivial dialog cleanups.
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/E.h,v
retrieving revision 1.168
retrieving revision 1.169
diff -u -3 -r1.168 -r1.169
--- E.h 28 Dec 2003 17:57:30 -0000 1.168
+++ E.h 3 Jan 2004 12:21:51 -0000 1.169
@@ -224,34 +224,6 @@
#define AUDIO_PLAY(sclass) \
ApplySclass(FindItem((sclass), 0, LIST_FINDBY_NAME, LIST_TYPE_SCLASS));
-/************************************************************************/
-/* dialog macro convenience funcs */
-/************************************************************************/
-
-#define DIALOG_OK(title, text) \
-{ \
- Dialog *__d; \
- __d = CreateDialog("DIALOG"); \
- DialogSetTitle(__d, title); \
- DialogSetText(__d, text); \
- DialogAddButton(__d, _("OK"), NULL, 1); \
- ShowDialog(__d); \
-}
-
-#define DIALOG_PARAM_OK(title) \
-{ \
- Dialog *__d; \
- __d = CreateDialog("DIALOG"); \
- DialogSetTitle(__d, title);
-
-#define DIALOG_PARAM \
-DialogSetParamText(__d,
-
-#define DIALOG_PARAM_END \
- ); \
- DialogAddButton(__d, _("OK"), NULL, 1); \
- ShowDialog(__d); \
-}
/************************************************************************/
@@ -2621,29 +2593,24 @@
int (*CompareFunc) (void *d1, void *d2));
/* dialog.c */
-Dialog *CreateDialog(char *name);
+Dialog *DialogCreate(char *name);
+void DialogDestroy(Dialog * d);
void DialogBindKey(Dialog * d, char *key,
void (*func) (int val, void *data), int val,
void *data);
-void FreeDialog(Dialog * d);
void DialogSetText(Dialog * d, char *text);
void DialogSetTitle(Dialog * d, char *title);
-void DialogAddButton(Dialog * d, char *text,
- void (*func) (int val, void *data),
- char close);
-void DialogDrawButton(Dialog * d, int bnum);
-void DialogActivateButton(Window win, int inclick);
-void DialogDraw(Dialog * d);
-void DialogDrawArea(Dialog * d, int x, int y, int w, int h);
+void DialogSetExitFunction(Dialog * d,
+ void (*func) (int val, void *data),
+ int val, void *data);
void DialogRedraw(Dialog * d);
void DialogMove(Dialog * d);
void ShowDialog(Dialog * d);
void DialogClose(Dialog * d);
-void DialogSetParamText(Dialog * d, char *fmt, ...);
-void DialogAlert(char *fmt, ...);
-void DialogAlertOK(char *fmt, ...);
-void DialogRestart(int val, void *data);
-void DialogQuit(int val, void *data);
+
+void DialogAddButton(Dialog * d, char *text,
+ void (*func) (int val, void *data),
+ char close);
DItem *DialogInitItem(Dialog * d);
DItem *DialogAddItem(DItem * dii, int type);
DItem *DialogItem(Dialog * d);
@@ -2657,10 +2624,8 @@
void DialogItemSetFill(DItem * di, char fill_h, char fill_v);
void DialogItemSetAlign(DItem * di, int align_h, int align_v);
void DialogItemCallCallback(DItem * di);
-void DialogRealizeItem(Dialog * d, DItem * di);
void DialogDrawItems(Dialog * d, DItem * di, int x, int y, int w,
int h);
-void DialogItemsRealize(Dialog * d);
void DialogItemButtonSetText(DItem * di, char *text);
void DialogItemCheckButtonSetText(DItem * di, char *text);
void DialogItemTextSetText(DItem * di, char *text);
@@ -2677,18 +2642,13 @@
char horizontal);
void DialogItemImageSetFile(DItem * di, char *image);
void DialogFreeItem(DItem * di);
-DItem *DialogItemFindWindow(DItem * di, Window win);
void DialogItemSetRowSpan(DItem * di, int row_span);
void DialogItemSetColSpan(DItem * di, int col_span);
-void DialogSetExitFunction(Dialog * d,
- void (*func) (int val, void *data),
- int val, void *data);
void DialogItemRadioButtonSetText(DItem * di, char *text);
void DialogItemRadioButtonSetFirst(DItem * di, DItem * first);
void DialogItemRadioButtonGroupSetValPtr(DItem * di,
int *val_ptr);
void DialogItemRadioButtonGroupSetVal(DItem * di, int val);
-void MoveTableBy(Dialog * d, DItem * di, int dx, int dy);
void DialogItemSliderSetVal(DItem * di, int val);
void DialogItemSliderSetBounds(DItem * di, int lower, int upper);
@@ -2707,6 +2667,14 @@
void DialogItemAreaSetEventFunc(DItem * di,
void (*func) (int val,
void *data));
+
+void DialogOK(const char *title, const char *fmt, ...);
+void DialogOKstr(const char *title, const char *txt);
+void DialogRestart(int val, void *data);
+void DialogQuit(int val, void *data);
+void DialogAlert(const char *fmt, ...);
+void DialogAlertOK(const char *fmt, ...);
+
int DialogEventKeyPress(XEvent * ev);
int DialogEventMotion(XEvent * ev);
int DialogEventExpose(XEvent * ev);
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/actions.c,v
retrieving revision 1.122
retrieving revision 1.123
diff -u -3 -r1.122 -r1.123
--- actions.c 27 Dec 2003 19:20:15 -0000 1.122
+++ actions.c 3 Jan 2004 12:21:51 -0000 1.123
@@ -277,11 +277,8 @@
if (ActionClassToRemove->ref_count > 0)
{
- char stuff[255];
-
- Esnprintf(stuff, sizeof(stuff), _("%u references remain\n"),
- ActionClassToRemove->ref_count);
- DIALOG_OK(_("ActionClass Error!"), stuff);
+ DialogOK(_("ActionClass Error!"), _("%u references remain\n"),
+ ActionClassToRemove->ref_count);
EDBUG_RETURN_;
}
while (RemoveItemByPtr(ActionClassToRemove, LIST_TYPE_ACLASS));
@@ -3199,7 +3196,7 @@
ShowDialog(d);
EDBUG_RETURN(0);
}
- d = CreateDialog("ABOUT_ENLIGHTENMENT");
+ d = DialogCreate("ABOUT_ENLIGHTENMENT");
{
char stuff[255];
@@ -3829,17 +3826,17 @@
("You have been warned about the dangers of Zoom mode\n"));
fclose(f);
}
- DIALOG_OK(_("Warning !!!"),
- _("This feature is heavily reliant on a feature of your\n"
- "X Server called the Vid Mode Extension. This feature exists\n"
- "in XFree86 Servers, but is not a heavily used part of the\n"
- "Server and thus isn't tested much.\n\n"
- "It is possible your X Server does not deal well with being\n"
- "asked to switch modes quickly and it may hang, glitch,\n"
- "display artefacts or perhaps simply refuse to work.\n\n"
- "This is a warning and will only be displayed this one time.\n"
- "If your Server does not behave well then you will probably\n"
- "have to avoid using this feature.\n"));
+ DialogOK(_("Warning !!!"),
+ _("This feature is heavily reliant on a feature of your\n"
+ "X Server called the Vid Mode Extension. This feature exists\n"
+ "in XFree86 Servers, but is not a heavily used part of the\n"
+ "Server and thus isn't tested much.\n\n"
+ "It is possible your X Server does not deal well with being\n"
+ "asked to switch modes quickly and it may hang, glitch,\n"
+ "display artefacts or perhaps simply refuse to work.\n\n"
+ "This is a warning and will only be displayed this one time.\n"
+ "If your Server does not behave well then you will probably\n"
+ "have to avoid using this feature.\n"));
EDBUG_RETURN(0);
}
ewin = GetFocusEwin();
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/borders.c,v
retrieving revision 1.115
retrieving revision 1.116
diff -u -3 -r1.115 -r1.116
--- borders.c 28 Dec 2003 17:57:30 -0000 1.115
+++ borders.c 3 Jan 2004 12:21:51 -0000 1.116
@@ -2191,13 +2191,10 @@
if (b->ref_count > 0)
{
- char stuff[255];
-
- Esnprintf(stuff, sizeof(stuff), _("%u references remain\n"),
- b->ref_count);
- DIALOG_OK(_("Border Error!"), stuff);
+ DialogOK(_("Border Error!"), _("%u references remain\n"), b->ref_count);
EDBUG_RETURN_;
}
+
while (RemoveItemByPtr(b, LIST_TYPE_BORDER));
for (i = 0; i < b->num_winparts; i++)
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/buttons.c,v
retrieving revision 1.24
retrieving revision 1.25
diff -u -3 -r1.24 -r1.25
--- buttons.c 13 Dec 2003 14:12:22 -0000 1.24
+++ buttons.c 3 Jan 2004 12:21:51 -0000 1.25
@@ -121,12 +121,7 @@
if (b->ref_count > 0)
{
- char stuff[255];
-
- Esnprintf(stuff, sizeof(stuff), _("%u references remain\n"),
- b->ref_count);
- DIALOG_OK(_("Button Error!"), stuff);
-
+ DialogOK(_("Button Error!"), _("%u references remain\n"), b->ref_count);
EDBUG_RETURN_;
}
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/cmclass.c,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -3 -r1.11 -r1.12
--- cmclass.c 5 Nov 2003 17:24:42 -0000 1.11
+++ cmclass.c 3 Jan 2004 12:21:51 -0000 1.12
@@ -62,13 +62,11 @@
}
EDBUG_RETURN_;
-
}
void
FreeModCurve(ModCurve * c)
{
-
EDBUG(6, "FreeModCurve");
if (!c)
@@ -78,13 +76,11 @@
Efree(c->py);
EDBUG_RETURN_;
-
}
void
FreeCMClass(ColorModifierClass * cm)
{
-
EDBUG(5, "FreeCmClass");
if (!cm)
@@ -92,14 +88,9 @@
if (cm->ref_count > 0)
{
- char stuff[255];
-
- Esnprintf(stuff, sizeof(stuff), _("%u references remain\n"),
- cm->ref_count);
- DIALOG_OK(_("ColorModClass Error!"), stuff);
-
+ DialogOK(_("ColorModClass Error!"), _("%u references remain\n"),
+ cm->ref_count);
EDBUG_RETURN_;
-
}
while (RemoveItemByPtr(cm, LIST_TYPE_COLORMODIFIER));
@@ -110,7 +101,6 @@
FreeModCurve(&(cm->blue));
EDBUG_RETURN_;
-
}
ColorModifierClass *
@@ -180,7 +170,6 @@
CreateCurve(&(cm->blue));
EDBUG_RETURN(cm);
-
}
void
@@ -260,5 +249,4 @@
CreateCurve(&(cm->blue));
EDBUG_RETURN_;
-
}
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/comms.c,v
retrieving revision 1.37
retrieving revision 1.38
diff -u -3 -r1.37 -r1.38
--- comms.c 11 Dec 2003 21:13:50 -0000 1.37
+++ comms.c 3 Jan 2004 12:21:51 -0000 1.38
@@ -2057,13 +2057,10 @@
if (!s2)
s2 = sunknown;
{
- char buf[FILEPATH_LEN_MAX];
-
- Esnprintf(buf, sizeof(buf),
- _("Received Unknown Client Message.\n"
- "Client Name: %s\n" "Client Version: %s\n"
- "Message Contents:\n\n" "%s\n"), s1, s2, s);
- DIALOG_OK(_("E IPC Error"), buf);
+ DialogOK(_("E IPC Error"),
+ _("Received Unknown Client Message.\n"
+ "Client Name: %s\n" "Client Version: %s\n"
+ "Message Contents:\n\n" "%s\n"), s1, s2, s);
AUDIO_PLAY("SOUND_ERROR_IPC");
}
}
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/cursors.c,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -3 -r1.13 -r1.14
--- cursors.c 15 Nov 2003 22:27:17 -0000 1.13
+++ cursors.c 3 Jan 2004 12:21:51 -0000 1.14
@@ -91,25 +91,18 @@
if (!ec)
return;
XDefineCursor(disp, win, ec->cursor);
-
- return;
}
void
FreeECursor(ECursor * ec)
{
-
if (!ec)
return;
if (ec->ref_count > 0)
{
- char stuff[255];
-
- Esnprintf(stuff, sizeof(stuff), _("%u references remain\n"),
- ec->ref_count);
- DIALOG_OK(_("ECursor Error!"), stuff);
-
+ DialogOK(_("ECursor Error!"), _("%u references remain\n"),
+ ec->ref_count);
return;
}
@@ -120,6 +113,4 @@
if (ec->file)
Efree(ec->file);
Efree(ec);
-
- return;
}
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/desktops.c,v
retrieving revision 1.50
retrieving revision 1.51
diff -u -3 -r1.50 -r1.51
--- desktops.c 7 Dec 2003 09:18:55 -0000 1.50
+++ desktops.c 3 Jan 2004 12:21:51 -0000 1.51
@@ -369,7 +369,6 @@
void
FreeDesktopBG(Background * bg)
{
-
EDBUG(6, "FreeDesktopBG");
if (!bg)
@@ -377,12 +376,8 @@
if (bg->ref_count > 0)
{
- char stuff[255];
-
- Esnprintf(stuff, sizeof(stuff), _("%u references remain\n"),
- bg->ref_count);
- DIALOG_OK(_("Background Error!"), stuff);
-
+ DialogOK(_("Background Error!"), _("%u references remain\n"),
+ bg->ref_count);
EDBUG_RETURN_;
}
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/dialog.c,v
retrieving revision 1.70
retrieving revision 1.71
diff -u -3 -r1.70 -r1.71
--- dialog.c 28 Dec 2003 17:57:30 -0000 1.70
+++ dialog.c 3 Jan 2004 12:21:52 -0000 1.71
@@ -22,17 +22,7 @@
*/
#include "E.h"
-typedef struct _ditembutton DItemButton;
-typedef struct _ditemcheckbutton DItemCheckButton;
-typedef struct _ditemtext DItemText;
-typedef struct _ditemimage DItemImage;
-typedef struct _ditemseparator DItemSeparator;
-typedef struct _ditemtable DItemTable;
-typedef struct _ditemradiobutton DItemRadioButton;
-typedef struct _ditemslider DItemSlider;
-typedef struct _ditemarea DItemArea;
-
-struct _ditemslider
+typedef struct
{
char horizontal;
@@ -67,45 +57,45 @@
Window base_win;
Window knob_win;
Window border_win;
-};
+} DItemSlider;
-struct _ditemarea
+typedef struct
{
Window area_win;
int w, h;
void (*event_func) (int val, void *data);
-};
+} DItemArea;
-struct _ditembutton
+typedef struct
{
char *text;
-};
+} DItemButton;
-struct _ditemcheckbutton
+typedef struct
{
char *text;
Window check_win;
int check_orig_w, check_orig_h;
char onoff;
char *onoff_ptr;
-};
+} DItemCheckButton;
-struct _ditemtext
+typedef struct
{
char *text;
-};
+} DItemText;
-struct _ditemimage
+typedef struct
{
char *image;
-};
+} DItemImage;
-struct _ditemseparator
+typedef struct
{
char horizontal;
-};
+} DItemSeparator;
-struct _ditemtable
+typedef struct
{
int num_columns;
char border;
@@ -113,9 +103,9 @@
char homogenous_v;
int num_items;
DItem **items;
-};
+} DItemTable;
-struct _ditemradiobutton
+typedef struct
{
char *text;
Window radio_win;
@@ -126,7 +116,7 @@
DItem *next;
DItem *first;
void (*event_func) (int val, void *data);
-};
+} DItemRadioButton;
struct _ditem
{
@@ -205,6 +195,9 @@
DKeyBind *keybindings;
};
+static void MoveTableBy(Dialog * d, DItem * di, int dx, int dy);
+static void DialogItemsRealize(Dialog * d);
+
static ImageClass *d_ic_default = NULL;
static TextClass *d_tc_default = NULL;
@@ -306,7 +299,7 @@
}
Dialog *
-CreateDialog(char *name)
+DialogCreate(char *name)
{
Dialog *d;
@@ -360,7 +353,7 @@
}
void
-FreeDialog(Dialog * d)
+DialogDestroy(Dialog * d)
{
int i;
@@ -386,60 +379,6 @@
}
void
-DialogRestart(int val, void *data)
-{
- doExit("restart");
- val = 0;
- data = NULL;
-}
-
-void
-DialogQuit(int val, void *data)
-{
- doExit("error");
- val = 0;
- data = NULL;
-}
-
-void
-DialogAlert(char *fmt, ...)
-{
- char text[10240];
- va_list ap;
-
- va_start(ap, fmt);
- Evsnprintf(text, 10240, fmt, ap);
- va_end(ap);
- Alert(text);
-}
-
-void
-DialogAlertOK(char *fmt, ...)
-{
- char text[10240];
- va_list ap;
-
- va_start(ap, fmt);
- Evsnprintf(text, 10240, fmt, ap);
- va_end(ap);
- ASSIGN_ALERT(_("Attention !!!"), _("OK"), " ", " ");
- Alert(text);
- RESET_ALERT;
-}
-
-void
-DialogSetParamText(Dialog * d, char *fmt, ...)
-{
- char text[10240];
- va_list ap;
-
- va_start(ap, fmt);
- Evsnprintf(text, 10240, fmt, ap);
- va_end(ap);
- DialogSetText(d, text);
-}
-
-void
DialogSetText(Dialog * d, char *text)
{
int w, h;
@@ -523,7 +462,7 @@
ButtonReleaseMask | ExposureMask);
}
-void
+static void
DialogDrawButton(Dialog * d, int bnum)
{
int state;
@@ -548,7 +487,7 @@
d->button[bnum]->tclass, d->button[bnum]->text);
}
-void
+static void
DialogActivateButton(Window win, int inclick)
{
Dialog *d;
@@ -576,7 +515,7 @@
DialogClose(d);
}
-void
+static void
DialogDraw(Dialog * d)
{
if ((!d->tclass) || (!d->iclass))
@@ -593,7 +532,7 @@
}
}
-void
+static void
DialogDrawArea(Dialog * d, int x, int y, int w, int h)
{
if ((!d->tclass) || (!d->iclass))
@@ -766,7 +705,7 @@
if (d->exit_func)
(d->exit_func) (d->exit_val, d->exit_data);
RemoveItem(NULL, d->win, LIST_FINDBY_ID, LIST_TYPE_DIALOG);
- FreeDialog(d);
+ DialogDestroy(d);
}
DItem *
@@ -1016,7 +955,7 @@
di->func(di->val, di->data);
}
-void
+static void
DialogRealizeItem(Dialog * d, DItem * di)
{
char *def = NULL;
@@ -1596,7 +1535,7 @@
}
}
-void
+static void
MoveTableBy(Dialog * d, DItem * di, int dx, int dy)
{
int i;
@@ -1844,7 +1783,7 @@
}
}
-void
+static void
DialogItemsRealize(Dialog * d)
{
char pq;
@@ -2124,7 +2063,7 @@
Efree(di);
}
-DItem *
+static DItem *
DialogItemFindWindow(DItem * di, Window win)
{
DItem *dii = NULL;
@@ -2154,6 +2093,78 @@
DialogItem(Dialog * d)
{
return d->item;
+}
+
+/*
+ * Predefined dialogs
+ */
+
+void
+DialogOK(const char *title, const char *fmt, ...)
+{
+ char text[10240];
+ va_list ap;
+
+ va_start(ap, fmt);
+ Evsnprintf(text, sizeof(text), fmt, ap);
+ va_end(ap);
+
+ DialogOKstr(title, text);
+}
+
+void
+DialogOKstr(const char *title, const char *txt)
+{
+ Dialog *d;
+
+ d = DialogCreate("DIALOG");
+ DialogSetTitle(d, title);
+ DialogSetText(d, txt);
+
+ DialogAddButton(d, _("OK"), NULL, 1);
+ ShowDialog(d);
+}
+
+void
+DialogRestart(int val, void *data)
+{
+ doExit("restart");
+ val = 0;
+ data = NULL;
+}
+
+void
+DialogQuit(int val, void *data)
+{
+ doExit("error");
+ val = 0;
+ data = NULL;
+}
+
+void
+DialogAlert(const char *fmt, ...)
+{
+ char text[10240];
+ va_list ap;
+
+ va_start(ap, fmt);
+ Evsnprintf(text, 10240, fmt, ap);
+ va_end(ap);
+ Alert(text);
+}
+
+void
+DialogAlertOK(const char *fmt, ...)
+{
+ char text[10240];
+ va_list ap;
+
+ va_start(ap, fmt);
+ Evsnprintf(text, 10240, fmt, ap);
+ va_end(ap);
+ ASSIGN_ALERT(_("Attention !!!"), _("OK"), " ", " ");
+ Alert(text);
+ RESET_ALERT;
}
/*
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/groups.c,v
retrieving revision 1.46
retrieving revision 1.47
diff -u -3 -r1.46 -r1.47
--- groups.c 27 Dec 2003 19:20:15 -0000 1.46
+++ groups.c 3 Jan 2004 12:21:52 -0000 1.47
@@ -114,10 +114,10 @@
AddEwinToGroup(ewins[i], g);
else
{
- DIALOG_OK(_("Cannot comply"),
- _("Iconboxes and Pagers are disallowed from being\n"
- "members of a group. You cannot add these windows\n"
- "to a group.\n"));
+ DialogOK(_("Cannot comply"),
+ _("Iconboxes and Pagers are disallowed from being\n"
+ "members of a group. You cannot add these windows\n"
+ "to a group.\n"));
}
}
}
@@ -146,10 +146,10 @@
}
else
{
- DIALOG_OK(_("Cannot comply"),
- _("Iconboxes and Pagers are disallowed from being\n"
- "members of a group. You cannot add these windows\n"
- "to a group.\n"));
+ DialogOK(_("Cannot comply"),
+ _("Iconboxes and Pagers are disallowed from being\n"
+ "members of a group. You cannot add these windows\n"
+ "to a group.\n"));
}
}
}
@@ -592,26 +592,26 @@
if ((num_groups == 0)
&& (action == ACTION_BREAK_GROUP || action == ACTION_REMOVE_FROM_GROUP))
{
- DIALOG_OK(_("Window Group Error"),
- _
- ("\n This window currently does not belong to any groups. \n"
- " You can only destroy groups or remove windows from groups \n"
- " through a window that actually belongs to at least one
group.\n\n"));
+ DialogOK(_("Window Group Error"),
+ _
+ ("\n This window currently does not belong to any groups. \n"
+ " You can only destroy groups or remove windows from groups \n"
+ " through a window that actually belongs to at least one
group.\n\n"));
return;
}
if ((num_groups == 0) && (group_select == GROUP_SELECT_ALL_EXCEPT_EWIN))
{
- DIALOG_OK(_("Window Group Error"),
- _("\n Currently, no groups exist or this window \n"
- " already belongs to all existing groups. \n"
- " You have to start other groups first. \n\n"));
+ DialogOK(_("Window Group Error"),
+ _("\n Currently, no groups exist or this window \n"
+ " already belongs to all existing groups. \n"
+ " You have to start other groups first. \n\n"));
return;
}
if (!tmp_groups)
{
- DIALOG_OK(_("Window Group Error"),
- _
- ("\n Currently, no groups exist. You have to start a group
first.\n\n"));
+ DialogOK(_("Window Group Error"),
+ _
+ ("\n Currently, no groups exist. You have to start a group
first.\n\n"));
return;
}
@@ -625,7 +625,7 @@
}
AUDIO_PLAY("SOUND_SETTINGS_GROUP");
- d = CreateDialog("GROUP_SELECTION");
+ d = DialogCreate("GROUP_SELECTION");
DialogSetTitle(d, _("Window Group Selection"));
table = DialogInitItem(d);
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/iclass.c,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -3 -r1.21 -r1.22
--- iclass.c 28 Dec 2003 17:57:30 -0000 1.21
+++ iclass.c 3 Jan 2004 12:21:52 -0000 1.22
@@ -110,11 +110,8 @@
if (i->ref_count > 0)
{
- char stuff[255];
-
- Esnprintf(stuff, sizeof(stuff), _("%u references remain\n"),
- i->ref_count);
- DIALOG_OK(_("ImageClass Error!"), stuff);
+ DialogOK(_("ImageClass Error!"), _("%u references remain\n"),
+ i->ref_count);
EDBUG_RETURN_;
}
while (RemoveItemByPtr(i, LIST_TYPE_ICLASS));
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/ipc.c,v
retrieving revision 1.124
retrieving revision 1.125
diff -u -3 -r1.124 -r1.125
--- ipc.c 27 Dec 2003 19:20:15 -0000 1.124
+++ ipc.c 3 Jan 2004 12:21:52 -0000 1.125
@@ -2232,9 +2232,7 @@
buf[0] = 0;
if (params)
- {
- DIALOG_OK(_("Message"), params);
- }
+ DialogOKstr(_("Message"), params);
else
Esnprintf(buf, sizeof(buf), "Error: No text for dialog specified");
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/session.c,v
retrieving revision 1.45
retrieving revision 1.46
diff -u -3 -r1.45 -r1.46
--- session.c 9 Dec 2003 20:25:17 -0000 1.45
+++ session.c 3 Jan 2004 12:21:52 -0000 1.46
@@ -605,7 +605,7 @@
LIST_TYPE_DIALOG)))
{
AUDIO_PLAY("SOUND_LOGOUT");
- d = CreateDialog("LOGOUT_DIALOG");
+ d = DialogCreate("LOGOUT_DIALOG");
DialogSetTitle(d, "Are you sure?");
DialogSetText(d,
"\n" "\n"
@@ -1157,7 +1157,7 @@
FindItem("LOGOUT_DIALOG", 0, LIST_FINDBY_NAME, LIST_TYPE_DIALOG)))
{
AUDIO_PLAY("SOUND_LOGOUT");
- d = CreateDialog("LOGOUT_DIALOG");
+ d = DialogCreate("LOGOUT_DIALOG");
DialogSetTitle(d, _("Are you sure?"));
DialogSetText(d,
_("\n" "\n"
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/settings.c,v
retrieving revision 1.83
retrieving revision 1.84
diff -u -3 -r1.83 -r1.84
--- settings.c 9 Dec 2003 20:25:17 -0000 1.83
+++ settings.c 3 Jan 2004 12:21:52 -0000 1.84
@@ -123,7 +123,7 @@
tmp_pager_do_scan = 1;
tmp_pager_scan_speed = mode.pager_scanspeed;
- d = pager_settings_dialog = CreateDialog("CONFIGURE_PAGER");
+ d = pager_settings_dialog = DialogCreate("CONFIGURE_PAGER");
DialogSetTitle(d, _("Pager Settings"));
table = DialogInitItem(d);
@@ -413,7 +413,7 @@
#endif /* WITH_TARTY_WARP */
tmp_clickalways = mode.clickalways;
- d = CreateDialog("CONFIGURE_FOCUS");
+ d = DialogCreate("CONFIGURE_FOCUS");
DialogSetTitle(d, _("Focus Settings"));
table = DialogInitItem(d);
@@ -798,7 +798,7 @@
tmp_resize = mode.resizemode;
tmp_geominfo = mode.geominfomode;
- d = CreateDialog("CONFIGURE_MOVERESIZE");
+ d = DialogCreate("CONFIGURE_MOVERESIZE");
DialogSetTitle(d, _("Move & Resize Settings"));
table = DialogInitItem(d);
@@ -981,7 +981,7 @@
ShowDialog(d);
/*
- * dexp = CreateDialog("CONFIGURE_MOVERESIZE_EXAMPLE");
+ * dexp = DialogCreate("CONFIGURE_MOVERESIZE_EXAMPLE");
* DialogSetTitle(dexp, _("Move & Resize Settings Example"));
*/
@@ -1118,7 +1118,7 @@
tmp_desktops = mode.numdesktops;
tmp_desktop_wraparound = mode.desktop_wraparound;
- d = tmp_desk_dialog = CreateDialog("CONFIGURE_DESKTOPS");
+ d = tmp_desk_dialog = DialogCreate("CONFIGURE_DESKTOPS");
DialogSetTitle(d, _("Multiple Desktop Settings"));
table = DialogInitItem(d);
@@ -1318,7 +1318,7 @@
GetAreaSize(&tmp_area_x, &tmp_area_y);
tmp_area_y = 9 - tmp_area_y;
- d = tmp_area_dialog = CreateDialog("CONFIGURE_AREA");
+ d = tmp_area_dialog = DialogCreate("CONFIGURE_AREA");
DialogSetTitle(d, _("Virtual Desktop Settings"));
table = DialogInitItem(d);
@@ -1496,7 +1496,7 @@
tmp_extra_head = mode.extra_head;
#endif
- d = CreateDialog("CONFIGURE_PLACEMENT");
+ d = DialogCreate("CONFIGURE_PLACEMENT");
DialogSetTitle(d, _("Window Placement Settings"));
table = DialogInitItem(d);
@@ -1626,7 +1626,7 @@
tmp_autoraise = mode.autoraise;
tmp_autoraisetime = (int)(mode.autoraisetime * 100);
- d = CreateDialog("CONFIGURE_AUTORAISE");
+ d = DialogCreate("CONFIGURE_AUTORAISE");
DialogSetTitle(d, _("Autoraise Settings"));
table = DialogInitItem(d);
@@ -1727,7 +1727,7 @@
tmp_tooltiptime = (int)(mode.tiptime * 100);
tmp_roottip = mode.showroottooltip;
- d = CreateDialog("CONFIGURE_TOOLTIPS");
+ d = DialogCreate("CONFIGURE_TOOLTIPS");
DialogSetTitle(d, _("Tooltip Settings"));
table = DialogInitItem(d);
@@ -1829,7 +1829,7 @@
tmp_dialog_headers = mode.dialog_headers;
- d = CreateDialog("CONFIGURE_MISCELLANEOUS");
+ d = DialogCreate("CONFIGURE_MISCELLANEOUS");
DialogSetTitle(d, _("Miscellaneous Settings"));
table = DialogInitItem(d);
@@ -1912,7 +1912,7 @@
tmp_audio = mode.sound;
- d = CreateDialog("CONFIGURE_AUDIO");
+ d = DialogCreate("CONFIGURE_AUDIO");
DialogSetTitle(d, _("Audio Settings"));
table = DialogInitItem(d);
@@ -2072,7 +2072,7 @@
tmp_effect_ripples = FX_IsOn("ripples");
tmp_effect_waves = FX_IsOn("waves");
- d = CreateDialog("CONFIGURE_FX");
+ d = DialogCreate("CONFIGURE_FX");
DialogSetTitle(d, _("Special FX Settings"));
table = DialogInitItem(d);
@@ -3301,7 +3301,7 @@
tmp_userbg = mode.user_bg;
tmp_bg_timeout = mode.desktop_bg_timeout;
- d = bg_sel_dialog = CreateDialog("CONFIGURE_BG");
+ d = bg_sel_dialog = DialogCreate("CONFIGURE_BG");
DialogSetTitle(d, _("Desktop Background Settings"));
table = DialogInitItem(d);
@@ -3770,7 +3770,7 @@
Efree(tmp_ib_name);
tmp_ib_name = duplicate(name);
- d = CreateDialog("CONFIGURE_ICONBOX");
+ d = DialogCreate("CONFIGURE_ICONBOX");
DialogSetTitle(d, _("Iconbox Settings"));
table = DialogInitItem(d);
@@ -4143,9 +4143,9 @@
return;
if (ewin->num_groups == 0)
{
- DIALOG_OK(_("Window Group Error"),
- _
- ("\n This window currently does not belong to any groups. \n\n"));
+ DialogOK(_("Window Group Error"),
+ _
+ ("\n This window currently does not belong to any groups. \n\n"));
return;
}
if ((d = FindItem("CONFIGURE_GROUP", 0, LIST_FINDBY_NAME, LIST_TYPE_DIALOG)))
@@ -4167,7 +4167,7 @@
for (i = 0; i < ewin->num_groups; i++)
CopyGroupConfig(&(ewin->groups[i]->cfg), &(tmp_cfgs[i]));
- d = CreateDialog("CONFIGURE_GROUP");
+ d = DialogCreate("CONFIGURE_GROUP");
DialogSetTitle(d, _("Window Group Settings"));
table = DialogInitItem(d);
@@ -4371,7 +4371,7 @@
CopyGroupConfig(&(mode.group_config), &tmp_group_cfg);
tmp_group_swap = mode.group_swapmove;
- d = CreateDialog("CONFIGURE_DEFAULT_GROUP_CONTROL");
+ d = DialogCreate("CONFIGURE_DEFAULT_GROUP_CONTROL");
DialogSetTitle(d, _("Default Group Control Settings"));
table = DialogInitItem(d);
@@ -4619,7 +4619,7 @@
}
AUDIO_PLAY("SOUND_SETTINGS_REMEMBER");
- d = CreateDialog("REMEMBER_WINDOW");
+ d = DialogCreate("REMEMBER_WINDOW");
DialogSetTitle(d, _("Remembered Windows Settings"));
table = DialogInitItem(d);
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/snaps.c,v
retrieving revision 1.54
retrieving revision 1.55
diff -u -3 -r1.54 -r1.55
--- snaps.c 27 Dec 2003 19:20:15 -0000 1.54
+++ snaps.c 3 Jan 2004 12:21:52 -0000 1.55
@@ -280,7 +280,7 @@
ShowDialog(d);
return;
}
- d = CreateDialog("SNAPSHOT_WINDOW");
+ d = DialogCreate("SNAPSHOT_WINDOW");
DialogSetTitle(d, _("Remembered Application Attributes"));
table = DialogInitItem(d);
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/sound.c,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -3 -r1.16 -r1.17
--- sound.c 5 Nov 2003 17:24:46 -0000 1.16
+++ sound.c 3 Jan 2004 12:21:52 -0000 1.17
@@ -50,13 +50,11 @@
find = FindFile(file);
if (!find)
{
- DIALOG_PARAM_OK(_("Error finding sound file"));
- DIALOG_PARAM _("Warning! Enlightenment was unable "
- "to load the\nfollowing sound file:\n%s\n"
- "Enlightenment will continue to operate, but you\n"
- "may wish to check your configuration settings.\n"),
- file DIALOG_PARAM_END;
-
+ DialogOK(_("Error finding sound file"),
+ _("Warning! Enlightenment was unable to load the\n"
+ "following sound file:\n%s\n"
+ "Enlightenment will continue to operate, but you\n"
+ "may wish to check your configuration settings.\n"), file);
EDBUG_RETURN(NULL);
}
in_file = afOpenFile(find, "r", NULL);
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/tclass.c,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -3 -r1.17 -r1.18
--- tclass.c 12 Dec 2003 18:42:15 -0000 1.17
+++ tclass.c 3 Jan 2004 12:21:52 -0000 1.18
@@ -66,11 +66,8 @@
if (t->ref_count > 0)
{
- char stuff[255];
-
- Esnprintf(stuff, sizeof(stuff), _("%u references remain\n"),
- t->ref_count);
- DIALOG_OK(_("TextClass Error!"), stuff);
+ DialogOK(_("TextClass Error!"), _("%u references remain\n"),
+ t->ref_count);
EDBUG_RETURN_;
}
if (t->name)
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/theme.c,v
retrieving revision 1.26
retrieving revision 1.27
diff -u -3 -r1.26 -r1.27
--- theme.c 5 Nov 2003 17:24:47 -0000 1.26
+++ theme.c 3 Jan 2004 12:21:52 -0000 1.27
@@ -344,16 +344,13 @@
void
BadThemeDialog(void)
{
- char s[1024];
-
if (!badtheme)
return;
- Esnprintf(s, sizeof(s),
- _("The theme:\n" "%s\n"
- "Is a badly formed theme package and is thus not being used.\n"
- "Enlightenment has fallen back to using the DEFAULT theme.\n"
- "\n" "The reason this theme is bad is:\n" "%s"), badtheme,
- badreason);
- DIALOG_OK(_("Bad Theme"), s);
+ DialogOK(_("Bad Theme"),
+ _("The theme:\n" "%s\n"
+ "Is a badly formed theme package and is thus not being used.\n"
+ "Enlightenment has fallen back to using the DEFAULT theme.\n"
+ "\n" "The reason this theme is bad is:\n" "%s"),
+ badtheme, badreason);
}
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/tooltips.c,v
retrieving revision 1.52
retrieving revision 1.53
diff -u -3 -r1.52 -r1.53
--- tooltips.c 15 Nov 2003 22:27:17 -0000 1.52
+++ tooltips.c 3 Jan 2004 12:21:52 -0000 1.53
@@ -858,11 +858,9 @@
if (tt->ref_count > 0)
{
- char stuff[255];
-
- Esnprintf(stuff, sizeof(stuff), _("%u references remain\n"),
- tt->ref_count);
- DIALOG_OK(_("ToolTip Error!"), stuff);
+ DialogOK(_("ToolTip Error!"), _("%u references remain\n"),
+ tt->ref_count);
}
+
EDBUG_RETURN_;
}
-------------------------------------------------------
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills. Sign up for IBM's
Free Linux Tutorials. Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
_______________________________________________
enlightenment-cvs mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs