Patch from Lucas Rocha <lucasr@im.ufba.br> to use the GOption API for the

2004-12-07  Glynn Foster  <glynn.foster@sun.com>

	Patch from Lucas Rocha <lucasr@im.ufba.br> to use the GOption
	API for the zenity parsing options, with some spacing fixes
	from Glynn.

	* configure.in: zenity now requires glib-2.0 >= 2.5.3 to build
	because now it uses GOption. popt requirement removed.
	* src/Makefile.am: update for new files
	* src/main.c: use GOption API
	* src/option.c, src/option.h: New files to implement the new
	functionality.
	* src/zenity.h: Fix spacing.

2004-12-07  Glynn Foster  <glynn.foster@sun.com>

	* POTFILES.in: Add new files.
This commit is contained in:
Glynn Foster 2004-12-07 00:17:16 +00:00 committed by Glynn Foster
parent d9f8ccdc47
commit 530a4c0408
7 changed files with 52 additions and 1537 deletions

View File

@ -1,3 +1,17 @@
2004-12-07 Glynn Foster <glynn.foster@sun.com>
Patch from Lucas Rocha <lucasr@im.ufba.br> to use the GOption
API for the zenity parsing options, with some spacing fixes
from Glynn.
* configure.in: zenity now requires glib-2.0 >= 2.5.3 to build
because now it uses GOption. popt requirement removed.
* src/Makefile.am: update for new files
* src/main.c: use GOption API
* src/option.c, src/option.h: New files to implement the new
functionality.
* src/zenity.h: Fix spacing.
2004-11-23 Ross Burton <ross@burtonini.com> 2004-11-23 Ross Burton <ross@burtonini.com>
* src/util.c: Check the xterm window ID is valid for the current * src/util.c: Check the xterm window ID is valid for the current

View File

@ -11,12 +11,10 @@ AC_PROG_CC
GTK_REQUIRED=2.3.1 GTK_REQUIRED=2.3.1
PKG_CHECK_MODULES(ZENITY, gtk+-2.0 >= $GTK_REQUIRED libglade-2.0 libgnomecanvas-2.0) PKG_CHECK_MODULES(ZENITY, gtk+-2.0 >= $GTK_REQUIRED libglade-2.0 libgnomecanvas-2.0 glib-2.0 >= 2.5.3)
AC_SUBST(ZENITY_CFLAGS) AC_SUBST(ZENITY_CFLAGS)
AC_SUBST(ZENITY_LIBS) AC_SUBST(ZENITY_LIBS)
AC_CHECK_LIB(popt, poptHelpOptions,, AC_MSG_ERROR([popt is required to build script.]))
dnl *********************************************** dnl ***********************************************
dnl scrollkeeper checks dnl scrollkeeper checks
dnl *********************************************** dnl ***********************************************

View File

@ -1,3 +1,7 @@
2004-12-07 Glynn Foster <glynn.foster@sun.com>
* POTFILES.in: Add new files.
2004-12-04 Žygimantas Beručka <uid0@akl.lt> 2004-12-04 Žygimantas Beručka <uid0@akl.lt>
* lt.po: Updated Lithuanian translation. * lt.po: Updated Lithuanian translation.

View File

@ -5,3 +5,4 @@ src/notification.c
src/tree.c src/tree.c
src/util.c src/util.c
src/zenity.glade src/zenity.glade
src/option.c

View File

@ -4,6 +4,8 @@ bin_SCRIPTS = gdialog
zenity_SOURCES = \ zenity_SOURCES = \
main.c \ main.c \
option.c \
option.h \
zenity.h \ zenity.h \
calendar.c \ calendar.c \
msg.c \ msg.c \

1536
src/main.c

File diff suppressed because it is too large Load Diff

View File

@ -55,35 +55,35 @@ typedef enum {
} MsgMode; } MsgMode;
typedef struct { typedef struct {
gchar *dialog_text; gchar *dialog_text;
MsgMode mode; MsgMode mode;
} ZenityMsgData; } ZenityMsgData;
typedef struct { typedef struct {
gchar *uri; gchar *uri;
gboolean multi; gboolean multi;
gboolean directory; gboolean directory;
gboolean save; gboolean save;
gchar *separator; gchar *separator;
} ZenityFileData; } ZenityFileData;
typedef struct { typedef struct {
gchar *dialog_text; gchar *dialog_text;
gchar *entry_text; gchar *entry_text;
gboolean visible; gboolean visible;
} ZenityEntryData; } ZenityEntryData;
typedef struct { typedef struct {
gchar *dialog_text; gchar *dialog_text;
gchar *entry_text; gchar *entry_text;
gboolean pulsate; gboolean pulsate;
gboolean autoclose; gboolean autoclose;
gdouble percentage; gdouble percentage;
} ZenityProgressData; } ZenityProgressData;
typedef struct { typedef struct {
gchar *uri; gchar *uri;
gboolean editable; gboolean editable;
GtkTextBuffer *buffer; GtkTextBuffer *buffer;
} ZenityTextData; } ZenityTextData;
@ -99,8 +99,8 @@ typedef struct {
} ZenityTreeData; } ZenityTreeData;
typedef struct { typedef struct {
gchar *notification_text; gchar *notification_text;
gboolean listen; gboolean listen;
} ZenityNotificationData; } ZenityNotificationData;
void zenity_calendar (ZenityData *data, void zenity_calendar (ZenityData *data,