From 7832b2a4cf6d319bb95c8ad0836ae930ee780519 Mon Sep 17 00:00:00 2001 From: dan Date: Wed, 13 Sep 2000 20:19:05 +0000 Subject: [PATCH] Rearranged the structure of the WINGs subdirectory. Created Documentation, Examples and Tests subdirectories. Run update-autoconf after this update. --- WINGs/Documentation/.cvsignore | 3 +++ WINGs/Documentation/Makefile.am | 6 ++++++ WINGs/{ => Documentation}/wm.html | 0 WINGs/{ => Documentation}/wm.png | Bin WINGs/Examples/.cvsignore | 3 +++ WINGs/Examples/Makefile.am | 27 +++++++++++++++++++++++++++ WINGs/{ => Examples}/connect.c | 0 WINGs/{ => Examples}/fontl.c | 0 WINGs/{ => Examples}/puzzle.c | 0 WINGs/Makefile.am | 16 ++-------------- WINGs/Tests/.cvsignore | 3 +++ WINGs/Tests/Makefile.am | 24 ++++++++++++++++++++++++ WINGs/{ => Tests}/logo.xpm | 0 WINGs/{ => Tests}/mywidget.c | 0 WINGs/{ => Tests}/mywidget.h | 0 WINGs/{ => Tests}/testcolorpanel.c | 0 WINGs/{ => Tests}/testmywidget.c | 0 WINGs/{ => Tests}/testtext.c | 0 WINGs/{ => Tests}/upbtn.xpm | 0 WINGs/{ => Tests}/wmfile.c | 0 WINGs/{ => Tests}/wmquery.c | 0 WINGs/{ => Tests}/wtest.c | 2 +- WINGs/WUtil.h | 2 +- WINGs/bagarray.c | 33 ++++++++++++++++----------------- WPrefs.app/Makefile.am | 1 + configure.in | 13 +++++++------ 26 files changed, 94 insertions(+), 39 deletions(-) create mode 100644 WINGs/Documentation/.cvsignore create mode 100644 WINGs/Documentation/Makefile.am rename WINGs/{ => Documentation}/wm.html (100%) rename WINGs/{ => Documentation}/wm.png (100%) create mode 100644 WINGs/Examples/.cvsignore create mode 100644 WINGs/Examples/Makefile.am rename WINGs/{ => Examples}/connect.c (100%) rename WINGs/{ => Examples}/fontl.c (100%) rename WINGs/{ => Examples}/puzzle.c (100%) create mode 100644 WINGs/Tests/.cvsignore create mode 100644 WINGs/Tests/Makefile.am rename WINGs/{ => Tests}/logo.xpm (100%) rename WINGs/{ => Tests}/mywidget.c (100%) rename WINGs/{ => Tests}/mywidget.h (100%) rename WINGs/{ => Tests}/testcolorpanel.c (100%) rename WINGs/{ => Tests}/testmywidget.c (100%) rename WINGs/{ => Tests}/testtext.c (100%) rename WINGs/{ => Tests}/upbtn.xpm (100%) rename WINGs/{ => Tests}/wmfile.c (100%) rename WINGs/{ => Tests}/wmquery.c (100%) rename WINGs/{ => Tests}/wtest.c (99%) diff --git a/WINGs/Documentation/.cvsignore b/WINGs/Documentation/.cvsignore new file mode 100644 index 00000000..9375a4f2 --- /dev/null +++ b/WINGs/Documentation/.cvsignore @@ -0,0 +1,3 @@ +Makefile Makefile.in +.psrc .inslog2 tca.map tca.log +*.rpt diff --git a/WINGs/Documentation/Makefile.am b/WINGs/Documentation/Makefile.am new file mode 100644 index 00000000..07a38acf --- /dev/null +++ b/WINGs/Documentation/Makefile.am @@ -0,0 +1,6 @@ +## automake input file for WINGs - Documentation + +AUTOMAKE_OPTIONS = no-dependencies + +EXTRA_DIST = wm.png wm.html + diff --git a/WINGs/wm.html b/WINGs/Documentation/wm.html similarity index 100% rename from WINGs/wm.html rename to WINGs/Documentation/wm.html diff --git a/WINGs/wm.png b/WINGs/Documentation/wm.png similarity index 100% rename from WINGs/wm.png rename to WINGs/Documentation/wm.png diff --git a/WINGs/Examples/.cvsignore b/WINGs/Examples/.cvsignore new file mode 100644 index 00000000..9375a4f2 --- /dev/null +++ b/WINGs/Examples/.cvsignore @@ -0,0 +1,3 @@ +Makefile Makefile.in +.psrc .inslog2 tca.map tca.log +*.rpt diff --git a/WINGs/Examples/Makefile.am b/WINGs/Examples/Makefile.am new file mode 100644 index 00000000..6d4dbe9c --- /dev/null +++ b/WINGs/Examples/Makefile.am @@ -0,0 +1,27 @@ +## automake input file for WINGs - Examples + +AUTOMAKE_OPTIONS = no-dependencies + + +noinst_PROGRAMS = connect fontl puzzle + + +LDADD= $(top_builddir)/WINGs/libWINGs.a $(top_builddir)/wrlib/libwraster.la \ + @LIBRARY_SEARCH_PATH@ @GFXLIBS@ @XLIBS@ \ + -lm @LIBPL@ + + +fontl_DEPENDENCIES = $(top_builddir)/WINGs/libWINGs.a + +puzzle_DEPENDENCIES = $(top_builddir)/WINGs/libWINGs.a + +connect_DEPENDENCIES = $(top_builddir)/WINGs/libWUtil.a + +connect_LDADD = $(top_builddir)/WINGs/libWUtil.a @LIBRARY_SEARCH_PATH@ \ + @NETLIBS@ @LIBPL@ + + +INCLUDES = -I$(top_srcdir)/WINGs -I$(top_srcdir)/wrlib -I$(top_srcdir)/src \ + -DRESOURCE_PATH=\"$(datadir)/WINGs\" @HEADER_SEARCH_PATH@ -DDEBUG + + diff --git a/WINGs/connect.c b/WINGs/Examples/connect.c similarity index 100% rename from WINGs/connect.c rename to WINGs/Examples/connect.c diff --git a/WINGs/fontl.c b/WINGs/Examples/fontl.c similarity index 100% rename from WINGs/fontl.c rename to WINGs/Examples/fontl.c diff --git a/WINGs/puzzle.c b/WINGs/Examples/puzzle.c similarity index 100% rename from WINGs/puzzle.c rename to WINGs/Examples/puzzle.c diff --git a/WINGs/Makefile.am b/WINGs/Makefile.am index a70dd07b..8150b3c7 100644 --- a/WINGs/Makefile.am +++ b/WINGs/Makefile.am @@ -2,7 +2,7 @@ AUTOMAKE_OPTIONS = no-dependencies -SUBDIRS = Resources +SUBDIRS = . Documentation Resources Examples Tests @@ -12,9 +12,6 @@ include_HEADERS = WINGs.h WUtil.h WINGsP.h bin_SCRIPTS = get-wings-flags get-wutil-flags -noinst_PROGRAMS = wtest wmquery wmfile fontl testmywidget testcolorpanel\ - connect puzzle testtext - lib_LIBRARIES = libWINGs.a libWUtil.a @@ -23,16 +20,7 @@ LDADD= libWINGs.a $(top_builddir)/wrlib/libwraster.la\ -lm @LIBPL@ -testmywidget_SOURCES = testmywidget.c mywidget.c mywidget.h - -wtest_DEPENDENCIES = libWINGs.a - -testtext_DEPENDENCIES = libWINGs.a - -connect_LDADD = libWUtil.a @LIBRARY_SEARCH_PATH@ @NETLIBS@ @LIBPL@ - - -EXTRA_DIST = logo.xpm BUGS wm.png upbtn.xpm wm.html +EXTRA_DIST = BUGS # wbutton.c libWINGs_a_SOURCES = \ diff --git a/WINGs/Tests/.cvsignore b/WINGs/Tests/.cvsignore new file mode 100644 index 00000000..9375a4f2 --- /dev/null +++ b/WINGs/Tests/.cvsignore @@ -0,0 +1,3 @@ +Makefile Makefile.in +.psrc .inslog2 tca.map tca.log +*.rpt diff --git a/WINGs/Tests/Makefile.am b/WINGs/Tests/Makefile.am new file mode 100644 index 00000000..2a64d998 --- /dev/null +++ b/WINGs/Tests/Makefile.am @@ -0,0 +1,24 @@ +## automake input file for WINGs - Tests + +AUTOMAKE_OPTIONS = no-dependencies + +noinst_PROGRAMS = wtest wmquery wmfile testmywidget testcolorpanel testtext + +LDADD= $(top_builddir)/WINGs/libWINGs.a $(top_builddir)/wrlib/libwraster.la \ + @LIBRARY_SEARCH_PATH@ @GFXLIBS@ @XLIBS@ \ + -lm @LIBPL@ + + +testmywidget_SOURCES = testmywidget.c mywidget.c mywidget.h + +wtest_DEPENDENCIES = $(top_builddir)/WINGs/libWINGs.a + +testtext_DEPENDENCIES = $(top_builddir)/WINGs/libWINGs.a + + +EXTRA_DIST = logo.xpm upbtn.xpm + +INCLUDES = -I$(top_srcdir)/WINGs -I$(top_srcdir)/wrlib -I$(top_srcdir)/src \ + -DRESOURCE_PATH=\"$(datadir)/WINGs\" @HEADER_SEARCH_PATH@ -DDEBUG + + diff --git a/WINGs/logo.xpm b/WINGs/Tests/logo.xpm similarity index 100% rename from WINGs/logo.xpm rename to WINGs/Tests/logo.xpm diff --git a/WINGs/mywidget.c b/WINGs/Tests/mywidget.c similarity index 100% rename from WINGs/mywidget.c rename to WINGs/Tests/mywidget.c diff --git a/WINGs/mywidget.h b/WINGs/Tests/mywidget.h similarity index 100% rename from WINGs/mywidget.h rename to WINGs/Tests/mywidget.h diff --git a/WINGs/testcolorpanel.c b/WINGs/Tests/testcolorpanel.c similarity index 100% rename from WINGs/testcolorpanel.c rename to WINGs/Tests/testcolorpanel.c diff --git a/WINGs/testmywidget.c b/WINGs/Tests/testmywidget.c similarity index 100% rename from WINGs/testmywidget.c rename to WINGs/Tests/testmywidget.c diff --git a/WINGs/testtext.c b/WINGs/Tests/testtext.c similarity index 100% rename from WINGs/testtext.c rename to WINGs/Tests/testtext.c diff --git a/WINGs/upbtn.xpm b/WINGs/Tests/upbtn.xpm similarity index 100% rename from WINGs/upbtn.xpm rename to WINGs/Tests/upbtn.xpm diff --git a/WINGs/wmfile.c b/WINGs/Tests/wmfile.c similarity index 100% rename from WINGs/wmfile.c rename to WINGs/Tests/wmfile.c diff --git a/WINGs/wmquery.c b/WINGs/Tests/wmquery.c similarity index 100% rename from WINGs/wmquery.c rename to WINGs/Tests/wmquery.c diff --git a/WINGs/wtest.c b/WINGs/Tests/wtest.c similarity index 99% rename from WINGs/wtest.c rename to WINGs/Tests/wtest.c index e0411062..70f8456f 100644 --- a/WINGs/wtest.c +++ b/WINGs/Tests/wtest.c @@ -1082,7 +1082,7 @@ int main(int argc, char **argv) testDragAndDrop(scr); testFontPanel(scr); -#if 0 +#if 0 testScrollView(scr); testButton(scr); diff --git a/WINGs/WUtil.h b/WINGs/WUtil.h index 368c554b..8e4ec21c 100644 --- a/WINGs/WUtil.h +++ b/WINGs/WUtil.h @@ -352,7 +352,7 @@ extern const WMHashTableCallbacks WMStringPointerHashCallbacks; * * Cons: * A little slower [O(n)] for insertion/deletion of elements that - * arent in the end + * aren't in the end * Element indexes with large difference will cause large holes */ #if 0 diff --git a/WINGs/bagarray.c b/WINGs/bagarray.c index 1e66ff18..bb42c778 100644 --- a/WINGs/bagarray.c +++ b/WINGs/bagarray.c @@ -20,27 +20,27 @@ typedef struct W_ArrayBag { } W_ArrayBag; -static int getItemCount(WMBag *bag); +static int getItemCount(WMBag *bag); static int appendBag(WMBag *bag, WMBag *appendedBag); static int putInBag(WMBag *bag, void *item); static int insertInBag(WMBag *bag, int index, void *item); static int removeFromBag(WMBag *bag, void *item); static int deleteFromBag(WMBag *bag, int index); -static void* getFromBag(WMBag *bag, int index); -static int firstInBag(WMBag *bag, void *item); -static int countInBag(WMBag *bag, void *item); -static void* replaceInBag(WMBag *bag, int index, void *item); +static void* getFromBag(WMBag *bag, int index); +static int firstInBag(WMBag *bag, void *item); +static int countInBag(WMBag *bag, void *item); +static void* replaceInBag(WMBag *bag, int index, void *item); static int sortBag(WMBag *bag, int (*comparer)(const void*, const void*)); -static void emptyBag(WMBag *bag); -static void freeBag(WMBag *bag); -static void mapBag(WMBag *bag, void (*function)(void*, void*), void *data); -static int findInBag(WMBag *bag, int (*match)(void*)); -static void* first(WMBag *bag, void **ptr); -static void* last(WMBag *bag, void **ptr); -static void* next(WMBag *bag, void **ptr); -static void* previous(WMBag *bag, void **ptr); -static void* iteratorAtIndex(WMBag *bag, int index, WMBagIterator *ptr); -static int indexForIterator(WMBag *bag, WMBagIterator ptr); +static void emptyBag(WMBag *bag); +static void freeBag(WMBag *bag); +static void mapBag(WMBag *bag, void (*function)(void*, void*), void *data); +static int findInBag(WMBag *bag, int (*match)(void*)); +static void* first(WMBag *bag, void **ptr); +static void* last(WMBag *bag, void **ptr); +static void* next(WMBag *bag, void **ptr); +static void* previous(WMBag *bag, void **ptr); +static void* iteratorAtIndex(WMBag *bag, int index, WMBagIterator *ptr); +static int indexForIterator(WMBag *bag, WMBagIterator ptr); static W_BagFunctions arrayFunctions = { @@ -69,7 +69,7 @@ static W_BagFunctions arrayFunctions = { }; -#define ARRAY ((W_ArrayBag*)bag->data) +#define ARRAY ((W_ArrayBag*)(bag->data)) #define I2O(a, i) ((a)->base + i) @@ -235,7 +235,6 @@ getFromBag(WMBag *bag, int index) } - static int firstInBag(WMBag *bag, void *item) { diff --git a/WPrefs.app/Makefile.am b/WPrefs.app/Makefile.am index 63e1d2cc..25bc0cad 100644 --- a/WPrefs.app/Makefile.am +++ b/WPrefs.app/Makefile.am @@ -39,6 +39,7 @@ WPrefs_SOURCES = \ editmenu.c \ editmenu.h \ imagebrowser.c \ + imagebrowser.h \ xmodifier.c CPPFLAGS = @CPPFLAGS@ -DLOCALEDIR=\"$(NLSDIR)\" diff --git a/configure.in b/configure.in index 42aeced7..c329081d 100644 --- a/configure.in +++ b/configure.in @@ -850,12 +850,13 @@ dnl AC_CHECK_PROG(TEXI2HTML, texi2html, texi2html, ,$PATH) dnl AC_SUBST(DOCTYPES) AC_OUTPUT(Makefile po/Makefile util/Makefile test/Makefile wmlib/Makefile \ - WINGs/Makefile WINGs/Resources/Makefile src/Makefile src/wconfig.h \ - wrlib/Makefile doc/Makefile WindowMaker/Makefile contrib/Makefile \ - WindowMaker/Backgrounds/Makefile WindowMaker/Defaults/Makefile \ - WindowMaker/IconSets/Makefile WindowMaker/Icons/Makefile \ - WindowMaker/Pixmaps/Makefile WindowMaker/Styles/Makefile \ - WindowMaker/Themes/Makefile \ + WINGs/Makefile WINGs/Documentation/Makefile WINGs/Examples/Makefile \ + WINGs/Resources/Makefile WINGs/Tests/Makefile wrlib/Makefile \ + src/Makefile src/wconfig.h doc/Makefile contrib/Makefile \ + WindowMaker/Makefile WindowMaker/Backgrounds/Makefile \ + WindowMaker/Defaults/Makefile WindowMaker/IconSets/Makefile \ + WindowMaker/Icons/Makefile WindowMaker/Pixmaps/Makefile \ + WindowMaker/Styles/Makefile WindowMaker/Themes/Makefile \ WPrefs.app/Makefile WPrefs.app/tiff/Makefile WPrefs.app/xpm/Makefile \ WPrefs.app/po/Makefile contrib/WindowMaker.spec ) -- 2.11.4.GIT