PYTHON_DIST:
mkdir $(DISTDIR)/wxPython
mkdir $(DISTDIR)/wxPython/contrib
+ mkdir $(DISTDIR)/wxPython/contrib/dllwidget
mkdir $(DISTDIR)/wxPython/contrib/gizmos
mkdir $(DISTDIR)/wxPython/contrib/glcanvas
mkdir $(DISTDIR)/wxPython/contrib/glcanvas/gtk
mkdir $(DISTDIR)/wxPython/src/gtk
mkdir $(DISTDIR)/wxPython/wxPython
mkdir $(DISTDIR)/wxPython/wxPython/lib
+ mkdir $(DISTDIR)/wxPython/wxPython/lib/PyCrust
mkdir $(DISTDIR)/wxPython/wxPython/lib/editor
mkdir $(DISTDIR)/wxPython/wxPython/lib/mixins
cp $(WXDIR)/wxPython/*.py $(DISTDIR)/wxPython
cp $(WXDIR)/wxPython/setup.cfg $(DISTDIR)/wxPython
cp $(WXDIR)/wxPython/MANIFEST.in $(DISTDIR)/wxPython
+ cp $(WXDIR)/wxPython/contrib/dllwidget/*.{py,cpp,h,i} $(DISTDIR)/wxPython/contrib/dllwidget
cp $(WXDIR)/wxPython/contrib/gizmos/*.{py,cpp,i} $(DISTDIR)/wxPython/contrib/gizmos
-cp $(WXDIR)/wxPython/contrib/glcanvas/* $(DISTDIR)/wxPython/contrib/glcanvas
cp $(WXDIR)/wxPython/contrib/glcanvas/gtk/glcanvas.* $(DISTDIR)/wxPython/contrib/glcanvas/gtk
cp $(WXDIR)/wxPython/src/gtk/*.py $(DISTDIR)/wxPython/src/gtk
cp $(WXDIR)/wxPython/src/gtk/*.cpp $(DISTDIR)/wxPython/src/gtk
cp $(WXDIR)/wxPython/wxPython/lib/*.py $(DISTDIR)/wxPython/wxPython/lib
+ cp $(WXDIR)/wxPython/wxPython/lib/PyCrust/*.py $(DISTDIR)/wxPython/wxPython/lib/PyCrust
cp $(WXDIR)/wxPython/wxPython/lib/editor/*.py $(DISTDIR)/wxPython/wxPython/lib/editor
cp $(WXDIR)/wxPython/wxPython/lib/mixins/*.py $(DISTDIR)/wxPython/wxPython/lib/mixins
--enable-fraction use wxFraction class"
ac_help="$ac_help
--enable-dynlib use wxLibrary class for DLL loading"
+ac_help="$ac_help
+ --enable-dynamicloader use (new) wxDynamicLibrary class"
ac_help="$ac_help
--enable-longlong use wxLongLong class"
ac_help="$ac_help
--enable-sysoptions use wxSystemOptions"
ac_help="$ac_help
--enable-threads use threads"
-ac_help="$ac_help
- --enable-serial use class serialization"
ac_help="$ac_help
--enable-docview use document view architecture"
ac_help="$ac_help
DEFAULT_wxUSE_STREAMS=no
DEFAULT_wxUSE_SOCKETS=no
DEFAULT_wxUSE_DIALUP_MANAGER=no
- DEFAULT_wxUSE_SERIAL=no
DEFAULT_wxUSE_JOYSTICK=no
DEFAULT_wxUSE_DYNLIB_CLASS=no
+ DEFAULT_wxUSE_DYNAMIC_LOADER=no
DEFAULT_wxUSE_LONGLONG=no
DEFAULT_wxUSE_GEOMETRY=no
DEFAULT_wxUSE_STREAMS=yes
DEFAULT_wxUSE_SOCKETS=yes
DEFAULT_wxUSE_DIALUP_MANAGER=yes
- DEFAULT_wxUSE_SERIAL=yes
DEFAULT_wxUSE_JOYSTICK=yes
- DEFAULT_wxUSE_DYNLIB_CLASS=yes
+ DEFAULT_wxUSE_DYNLIB_CLASS=no
+ DEFAULT_wxUSE_DYNAMIC_LOADER=yes
DEFAULT_wxUSE_LONGLONG=yes
DEFAULT_wxUSE_GEOMETRY=yes
fi
+ echo $ac_n "checking for --enable-dynamicloader""... $ac_c" 1>&6
+echo "configure:3540: checking for --enable-dynamicloader" >&5
+ no_cache=0
+ # Check whether --enable-dynamicloader or --disable-dynamicloader was given.
+if test "${enable_dynamicloader+set}" = set; then
+ enableval="$enable_dynamicloader"
+
+ if test "$enableval" = yes; then
+ ac_cv_use_dynamicloader='wxUSE_DYNAMIC_LOADER=yes'
+ else
+ ac_cv_use_dynamicloader='wxUSE_DYNAMIC_LOADER=no'
+ fi
+
+else
+
+ LINE=`grep "wxUSE_DYNAMIC_LOADER" ${wx_arg_cache_file}`
+ if test "x$LINE" != x ; then
+ eval "DEFAULT_$LINE"
+ else
+ no_cache=1
+ fi
+
+ ac_cv_use_dynamicloader='wxUSE_DYNAMIC_LOADER='$DEFAULT_wxUSE_DYNAMIC_LOADER
+
+fi
+
+
+ eval "$ac_cv_use_dynamicloader"
+ if test "$no_cache" != 1; then
+ echo $ac_cv_use_dynamicloader >> ${wx_arg_cache_file}.tmp
+ fi
+
+ if test "$wxUSE_DYNAMIC_LOADER" = yes; then
+ echo "$ac_t""yes" 1>&6
+ else
+ echo "$ac_t""no" 1>&6
+ fi
+
+
echo $ac_n "checking for --enable-longlong""... $ac_c" 1>&6
-echo "configure:3540: checking for --enable-longlong" >&5
+echo "configure:3579: checking for --enable-longlong" >&5
no_cache=0
# Check whether --enable-longlong or --disable-longlong was given.
if test "${enable_longlong+set}" = set; then
echo $ac_n "checking for --enable-geometry""... $ac_c" 1>&6
-echo "configure:3579: checking for --enable-geometry" >&5
+echo "configure:3618: checking for --enable-geometry" >&5
no_cache=0
# Check whether --enable-geometry or --disable-geometry was given.
if test "${enable_geometry+set}" = set; then
echo $ac_n "checking for --enable-log""... $ac_c" 1>&6
-echo "configure:3618: checking for --enable-log" >&5
+echo "configure:3657: checking for --enable-log" >&5
no_cache=0
# Check whether --enable-log or --disable-log was given.
if test "${enable_log+set}" = set; then
echo $ac_n "checking for --enable-streams""... $ac_c" 1>&6
-echo "configure:3657: checking for --enable-streams" >&5
+echo "configure:3696: checking for --enable-streams" >&5
no_cache=0
# Check whether --enable-streams or --disable-streams was given.
if test "${enable_streams+set}" = set; then
echo $ac_n "checking for --enable-file""... $ac_c" 1>&6
-echo "configure:3696: checking for --enable-file" >&5
+echo "configure:3735: checking for --enable-file" >&5
no_cache=0
# Check whether --enable-file or --disable-file was given.
if test "${enable_file+set}" = set; then
echo $ac_n "checking for --enable-ffile""... $ac_c" 1>&6
-echo "configure:3735: checking for --enable-ffile" >&5
+echo "configure:3774: checking for --enable-ffile" >&5
no_cache=0
# Check whether --enable-ffile or --disable-ffile was given.
if test "${enable_ffile+set}" = set; then
echo $ac_n "checking for --enable-textbuf""... $ac_c" 1>&6
-echo "configure:3774: checking for --enable-textbuf" >&5
+echo "configure:3813: checking for --enable-textbuf" >&5
no_cache=0
# Check whether --enable-textbuf or --disable-textbuf was given.
if test "${enable_textbuf+set}" = set; then
echo $ac_n "checking for --enable-textfile""... $ac_c" 1>&6
-echo "configure:3813: checking for --enable-textfile" >&5
+echo "configure:3852: checking for --enable-textfile" >&5
no_cache=0
# Check whether --enable-textfile or --disable-textfile was given.
if test "${enable_textfile+set}" = set; then
echo $ac_n "checking for --enable-fontmap""... $ac_c" 1>&6
-echo "configure:3852: checking for --enable-fontmap" >&5
+echo "configure:3891: checking for --enable-fontmap" >&5
no_cache=0
# Check whether --enable-fontmap or --disable-fontmap was given.
if test "${enable_fontmap+set}" = set; then
echo $ac_n "checking for --enable-unicode""... $ac_c" 1>&6
-echo "configure:3891: checking for --enable-unicode" >&5
+echo "configure:3930: checking for --enable-unicode" >&5
no_cache=0
# Check whether --enable-unicode or --disable-unicode was given.
if test "${enable_unicode+set}" = set; then
echo $ac_n "checking for --enable-wxprintfv""... $ac_c" 1>&6
-echo "configure:3930: checking for --enable-wxprintfv" >&5
+echo "configure:3969: checking for --enable-wxprintfv" >&5
no_cache=0
# Check whether --enable-wxprintfv or --disable-wxprintfv was given.
if test "${enable_wxprintfv+set}" = set; then
echo $ac_n "checking for --enable-std_iostreams""... $ac_c" 1>&6
-echo "configure:3969: checking for --enable-std_iostreams" >&5
+echo "configure:4008: checking for --enable-std_iostreams" >&5
no_cache=0
# Check whether --enable-std_iostreams or --disable-std_iostreams was given.
if test "${enable_std_iostreams+set}" = set; then
echo $ac_n "checking for --enable-filesystem""... $ac_c" 1>&6
-echo "configure:4008: checking for --enable-filesystem" >&5
+echo "configure:4047: checking for --enable-filesystem" >&5
no_cache=0
# Check whether --enable-filesystem or --disable-filesystem was given.
if test "${enable_filesystem+set}" = set; then
echo $ac_n "checking for --enable-fs_inet""... $ac_c" 1>&6
-echo "configure:4047: checking for --enable-fs_inet" >&5
+echo "configure:4086: checking for --enable-fs_inet" >&5
no_cache=0
# Check whether --enable-fs_inet or --disable-fs_inet was given.
if test "${enable_fs_inet+set}" = set; then
echo $ac_n "checking for --enable-fs_zip""... $ac_c" 1>&6
-echo "configure:4086: checking for --enable-fs_zip" >&5
+echo "configure:4125: checking for --enable-fs_zip" >&5
no_cache=0
# Check whether --enable-fs_zip or --disable-fs_zip was given.
if test "${enable_fs_zip+set}" = set; then
echo $ac_n "checking for --enable-zipstream""... $ac_c" 1>&6
-echo "configure:4125: checking for --enable-zipstream" >&5
+echo "configure:4164: checking for --enable-zipstream" >&5
no_cache=0
# Check whether --enable-zipstream or --disable-zipstream was given.
if test "${enable_zipstream+set}" = set; then
echo $ac_n "checking for --enable-catch_segvs""... $ac_c" 1>&6
-echo "configure:4165: checking for --enable-catch_segvs" >&5
+echo "configure:4204: checking for --enable-catch_segvs" >&5
no_cache=0
# Check whether --enable-catch_segvs or --disable-catch_segvs was given.
if test "${enable_catch_segvs+set}" = set; then
echo $ac_n "checking for --enable-snglinst""... $ac_c" 1>&6
-echo "configure:4204: checking for --enable-snglinst" >&5
+echo "configure:4243: checking for --enable-snglinst" >&5
no_cache=0
# Check whether --enable-snglinst or --disable-snglinst was given.
if test "${enable_snglinst+set}" = set; then
echo $ac_n "checking for --enable-mimetype""... $ac_c" 1>&6
-echo "configure:4244: checking for --enable-mimetype" >&5
+echo "configure:4283: checking for --enable-mimetype" >&5
no_cache=0
# Check whether --enable-mimetype or --disable-mimetype was given.
if test "${enable_mimetype+set}" = set; then
echo $ac_n "checking for --enable-system_options""... $ac_c" 1>&6
-echo "configure:4283: checking for --enable-system_options" >&5
+echo "configure:4322: checking for --enable-system_options" >&5
no_cache=0
# Check whether --enable-system_options or --disable-system_options was given.
if test "${enable_system_options+set}" = set; then
echo $ac_n "checking for --enable-threads""... $ac_c" 1>&6
-echo "configure:4324: checking for --enable-threads" >&5
+echo "configure:4363: checking for --enable-threads" >&5
no_cache=0
# Check whether --enable-threads or --disable-threads was given.
if test "${enable_threads+set}" = set; then
fi
- echo $ac_n "checking for --enable-serial""... $ac_c" 1>&6
-echo "configure:4363: checking for --enable-serial" >&5
- no_cache=0
- # Check whether --enable-serial or --disable-serial was given.
-if test "${enable_serial+set}" = set; then
- enableval="$enable_serial"
-
- if test "$enableval" = yes; then
- ac_cv_use_serial='wxUSE_SERIAL=yes'
- else
- ac_cv_use_serial='wxUSE_SERIAL=no'
- fi
-
-else
-
- LINE=`grep "wxUSE_SERIAL" ${wx_arg_cache_file}`
- if test "x$LINE" != x ; then
- eval "DEFAULT_$LINE"
- else
- no_cache=1
- fi
-
- ac_cv_use_serial='wxUSE_SERIAL='$DEFAULT_wxUSE_SERIAL
-
-fi
-
-
- eval "$ac_cv_use_serial"
- if test "$no_cache" != 1; then
- echo $ac_cv_use_serial >> ${wx_arg_cache_file}.tmp
- fi
-
- if test "$wxUSE_SERIAL" = yes; then
- echo "$ac_t""yes" 1>&6
- else
- echo "$ac_t""no" 1>&6
- fi
-
-
if test "$wxUSE_GUI" = "yes"; then
#line 13526 "configure"
#include "confdefs.h"
#include <stdio.h>
+#include <sys/types.h>
main()
{
FILE *f=fopen("conftestval", "w");
exit(0);
}
EOF
-if { (eval echo configure:13537: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:13538: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_char=`cat conftestval`
else
echo $ac_n "checking size of short""... $ac_c" 1>&6
-echo "configure:13557: checking size of short" >&5
+echo "configure:13558: checking size of short" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_short'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_sizeof_short=2
else
cat > conftest.$ac_ext <<EOF
-#line 13565 "configure"
+#line 13566 "configure"
#include "confdefs.h"
#include <stdio.h>
+#include <sys/types.h>
main()
{
FILE *f=fopen("conftestval", "w");
exit(0);
}
EOF
-if { (eval echo configure:13576: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:13578: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_short=`cat conftestval`
else
echo $ac_n "checking size of int *""... $ac_c" 1>&6
-echo "configure:13596: checking size of int *" >&5
+echo "configure:13598: checking size of int *" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_int_p'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_sizeof_int_p=4
else
cat > conftest.$ac_ext <<EOF
-#line 13604 "configure"
+#line 13606 "configure"
#include "confdefs.h"
#include <stdio.h>
+#include <sys/types.h>
main()
{
FILE *f=fopen("conftestval", "w");
exit(0);
}
EOF
-if { (eval echo configure:13615: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:13618: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_int_p=`cat conftestval`
else
echo $ac_n "checking size of int""... $ac_c" 1>&6
-echo "configure:13635: checking size of int" >&5
+echo "configure:13638: checking size of int" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_sizeof_int=4
else
cat > conftest.$ac_ext <<EOF
-#line 13643 "configure"
+#line 13646 "configure"
#include "confdefs.h"
#include <stdio.h>
+#include <sys/types.h>
main()
{
FILE *f=fopen("conftestval", "w");
exit(0);
}
EOF
-if { (eval echo configure:13654: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:13658: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_int=`cat conftestval`
else
echo $ac_n "checking size of long""... $ac_c" 1>&6
-echo "configure:13674: checking size of long" >&5
+echo "configure:13678: checking size of long" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_sizeof_long=4
else
cat > conftest.$ac_ext <<EOF
-#line 13682 "configure"
+#line 13686 "configure"
#include "confdefs.h"
#include <stdio.h>
+#include <sys/types.h>
main()
{
FILE *f=fopen("conftestval", "w");
exit(0);
}
EOF
-if { (eval echo configure:13693: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:13698: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_long=`cat conftestval`
else
echo $ac_n "checking size of long long""... $ac_c" 1>&6
-echo "configure:13713: checking size of long long" >&5
+echo "configure:13718: checking size of long long" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_long_long'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_sizeof_long_long=0
else
cat > conftest.$ac_ext <<EOF
-#line 13721 "configure"
+#line 13726 "configure"
#include "confdefs.h"
#include <stdio.h>
+#include <sys/types.h>
main()
{
FILE *f=fopen("conftestval", "w");
exit(0);
}
EOF
-if { (eval echo configure:13732: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:13738: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_long_long=`cat conftestval`
else
echo $ac_n "checking size of wchar_t""... $ac_c" 1>&6
-echo "configure:13753: checking size of wchar_t" >&5
+echo "configure:13759: checking size of wchar_t" >&5
if eval "test \"`echo '$''{'wx_cv_sizeof_wchar_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
else
cat > conftest.$ac_ext <<EOF
-#line 13763 "configure"
+#line 13769 "configure"
#include "confdefs.h"
#ifdef HAVE_WCHAR_H
}
EOF
-if { (eval echo configure:13785: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:13791: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
wx_cv_sizeof_wchar_t=`cat conftestval`
else
echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
-echo "configure:13808: checking whether byte ordering is bigendian" >&5
+echo "configure:13814: checking whether byte ordering is bigendian" >&5
if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_bigendian=unknown
# See if sys/param.h defines the BYTE_ORDER macro.
cat > conftest.$ac_ext <<EOF
-#line 13815 "configure"
+#line 13821 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/param.h>
#endif
; return 0; }
EOF
-if { (eval echo configure:13826: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:13832: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
# It does; now see whether it defined to BIG_ENDIAN or not.
cat > conftest.$ac_ext <<EOF
-#line 13830 "configure"
+#line 13836 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/param.h>
#endif
; return 0; }
EOF
-if { (eval echo configure:13841: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:13847: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_bigendian=yes
else
ac_cv_c_bigendian=unknown
else
cat > conftest.$ac_ext <<EOF
-#line 13861 "configure"
+#line 13867 "configure"
#include "confdefs.h"
main () {
/* Are we little or big endian? From Harbison&Steele. */
exit (u.c[sizeof (long) - 1] == 1);
}
EOF
-if { (eval echo configure:13874: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:13880: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_bigendian=no
else
echo $ac_n "checking how to run the C++ preprocessor""... $ac_c" 1>&6
-echo "configure:13902: checking how to run the C++ preprocessor" >&5
+echo "configure:13908: checking how to run the C++ preprocessor" >&5
if test -z "$CXXCPP"; then
if eval "test \"`echo '$''{'ac_cv_prog_CXXCPP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
cross_compiling=$ac_cv_prog_cxx_cross
CXXCPP="${CXX-g++} -E"
cat > conftest.$ac_ext <<EOF
-#line 13915 "configure"
+#line 13921 "configure"
#include "confdefs.h"
#include <stdlib.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:13920: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:13926: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:13964: checking for $ac_hdr" >&5
+echo "configure:13970: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 13969 "configure"
+#line 13975 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:13974: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:13980: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
echo $ac_n "checking if C++ compiler supports bool""... $ac_c" 1>&6
-echo "configure:14022: checking if C++ compiler supports bool" >&5
+echo "configure:14028: checking if C++ compiler supports bool" >&5
if eval "test \"`echo '$''{'wx_cv_cpp_bool'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 14037 "configure"
+#line 14043 "configure"
#include "confdefs.h"
; return 0; }
EOF
-if { (eval echo configure:14049: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:14055: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wx_cv_cpp_bool=yes
echo $ac_n "checking for wcslen in -lc""... $ac_c" 1>&6
-echo "configure:14087: checking for wcslen in -lc" >&5
+echo "configure:14093: checking for wcslen in -lc" >&5
ac_lib_var=`echo c'_'wcslen | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lc $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 14095 "configure"
+#line 14101 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
wcslen()
; return 0; }
EOF
-if { (eval echo configure:14106: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14112: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for wcslen in -lw""... $ac_c" 1>&6
-echo "configure:14132: checking for wcslen in -lw" >&5
+echo "configure:14138: checking for wcslen in -lw" >&5
ac_lib_var=`echo w'_'wcslen | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lw $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 14140 "configure"
+#line 14146 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
wcslen()
; return 0; }
EOF
-if { (eval echo configure:14151: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14157: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for wcslen in -lmsvcrt""... $ac_c" 1>&6
-echo "configure:14177: checking for wcslen in -lmsvcrt" >&5
+echo "configure:14183: checking for wcslen in -lmsvcrt" >&5
ac_lib_var=`echo msvcrt'_'wcslen | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lmsvcrt $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 14185 "configure"
+#line 14191 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
wcslen()
; return 0; }
EOF
-if { (eval echo configure:14196: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14202: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
for ac_func in wcsrtombs
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:14232: checking for $ac_func" >&5
+echo "configure:14238: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 14237 "configure"
+#line 14243 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:14260: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14266: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
echo $ac_n "checking for vprintf""... $ac_c" 1>&6
-echo "configure:14286: checking for vprintf" >&5
+echo "configure:14292: checking for vprintf" >&5
if eval "test \"`echo '$''{'ac_cv_func_vprintf'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 14291 "configure"
+#line 14297 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char vprintf(); below. */
; return 0; }
EOF
-if { (eval echo configure:14314: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14320: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_vprintf=yes"
else
if test "$ac_cv_func_vprintf" != yes; then
echo $ac_n "checking for _doprnt""... $ac_c" 1>&6
-echo "configure:14338: checking for _doprnt" >&5
+echo "configure:14344: checking for _doprnt" >&5
if eval "test \"`echo '$''{'ac_cv_func__doprnt'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 14343 "configure"
+#line 14349 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char _doprnt(); below. */
; return 0; }
EOF
-if { (eval echo configure:14366: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14372: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func__doprnt=yes"
else
echo $ac_n "checking for vsnprintf""... $ac_c" 1>&6
-echo "configure:14396: checking for vsnprintf" >&5
+echo "configure:14402: checking for vsnprintf" >&5
if eval "test \"`echo '$''{'wx_cv_func_vsnprintf'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 14402 "configure"
+#line 14408 "configure"
#include "confdefs.h"
#include <stdio.h>
; return 0; }
EOF
-if { (eval echo configure:14427: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14433: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
wx_cv_func_vsnprintf=yes
rm -rf conftest*
cat > conftest.$ac_ext <<EOF
-#line 14438 "configure"
+#line 14444 "configure"
#include "confdefs.h"
#include <stdio.h>
; return 0; }
EOF
-if { (eval echo configure:14463: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14469: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
wx_cv_func_vsnprintf=yes
fi
echo $ac_n "checking for vsscanf""... $ac_c" 1>&6
-echo "configure:14495: checking for vsscanf" >&5
+echo "configure:14501: checking for vsscanf" >&5
if eval "test \"`echo '$''{'wx_cv_func_vsscanf'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 14501 "configure"
+#line 14507 "configure"
#include "confdefs.h"
#include <stdio.h>
; return 0; }
EOF
-if { (eval echo configure:14524: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:14530: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wx_cv_func_vsscanf=yes
cross_compiling=$ac_cv_prog_cxx_cross
echo $ac_n "checking if iconv() takes char**""... $ac_c" 1>&6
-echo "configure:14562: checking if iconv() takes char**" >&5
+echo "configure:14568: checking if iconv() takes char**" >&5
if eval "test \"`echo '$''{'wx_cv_iconv_takes_char'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 14568 "configure"
+#line 14574 "configure"
#include "confdefs.h"
#include <iconv.h>
int main() {
; return 0; }
EOF
-if { (eval echo configure:14580: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:14586: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wx_cv_iconv_takes_char=yes
else
for ac_func in sigaction
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:14613: checking for $ac_func" >&5
+echo "configure:14619: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 14618 "configure"
+#line 14624 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:14641: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14647: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
echo $ac_n "checking for sa_handler type""... $ac_c" 1>&6
-echo "configure:14682: checking for sa_handler type" >&5
+echo "configure:14688: checking for sa_handler type" >&5
if eval "test \"`echo '$''{'wx_cv_type_sa_handler'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 14688 "configure"
+#line 14694 "configure"
#include "confdefs.h"
#include <signal.h>
int main() {
; return 0; }
EOF
-if { (eval echo configure:14700: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:14706: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wx_cv_type_sa_handler=int
for ac_func in vfork
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:14737: checking for $ac_func" >&5
+echo "configure:14743: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 14742 "configure"
+#line 14748 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:14765: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14771: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
for ac_func in mkstemp mktemp
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:14793: checking for $ac_func" >&5
+echo "configure:14799: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 14798 "configure"
+#line 14804 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:14821: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14827: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
echo $ac_n "checking for statfs""... $ac_c" 1>&6
-echo "configure:14847: checking for statfs" >&5
+echo "configure:14853: checking for statfs" >&5
if eval "test \"`echo '$''{'wx_cv_func_statfs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 14852 "configure"
+#line 14858 "configure"
#include "confdefs.h"
#if defined(__BSD__)
; return 0; }
EOF
-if { (eval echo configure:14873: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:14879: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wx_cv_func_statfs=yes
else
echo $ac_n "checking for statvfs""... $ac_c" 1>&6
-echo "configure:14900: checking for statvfs" >&5
+echo "configure:14906: checking for statvfs" >&5
if eval "test \"`echo '$''{'wx_cv_func_statvfs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 14905 "configure"
+#line 14911 "configure"
#include "confdefs.h"
#include <sys/statvfs.h>
; return 0; }
EOF
-if { (eval echo configure:14921: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:14927: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wx_cv_func_statvfs=yes
for ac_func in fcntl flock
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:14955: checking for $ac_func" >&5
+echo "configure:14961: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 14960 "configure"
+#line 14966 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:14983: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14989: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
for ac_func in timegm
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:15017: checking for $ac_func" >&5
+echo "configure:15023: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 15022 "configure"
+#line 15028 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:15045: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15051: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
for ac_func in putenv setenv
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:15073: checking for $ac_func" >&5
+echo "configure:15079: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 15078 "configure"
+#line 15084 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:15101: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15107: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
for ac_func in nanosleep
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:15148: checking for $ac_func" >&5
+echo "configure:15154: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 15153 "configure"
+#line 15159 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:15176: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15182: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for nanosleep in -lposix4""... $ac_c" 1>&6
-echo "configure:15201: checking for nanosleep in -lposix4" >&5
+echo "configure:15207: checking for nanosleep in -lposix4" >&5
ac_lib_var=`echo posix4'_'nanosleep | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lposix4 $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 15209 "configure"
+#line 15215 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
nanosleep()
; return 0; }
EOF
-if { (eval echo configure:15220: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15226: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
for ac_func in usleep
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:15248: checking for $ac_func" >&5
+echo "configure:15254: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 15253 "configure"
+#line 15259 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:15276: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15282: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
for ac_func in uname gethostname
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:15319: checking for $ac_func" >&5
+echo "configure:15325: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 15324 "configure"
+#line 15330 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:15347: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15353: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
for ac_func in strtok_r
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:15384: checking for $ac_func" >&5
+echo "configure:15390: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 15389 "configure"
+#line 15395 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:15415: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15421: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
for ac_func in inet_addr
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:15452: checking for $ac_func" >&5
+echo "configure:15458: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 15457 "configure"
+#line 15463 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:15480: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15486: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for inet_addr in -lnsl""... $ac_c" 1>&6
-echo "configure:15505: checking for inet_addr in -lnsl" >&5
+echo "configure:15511: checking for inet_addr in -lnsl" >&5
ac_lib_var=`echo nsl'_'inet_addr | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lnsl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 15513 "configure"
+#line 15519 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
inet_addr()
; return 0; }
EOF
-if { (eval echo configure:15524: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15530: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for inet_addr in -lresolv""... $ac_c" 1>&6
-echo "configure:15543: checking for inet_addr in -lresolv" >&5
+echo "configure:15549: checking for inet_addr in -lresolv" >&5
ac_lib_var=`echo resolv'_'inet_addr | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lresolv $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 15551 "configure"
+#line 15557 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
inet_addr()
; return 0; }
EOF
-if { (eval echo configure:15562: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15568: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
for ac_func in inet_aton
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:15595: checking for $ac_func" >&5
+echo "configure:15601: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 15600 "configure"
+#line 15606 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:15623: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15629: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for inet_aton in -l$INET_LINK""... $ac_c" 1>&6
-echo "configure:15648: checking for inet_aton in -l$INET_LINK" >&5
+echo "configure:15654: checking for inet_aton in -l$INET_LINK" >&5
ac_lib_var=`echo $INET_LINK'_'inet_aton | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-l$INET_LINK $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 15656 "configure"
+#line 15662 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
inet_aton()
; return 0; }
EOF
-if { (eval echo configure:15667: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15673: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
fi
echo $ac_n "checking for pthread_create in -l$THREADS_LIB""... $ac_c" 1>&6
-echo "configure:15782: checking for pthread_create in -l$THREADS_LIB" >&5
+echo "configure:15788: checking for pthread_create in -l$THREADS_LIB" >&5
ac_lib_var=`echo $THREADS_LIB'_'pthread_create | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-l$THREADS_LIB $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 15790 "configure"
+#line 15796 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
pthread_create()
; return 0; }
EOF
-if { (eval echo configure:15801: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15807: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for pthread_create in -lc_r""... $ac_c" 1>&6
-echo "configure:15824: checking for pthread_create in -lc_r" >&5
+echo "configure:15830: checking for pthread_create in -lc_r" >&5
ac_lib_var=`echo c_r'_'pthread_create | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lc_r $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 15832 "configure"
+#line 15838 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
pthread_create()
; return 0; }
EOF
-if { (eval echo configure:15843: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15849: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
ac_safe=`echo "sys/prctl.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for sys/prctl.h""... $ac_c" 1>&6
-echo "configure:15867: checking for sys/prctl.h" >&5
+echo "configure:15873: checking for sys/prctl.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 15872 "configure"
+#line 15878 "configure"
#include "confdefs.h"
#include <sys/prctl.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:15877: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:15883: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
for ac_func in thr_setconcurrency
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:15917: checking for $ac_func" >&5
+echo "configure:15923: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 15922 "configure"
+#line 15928 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:15945: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15951: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:15975: checking for $ac_hdr" >&5
+echo "configure:15981: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 15980 "configure"
+#line 15986 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:15985: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:15991: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
echo $ac_n "checking for sched_yield in -l$THREADS_LINK""... $ac_c" 1>&6
-echo "configure:16013: checking for sched_yield in -l$THREADS_LINK" >&5
+echo "configure:16019: checking for sched_yield in -l$THREADS_LINK" >&5
ac_lib_var=`echo $THREADS_LINK'_'sched_yield | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-l$THREADS_LINK $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 16021 "configure"
+#line 16027 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
sched_yield()
; return 0; }
EOF
-if { (eval echo configure:16032: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:16038: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for sched_yield in -lposix4""... $ac_c" 1>&6
-echo "configure:16054: checking for sched_yield in -lposix4" >&5
+echo "configure:16060: checking for sched_yield in -lposix4" >&5
ac_lib_var=`echo posix4'_'sched_yield | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lposix4 $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 16062 "configure"
+#line 16068 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
sched_yield()
; return 0; }
EOF
-if { (eval echo configure:16073: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:16079: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
HAVE_PRIOR_FUNCS=0
echo $ac_n "checking for pthread_attr_getschedpolicy in -l$THREADS_LINK""... $ac_c" 1>&6
-echo "configure:16104: checking for pthread_attr_getschedpolicy in -l$THREADS_LINK" >&5
+echo "configure:16110: checking for pthread_attr_getschedpolicy in -l$THREADS_LINK" >&5
ac_lib_var=`echo $THREADS_LINK'_'pthread_attr_getschedpolicy | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-l$THREADS_LINK $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 16112 "configure"
+#line 16118 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
pthread_attr_getschedpolicy()
; return 0; }
EOF
-if { (eval echo configure:16123: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:16129: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for pthread_attr_setschedparam in -l$THREADS_LINK""... $ac_c" 1>&6
-echo "configure:16139: checking for pthread_attr_setschedparam in -l$THREADS_LINK" >&5
+echo "configure:16145: checking for pthread_attr_setschedparam in -l$THREADS_LINK" >&5
ac_lib_var=`echo $THREADS_LINK'_'pthread_attr_setschedparam | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-l$THREADS_LINK $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 16147 "configure"
+#line 16153 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
pthread_attr_setschedparam()
; return 0; }
EOF
-if { (eval echo configure:16158: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:16164: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for sched_get_priority_max in -l$THREADS_LINK""... $ac_c" 1>&6
-echo "configure:16174: checking for sched_get_priority_max in -l$THREADS_LINK" >&5
+echo "configure:16180: checking for sched_get_priority_max in -l$THREADS_LINK" >&5
ac_lib_var=`echo $THREADS_LINK'_'sched_get_priority_max | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-l$THREADS_LINK $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 16182 "configure"
+#line 16188 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
sched_get_priority_max()
; return 0; }
EOF
-if { (eval echo configure:16193: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:16199: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for sched_get_priority_max in -lposix4""... $ac_c" 1>&6
-echo "configure:16212: checking for sched_get_priority_max in -lposix4" >&5
+echo "configure:16218: checking for sched_get_priority_max in -lposix4" >&5
ac_lib_var=`echo posix4'_'sched_get_priority_max | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lposix4 $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 16220 "configure"
+#line 16226 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
sched_get_priority_max()
; return 0; }
EOF
-if { (eval echo configure:16231: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:16237: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
fi
echo $ac_n "checking for pthread_cancel in -l$THREADS_LINK""... $ac_c" 1>&6
-echo "configure:16278: checking for pthread_cancel in -l$THREADS_LINK" >&5
+echo "configure:16284: checking for pthread_cancel in -l$THREADS_LINK" >&5
ac_lib_var=`echo $THREADS_LINK'_'pthread_cancel | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-l$THREADS_LINK $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 16286 "configure"
+#line 16292 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
pthread_cancel()
; return 0; }
EOF
-if { (eval echo configure:16297: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:16303: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
echo $ac_n "checking for pthread_cleanup_push/pop""... $ac_c" 1>&6
-echo "configure:16323: checking for pthread_cleanup_push/pop" >&5
+echo "configure:16329: checking for pthread_cleanup_push/pop" >&5
if eval "test \"`echo '$''{'wx_cv_func_pthread_cleanup_push'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 16329 "configure"
+#line 16335 "configure"
#include "confdefs.h"
#include <pthread.h>
int main() {
; return 0; }
EOF
-if { (eval echo configure:16339: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:16345: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wx_cv_func_pthread_cleanup_push=yes
fi
echo $ac_n "checking for pthread_mutexattr_t""... $ac_c" 1>&6
-echo "configure:16371: checking for pthread_mutexattr_t" >&5
+echo "configure:16377: checking for pthread_mutexattr_t" >&5
if eval "test \"`echo '$''{'wx_cv_type_pthread_mutexattr_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 16377 "configure"
+#line 16383 "configure"
#include "confdefs.h"
#include <pthread.h>
int main() {
; return 0; }
EOF
-if { (eval echo configure:16387: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:16393: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wx_cv_type_pthread_mutexattr_t=yes
else
echo $ac_n "checking for PTHREAD_RECURSIVE_MUTEX_INITIALIZER""... $ac_c" 1>&6
-echo "configure:16414: checking for PTHREAD_RECURSIVE_MUTEX_INITIALIZER" >&5
+echo "configure:16420: checking for PTHREAD_RECURSIVE_MUTEX_INITIALIZER" >&5
if eval "test \"`echo '$''{'wx_cv_type_pthread_rec_mutex_init'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 16420 "configure"
+#line 16426 "configure"
#include "confdefs.h"
#include <pthread.h>
int main() {
; return 0; }
EOF
-if { (eval echo configure:16429: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:16435: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wx_cv_type_pthread_rec_mutex_init=yes
else
if test "$ac_cv_func_strtok_r" = "yes"; then
echo $ac_n "checking if -D_REENTRANT is needed""... $ac_c" 1>&6
-echo "configure:16481: checking if -D_REENTRANT is needed" >&5
+echo "configure:16487: checking if -D_REENTRANT is needed" >&5
if test "$NEEDS_D_REENTRANT_FOR_R_FUNCS" = 1; then
TOOLCHAIN_DEFS="${TOOLCHAIN_DEFS} -D_REENTRANT"
echo "$ac_t""yes" 1>&6
for ac_func in strptime
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:16861: checking for $ac_func" >&5
+echo "configure:16867: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 16866 "configure"
+#line 16872 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:16889: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:16895: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
echo $ac_n "checking for timezone variable in <time.h>""... $ac_c" 1>&6
-echo "configure:16915: checking for timezone variable in <time.h>" >&5
+echo "configure:16921: checking for timezone variable in <time.h>" >&5
if eval "test \"`echo '$''{'wx_cv_var_timezone'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 16921 "configure"
+#line 16927 "configure"
#include "confdefs.h"
#include <time.h>
; return 0; }
EOF
-if { (eval echo configure:16933: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:16939: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wx_cv_var_timezone=timezone
rm -rf conftest*
cat > conftest.$ac_ext <<EOF
-#line 16944 "configure"
+#line 16950 "configure"
#include "confdefs.h"
#include <time.h>
; return 0; }
EOF
-if { (eval echo configure:16956: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:16962: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wx_cv_var_timezone=_timezone
rm -rf conftest*
cat > conftest.$ac_ext <<EOF
-#line 16967 "configure"
+#line 16973 "configure"
#include "confdefs.h"
#include <time.h>
; return 0; }
EOF
-if { (eval echo configure:16979: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:16985: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wx_cv_var_timezone=__timezone
for ac_func in localtime
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:17020: checking for $ac_func" >&5
+echo "configure:17026: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 17025 "configure"
+#line 17031 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:17048: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:17054: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
if test "$ac_cv_func_localtime" = "yes"; then
echo $ac_n "checking for tm_gmtoff in struct tm""... $ac_c" 1>&6
-echo "configure:17075: checking for tm_gmtoff in struct tm" >&5
+echo "configure:17081: checking for tm_gmtoff in struct tm" >&5
if eval "test \"`echo '$''{'wx_cv_struct_tm_has_gmtoff'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 17081 "configure"
+#line 17087 "configure"
#include "confdefs.h"
#include <time.h>
; return 0; }
EOF
-if { (eval echo configure:17093: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:17099: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wx_cv_struct_tm_has_gmtoff=yes
for ac_func in gettimeofday ftime
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:17122: checking for $ac_func" >&5
+echo "configure:17128: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 17127 "configure"
+#line 17133 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:17150: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:17156: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
if test "$ac_cv_func_gettimeofday" = "yes"; then
echo $ac_n "checking whether gettimeofday takes two arguments""... $ac_c" 1>&6
-echo "configure:17177: checking whether gettimeofday takes two arguments" >&5
+echo "configure:17183: checking whether gettimeofday takes two arguments" >&5
if eval "test \"`echo '$''{'wx_cv_func_gettimeofday_has_2_args'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 17192 "configure"
+#line 17198 "configure"
#include "confdefs.h"
#include <sys/time.h>
; return 0; }
EOF
-if { (eval echo configure:17205: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:17211: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wx_cv_func_gettimeofday_has_2_args=yes
else
cat conftest.$ac_ext >&5
rm -rf conftest*
cat > conftest.$ac_ext <<EOF
-#line 17213 "configure"
+#line 17219 "configure"
#include "confdefs.h"
#include <sys/time.h>
; return 0; }
EOF
-if { (eval echo configure:17226: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:17232: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wx_cv_func_gettimeofday_has_2_args=no
else
if test "$wxUSE_SOCKETS" = "yes"; then
echo $ac_n "checking for socket""... $ac_c" 1>&6
-echo "configure:17275: checking for socket" >&5
+echo "configure:17281: checking for socket" >&5
if eval "test \"`echo '$''{'ac_cv_func_socket'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 17280 "configure"
+#line 17286 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char socket(); below. */
; return 0; }
EOF
-if { (eval echo configure:17303: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:17309: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_socket=yes"
else
else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6
-echo "configure:17321: checking for socket in -lsocket" >&5
+echo "configure:17327: checking for socket in -lsocket" >&5
ac_lib_var=`echo socket'_'socket | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lsocket $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 17329 "configure"
+#line 17335 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
socket()
; return 0; }
EOF
-if { (eval echo configure:17340: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:17346: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
if test "$wxUSE_SOCKETS" = "yes" ; then
echo $ac_n "checking what is the type of the third argument of getsockname""... $ac_c" 1>&6
-echo "configure:17373: checking what is the type of the third argument of getsockname" >&5
+echo "configure:17379: checking what is the type of the third argument of getsockname" >&5
if eval "test \"`echo '$''{'wx_cv_type_getsockname3'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 17388 "configure"
+#line 17394 "configure"
#include "confdefs.h"
#include <sys/types.h>
; return 0; }
EOF
-if { (eval echo configure:17401: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:17407: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wx_cv_type_getsockname3=socklen_t
else
cat conftest.$ac_ext >&5
rm -rf conftest*
cat > conftest.$ac_ext <<EOF
-#line 17409 "configure"
+#line 17415 "configure"
#include "confdefs.h"
#include <sys/types.h>
; return 0; }
EOF
-if { (eval echo configure:17422: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:17428: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wx_cv_type_getsockname3=size_t
else
cat conftest.$ac_ext >&5
rm -rf conftest*
cat > conftest.$ac_ext <<EOF
-#line 17430 "configure"
+#line 17436 "configure"
#include "confdefs.h"
#include <sys/types.h>
; return 0; }
EOF
-if { (eval echo configure:17443: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:17449: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wx_cv_type_getsockname3=int
else
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:17511: checking for $ac_hdr" >&5
+echo "configure:17517: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 17516 "configure"
+#line 17522 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:17521: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:17527: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
HAVE_DL_FUNCS=0
HAVE_SHL_FUNCS=0
- if test "$wxUSE_DYNLIB_CLASS" = "yes"; then
+ if test "$wxUSE_DYNAMIC_LOADER" = "yes" -o "$wxUSE_DYNLIB_CLASS" = "yes" ; then
if test "$USE_DARWIN" = 1; then
HAVE_DL_FUNCS=1
else
for ac_func in dlopen
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:17575: checking for $ac_func" >&5
+echo "configure:17581: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 17580 "configure"
+#line 17586 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:17603: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:17609: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
-echo "configure:17631: checking for dlopen in -ldl" >&5
+echo "configure:17637: checking for dlopen in -ldl" >&5
ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-ldl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 17639 "configure"
+#line 17645 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
dlopen()
; return 0; }
EOF
-if { (eval echo configure:17650: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:17656: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
for ac_func in shl_load
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:17679: checking for $ac_func" >&5
+echo "configure:17685: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 17684 "configure"
+#line 17690 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:17707: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:17713: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for dld in -lshl_load""... $ac_c" 1>&6
-echo "configure:17735: checking for dld in -lshl_load" >&5
+echo "configure:17741: checking for dld in -lshl_load" >&5
ac_lib_var=`echo shl_load'_'dld | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lshl_load $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 17743 "configure"
+#line 17749 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
dld()
; return 0; }
EOF
-if { (eval echo configure:17754: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:17760: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
for ac_func in dlerror
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:17793: checking for $ac_func" >&5
+echo "configure:17799: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 17798 "configure"
+#line 17804 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:17821: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:17827: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for dlerror in -ldl""... $ac_c" 1>&6
-echo "configure:17846: checking for dlerror in -ldl" >&5
+echo "configure:17852: checking for dlerror in -ldl" >&5
ac_lib_var=`echo dl'_'dlerror | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-ldl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 17854 "configure"
+#line 17860 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
dlerror()
; return 0; }
EOF
-if { (eval echo configure:17865: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:17871: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
if test "$HAVE_SHL_FUNCS" = 0; then
if test "$USE_UNIX" = 1; then
echo "configure: warning: Missing dynamic loading support, several features will be disabled" 1>&2
+ wxUSE_DYNAMIC_LOADER=no
wxUSE_DYNLIB_CLASS=no
else
echo "configure: warning: Assuming wxLibrary class works on this platform" 1>&2
fi
fi
-if test "$wxUSE_DYNLIB_CLASS" = "yes" ; then
+if test "$wxUSE_DYNAMIC_LOADER" = "yes" ; then
+ cat >> confdefs.h <<\EOF
+#define wxUSE_DYNAMIC_LOADER 1
+EOF
+
+elif test "$wxUSE_DYNLIB_CLASS" = "yes" ; then
cat >> confdefs.h <<\EOF
#define wxUSE_DYNLIB_CLASS 1
EOF
-else
- wxUSE_ODBC=no
- wxUSE_SERIAL=no
fi
fi
-if test "$wxUSE_SERIAL" = "yes" ; then
- cat >> confdefs.h <<\EOF
-#define wxUSE_SERIAL 1
-EOF
-
-fi
-
IODBC_C_SRC=""
if test "$wxUSE_ODBC" = "yes" ; then
if test "$wxUSE_MS_HTML_HELP" = "yes"; then
ac_safe=`echo "htmlhelp.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for htmlhelp.h""... $ac_c" 1>&6
-echo "configure:18022: checking for htmlhelp.h" >&5
+echo "configure:18024: checking for htmlhelp.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 18027 "configure"
+#line 18029 "configure"
#include "confdefs.h"
#include <htmlhelp.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:18032: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:18034: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:18120: checking for $ac_hdr" >&5
+echo "configure:18122: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 18125 "configure"
+#line 18127 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:18130: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:18132: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:19031: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:19033: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
DEFAULT_wxUSE_STREAMS=no
DEFAULT_wxUSE_SOCKETS=no
DEFAULT_wxUSE_DIALUP_MANAGER=no
- DEFAULT_wxUSE_SERIAL=no
DEFAULT_wxUSE_JOYSTICK=no
DEFAULT_wxUSE_DYNLIB_CLASS=no
+ DEFAULT_wxUSE_DYNAMIC_LOADER=no
DEFAULT_wxUSE_LONGLONG=no
DEFAULT_wxUSE_GEOMETRY=no
DEFAULT_wxUSE_STREAMS=yes
DEFAULT_wxUSE_SOCKETS=yes
DEFAULT_wxUSE_DIALUP_MANAGER=yes
- DEFAULT_wxUSE_SERIAL=yes
DEFAULT_wxUSE_JOYSTICK=yes
- DEFAULT_wxUSE_DYNLIB_CLASS=yes
+ DEFAULT_wxUSE_DYNLIB_CLASS=no
+ DEFAULT_wxUSE_DYNAMIC_LOADER=yes
DEFAULT_wxUSE_LONGLONG=yes
DEFAULT_wxUSE_GEOMETRY=yes
WX_ARG_ENABLE(wave, [ --enable-wave use wxWave class], wxUSE_WAVE)
WX_ARG_ENABLE(fraction, [ --enable-fraction use wxFraction class], wxUSE_FRACTION)
WX_ARG_ENABLE(dynlib, [ --enable-dynlib use wxLibrary class for DLL loading], wxUSE_DYNLIB_CLASS)
+WX_ARG_ENABLE(dynamicloader, [ --enable-dynamicloader use (new) wxDynamicLibrary class], wxUSE_DYNAMIC_LOADER)
WX_ARG_ENABLE(longlong, [ --enable-longlong use wxLongLong class], wxUSE_LONGLONG)
WX_ARG_ENABLE(geometry, [ --enable-geometry use geometry class], wxUSE_GEOMETRY)
WX_ARG_ENABLE(log, [ --enable-log use logging system], wxUSE_LOG)
dnl ---------------------------------------------------------------------------
WX_ARG_ENABLE(threads, [ --enable-threads use threads], wxUSE_THREADS)
-WX_ARG_ENABLE(serial, [ --enable-serial use class serialization], wxUSE_SERIAL)
if test "$wxUSE_GUI" = "yes"; then
HAVE_DL_FUNCS=0
HAVE_SHL_FUNCS=0
- if test "$wxUSE_DYNLIB_CLASS" = "yes"; then
+ if test "$wxUSE_DYNAMIC_LOADER" = "yes" -o "$wxUSE_DYNLIB_CLASS" = "yes" ; then
if test "$USE_DARWIN" = 1; then
dnl dlopen/dlerror is implemented in dynlib.cpp for Darwin/Mac OS X
HAVE_DL_FUNCS=1
if test "$HAVE_SHL_FUNCS" = 0; then
if test "$USE_UNIX" = 1; then
AC_MSG_WARN([Missing dynamic loading support, several features will be disabled])
+ wxUSE_DYNAMIC_LOADER=no
wxUSE_DYNLIB_CLASS=no
else
AC_MSG_WARN([Assuming wxLibrary class works on this platform])
fi
fi
-if test "$wxUSE_DYNLIB_CLASS" = "yes" ; then
+if test "$wxUSE_DYNAMIC_LOADER" = "yes" ; then
+ AC_DEFINE(wxUSE_DYNAMIC_LOADER)
+elif test "$wxUSE_DYNLIB_CLASS" = "yes" ; then
AC_DEFINE(wxUSE_DYNLIB_CLASS)
-else
- wxUSE_ODBC=no
- wxUSE_SERIAL=no
fi
dnl ---------------------------------------------------------------------------
AC_DEFINE(wxUSE_EXPERIMENTAL_PRINTF)
fi
-dnl ----------------------------------------------------------------
-dnl serialization support
-dnl ----------------------------------------------------------------
-
-if test "$wxUSE_SERIAL" = "yes" ; then
- AC_DEFINE(wxUSE_SERIAL)
-fi
dnl ----------------------------------------------------------------
dnl iODBC support
-- Ron Lee <ron@debian.org> Sat, 27 Jan 2001 01:51:24 -0800
+ wxwindows2.2 (2.2.8.5) unstable; urgency=low
+
+ * Add wxSIZE_T_IS defines to setup.h
+ Add automate that to my TODO list.
+
+ -- Ron Lee <ron@debian.org> Tue, 27 Nov 2001 05:55:47 -0800
+
wxwindows2.2 (2.2.8.4) unstable; urgency=low
* Put the (modified) size_t == ulong kludge back into sndwav.cpp
dseldlg.cpp Common
dynarray.cpp Common Base
dynlib.cpp Common Base
+dynload.cpp Common Base
effects.cpp Common
encconv.cpp Common Base
event.cpp Common Base
mstream.cpp Common Base
nbkbase.cpp Common
object.cpp Common Base
-objstrm.cpp Common Base
odbc.cpp Common NotGTK,NotX,NotOS2
paper.cpp Common
popupcmn.cpp Common
sckfile.cpp Common Socket,Base
sckipc.cpp Common Socket,Base
sckstrm.cpp Common Socket,Base
-serbase.cpp Common Base
sizer.cpp Common
socket.cpp Common Socket,Base
statbar.cpp Common
config.h WXH Base
containr.h WXH
control.h WXH
+cshelp.h WXH
ctrlsub.h WXH
cursor.h WXH
dataobj.h WXH
dragimag.h WXH
dynarray.h WXH Base
dynlib.h WXH Base
+dynload.h WXH Base
encconv.h WXH Base
event.h WXH Base
expr.h WXH
hash.h WXH Base
help.h WXH
helpbase.h WXH
-cshelp.h WXH
helphtml.h WXH
helpwin.h WXH
icon.h WXH
mstream.h WXH Base
notebook.h WXH
object.h WXH Base
-objstrm.h WXH Base
odbc.h WXH
ownerdrw.h WXH
palette.h WXH
sckstrm.h WXH Base
scrolbar.h WXH
scrolwin.h WXH
-serbase.h WXH Base
settings.h WXH
sizer.h WXH
slider.h WXH
// because -1 is a valid (and largely used) value for window id.
typedef int wxWindowID;
+// ----------------------------------------------------------------------------
+// other feature tests
+// ----------------------------------------------------------------------------
+
+ // Every ride down a slippery slope begins with a single step..
+ //
+ // Yes, using nested classes is indeed against our coding standards in
+ // general, but there are places where you can use them to advantage
+ // without totally breaking ports that cannot use them. If you do, then
+ // wrap it in this guard, but such cases should still be relatively rare.
+
+#ifndef __WIN16__
+#define wxUSE_NESTED_CLASSES 1
+#else
+#define wxUSE_NESTED_CLASSES 0
+#endif
+
// ----------------------------------------------------------------------------
// portable calling conventions macros
// ----------------------------------------------------------------------------
virtual wxInputStream& LoadObject(wxInputStream& stream);
#endif
-#if wxUSE_SERIAL
- // need this to keep from hiding the virtual from wxObject
- virtual void LoadObject(wxObjectInputStream& stream) { wxObject::LoadObject(stream); };
-#endif
-
// Called by wxWindows
virtual bool OnSaveDocument(const wxString& filename);
virtual bool OnOpenDocument(const wxString& filename);
#include "wx/setup.h"
-#if wxUSE_DYNLIB_CLASS
+#if wxUSE_DYNAMIC_LOADER
+
+#include "wx/dynload.h" // Use the new (version of) wxDynamicLibrary instead
+
+#elif wxUSE_DYNLIB_CLASS
#include "wx/string.h"
#include "wx/list.h"
if success pointer is not NULL, it will be filled with TRUE if everything
went ok and FALSE otherwise
*/
- static wxDllType LoadLibrary(const wxString& libname, bool *success = NULL);
+ static wxDllType LoadLibrary(const wxString& libname, bool *success = 0);
/*
This function unloads the shared library previously loaded with
Returns the pointer to the symbol or NULL on error.
*/
- static void * GetSymbol(wxDllType dllHandle, const wxString &name);
+ static void *GetSymbol(wxDllType dllHandle, const wxString &name, bool success = 0);
// return the standard DLL extension (with leading dot) for this platform
- static wxString GetDllExt();
+ static const wxString &GetDllExt() { return ms_dllext; }
private:
// forbid construction of objects
wxDllLoader();
+ static const wxString ms_dllext;
};
// ----------------------------------------------------------------------------
--- /dev/null
+/////////////////////////////////////////////////////////////////////////////
+// Name: dynload.h
+// Purpose: Dynamic loading framework
+// Author: Ron Lee, David Falkinder, Vadim Zeitlin and a cast of 1000's
+// (derived in part from dynlib.cpp (c) 1998 Guilhem Lavaux)
+// Modified by:
+// Created: 03/12/01
+// RCS-ID: $Id$
+// Copyright: (c) 2001 Ron Lee <ron@debian.org>
+// Licence: wxWindows license
+/////////////////////////////////////////////////////////////////////////////
+
+#ifndef _WX_DYNAMICLOADER_H__
+#define _WX_DYNAMICLOADER_H__
+
+#ifdef __GNUG__
+#pragma interface "dynload.h"
+#endif
+
+// ----------------------------------------------------------------------------
+// headers
+// ----------------------------------------------------------------------------
+
+#include "wx/defs.h"
+
+#if wxUSE_DYNAMIC_LOADER
+
+#include "wx/hash.h"
+#include "wx/module.h"
+
+
+// Ugh, I'd much rather this was typesafe, but no time
+// to rewrite wxHashTable right now..
+
+typedef wxHashTable wxDLManifest;
+typedef wxHashTable wxDLImports;
+
+// ----------------------------------------------------------------------------
+// conditional compilation
+// ----------------------------------------------------------------------------
+
+ // Note: WXPM/EMX has to be tested first, since we want to use
+ // native version, even if configure detected presence of DLOPEN.
+
+#if defined(__WXPM__) || defined(__EMX__)
+#define INCL_DOS
+#include <os2.h>
+ typedef HMODULE wxDllType;
+#elif defined(HAVE_DLOPEN)
+#include <dlfcn.h>
+ typedef void *wxDllType;
+#elif defined(HAVE_SHL_LOAD)
+#include <dl.h>
+ typedef shl_t wxDllType;
+#elif defined(__WINDOWS__)
+#include <windows.h> // needed to get HMODULE
+ typedef HMODULE wxDllType;
+#elif defined(__DARWIN__)
+ typedef void *wxDllType;
+#elif defined(__WXMAC__)
+ typedef CFragConnectionID wxDllType;
+#else
+#error "wxLibrary can't be compiled on this platform, sorry."
+#endif
+
+ // LoadLibrary is defined in windows.h as LoadLibraryA, but wxDllLoader
+ // method should be called LoadLibrary, not LoadLibraryA or LoadLibraryW!
+
+#if defined(__WIN32__) && defined(LoadLibrary)
+# include "wx/msw/winundef.h"
+#endif
+
+
+// ---------------------------------------------------------------------------
+// wxDllLoader
+// ---------------------------------------------------------------------------
+
+ // Cross platform wrapper for dlopen and friends.
+ // There are no instances of this class, it simply
+ // serves as a namespace for its static member functions.
+
+class WXDLLEXPORT wxDllLoader
+{
+public:
+
+ // libname may be either the full path to the file or just the filename
+ // in which case the library is searched for in all standard locations.
+ // The platform specific library extension is automatically appended.
+
+ static wxDllType Load(const wxString& name);
+
+ // The same as Load, except 'name' is searched for without modification.
+
+ static wxDllType LoadLibrary(const wxString& name);
+ static void UnloadLibrary(wxDllType dll);
+
+ // return a valid handle for the main program itself or NULL if
+ // back linking is not supported by the current platform (e.g. Win32)
+
+ static wxDllType GetProgramHandle();
+
+ // resolve a symbol in a loaded DLL, such as a variable or function
+ // name. dllHandle is a handle previously returned by LoadLibrary(),
+ // symbol is the (possibly mangled) name of the symbol.
+ // (use extern "C" to export unmangled names)
+ //
+ // Since it is perfectly valid for the returned symbol to actually be
+ // NULL, that is not always indication of an error. Pass and test the
+ // parameter 'success' for a true indication of success or failure to
+ // load the symbol.
+ //
+ // Returns a pointer to the symbol on success.
+
+ static void *GetSymbol(wxDllType dllHandle, const wxString &name, bool *success = 0);
+
+ // return the platform standard DLL extension (with leading dot)
+
+ static const wxString &GetDllExt() { return ms_dllext; }
+
+private:
+
+ wxDllLoader(); // forbid construction of objects
+ static const wxString ms_dllext; // Platform specific shared lib suffix.
+};
+
+
+// ---------------------------------------------------------------------------
+// wxDynamicLibrary
+// ---------------------------------------------------------------------------
+
+class wxDLManifestEntry
+{
+public:
+
+ static wxDLImports ms_classes; // Static hash of all imported classes.
+
+ wxDLManifestEntry( const wxString &libname );
+ ~wxDLManifestEntry();
+
+ wxDLManifestEntry *Ref() { ++m_count; return this; }
+ bool Unref() { return (m_count-- < 2) ? (delete this, TRUE) : FALSE; }
+
+ bool IsLoaded() const { return m_count > 0; }
+
+ wxDllType GetLinkHandle() const { return m_handle; }
+ wxDllType GetProgramHandle() const { return wxDllLoader::GetProgramHandle(); }
+ void *GetSymbol(const wxString &symbol, bool *success = 0)
+ {
+ return wxDllLoader::GetSymbol( m_handle, symbol, success );
+ }
+
+private:
+
+ // Order of these three *is* important, do not change it
+
+ wxClassInfo *m_before; // sm_first before loading this lib
+ wxDllType m_handle; // Handle from dlopen.
+ wxClassInfo *m_after; // ..and after.
+
+ size_t m_count; // Ref count of Link and Create calls.
+ wxModuleList m_wxmodules; // any wxModules that we initialised.
+
+ void UpdateClassInfo(); // Update the wxClassInfo table
+ void RestoreClassInfo(); // Restore the original wxClassInfo state.
+ void RegisterModules(); // Init any wxModules in the lib.
+ void UnregisterModules(); // Cleanup any wxModules we installed.
+
+DECLARE_NO_COPY_CLASS(wxDLManifestEntry)
+};
+
+
+class WXDLLEXPORT wxDynamicLibrary
+{
+public:
+
+ // Static accessors.
+
+ static wxDLManifestEntry *Link(const wxString &libname);
+ static bool Unlink(const wxString &libname);
+
+ // Instance methods.
+
+ wxDynamicLibrary(const wxString &libname);
+ ~wxDynamicLibrary();
+
+ bool IsLoaded() const { return m_entry && m_entry->IsLoaded(); }
+ void *GetSymbol(const wxString &symbol, bool *success = 0)
+ {
+ return m_entry->GetSymbol( symbol, success );
+ }
+
+private:
+
+ static wxDLManifest ms_manifest; // Static hash of loaded libs.
+ wxDLManifestEntry *m_entry; // Cache our entry in the manifest.
+
+ // We could allow this class to be copied if we really
+ // wanted to, but not without modification.
+
+DECLARE_NO_COPY_CLASS(wxDynamicLibrary)
+};
+
+
+#endif // wxUSE_DYNAMIC_LOADER
+#endif // _WX_DYNAMICLOADER_H__
+
+// vi:sts=4:sw=4:et
class WXDLLEXPORT wxFileConfigGroup;
class WXDLLEXPORT wxFileConfigEntry;
class WXDLLEXPORT wxFileConfigLineList;
+class WXDLLEXPORT wxInputStream;
class WXDLLEXPORT wxFileConfig : public wxConfigBase
{
* Use streams
*/
#define wxUSE_STREAMS 1
-/*
- * Use class serialization
- */
-#define wxUSE_SERIAL 1
/*
* Use sockets
*/
* streams implementation.
*/
#define wxUSE_STD_IOSTREAM 0
-/*
- * wxLibrary class
- */
-#define wxUSE_DYNLIB_CLASS 1
/*
* Use font metric files in GetTextExtent for wxPostScriptDC
*/
#define wxUSE_SPLINES 1
/*
- * Use wxLibrary class
+ * Use wxObjectLoader class
*/
-#define wxUSE_DYNLIB_CLASS 1
+#define wxUSE_DYNAMIC_LOADER 1
/*
* Use the mdi architecture
* Use streams
*/
#define wxUSE_STREAMS 1
-/*
- * Use class serialization
- */
-#define wxUSE_SERIAL 1
/*
* Use sockets
*/
* streams implementation.
*/
#define wxUSE_STD_IOSTREAM 0
-/*
- * wxLibrary class
- */
-#define wxUSE_DYNLIB_CLASS 1
/*
* Use font metric files in GetTextExtent for wxPostScriptDC
*/
#define wxUSE_SPLINES 1
/*
- * Use wxLibrary class
+ * Use wxObjectLoader class
*/
-#define wxUSE_DYNLIB_CLASS 1
+#define wxUSE_DYNAMIC_LOADER 1
/*
* Use the mdi architecture
#define WX_DECLARE_EXPORTED_HASH(el, list, hash) \
_WX_DECLARE_HASH(el, list, hash, class WXDLLEXPORT)
+#define WX_DECLARE_USER_EXPORTED_HASH(el, list, hash, usergoo) \
+ _WX_DECLARE_HASH(el, list, hash, class usergoo)
+
#endif
// _WX_HASH_H__
typedef elementtype _WX_LIST_ITEM_TYPE_##listname; \
WX_DECLARE_LIST_2(elementtype, listname, wx##listname##Node, class WXDLLEXPORT)
+#define WX_DECLARE_USER_EXPORTED_LIST(elementtype, listname, usergoo) \
+ typedef elementtype _WX_LIST_ITEM_TYPE_##listname; \
+ WX_DECLARE_LIST_2(elementtype, listname, wx##listname##Node, class usergoo)
+
// this macro must be inserted in your program after
// #include <wx/listimpl.cpp>
#define WX_DEFINE_LIST(name) "don't forget to include listimpl.cpp!"
+#define WX_DEFINE_EXPORTED_LIST(name) WX_DEFINE_LIST(name)
+#define WX_DEFINE_USER_EXPORTED_LIST(name) WX_DEFINE_LIST(name)
+
+
// =============================================================================
// now we can define classes 100% compatible with the old ones
// =============================================================================
wxModule() {}
virtual ~wxModule() {}
- // if module init routine returns FALSE application will fail to startup
+ // if module init routine returns FALSE application
+ // will fail to startup
+
bool Init() { return OnInit(); }
void Exit() { OnExit(); }
- // Override both of these
+ // Override both of these
// called on program startup
+
virtual bool OnInit() = 0;
- // called just before program termination, but only if OnInit()
+
+ // called just before program termination, but only if OnInit()
// succeeded
+
virtual void OnExit() = 0;
static void RegisterModule(wxModule* module);
static bool InitializeModules();
static void CleanUpModules();
+ // used by wxObjectLoader when unloading shared libs's
+
+ static void UnregisterModule(wxModule* module);
+
protected:
static wxModuleList m_modules;
// Use standard C++ streams if 1. If 0, use wxWin streams implementation.
#define wxUSE_STD_IOSTREAM 0
-// Use serialization (requires utils/serialize)
-#define wxUSE_SERIAL 0
-
// ----------------------------------------------------------------------------
// non GUI features selection
// ----------------------------------------------------------------------------
// If wxUSE_DIALUP_MANAGER is 1, compile in wxDialUpManager class which allows
// to connect/disconnect from the network and be notified whenever the dial-up
-// network connection is established/terminated. Requires wxUSE_DYNLIB_CLASS.
+// network connection is established/terminated. Requires wxUSE_DYNAMIC_LOADER.
//
// Default is 1.
//
// Recommended setting: 1
#define wxUSE_DIALUP_MANAGER 1
-// Compile in wxLibrary class for run-time DLL loading and function calling.
+// Compile in classes for run-time DLL loading and function calling.
// Required by wxUSE_DIALUP_MANAGER.
//
// This setting is for Win32 only
// Default is 1.
//
// Recommended setting: 1
-#define wxUSE_DYNLIB_CLASS 1
+#define wxUSE_DYNAMIC_LOADER 1
// Set to 1 to use socket classes
#define wxUSE_SOCKETS 1
// Name: object.h
// Purpose: wxObject class, plus run-time type information macros
// Author: Julian Smart
-// Modified by:
+// Modified by: Ron Lee
// Created: 01/02/97
// RCS-ID: $Id$
-// Copyright: (c) Julian Smart and Markus Holzem
+// Copyright: (c) 1997 Julian Smart and Markus Holzem
+// (c) 2001 Ron Lee <ron@debian.org>
// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
#pragma interface "object.h"
#endif
+// ----------------------------------------------------------------------------
+// headers
+// ----------------------------------------------------------------------------
+
#include "wx/defs.h"
#include "wx/memory.h"
#if wxUSE_DYNAMIC_CLASSES
-// #ifdef __GNUWIN32__
+// ----------------------------------------------------------------------------
+// conditional compilation
+// ----------------------------------------------------------------------------
+
#ifdef GetClassName
#undef GetClassName
#endif
#ifdef GetClassInfo
#undef GetClassInfo
#endif
-// #endif
class WXDLLEXPORT wxClassInfo;
-class WXDLLEXPORT wxInputStream;
-class WXDLLEXPORT wxOutputStream;
-class WXDLLEXPORT wxObjectInputStream;
-class WXDLLEXPORT wxObjectOutputStream;
class WXDLLEXPORT wxHashTable;
-class WXDLLEXPORT wxObject_Serialize;
#if wxUSE_STD_IOSTREAM && (defined(__WXDEBUG__) || wxUSE_DEBUG_CONTEXT)
- #include "wx/ioswrap.h"
+#include "wx/ioswrap.h"
#endif
-/*
- * Dynamic object system declarations
- */
-typedef wxObject * (*wxObjectConstructorFn) (void);
+// ----------------------------------------------------------------------------
+// wxClassInfo
+// ----------------------------------------------------------------------------
+
+typedef wxObject *(*wxObjectConstructorFn)(void);
class WXDLLEXPORT wxClassInfo
{
public:
- wxClassInfo(const wxChar *cName,
- const wxChar *baseName1,
- const wxChar *baseName2,
- int sz,
- wxObjectConstructorFn fn);
-
- wxObject *CreateObject(void);
+ wxClassInfo::wxClassInfo(const wxChar *className,
+ const wxChar *baseName1,
+ const wxChar *baseName2,
+ int size,
+ wxObjectConstructorFn ctor)
+ : m_className(className)
+ , m_baseClassName1(baseName1)
+ , m_baseClassName2(baseName2)
+ , m_objectSize(size)
+ , m_objectConstructor(ctor)
+ , m_baseInfo1(0)
+ , m_baseInfo2(0)
+ , m_next(sm_first)
+ { sm_first = this; }
+
+ wxObject *CreateObject() { return m_objectConstructor ? (*m_objectConstructor)() : 0; }
+
+ const wxChar *GetClassName() const { return m_className; }
+ const wxChar *GetBaseClassName1() const { return m_baseClassName1; }
+ const wxChar *GetBaseClassName2() const { return m_baseClassName2; }
+ const wxClassInfo *GetBaseClass1() const { return m_baseInfo1; }
+ const wxClassInfo *GetBaseClass2() const { return m_baseInfo2; }
+ int GetSize() const { return m_objectSize; }
+
+ wxObjectConstructorFn GetConstructor() const { return m_objectConstructor; }
+ static const wxClassInfo *GetFirst() { return sm_first; }
+ const wxClassInfo *GetNext() const { return m_next; }
+ static wxClassInfo *FindClass(const wxChar *className);
+
+ // Climb upwards through inheritance hierarchy.
+ // Dual inheritance is catered for.
+
+ bool IsKindOf(const wxClassInfo *info) const
+ {
+ return info != 0 &&
+ ( info == this ||
+ ( m_baseInfo1 && m_baseInfo1->IsKindOf(info) ) ||
+ ( m_baseInfo2 && m_baseInfo2->IsKindOf(info) ) );
+ }
- const wxChar *GetClassName() const { return m_className; }
- const wxChar *GetBaseClassName1() const { return m_baseClassName1; }
- const wxChar *GetBaseClassName2() const { return m_baseClassName2; }
- const wxClassInfo* GetBaseClass1() const { return m_baseInfo1; }
- const wxClassInfo* GetBaseClass2() const { return m_baseInfo2; }
- int GetSize() const { return m_objectSize; }
- wxObjectConstructorFn GetConstructor() const { return m_objectConstructor; }
- static const wxClassInfo* GetFirst() { return sm_first; }
- const wxClassInfo* GetNext() const { return m_next; }
- bool IsKindOf(const wxClassInfo *info) const;
+ // Initializes parent pointers and hash table for fast searching.
- static wxClassInfo *FindClass(const wxChar *c);
+ static void InitializeClasses();
- // Initializes parent pointers and hash table for fast searching.
- static void InitializeClasses();
+ // Cleans up hash table used for fast searching.
- // Cleans up hash table used for fast searching.
- static void CleanUpClasses();
+ static void CleanUpClasses();
public:
- const wxChar* m_className;
- const wxChar* m_baseClassName1;
- const wxChar* m_baseClassName2;
- int m_objectSize;
- wxObjectConstructorFn m_objectConstructor;
-
- // Pointers to base wxClassInfos: set in InitializeClasses
- const wxClassInfo* m_baseInfo1;
- const wxClassInfo* m_baseInfo2;
-
- // class info object live in a linked list: pointers to its head and the
- // next element in it
- static wxClassInfo* sm_first;
- wxClassInfo* m_next;
-
- static wxHashTable* sm_classTable;
+ const wxChar *m_className;
+ const wxChar *m_baseClassName1;
+ const wxChar *m_baseClassName2;
+ int m_objectSize;
+ wxObjectConstructorFn m_objectConstructor;
+
+ // Pointers to base wxClassInfos: set in InitializeClasses
+
+ const wxClassInfo *m_baseInfo1;
+ const wxClassInfo *m_baseInfo2;
+
+ // class info object live in a linked list:
+ // pointers to its head and the next element in it
+
+ static wxClassInfo *sm_first;
+ wxClassInfo *m_next;
+
+ static wxHashTable *sm_classTable;
};
-WXDLLEXPORT wxObject* wxCreateDynamicObject(const wxChar *name);
+WXDLLEXPORT wxObject *wxCreateDynamicObject(const wxChar *name);
-#if wxUSE_SERIAL
-WXDLLEXPORT wxObject* wxCreateStoredObject( wxInputStream& stream );
-#endif
-#define DECLARE_DYNAMIC_CLASS(name) \
- public:\
- static wxClassInfo sm_class##name;\
- wxClassInfo *GetClassInfo() const \
+// ----------------------------------------------------------------------------
+// Dynamic class macros
+// ----------------------------------------------------------------------------
+
+#define DECLARE_DYNAMIC_CLASS(name) \
+ public: \
+ static wxClassInfo sm_class##name; \
+ virtual wxClassInfo *GetClassInfo() const \
{ return &name::sm_class##name; }
#define DECLARE_ABSTRACT_CLASS(name) DECLARE_DYNAMIC_CLASS(name)
#define DECLARE_CLASS(name) DECLARE_DYNAMIC_CLASS(name)
-//////
-////// for concrete classes
-//////
+// -----------------------------------
+// for concrete classes
+// -----------------------------------
+
+ // Single inheritance with one base class
-// Single inheritance with one base class
-#define IMPLEMENT_DYNAMIC_CLASS(name, basename) \
-wxObject* WXDLLEXPORT_CTORFN wxConstructorFor##name(void) \
- { return new name; }\
- wxClassInfo name::sm_class##name((wxChar *) wxT(#name), (wxChar *) wxT(#basename), (wxChar *) NULL, (int) sizeof(name), (wxObjectConstructorFn) wxConstructorFor##name);
+#define IMPLEMENT_DYNAMIC_CLASS(name, basename) \
+ wxObject* WXDLLEXPORT_CTORFN wxConstructorFor##name() \
+ { return new name; } \
+ wxClassInfo name::sm_class##name(wxT(#name), wxT(#basename), \
+ 0, (int) sizeof(name), \
+ (wxObjectConstructorFn) wxConstructorFor##name);
-// Multiple inheritance with two base classes
-#define IMPLEMENT_DYNAMIC_CLASS2(name, basename1, basename2) \
-wxObject* WXDLLEXPORT_CTORFN wxConstructorFor##name(void) \
- { return new name; }\
- wxClassInfo name::sm_class##name((wxChar *) wxT(#name), (wxChar *) wxT(#basename1), (wxChar *) wxT(#basename2), (int) sizeof(name), (wxObjectConstructorFn) wxConstructorFor##name);
+ // Multiple inheritance with two base classes
-//////
-////// for abstract classes
-//////
+#define IMPLEMENT_DYNAMIC_CLASS2(name, basename1, basename2) \
+ wxObject* WXDLLEXPORT_CTORFN wxConstructorFor##name() \
+ { return new name; } \
+ wxClassInfo name::sm_class##name(wxT(#name), wxT(#basename1), \
+ wxT(#basename2), (int) sizeof(name), \
+ (wxObjectConstructorFn) wxConstructorFor##name);
-// Single inheritance with one base class
-#define IMPLEMENT_ABSTRACT_CLASS(name, basename) \
- wxClassInfo name::sm_class##name((wxChar *) wxT(#name), (wxChar *) wxT(#basename), \
- (wxChar *) NULL, (int) sizeof(name), (wxObjectConstructorFn) NULL);
+// -----------------------------------
+// for abstract classes
+// -----------------------------------
-// Multiple inheritance with two base classes
-#define IMPLEMENT_ABSTRACT_CLASS2(name, basename1, basename2) \
- wxClassInfo name::sm_class##name((wxChar *) wxT(#name), (wxChar *) wxT(#basename1), \
- (wxChar *) wxT(#basename2), (int) sizeof(name), (wxObjectConstructorFn) NULL);
+ // Single inheritance with one base class
+
+#define IMPLEMENT_ABSTRACT_CLASS(name, basename) \
+ wxClassInfo name::sm_class##name(wxT(#name), wxT(#basename), \
+ 0, (int) sizeof(name), (wxObjectConstructorFn) 0);
+
+ // Multiple inheritance with two base classes
+
+#define IMPLEMENT_ABSTRACT_CLASS2(name, basename1, basename2) \
+ wxClassInfo name::sm_class##name(wxT(#name), wxT(#basename1), \
+ wxT(#basename2), (int) sizeof(name), \
+ (wxObjectConstructorFn) 0);
#define IMPLEMENT_CLASS IMPLEMENT_ABSTRACT_CLASS
#define IMPLEMENT_CLASS2 IMPLEMENT_ABSTRACT_CLASS2
+// -----------------------------------
+// for pluggable classes
+// -----------------------------------
+
+ // NOTE: this should probably be the very first statement
+ // in the class declaration so wxPluginSentinel is
+ // the first member initialised and the last destroyed.
+
+// _DECLARE_DL_SENTINEL(name) wxPluginSentinel m_pluginsentinel;
+
+#if wxUSE_NESTED_CLASSES
+
+#if 0
+#define _DECLARE_DL_SENTINEL(name) \
+ wxPluginSentinel m_pluginsentinel;
+
+#else
+
+#define _DECLARE_DL_SENTINEL(name) \
+class name##PluginSentinel { \
+private: \
+ static const wxString sm_className; \
+public: \
+ name##PluginSentinel(); \
+ ~##name##PluginSentinel(); \
+}; \
+name##PluginSentinel m_pluginsentinel;
+#endif
+
+#define _IMPLEMENT_DL_SENTINEL(name) \
+ const wxString name::name##PluginSentinel::sm_className(#name); \
+ name::name##PluginSentinel::name##PluginSentinel() { \
+ wxDLManifestEntry *e = (wxDLManifestEntry*) wxDLManifestEntry::ms_classes.Get(#name); \
+ if( e != 0 ) { e->Ref(); } \
+ } \
+ name::name##PluginSentinel::~##name##PluginSentinel() { \
+ wxDLManifestEntry *e = (wxDLManifestEntry*) wxDLManifestEntry::ms_classes.Get(#name); \
+ if( e != 0 ) { wxCHECK_RET( !e->Unref(), _T("premature library unlinking") ); } \
+ }
+#else
+
+#define _DECLARE_DL_SENTINEL(name)
+#define _IMPLEMENT_DL_SENTINEL(name)
+
+#endif // wxUSE_NESTED_CLASSES
+
+#define DECLARE_PLUGGABLE_CLASS(name) \
+ DECLARE_DYNAMIC_CLASS(name) _DECLARE_DL_SENTINEL(name)
+
+#define DECLARE_ABSTRACT_PLUGGABLE_CLASS(name) \
+ DECLARE_ABSTRACT_CLASS(name) _DECLARE_DL_SENTINEL(name)
+
+#define IMPLEMENT_PLUGGABLE_CLASS(name, basename) \
+ IMPLEMENT_DYNAMIC_CLASS(name, basename) _IMPLEMENT_DL_SENTINEL(name)
+#define IMPLEMENT_PLUGGABLE_CLASS2(name, basename1, basename2) \
+ IMPLEMENT_DYNAMIC_CLASS2(name, basename1, basename2) _IMPLEMENT_DL_SENTINEL(name)
+
+#define IMPLEMENT_ABSTRACT_PLUGGABLE_CLASS(name, basename) \
+ IMPLEMENT_ABSTRACT_CLASS(name, basename) _IMPLEMENT_DL_SENTINEL(name)
+#define IMPLEMENT_ABSTRACT_PLUGGABLE_CLASS2(name, basename1, basename2) \
+ IMPLEMENT_ABSTRACT_CLASS2(name, basename1, basename2) _IMPLEMENT_DL_SENTINEL(name)
+
+
#define CLASSINFO(name) (&name::sm_class##name)
#else // !wxUSE_DYNAMIC_CLASSES
-// No dynamic class system: so stub out the macros
+ // No dynamic class system: so stub out the macros
+
#define DECLARE_DYNAMIC_CLASS(name)
#define DECLARE_ABSTRACT_CLASS(name)
#define DECLARE_CLASS(name)
#define IMPLEMENT_CLASS IMPLEMENT_ABSTRACT_CLASS
#define IMPLEMENT_CLASS2 IMPLEMENT_ABSTRACT_CLASS2
-#endif // wxUSE_DYNAMIC_CLASSES/!wxUSE_DYNAMIC_CLASSES
+#define DECLARE_PLUGGABLE_CLASS(name)
+#define DECLARE_ABSTRACT_PLUGGABLE_CLASS(name)
+#define IMPLEMENT_PLUGGABLE_CLASS(name, basename)
+#define IMPLEMENT_PLUGGABLE_CLASS2(name, basename1, basename2)
+#define IMPLEMENT_ABSTRACT_PLUGGABLE_CLASS(name, basename)
+#define IMPLEMENT_ABSTRACT_PLUGGABLE_CLASS2(name, basename1, basename2)
+
+#endif // wxUSE_DYNAMIC_CLASSES
+
#define wxIS_KIND_OF(obj, className) obj->IsKindOf(&className::sm_class##className)
-// Just seems a bit nicer-looking (pretend it's not a macro)
+ // Just seems a bit nicer-looking (pretend it's not a macro)
+
#define wxIsKindOf(obj, className) obj->IsKindOf(&className::sm_class##className)
-// to be replaced by dynamic_cast<> in the future
+ // to be replaced by dynamic_cast<> in the future
+
#define wxDynamicCast(obj, className) \
- (className *) wxCheckDynamicCast((wxObject*)(obj), &className::sm_class##className)
+ (className *) wxCheckDynamicCast((wxObject*)(obj), &className::sm_class##className)
+
+ // The 'this' pointer is always true, so use this version
+ // to cast the this pointer and avoid compiler warnings.
-// The 'this' pointer is always true, so use this version to cast the this
-// pointer and avoid compiler warnings.
#define wxDynamicCastThis(className) \
- (IsKindOf(&className::sm_class##className) \
- ? (className *)(this) \
- : (className *)0)
+ (IsKindOf(&className::sm_class##className) ? (className *)(this) : (className *)0)
#define wxConstCast(obj, className) ((className *)(obj))
+
#ifdef __WXDEBUG__
- inline void wxCheckCast(void *ptr)
- {
- wxASSERT_MSG( ptr, _T("wxStaticCast() used incorrectly") );
- }
+inline void wxCheckCast(void *ptr)
+{
+ wxASSERT_MSG( ptr, _T("wxStaticCast() used incorrectly") );
+}
+#define wxStaticCast(obj, className) \
+ (wxCheckCast(wxDynamicCast(obj, className)), ((className *)(obj)))
- #define wxStaticCast(obj, className) \
- (wxCheckCast(wxDynamicCast(obj, className)), ((className *)(obj)))
+#else // !__WXDEBUG__
+#define wxStaticCast(obj, className) ((className *)(obj))
-#else // !Debug
- #define wxStaticCast(obj, className) ((className *)(obj))
-#endif // Debug/!Debug
+#endif // __WXDEBUG__
-// Unfortunately Borland seems to need this include.
-#if wxUSE_STD_IOSTREAM && (defined(__WXDEBUG__) || wxUSE_DEBUG_CONTEXT)
-#ifdef __BORLANDC__
- #if wxUSE_IOSTREAMH
- #include <iostream.h>
- #else
- #include <iostream>
- #endif
+
+ // Unfortunately Borland seems to need this include.
+
+#if wxUSE_STD_IOSTREAM \
+ && (defined(__WXDEBUG__) || wxUSE_DEBUG_CONTEXT) \
+ && defined(__BORLANDC__)
+#if wxUSE_IOSTREAMH
+#include <iostream.h>
+#else
+#include <iostream>
#endif
#endif
+
+// ----------------------------------------------------------------------------
+// wxObject
+// ----------------------------------------------------------------------------
+
class WXDLLEXPORT wxObjectRefData;
class WXDLLEXPORT wxObject
{
- public:
-
- // This is equivalent to using the macro DECLARE_ABSTRACT_CLASS
- static wxClassInfo sm_classwxObject;
-
- wxObject(void);
- virtual ~wxObject(void);
+DECLARE_ABSTRACT_CLASS(wxObject)
- virtual wxClassInfo *GetClassInfo(void) const { return &sm_classwxObject; }
+public:
+ wxObject() : m_refData(0) {}
+ virtual ~wxObject() { UnRef(); }
- bool IsKindOf(wxClassInfo *info) const;
+ bool IsKindOf(wxClassInfo *info) const;
#if defined(__WXDEBUG__) && wxUSE_MEMORY_TRACING
- void * operator new (size_t size, wxChar * fileName = NULL, int lineNum = 0);
-# if defined(__VISAGECPP__)
-# if __DEBUG_ALLOC__
- void operator delete (void * buf,const char * _fname, size_t _line);
-# endif //__DEBUG_ALLOC__
-# else // Everybody else
+ void *operator new (size_t size, wxChar *fileName = 0, int lineNum = 0);
+
+#ifndef __VISAGECPP__
void operator delete (void * buf);
-# endif // end of VISAGECPP
+#elif __DEBUG_ALLOC__
+ void operator delete (void *buf, const char *_fname, size_t _line);
+#endif
-// VC++ 6.0
-# if defined(__VISUALC__) && (__VISUALC__ >= 1200)
+ // VC++ 6.0
+
+#if defined(__VISUALC__) && (__VISUALC__ >= 1200)
void operator delete(void *buf, wxChar*, int);
-# endif
+#endif
// Causes problems for VC++
-# if wxUSE_ARRAY_MEMORY_OPERATORS && !defined(__VISUALC__) && !defined( __MWERKS__)
- void * operator new[] (size_t size, wxChar * fileName = NULL, int lineNum = 0);
- void operator delete[] (void * buf);
-# endif
-# ifdef __MWERKS__
- void * operator new[] (size_t size, wxChar * fileName , int lineNum = 0);
- void * operator new[] (size_t size) { return operator new[] ( size , NULL , 0 ) ; }
- void operator delete[] (void * buf);
-# endif
+#if wxUSE_ARRAY_MEMORY_OPERATORS && !defined(__VISUALC__) && !defined( __MWERKS__)
+ void *operator new[] (size_t size, wxChar *fileName = 0, int lineNum = 0);
+ void operator delete[] (void *buf);
+#endif
+
+#ifdef __MWERKS__
+ void *operator new[] (size_t size, wxChar *fileName , int lineNum = 0);
+ void *operator new[] (size_t size) { return operator new[] ( size, 0, 0 ) ; }
+ void operator delete[] (void *buf);
+#endif
#endif // Debug & memory tracing
-#if wxUSE_STD_IOSTREAM && (defined(__WXDEBUG__) || wxUSE_DEBUG_CONTEXT)
- virtual void Dump(wxSTD ostream& str);
-#endif
-#if wxUSE_SERIAL
- virtual void StoreObject( wxObjectOutputStream &stream );
- virtual void LoadObject( wxObjectInputStream &stream );
+#if wxUSE_STD_IOSTREAM && (defined(__WXDEBUG__) || wxUSE_DEBUG_CONTEXT)
+ virtual void Dump(wxSTD ostream& str);
#endif
- // make a 'clone' of the object
- void Ref(const wxObject& clone);
+ // make a 'clone' of the object
+
+ void Ref(const wxObject& clone);
- // destroy a reference
- void UnRef(void);
+ // destroy a reference
+
+ void UnRef();
- inline wxObjectRefData *GetRefData(void) const { return m_refData; }
- inline void SetRefData(wxObjectRefData *data) { m_refData = data; }
+ inline wxObjectRefData *GetRefData() const { return m_refData; }
+ inline void SetRefData(wxObjectRefData *data) { m_refData = data; }
protected:
- wxObjectRefData* m_refData;
-#if wxUSE_SERIAL
- wxObject_Serialize* m_serialObj;
-#endif
+ wxObjectRefData *m_refData;
};
-/*
- * wxObjectData
- */
-
-class WXDLLEXPORT wxObjectRefData {
+class WXDLLEXPORT wxObjectRefData
+{
friend class wxObject;
public:
- wxObjectRefData(void);
- virtual ~wxObjectRefData(void);
+ wxObjectRefData() : m_count(1) {}
+ virtual ~wxObjectRefData() {}
- inline int GetRefCount(void) const { return m_count; }
+ inline int GetRefCount() const { return m_count; }
private:
int m_count;
};
+
inline wxObject *wxCheckDynamicCast(wxObject *obj, wxClassInfo *classInfo)
{
return obj && obj->GetClassInfo()->IsKindOf(classInfo) ? obj : 0;
#define WXDEBUG_NEW new
#endif
-// Redefine new to be the debugging version. This doesn't
-// work with all compilers, in which case you need to
-// use WXDEBUG_NEW explicitly if you wish to use the debugging version.
+ // Redefine new to be the debugging version. This doesn't
+ // work with all compilers, in which case you need to
+ // use WXDEBUG_NEW explicitly if you wish to use the debugging version.
#if defined(__WXDEBUG__) && wxUSE_GLOBAL_MEMORY_OPERATORS && wxUSE_DEBUG_NEW_ALWAYS
#define new new(__TFILE__,__LINE__)
#endif
-#endif
- // _WX_OBJECTH__
-
+#endif // _WX_OBJECTH__
+// vi:sts=4:sw=4:et
+++ /dev/null
-/////////////////////////////////////////////////////////////////////////////
-// Name: objstrm.h
-// Purpose: wxObjectStream classes
-// Author: Guilhem Lavaux
-// Modified by:
-// Created: 16/07/98
-// RCS-ID: $Id$
-// Copyright: (c) 1998 Guilhem Lavaux
-// Licence: wxWindows license
-/////////////////////////////////////////////////////////////////////////////
-#ifndef _WX_WXOBJSTRM_H__
-#define _WX_WXOBJSTRM_H__
-
-#ifdef __GNUG__
-#pragma interface
-#endif
-
-#include "wx/defs.h"
-
-#if wxUSE_STREAMS && wxUSE_SERIAL
-
-#include "wx/object.h"
-#include "wx/string.h"
-#include "wx/stream.h"
-
-class wxObjectStreamInfo : public wxObject {
- public:
- wxString object_name;
- int n_children, children_removed;
- wxList children;
- wxObjectStreamInfo *parent;
- wxObject *object;
- bool duplicate, recall;
-};
-
-class wxObjectOutputStream : public wxFilterOutputStream {
- public:
- wxObjectOutputStream(wxOutputStream& s);
-
- void AddChild(wxObject *obj);
- bool SaveObject(wxObject& obj);
-
- bool FirstStage() const { return m_stage == 0; }
-
- wxString GetObjectName(wxObject *obj);
-
- protected:
- void WriteObjectDef(wxObjectStreamInfo& info);
- void ProcessObjectDef(wxObjectStreamInfo *info);
- void ProcessObjectData(wxObjectStreamInfo *info);
-
- protected:
- int m_stage;
- bool m_saving;
- wxObjectStreamInfo *m_current_info;
- wxList m_saved_objs;
-};
-
-class wxObjectInputStream : public wxFilterInputStream {
- public:
- wxObjectInputStream(wxInputStream& s);
-
- bool SecondCall() const { return m_secondcall; }
- void Recall(bool on = TRUE) { m_current_info->recall = on; }
-
- wxObject *GetChild(int no) const;
- wxObject *GetChild();
- int NumberOfChildren() const { return m_current_info->n_children; }
- void RemoveChildren(int nb);
- wxObject *GetParent() const;
- wxObject *LoadObject();
-
- wxObject *SolveName(const wxString& objName) const;
-
- protected:
- bool ReadObjectDef(wxObjectStreamInfo *info);
- wxObjectStreamInfo *ProcessObjectDef(wxObjectStreamInfo *info);
- void ProcessObjectData(wxObjectStreamInfo *info);
-
- protected:
- bool m_secondcall;
- wxObjectStreamInfo *m_current_info;
- wxList m_solver;
-};
-
-#endif
- // wxUSE_STREAMS && wxUSE_SERIAL
-
-#endif
-// _WX_WXOBJSTRM_H__
#undef FindResource
#endif
+class WXDLLEXPORT wxInputStream;
+
/*
* Internal format for control/panel item
*/
virtual bool DeleteResource(const wxString& name);
virtual bool ParseResourceFile(const wxString& filename);
- virtual bool ParseResourceFile( wxInputStream *is ) ;
+ virtual bool ParseResourceFile(wxInputStream *is);
virtual bool ParseResourceData(const wxString& data);
virtual bool SaveResource(const wxString& filename);
+++ /dev/null
-/////////////////////////////////////////////////////////////////////////////
-// Name: serbase.h
-// Purpose: Serialization plug-ins
-// Author: Guilhem Lavaux
-// Modified by:
-// Created: July 1998
-// RCS-ID: $Id$
-// Copyright: (c) Guilhem Lavaux
-// Licence: wxWindows license
-/////////////////////////////////////////////////////////////////////////////
-#ifndef _WX_WX_SERBASEH_H__
-#define _WX_WX_SERBASEH_H__
-
-#include "wx/setup.h"
-#include "wx/dynlib.h"
-
-#define WXSERIAL(classname) classname##_Serialize
-
-#if wxUSE_SERIAL
-class wxObject_Serialize : public wxObject {
- DECLARE_DYNAMIC_CLASS(wxObject_Serialize)
- public:
- wxObject_Serialize() {}
- virtual ~wxObject_Serialize() {}
-
- void SetObject(wxObject *obj) { m_object = obj; }
- wxObject *Object() { return m_object; }
-
- protected:
- wxObject *m_object;
-};
-#endif
- // wxUSE_SERIAL
-
-
-#define DECLARE_SERIAL_CLASS(classname, parent) \
-class WXSERIAL(classname) : public WXSERIAL(parent) { \
- DECLARE_DYNAMIC_CLASS(classname##_Serialize) \
- public: \
- WXSERIAL(classname)() { } \
- virtual ~WXSERIAL(classname)() { } \
-\
- virtual void StoreObject(wxObjectOutputStream& stream); \
- virtual void LoadObject(wxObjectInputStream& stream); \
-};
-
-#define DECLARE_ALIAS_SERIAL_CLASS(classname, parent) \
-class WXSERIAL(classname) : public WXSERIAL(parent) { \
- DECLARE_DYNAMIC_CLASS(classname##_Serialize) \
- public: \
- WXSERIAL(classname)() { } \
- virtual ~WXSERIAL(classname)() { } \
-};
-
-#define IMPLEMENT_SERIAL_CLASS(classname, parent) \
-IMPLEMENT_DYNAMIC_CLASS(classname##_Serialize, parent##_Serialize)
-
-#define IMPLEMENT_ALIAS_SERIAL_CLASS(classname, parent) \
-IMPLEMENT_DYNAMIC_CLASS(classname##_Serialize, parent##_Serialize)
-
-#if wxUSE_SERIAL
-DECLARE_SERIAL_CLASS(wxList, wxObject)
-DECLARE_SERIAL_CLASS(wxHashTable, wxObject)
-#endif
- // wxUSE_SERIAL
-
-#endif
// Operators
wxInputStream& operator>>(wxOutputStream& out) { return Read(out); }
-#if wxUSE_SERIAL
- wxInputStream& operator>>(wxObject *& obj);
-#endif
wxInputStream& operator>>( __wxInputManip func) { return func(*this); }
protected:
virtual void Sync();
wxOutputStream& operator<<(wxInputStream& out) { return Write(out); }
-#if wxUSE_SERIAL
- wxOutputStream& operator<<(wxObject& obj);
-#endif
wxOutputStream& operator<<( __wxOutputManip func) { return func(*this); }
protected:
* Use streams
*/
#define wxUSE_STREAMS 0
-/*
- * Use class serialization
- */
-#define wxUSE_SERIAL 0
/*
* Use sockets
*/
* wxLibrary class
*/
#define wxUSE_DYNLIB_CLASS 0
+/*
+ * Use wxObjectLoader
+ */
+#define wxUSE_DYNAMIC_LOADER 0
/*
* Use wxTimer
#include "wx/filefn.h"
#include "wx/intl.h"
#include "wx/log.h"
-#include "wx/tokenzr.h"
// ----------------------------------------------------------------------------
// conditional compilation
# define wxDllOpen(lib) shl_load(lib.fn_str(), BIND_DEFERRED, 0)
# define wxDllClose shl_unload
- static inline void *wxDllGetSymbol(shl_t handle, const wxString& name)
- {
- void *sym;
- if ( shl_findsym(&handle, name.mb_str(), TYPE_UNDEFINED, &sym) == 0 )
- return sym;
- else
- return (void *)0;
- }
+static inline void *wxDllGetSymbol(shl_t handle, const wxString& name)
+{
+ void *sym;
+ if ( shl_findsym(&handle, name.mb_str(), TYPE_UNDEFINED, &sym) == 0 )
+ return sym;
+ else
+ return 0;
+}
+
#elif defined(__DARWIN__)
/* Porting notes:
* The dlopen port is a port from dl_next.xs by Anno Siegel.
{
if (info->m_className)
classTable.Put(info->m_className, (wxObject *)info);
- info = (wxClassInfo *)info->GetNext();
+ info = info->m_next;
}
// Set base pointers for each wxClassInfo
// wxDllLoader
// ---------------------------------------------------------------------------
-/* static */
-wxString wxDllLoader::GetDllExt()
-{
- wxString ext;
#if defined(__WINDOWS__) || defined(__WXPM__) || defined(__EMX__)
- ext = _T(".dll");
+const wxString wxDllLoader::ms_dllext( _T(".dll") );
#elif defined(__UNIX__)
-# if defined(__HPUX__)
- ext = _T(".sl");
-# else //__HPUX__
- ext = _T(".so");
-# endif //__HPUX__
+#if defined(__HPUX__)
+const wxString wxDllLoader::ms_dllext( _T(".sl") );
+#else
+const wxString wxDllLoader::ms_dllext( _T(".so") );
+#endif
#endif
-
- return ext;
-}
/* static */
-wxDllType
-wxDllLoader::GetProgramHandle(void)
+wxDllType wxDllLoader::GetProgramHandle()
{
#if defined( HAVE_DLOPEN ) && !defined(__EMX__)
// optain handle for main program
}
/* static */
-wxDllType
-wxDllLoader::LoadLibrary(const wxString & libname, bool *success)
+wxDllType wxDllLoader::LoadLibrary(const wxString & libname, bool *success)
{
- wxDllType handle;
+ wxDllType handle;
+ bool failed = FALSE;
#if defined(__WXMAC__) && !defined(__UNIX__)
- FSSpec myFSSpec ;
- Ptr myMainAddr ;
- Str255 myErrName ;
-
- wxMacFilename2FSSpec( libname , &myFSSpec ) ;
- if (GetDiskFragment( &myFSSpec , 0 , kCFragGoesToEOF , "\p" , kPrivateCFragCopy , &handle , &myMainAddr ,
- myErrName ) != noErr )
+ FSSpec myFSSpec;
+ Ptr myMainAddr;
+ Str255 myErrName;
+
+ wxMacFilename2FSSpec( libname , &myFSSpec );
+
+ if( GetDiskFragment( &myFSSpec,
+ 0,
+ kCFragGoesToEOF,
+ "\p",
+ kPrivateCFragCopy,
+ &handle,
+ &myMainAddr,
+ myErrName ) != noErr )
{
- p2cstr( myErrName ) ;
- wxLogSysError( _("Failed to load shared library '%s' Error '%s'") , libname.c_str() , (char*)myErrName ) ;
- handle = NULL ;
+ p2cstr( myErrName );
+ wxLogSysError( _("Failed to load shared library '%s' Error '%s'"),
+ libname.c_str(),
+ (char*)myErrName );
+ handle = 0;
+ failed = TRUE;
}
+
#elif defined(__WXPM__) || defined(__EMX__)
- char zError[256] = "";
+ char zError[256] = "";
wxDllOpen(zError, libname, handle);
-#else // !Mac
+
+#else
handle = wxDllOpen(libname);
-#endif // OS
+
+#endif
if ( !handle )
{
wxString msg(_("Failed to load shared library '%s'"));
#ifdef HAVE_DLERROR
- const char *errmsg = dlerror();
- if ( errmsg )
- {
- // the error string format is "libname: ...", but we already have
- // libname, so cut it off
- const char *p = strchr(errmsg, ':');
- if ( p )
- {
- if ( *++p == ' ' )
- p++;
- }
- else
- {
- p = errmsg;
- }
-
- msg += _T(" (%s)");
- wxLogError(msg, libname.c_str(), p);
- }
- else
-#endif // HAVE_DLERROR
+ wxChar *err = dlerror();
+ if( err )
{
- wxLogSysError(msg, libname.c_str());
+ failed = TRUE;
+ wxLogError( msg, err );
}
+#else
+ failed = TRUE;
+ wxLogSysError( msg, libname.c_str() );
+#endif
}
if ( success )
- {
- *success = handle != 0;
- }
+ *success = !failed;
return handle;
}
/* static */
-void
-wxDllLoader::UnloadLibrary(wxDllType handle)
+void wxDllLoader::UnloadLibrary(wxDllType handle)
{
wxDllClose(handle);
}
/* static */
-void *
-wxDllLoader::GetSymbol(wxDllType dllHandle, const wxString &name)
+void *wxDllLoader::GetSymbol(wxDllType dllHandle, const wxString &name, bool *success)
{
- void *symbol = NULL; // return value
+ bool failed = FALSE;
+ void *symbol = 0;
#if defined(__WXMAC__) && !defined(__UNIX__)
- Ptr symAddress ;
- CFragSymbolClass symClass ;
- Str255 symName ;
+ Ptr symAddress;
+ CFragSymbolClass symClass;
+ Str255 symName;
#if TARGET_CARBON
- c2pstrcpy( (StringPtr) symName , name ) ;
+ c2pstrcpy( (StringPtr) symName, name );
#else
- strcpy( (char *) symName , name ) ;
- c2pstr( (char *) symName ) ;
+ strcpy( (char *) symName, name );
+ c2pstr( (char *) symName );
#endif
+ if( FindSymbol( dllHandle, symName, &symAddress, &symClass ) == noErr )
+ symbol = (void *)symAddress;
- if ( FindSymbol( dllHandle , symName , &symAddress , &symClass ) == noErr )
- symbol = (void *)symAddress ;
-#elif defined( __WXPM__ ) || defined(__EMX__)
+#elif defined(__WXPM__) || defined(__EMX__)
wxDllGetSymbol(dllHandle, symbol);
+
#else
// mb_str() is necessary in Unicode build
symbol = wxDllGetSymbol(dllHandle, name.mb_str());
+
#endif
if ( !symbol )
{
+ wxString msg(_("wxDllLoader failed to GetSymbol '%s'"));
+
+#ifdef HAVE_DLERROR
+ wxChar *err = dlerror();
+ if( err )
+ {
+ failed = TRUE;
+ wxLogError( msg, err );
+ }
+#else
+ failed = TRUE;
wxLogSysError(_("Couldn't find symbol '%s' in a dynamic library"),
name.c_str());
+#endif
}
+
+ if( success )
+ *success = !failed;
+
return symbol;
}
wxLibrary *wxLibraries::LoadLibrary(const wxString& name)
{
- wxNode *node;
- wxLibrary *lib;
+ wxLibrary *lib;
wxClassInfo *old_sm_first;
+ wxNode *node = m_loaded.Find(name.GetData());
-#if defined(__VISAGECPP__)
- node = m_loaded.Find(name.GetData());
if (node != NULL)
return ((wxLibrary *)node->Data());
-#else // !OS/2
- if ( (node = m_loaded.Find(name.GetData())) != NULL)
- return ((wxLibrary *)node->Data());
-#endif
+
// If DLL shares data, this is necessary.
old_sm_first = wxClassInfo::sm_first;
wxClassInfo::sm_first = NULL;
wxString libname = ConstructLibraryName(name);
-/*
- Unix automatically builds that library name, at least for dlopen()
-*/
-#if 0
-#if defined(__UNIX__)
- // found the first file in LD_LIBRARY_PATH with this name
- wxString libPath("/lib:/usr/lib"); // system path first
- const char *envLibPath = getenv("LD_LIBRARY_PATH");
- if ( envLibPath )
- libPath << wxT(':') << envLibPath;
- wxStringTokenizer tokenizer(libPath, wxT(':'));
- while ( tokenizer.HasMoreToken() )
- {
- wxString fullname(tokenizer.NextToken());
-
- fullname << wxT('/') << libname;
- if ( wxFileExists(fullname) )
- {
- libname = fullname;
-
- // found the library
- break;
- }
- }
- //else: not found in the path, leave the name as is (secutiry risk?)
-
-#endif // __UNIX__
-#endif
-
bool success = FALSE;
wxDllType handle = wxDllLoader::LoadLibrary(libname, &success);
if(success)
{
lib = new wxLibrary(handle);
wxClassInfo::sm_first = old_sm_first;
+
m_loaded.Append(name.GetData(), lib);
}
else
--- /dev/null
+/////////////////////////////////////////////////////////////////////////////
+// Name: dynload.cpp
+// Purpose: Dynamic loading framework
+// Author: Ron Lee, David Falkinder, Vadim Zeitlin and a cast of 1000's
+// (derived in part from dynlib.cpp (c) 1998 Guilhem Lavaux)
+// Modified by:
+// Created: 03/12/01
+// RCS-ID: $Id$
+// Copyright: (c) 2001 Ron Lee <ron@debian.org>
+// Licence: wxWindows license
+/////////////////////////////////////////////////////////////////////////////
+
+#ifdef __GNUG__
+#pragma implementation "dynload.h"
+#endif
+
+// ----------------------------------------------------------------------------
+// headers
+// ----------------------------------------------------------------------------
+
+#include "wx/wxprec.h"
+
+#ifdef __BORLANDC__
+#pragma hdrstop
+#endif
+
+#if wxUSE_DYNAMIC_LOADER
+
+#ifdef __WINDOWS__
+#include "wx/msw/private.h"
+#endif
+
+#ifndef WX_PRECOMP
+#include "wx/log.h"
+#include "wx/intl.h"
+#endif
+
+#include "wx/dynload.h"
+
+// ----------------------------------------------------------------------------
+// conditional compilation
+// ----------------------------------------------------------------------------
+
+#if defined(__WXPM__) || defined(__EMX__)
+#define INCL_DOS
+#include <os2.h>
+#define wxDllOpen(error, lib, handle) DosLoadModule(error, sizeof(error), lib, &handle)
+#define wxDllGetSymbol(handle, modaddr) DosQueryProcAddr(handle, 1L, NULL, (PFN*)modaddr)
+#define wxDllClose(handle) DosFreeModule(handle)
+
+#elif defined(HAVE_DLOPEN)
+ // note about dlopen() flags: we use RTLD_NOW to have more Windows-like
+ // behaviour (Win won't let you load a library with missing symbols) and
+ // RTLD_GLOBAL because it is needed sometimes and probably doesn't hurt
+ // otherwise. On True64-Unix RTLD_GLOBAL is not allowed and on VMS the
+ // second argument on dlopen is ignored.
+
+#ifdef __VMS
+#define wxDllOpen(lib) dlopen(lib.fn_str(), 0)
+
+#elif defined( __osf__ )
+#define wxDllOpen(lib) dlopen(lib.fn_str(), RTLD_LAZY)
+
+#else
+#define wxDllOpen(lib) dlopen(lib.fn_str(), RTLD_LAZY | RTLD_GLOBAL)
+#endif // __VMS
+
+#define wxDllGetSymbol(handle, name) dlsym(handle, name)
+#define wxDllClose dlclose
+
+#elif defined(HAVE_SHL_LOAD)
+#define wxDllOpen(lib) shl_load(lib.fn_str(), BIND_DEFERRED, 0)
+#define wxDllClose shl_unload
+
+static inline void *wxDllGetSymbol(shl_t handle, const wxString& name)
+{
+ void *sym;
+ return ( shl_findsym(&handle, name.mb_str(), TYPE_UNDEFINED, &sym) == 0 )
+ ? sym : 0;
+}
+
+#elif defined(__DARWIN__)
+
+ // Porting notes:
+ // The dlopen port is a port from dl_next.xs by Anno Siegel.
+ // dl_next.xs is itself a port from dl_dlopen.xs by Paul Marquess.
+ // The method used here is just to supply the sun style dlopen etc.
+ // functions in terms of Darwin NS*.
+
+void *dlopen(const char *path, int mode); // mode is ignored
+void *dlsym(void *handle, const char *symbol);
+int dlclose(void *handle);
+const char *dlerror(void);
+
+#define wxDllOpen(lib) dlopen(lib.fn_str(), 0)
+#define wxDllGetSymbol(handle, name) dlsym(handle, name)
+#define wxDllClose dlclose
+
+#elif defined(__WINDOWS__)
+
+ // using LoadLibraryEx under Win32 to avoid name clash with LoadLibrary
+
+#ifdef __WIN32__
+
+#ifdef _UNICODE
+#define wxDllOpen(lib) ::LoadLibraryExW(lib, 0, 0)
+#else
+#define wxDllOpen(lib) ::LoadLibraryExA(lib, 0, 0)
+#endif
+
+#else // Win16
+#define wxDllOpen(lib) ::LoadLibrary(lib)
+#endif // Win32/16
+#define wxDllGetSymbol(handle, name) ::GetProcAddress(handle, name)
+#define wxDllClose ::FreeLibrary
+
+#elif defined(__WXMAC__)
+#define wxDllClose(handle) CloseConnection(&handle)
+#else
+#error "Don't know how to load shared libraries on this platform."
+#endif
+
+
+// ============================================================================
+// implementation
+// ============================================================================
+
+// ---------------------------------------------------------------------------
+// wxDllLoader (all these methods are static)
+// ---------------------------------------------------------------------------
+
+
+#if defined(__WINDOWS__) || defined(__WXPM__) || defined(__EMX__)
+const wxString wxDllLoader::ms_dllext( _T(".dll") );
+#elif defined(__UNIX__)
+#if defined(__HPUX__)
+const wxString wxDllLoader::ms_dllext( _T(".sl") );
+#else
+const wxString wxDllLoader::ms_dllext( _T(".so") );
+#endif
+#endif
+
+wxDllType wxDllLoader::GetProgramHandle()
+{
+#if defined( HAVE_DLOPEN ) && !defined(__EMX__)
+ // obtain handle for main program
+ return dlopen(NULL, RTLD_NOW/*RTLD_LAZY*/);
+#elif defined (HAVE_SHL_LOAD)
+ // shl_findsymbol with NULL handle looks up in main program
+ return 0;
+#else
+ wxFAIL_MSG( wxT("This method is not implemented under Windows or OS/2"));
+ return 0;
+#endif
+}
+
+wxDllType wxDllLoader::LoadLibrary(const wxString &name)
+{
+ wxString libname( name + wxDllLoader::GetDllExt() );
+ wxDllType handle;
+
+#if defined(__WXMAC__) && !defined(__UNIX__)
+ FSSpec myFSSpec;
+ Ptr myMainAddr;
+ Str255 myErrName;
+
+ wxMacFilename2FSSpec( libname , &myFSSpec );
+
+ if( GetDiskFragment( &myFSSpec,
+ 0,
+ kCFragGoesToEOF,
+ "\p",
+ kPrivateCFragCopy,
+ &handle,
+ &myMainAddr,
+ myErrName ) != noErr )
+ {
+ p2cstr( myErrName );
+ wxLogSysError( _("Failed to load shared library '%s' Error '%s'"),
+ libname.c_str(),
+ (char*)myErrName );
+ handle = 0;
+ }
+
+#elif defined(__WXPM__) || defined(__EMX__)
+ char zError[256] = "";
+ wxDllOpen(zError, libname, handle);
+#else
+ handle = wxDllOpen(libname);
+#endif
+ if ( !handle )
+ {
+ wxString msg(_("Failed to load shared library '%s'"));
+#ifdef HAVE_DLERROR
+ wxChar *err = dlerror();
+ if( err )
+ wxLogError( msg, err );
+#else
+ wxLogSysError( msg, libname.c_str() );
+#endif
+ }
+ return handle;
+}
+
+void wxDllLoader::UnloadLibrary(wxDllType handle)
+{
+ wxDllClose(handle);
+}
+
+void *wxDllLoader::GetSymbol(wxDllType dllHandle, const wxString &name, bool *success)
+{
+ bool failed = FALSE;
+ void *symbol = 0;
+
+#if defined(__WXMAC__) && !defined(__UNIX__)
+ Ptr symAddress;
+ CFragSymbolClass symClass;
+ Str255 symName;
+#if TARGET_CARBON
+ c2pstrcpy( (StringPtr) symName, name );
+#else
+ strcpy( (char *) symName, name );
+ c2pstr( (char *) symName );
+#endif
+ if( FindSymbol( dllHandle, symName, &symAddress, &symClass ) == noErr )
+ symbol = (void *)symAddress;
+
+#elif defined(__WXPM__) || defined(__EMX__)
+ wxDllGetSymbol(dllHandle, symbol);
+#else
+
+ // mb_str() is necessary in Unicode build
+ symbol = wxDllGetSymbol(dllHandle, name.mb_str());
+#endif
+
+ if ( !symbol )
+ {
+ wxString msg(_("wxDllLoader failed to GetSymbol '%s'"));
+#ifdef HAVE_DLERROR
+ wxChar *err = dlerror();
+ if( err )
+ {
+ failed = TRUE;
+ wxLogError( msg, err );
+ }
+#else
+ failed = TRUE;
+ wxLogSysError(_("Couldn't find symbol '%s' in a dynamic library"),
+ name.c_str());
+#endif
+ }
+ if( success )
+ *success = !failed;
+
+ return symbol;
+}
+
+
+// ---------------------------------------------------------------------------
+// wxDLManifestEntry
+// ---------------------------------------------------------------------------
+
+
+wxDLImports wxDLManifestEntry::ms_classes(wxKEY_STRING);
+
+wxDLManifestEntry::wxDLManifestEntry( const wxString &libname )
+ : m_before(wxClassInfo::sm_first)
+ , m_handle(wxDllLoader::LoadLibrary( libname ))
+ , m_after(wxClassInfo::sm_first)
+ , m_count(1)
+{
+ if( m_handle != 0 )
+ {
+ UpdateClassInfo();
+ RegisterModules();
+ }
+ else
+ --m_count; // Flag us for deletion
+}
+
+wxDLManifestEntry::~wxDLManifestEntry()
+{
+ UnregisterModules();
+ RestoreClassInfo();
+
+ wxDllLoader::UnloadLibrary(m_handle);
+}
+
+
+// ------------------------
+// Private methods
+// ------------------------
+
+void wxDLManifestEntry::UpdateClassInfo()
+{
+ wxClassInfo *info;
+ wxHashTable *t = wxClassInfo::sm_classTable;
+
+ // FIXME: Below is simply a cut and paste specialisation of
+ // wxClassInfo::InitializeClasses. Once this stabilises,
+ // the two should probably be merged.
+ //
+ // Actually it's becoming questionable whether we should merge
+ // this info with the main ClassInfo tables since we can nearly
+ // handle this completely internally now and it does expose
+ // certain (minimal % user_stupidy) risks.
+
+ for(info = m_after; info != m_before; info = info->m_next)
+ {
+ if( info->m_className )
+ {
+ if( t->Get(info->m_className) == 0 )
+ t->Put(info->m_className, (wxObject *)info);
+
+ // Hash all the class names into a local table too so
+ // we can quickly find the entry they correspond to.
+
+ if( ms_classes.Get(info->m_className) == 0 )
+ ms_classes.Put(info->m_className, (wxObject *) this);
+ }
+ }
+
+ for(info = m_after; info != m_before; info = info->m_next)
+ {
+ if( info->m_baseClassName1 )
+ info->m_baseInfo1 = (wxClassInfo *)t->Get(info->m_baseClassName1);
+ if( info->m_baseClassName2 )
+ info->m_baseInfo2 = (wxClassInfo *)t->Get(info->m_baseClassName2);
+ }
+}
+
+void wxDLManifestEntry::RestoreClassInfo()
+{
+ wxClassInfo *info;
+
+ for(info = m_after; info != m_before; info = info->m_next)
+ {
+ wxClassInfo::sm_classTable->Delete(info->m_className);
+ ms_classes.Delete(info->m_className);
+ }
+
+ if( wxClassInfo::sm_first == m_after )
+ wxClassInfo::sm_first = m_before;
+ else
+ {
+ info = wxClassInfo::sm_first;
+ while( info->m_next && info->m_next != m_after ) info = info->m_next;
+
+ wxASSERT_MSG( info, _T("ClassInfo from wxDynamicLibrary not found on purge"))
+
+ info->m_next = m_before;
+ }
+}
+
+void wxDLManifestEntry::RegisterModules()
+{
+ // Plugin libraries might have wxModules, Register and initialise them if
+ // they do.
+ //
+ // Note that these classes are NOT included in the reference counting since
+ // it's implicit that they will be unloaded if and when the last handle to
+ // the library is. We do have to keep a copy of the module's pointer
+ // though, as there is currently no way to Unregister it without it.
+
+ wxASSERT_MSG( m_count == 1,
+ _T("RegisterModules should only be called for the first load") );
+
+ for(wxClassInfo *info = m_after; info != m_before; info = info->m_next)
+ {
+ if( info->IsKindOf(CLASSINFO(wxModule)) )
+ {
+ wxModule *m = wxDynamicCast(info->CreateObject(), wxModule);
+
+ wxASSERT_MSG( m, _T("wxDynamicCast of wxModule failed") );
+
+ m_wxmodules.Append(m);
+ wxModule::RegisterModule(m);
+ }
+ }
+
+ // FIXME: Likewise this is (well was) very similar to InitializeModules()
+
+ for(wxModuleList::Node *node = m_wxmodules.GetFirst(); node; node->GetNext())
+ {
+ if( !node->GetData()->Init() )
+ {
+ wxLogDebug(_T("wxModule::Init() failed for wxDynamicLibrary"));
+
+ // XXX: Watch this, a different hash implementation might break it,
+ // a good hash implementation would let us fix it though.
+
+ // The name of the game is to remove any uninitialised modules and
+ // let the dtor Exit the rest on shutdown, (which we'll initiate
+ // shortly).
+
+ wxModuleList::Node *oldNode = 0;
+ do {
+ node = node->GetNext();
+ delete oldNode;
+ wxModule::UnregisterModule( node->GetData() );
+ oldNode = node;
+ } while( node );
+
+ --m_count; // Flag us for deletion
+ break;
+ }
+ }
+}
+
+void wxDLManifestEntry::UnregisterModules()
+{
+ wxModuleList::Node *node;
+
+ for(node = m_wxmodules.GetFirst(); node; node->GetNext())
+ node->GetData()->Exit();
+
+ for(node = m_wxmodules.GetFirst(); node; node->GetNext())
+ wxModule::UnregisterModule( node->GetData() );
+
+ m_wxmodules.DeleteContents(TRUE);
+}
+
+
+// ---------------------------------------------------------------------------
+// wxDynamicLibrary
+// ---------------------------------------------------------------------------
+
+wxDLManifest wxDynamicLibrary::ms_manifest(wxKEY_STRING);
+
+// ------------------------
+// Static accessors
+// ------------------------
+
+wxDLManifestEntry *wxDynamicLibrary::Link(const wxString &libname)
+{
+ wxDLManifestEntry *entry = (wxDLManifestEntry*) ms_manifest.Get(libname);
+
+ if( entry )
+ {
+ entry->Ref();
+ }
+ else
+ {
+ entry = new wxDLManifestEntry( libname );
+
+ if( entry->IsLoaded() )
+ {
+ ms_manifest.Put(libname, (wxObject*) entry);
+ }
+ else
+ {
+ wxCHECK_MSG( !entry->Unref(), 0,
+ _T("Currently linked library is, ..not loaded??") );
+ entry = 0;
+ }
+ }
+ return entry;
+}
+
+bool wxDynamicLibrary::Unlink(const wxString &libname)
+{
+ wxDLManifestEntry *entry = (wxDLManifestEntry*) ms_manifest.Get(libname);
+
+ if( entry )
+ return entry->Unref();
+
+ wxLogDebug(_T("Attempt to Unlink library '%s' (which is not linked)."), libname.c_str());
+ return 0;
+}
+
+// ------------------------
+// Class implementation
+// ------------------------
+
+wxDynamicLibrary::wxDynamicLibrary(const wxString &libname)
+{
+ m_entry = (wxDLManifestEntry*) ms_manifest.Get(libname);
+
+ if( m_entry != 0 )
+ {
+ m_entry->Ref();
+ }
+ else
+ {
+ m_entry = new wxDLManifestEntry( libname );
+ ms_manifest.Put(libname, (wxObject*) m_entry);
+
+ wxASSERT_MSG( m_entry != 0, _T("Failed to create manifest entry") );
+ }
+}
+
+wxDynamicLibrary::~wxDynamicLibrary()
+{
+ wxNode *node;
+ ms_manifest.BeginFind();
+
+ // It's either this or store the name of the lib just to do this.
+
+ for(node = ms_manifest.Next(); node; node = ms_manifest.Next())
+ if( (wxDLManifestEntry*)node->GetData() == m_entry )
+ break;
+
+ if( m_entry && m_entry->Unref() )
+ delete node;
+}
+
+
+#ifdef __DARWIN__
+// ---------------------------------------------------------------------------
+// For Darwin/Mac OS X
+// supply the sun style dlopen functions in terms of Darwin NS*
+// ---------------------------------------------------------------------------
+
+extern "C" {
+#import <mach-o/dyld.h>
+};
+
+enum dyldErrorSource
+{
+ OFImage,
+};
+
+static char dl_last_error[1024];
+
+static
+void TranslateError(const char *path, enum dyldErrorSource type, int number)
+{
+ unsigned int index;
+ static char *OFIErrorStrings[] =
+ {
+ "%s(%d): Object Image Load Failure\n",
+ "%s(%d): Object Image Load Success\n",
+ "%s(%d): Not an recognisable object file\n",
+ "%s(%d): No valid architecture\n",
+ "%s(%d): Object image has an invalid format\n",
+ "%s(%d): Invalid access (permissions?)\n",
+ "%s(%d): Unknown error code from NSCreateObjectFileImageFromFile\n",
+ };
+#define NUM_OFI_ERRORS (sizeof(OFIErrorStrings) / sizeof(OFIErrorStrings[0]))
+
+ switch (type)
+ {
+ case OFImage:
+ index = number;
+ if (index > NUM_OFI_ERRORS - 1) {
+ index = NUM_OFI_ERRORS - 1;
+ }
+ sprintf(dl_last_error, OFIErrorStrings[index], path, number);
+ break;
+
+ default:
+ sprintf(dl_last_error, "%s(%d): Totally unknown error type %d\n",
+ path, number, type);
+ break;
+ }
+}
+
+const char *dlerror()
+{
+ return dl_last_error;
+}
+void *dlopen(const char *path, int mode /* mode is ignored */)
+{
+ int dyld_result;
+ NSObjectFileImage ofile;
+ NSModule handle = 0;
+
+ dyld_result = NSCreateObjectFileImageFromFile(path, &ofile);
+ if(dyld_result != NSObjectFileImageSuccess)
+ {
+ TranslateError(path, OFImage, dyld_result);
+ }
+ else
+ {
+ // NSLinkModule will cause the run to abort on any link error's
+ // not very friendly but the error recovery functionality is limited.
+ handle = NSLinkModule(ofile, path, TRUE);
+ }
+
+ return handle;
+}
+
+int dlclose(void *handle) /* stub only */
+{
+ return 0;
+}
+
+void *dlsym(void *handle, const char *symbol)
+{
+ return NSIsSymbolNameDefined(symbol)
+ ? NSAddressOfSymbol( NSLookupAndBindSymbol(symbol) )
+ : 0 ;
+}
+
+#endif // __DARWIN__
+#endif // wxUSE_DYNAMIC_LOADER
+
+// vi:sts=4:sw=4:et
// ----------------------------------------------------------------------------
#ifdef __GNUG__
- #pragma implementation "filename.h"
+#pragma implementation "filename.h"
#endif
// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#ifdef __BORLANDC__
- #pragma hdrstop
+#pragma hdrstop
#endif
#ifndef WX_PRECOMP
- #include "wx/intl.h"
- #include "wx/log.h"
+#include "wx/intl.h"
+#include "wx/log.h"
+#include "wx/file.h"
#endif
#include "wx/filename.h"
#include "wx/utils.h"
#include "wx/file.h"
-#if wxUSE_DYNLIB_CLASS
- #include "wx/dynlib.h"
+#if wxUSE_DYNAMIC_LOADER || wxUSE_DYNLIB_CLASS
+#include "wx/dynlib.h"
#endif
// For GetShort/LongPathName
#ifdef __WIN32__
- #include <windows.h>
-
- #include "wx/msw/winundef.h"
+#include <windows.h>
+#include "wx/msw/winundef.h"
#endif
// utime() is POSIX so should normally be available on all Unices
#ifdef __UNIX_LIKE__
- #include <sys/types.h>
- #include <utime.h>
- #include <sys/stat.h>
- #include <unistd.h>
+#include <sys/types.h>
+#include <utime.h>
+#include <sys/stat.h>
+#include <unistd.h>
#endif
#ifdef __MWERKS__
- #include <stat.h>
- #include <unistd.h>
- #include <unix.h>
+#include <stat.h>
+#include <unistd.h>
+#include <unix.h>
#endif
#ifdef __WATCOMC__
- #include <io.h>
- #include <sys/utime.h>
- #include <sys/stat.h>
+#include <io.h>
+#include <sys/utime.h>
+#include <sys/stat.h>
#endif
#ifdef __VISAGECPP__
bool success = FALSE;
// VZ: this code was disabled, why?
-#if 0 // wxUSE_DYNLIB_CLASS
+#if 0 // wxUSE_DYNAMIC_LOADER
typedef DWORD (*GET_LONG_PATH_NAME)(const wxChar *, wxChar *, DWORD);
static bool s_triedToLoad = FALSE;
}
if (success)
return pathOut;
-#endif // wxUSE_DYNLIB_CLASS
+#endif // wxUSE_DYNAMIC_LOADER
if (!success)
{
m_modules.Append(module);
}
+void wxModule::UnregisterModule(wxModule* module)
+{
+ m_modules.DeleteObject(module);
+}
+
// Collect up all module-derived classes, create an instance of each,
// and register them.
void wxModule::RegisterModules()
// Name: object.cpp
// Purpose: wxObject implementation
// Author: Julian Smart
-// Modified by:
+// Modified by: Ron Lee
// Created: 04/01/98
// RCS-ID: $Id$
-// Copyright: (c) Julian Smart and Markus Holzem
+// Copyright: (c) 1998 Julian Smart and Markus Holzem
+// (c) 2001 Ron Lee <ron@debian.org>
// Licence: wxWindows license
/////////////////////////////////////////////////////////////////////////////
#pragma implementation "object.h"
#endif
-// For compilers that support precompilation, includes "wx.h".
+ // For compilers that support precompilation, includes "wx.h".
+
#include "wx/wxprec.h"
#ifdef __BORLANDC__
#endif
#ifndef WX_PRECOMP
- #include "wx/hash.h"
- #if wxUSE_SERIAL
- #include "wx/objstrm.h"
- #include "wx/serbase.h"
-
- // for error messages
- #include "wx/log.h"
- #include "wx/intl.h"
- #endif // wxUSE_SERIAL
-#endif // WX_PRECOMP
-
-#ifdef __VISAGECPP__
- #include "wx/objstrm.h"
- #include "wx/serbase.h"
+#include "wx/hash.h"
#endif
#include <string.h>
#if defined(__WXDEBUG__) || wxUSE_DEBUG_CONTEXT
// for wxObject::Dump
- #include "wx/ioswrap.h"
- #if defined(__VISAGECPP__)
- // help with VA debugging
- #define DEBUG_PRINTF(NAME) { static int raz=0; \
- printf( #NAME " %i\n",raz); fflush(stdout); \
- raz++; \
- }
- #else
- #define DEBUG_PRINTF(NAME)
- #endif
-#endif
+#include "wx/ioswrap.h"
-wxClassInfo wxObject::sm_classwxObject((wxChar *) wxT("wxObject"), (wxChar *) NULL, (wxChar *) NULL, (int ) sizeof(wxObject), (wxObjectConstructorFn) NULL);
-wxClassInfo* wxClassInfo::sm_first = (wxClassInfo *) NULL;
-wxHashTable* wxClassInfo::sm_classTable = (wxHashTable*) NULL;
+#if defined(__VISAGECPP__)
+#define DEBUG_PRINTF(NAME) { static int raz=0; \
+ printf( #NAME " %i\n",raz); fflush(stdout); raz++; }
+#else
+#define DEBUG_PRINTF(NAME)
+#endif
-// These are here so we can avoid 'always true/false' warnings
-// by referring to these instead of TRUE/FALSE
-const bool wxTrue = TRUE;
-const bool wxFalse = FALSE;
+#endif
-/*
- * wxWindows root object.
- */
+
+wxClassInfo wxObject::sm_classwxObject( wxT("wxObject"), 0, 0,
+ (int) sizeof(wxObject),
+ (wxObjectConstructorFn) 0 );
+wxClassInfo* wxClassInfo::sm_first = 0;
+wxHashTable* wxClassInfo::sm_classTable = 0;
-wxObject::wxObject()
-{
- m_refData = (wxObjectRefData *) NULL;
-#if wxUSE_SERIAL
- m_serialObj = (wxObject_Serialize *)NULL;
-#endif
-}
+ // These are here so we can avoid 'always true/false' warnings
+ // by referring to these instead of TRUE/FALSE
-wxObject::~wxObject()
-{
- UnRef();
-#if wxUSE_SERIAL
- if (m_serialObj)
- delete m_serialObj;
-#endif
-}
+const bool wxTrue = TRUE;
+const bool wxFalse = FALSE;
-/*
- * Is this object a kind of (a subclass of) 'info'?
- * E.g. is wxWindow a kind of wxObject?
- * Go from this class to superclass, taking into account
- * two possible base classes.
- */
+ // Is this object a kind of (a subclass of) 'info'?
+ // E.g. is wxWindow a kind of wxObject?
+ // Go from this class to superclass, taking into account
+ // two possible base classes.
bool wxObject::IsKindOf(wxClassInfo *info) const
{
wxClassInfo *thisInfo = GetClassInfo();
- if (thisInfo)
- return thisInfo->IsKindOf(info);
- else
- return FALSE;
+ return (thisInfo) ? thisInfo->IsKindOf(info) : FALSE ;
}
#if wxUSE_STD_IOSTREAM && (defined(__WXDEBUG__) || wxUSE_DEBUG_CONTEXT)
#undef new
#endif
-void *wxObject::operator new (size_t size, wxChar * fileName, int lineNum)
+void *wxObject::operator new (size_t size, wxChar *fileName, int lineNum)
{
return wxDebugAlloc(size, fileName, lineNum, TRUE);
}
-#if defined(__VISAGECPP__)
-# if __DEBUG_ALLOC__
-void wxObject::operator delete (void * buf,const char * _fname, size_t _line)
+#ifndef __VISAGECPP__
+void wxObject::operator delete (void *buf)
{
wxDebugFree(buf);
}
-# endif //__DEBUG_ALLOC__
-#else
-void wxObject::operator delete (void * buf)
+#elif __DEBUG_ALLOC__
+void wxObject::operator delete (void *buf, const char *_fname, size_t _line)
{
wxDebugFree(buf);
}
-#endif // __VISAGECPP__
+#endif
+
+ // VC++ 6.0
-// VC++ 6.0
#if defined(__VISUALC__) && (__VISUALC__ >= 1200)
-void wxObject::operator delete(void* pData, wxChar* /* fileName */, int /* lineNum */)
+void wxObject::operator delete(void *pData, wxChar *WXUNUSED(fileName), int WXUNUSED(lineNum))
{
::operator delete(pData);
}
#endif
-// Cause problems for VC++ - crashes
+ // Cause problems for VC++ - crashes
+
#if (!defined(__VISUALC__) && wxUSE_ARRAY_MEMORY_OPERATORS ) || defined(__MWERKS__)
-void * wxObject::operator new[] (size_t size, wxChar * fileName, int lineNum)
+void *wxObject::operator new[] (size_t size, wxChar *fileName, int lineNum)
{
return wxDebugAlloc(size, fileName, lineNum, TRUE, TRUE);
}
-void wxObject::operator delete[] (void * buf)
+void wxObject::operator delete[] (void *buf)
{
wxDebugFree(buf, TRUE);
}
#endif
-#endif
-
-/*
- * Class info: provides run-time class type information.
- */
-
-wxClassInfo::wxClassInfo(const wxChar *cName,
- const wxChar *baseName1,
- const wxChar *baseName2,
- int sz,
- wxObjectConstructorFn constr)
-{
- m_className = cName;
- m_baseClassName1 = baseName1;
- m_baseClassName2 = baseName2;
-
- m_objectSize = sz;
- m_objectConstructor = constr;
+#endif // __WXDEBUG__ && wxUSE_MEMORY_TRACING
- m_next = sm_first;
- sm_first = this;
- m_baseInfo1 = (wxClassInfo *) NULL;
- m_baseInfo2 = (wxClassInfo *) NULL;
-}
+// ----------------------------------------------------------------------------
+// wxClassInfo
+// ----------------------------------------------------------------------------
-wxObject *wxClassInfo::CreateObject()
+wxClassInfo *wxClassInfo::FindClass(const wxChar *className)
{
- if (m_objectConstructor)
- return (wxObject *)(*m_objectConstructor)();
- else
- return (wxObject *) NULL;
-}
-
-wxClassInfo *wxClassInfo::FindClass(const wxChar *c)
-{
- wxClassInfo *p = sm_first;
- while (p)
- {
- if ( wxStrcmp(p->GetClassName(), c) == 0 )
- break;
+ for(wxClassInfo *info = sm_first; info ; info = info->m_next)
+ if( wxStrcmp(info->GetClassName(), className) == 0 )
+ return info;
- p = p->m_next;
- }
-
- return p;
+ return 0;
}
-// Climb upwards through inheritance hierarchy.
-// Dual inheritance is catered for.
-bool wxClassInfo::IsKindOf(const wxClassInfo *info) const
-{
- if (info == NULL)
- return FALSE;
-
- if (this == info)
- return TRUE;
-
- if (m_baseInfo1)
- if (m_baseInfo1->IsKindOf(info))
- return TRUE;
-
- if (m_baseInfo2)
- return m_baseInfo2->IsKindOf(info);
+ // Set pointers to base class(es) to speed up IsKindOf
- return FALSE;
-}
-
-// Set pointers to base class(es) to speed up IsKindOf
void wxClassInfo::InitializeClasses()
{
// using IMPLEMENT_DYNAMIC_CLASS() macro twice (which may happen if you
// because it will enter an infinite loop and eventually die with "out of
// memory" - as this is quite hard to detect if you're unaware of this,
// try to do some checks here
+
#ifdef __WXDEBUG__
- // more classes than we'll ever have
- static const size_t nMaxClasses = 10000;
+ static const size_t nMaxClasses = 10000; // more than we'll ever have
size_t nClass = 0;
-#endif // Debug
+#endif
wxClassInfo::sm_classTable = new wxHashTable(wxKEY_STRING);
- // Index all class infos by their class name
- wxClassInfo *info = sm_first;
- while (info)
+ // Index all class infos by their class name
+
+ wxClassInfo *info;
+ for(info = sm_first; info; info = info->m_next)
{
if (info->m_className)
{
wxASSERT_MSG( ++nClass < nMaxClasses,
_T("an infinite loop detected - have you used IMPLEMENT_DYNAMIC_CLASS() twice (may be by linking some object module(s) twice)?") );
-
sm_classTable->Put(info->m_className, (wxObject *)info);
}
-
- info = info->m_next;
}
- // Set base pointers for each wxClassInfo
- info = sm_first;
- while (info)
+ // Set base pointers for each wxClassInfo
+
+ for(info = sm_first; info; info = info->m_next)
{
if (info->GetBaseClassName1())
info->m_baseInfo1 = (wxClassInfo *)sm_classTable->Get(info->GetBaseClassName1());
if (info->GetBaseClassName2())
info->m_baseInfo2 = (wxClassInfo *)sm_classTable->Get(info->GetBaseClassName2());
- info = info->m_next;
}
}
void wxClassInfo::CleanUpClasses()
{
delete wxClassInfo::sm_classTable;
- wxClassInfo::sm_classTable = NULL;
+ wxClassInfo::sm_classTable = 0;
}
+
wxObject *wxCreateDynamicObject(const wxChar *name)
{
#if defined(__WXDEBUG__) || wxUSE_DEBUG_CONTEXT
if (wxClassInfo::sm_classTable)
{
wxClassInfo *info = (wxClassInfo *)wxClassInfo::sm_classTable->Get(name);
- if (!info)
- return (wxObject *)NULL;
-
- return info->CreateObject();
+ return info != 0 ? info->CreateObject() : 0;
}
else
{
- wxClassInfo *info = wxClassInfo::sm_first;
- while (info)
- {
+ for(wxClassInfo *info = wxClassInfo::sm_first; info; info = info->m_next)
if (info->m_className && wxStrcmp(info->m_className, name) == 0)
return info->CreateObject();
- info = info->m_next;
- }
- return (wxObject*) NULL;
+ return 0;
}
}
-#if wxUSE_SERIAL
-
-#include "wx/serbase.h"
-#include "wx/dynlib.h"
-wxObject* wxCreateStoredObject( wxInputStream &stream )
-{
- wxObjectInputStream obj_s(stream);
- return obj_s.LoadObject();
-};
-
-void wxObject::StoreObject( wxObjectOutputStream& stream )
-{
-#if defined(__WXDEBUG__) || wxUSE_DEBUG_CONTEXT
- DEBUG_PRINTF(wxObject::StoreObject)
-#endif
-
- wxString obj_name = wxString(GetClassInfo()->GetClassName()) + "_Serialize";
- wxLibrary *lib = wxTheLibraries.LoadLibrary("wxserial");
-
- if (!lib) {
- wxLogError(_("Can't load wxSerial dynamic library."));
- return;
- }
- if (!m_serialObj) {
- m_serialObj = (WXSERIAL(wxObject) *)lib->CreateObject( obj_name );
-
- if (!m_serialObj) {
- wxLogError(_("Can't find the serialization object '%s' "
- "for the object '%s'."),
- obj_name.c_str(),
- GetClassInfo()->GetClassName());
- return;
- }
- m_serialObj->SetObject(this);
- }
-
- m_serialObj->StoreObject(stream);
-}
-
-void wxObject::LoadObject( wxObjectInputStream& stream )
-{
-#if defined(__WXDEBUG__) || wxUSE_DEBUG_CONTEXT
- DEBUG_PRINTF(wxObject::LoadObject)
-#endif
-
- wxString obj_name = wxString(GetClassInfo()->GetClassName()) + "_Serialize";
- wxLibrary *lib = wxTheLibraries.LoadLibrary("wxserial");
-
- if (!m_serialObj) {
- m_serialObj = (WXSERIAL(wxObject) *)lib->CreateObject( obj_name );
-
- if (!m_serialObj) {
- wxLogError(_("Can't find the serialization object '%s' "
- "for the object '%s'."),
- obj_name.c_str(),
- GetClassInfo()->GetClassName());
- return;
- }
- m_serialObj->SetObject(this);
- }
-
- m_serialObj->LoadObject(stream);
-}
-
-#endif // wxUSE_SERIAL
-
-/*
- * wxObject: cloning of objects
- */
+// ----------------------------------------------------------------------------
+// wxClassInfo
+// ----------------------------------------------------------------------------
void wxObject::Ref(const wxObject& clone)
{
#if defined(__WXDEBUG__) || wxUSE_DEBUG_CONTEXT
DEBUG_PRINTF(wxObject::Ref)
#endif
- // delete reference to old data
+
+ // delete reference to old data
UnRef();
+
// reference new data
- if (clone.m_refData) {
+ if( clone.m_refData )
+ {
m_refData = clone.m_refData;
++(m_refData->m_count);
}
void wxObject::UnRef()
{
- if ( m_refData )
+ if( m_refData )
{
wxASSERT_MSG( m_refData->m_count > 0, _T("invalid ref data count") );
if ( !--m_refData->m_count )
delete m_refData;
- m_refData = (wxObjectRefData *) NULL;
+ m_refData = 0;
}
}
-/*
- * wxObjectData
- */
-
-wxObjectRefData::wxObjectRefData(void) : m_count(1)
-{
-}
-
-wxObjectRefData::~wxObjectRefData()
-{
-}
#if defined(__DARWIN__) && defined(DYLIB_INIT)
void wxWindowsDylibInit(void);
};
-// Dynamic shared library (dylib) initialization routine
-// required to initialize static C++ objects bacause of lazy dynamic linking
-// http://developer.apple.com/techpubs/macosx/Essentials/
-// SystemOverview/Frameworks/Dynamic_Shared_Libraries.html
-//
+ // Dynamic shared library (dylib) initialization routine
+ // required to initialize static C++ objects bacause of lazy dynamic linking
+ // http://developer.apple.com/techpubs/macosx/Essentials/
+ // SystemOverview/Frameworks/Dynamic_Shared_Libraries.html
+
void wxWindowsDylibInit()
{
// The function __initialize_Cplusplus() must be called from the shared
}
#endif
+
+// vi:sts=4:sw=4:et
+++ /dev/null
-/////////////////////////////////////////////////////////////////////////////
-// Name: objstrm.cpp
-// Purpose: wxObjectStream classes
-// Author: Guilhem Lavaux
-// Modified by:
-// Created: 16/07/98
-// RCS-ID: $Id$
-// Copyright: (c) 1998 Guilhem Lavaux
-// Licence: wxWindows license
-/////////////////////////////////////////////////////////////////////////////
-
-#ifdef __GNUG__
- #pragma implementation "objstrm.h"
-#endif
-
-// For compilers that support precompilation, includes "wx.h".
-#include "wx/wxprec.h"
-
-#ifdef __BORLANDC__
- #pragma hdrstop
-#endif
-
-#if wxUSE_SERIAL && wxUSE_STREAMS
-
-#include "wx/object.h"
-#include "wx/objstrm.h"
-#include "wx/datstrm.h"
-
-#define WXOBJ_BEGIN "OBEGIN"
-#define WXOBJ_BEG_LEN 6
-
-#define TAG_EMPTY_OBJECT "NULL"
-#define TAG_DUPLICATE_OBJECT "DUPLIC"
-
-// ----------------------------------------------------------------------------
-// wxObjectOutputStream
-// ----------------------------------------------------------------------------
-
-wxObjectOutputStream::wxObjectOutputStream(wxOutputStream& s)
- : wxFilterOutputStream(s)
-{
- m_saving = FALSE;
-}
-
-wxString wxObjectOutputStream::GetObjectName(wxObject *obj)
-{
- wxString name;
-
- name.Printf(wxT("%x"), (unsigned long)obj);
- return name;
-}
-
-void wxObjectOutputStream::WriteObjectDef(wxObjectStreamInfo& info)
-{
- wxDataOutputStream data_s(*this);
-
- Write(WXOBJ_BEGIN, WXOBJ_BEG_LEN);
-
- if (info.duplicate) {
- data_s.WriteString(TAG_DUPLICATE_OBJECT);
- data_s.WriteString(GetObjectName(info.object));
- wxPrintf(wxT("info.object (dup %s)\n"), info.object->GetClassInfo()->GetClassName());
- return;
- }
-
- if (info.object) {
- data_s.WriteString(info.object->GetClassInfo()->GetClassName());
- wxPrintf(wxT("info.object (%s)\n"), info.object->GetClassInfo()->GetClassName());
- } else {
- data_s.WriteString(TAG_EMPTY_OBJECT);
- wxPrintf(wxT("info.object (NULL)\n"));
- return;
- }
-
- data_s.WriteString(GetObjectName(info.object));
-
- // I assume an object will not have millions of children
- // Hmmm ... it could have (for example wxGrid)
- data_s.Write32(info.children.Number());
-}
-
-void wxObjectOutputStream::AddChild(wxObject *obj)
-{
- wxObjectStreamInfo *info;
-
- if (!FirstStage())
- return;
-
- info = new wxObjectStreamInfo;
-
- if (m_saved_objs.Member(obj) != NULL) {
- info->duplicate = TRUE;
- } else {
- info->duplicate = FALSE;
- m_saved_objs.Append(obj);
- }
- if (!obj)
- info->duplicate = FALSE;
-
- info->n_children = 0;
- info->object = obj;
- info->parent = m_current_info; // Not useful here.
- m_current_info->n_children++;
- m_current_info->children.Append(info);
-}
-
-void wxObjectOutputStream::ProcessObjectDef(wxObjectStreamInfo *info)
-{
- wxNode *node;
-
- m_current_info = info;
- // First stage: get children of obj
- if (info->object && !info->duplicate)
- info->object->StoreObject(*this);
-
- // Prepare and write the sub-entry about the child obj.
- WriteObjectDef(*info);
-
- node = info->children.First();
-
- while (node) {
- ProcessObjectDef((wxObjectStreamInfo *)node->Data());
- node = node->Next();
- }
-}
-
-void wxObjectOutputStream::ProcessObjectData(wxObjectStreamInfo *info)
-{
- wxNode *node = info->children.First();
-
- m_current_info = info;
-
- if (info->object && !info->duplicate)
- info->object->StoreObject(*this);
-
- while (node) {
- ProcessObjectData((wxObjectStreamInfo *)node->Data());
- node = node->Next();
- }
-}
-
-bool wxObjectOutputStream::SaveObject(wxObject& obj)
-{
- wxObjectStreamInfo info;
-
- if (m_saving)
- return FALSE;
-
- m_saving = TRUE;
-
- // First stage
- m_stage = 0;
- info.object = &obj;
- info.n_children = 0;
- info.duplicate = FALSE;
- ProcessObjectDef(&info);
-
- m_stage = 1;
- ProcessObjectData(&info);
-
- info.children.Clear();
- m_saved_objs.Clear();
-
- m_saving = FALSE;
-
- return TRUE;
-}
-
-// ----------------------------------------------------------------------------
-// wxObjectInputStream
-// ----------------------------------------------------------------------------
-
-wxObjectInputStream::wxObjectInputStream(wxInputStream& s)
- : wxFilterInputStream(s)
-{
- m_secondcall = FALSE;
-}
-
-wxObject *wxObjectInputStream::SolveName(const wxString& name) const
-{
- wxNode *node = m_solver.First();
- wxObjectStreamInfo *info;
-
- while (node) {
- info = (wxObjectStreamInfo *)node->Data();
- if (info->object_name == name)
- return info->object;
-
- node = node->Next();
- }
- return (wxObject *) NULL;
-}
-
-wxObject *wxObjectInputStream::GetParent() const
-{
- if (!m_current_info->parent)
- return (wxObject *) NULL;
-
- return m_current_info->parent->object;
-}
-
-wxObject *wxObjectInputStream::GetChild()
-{
- wxObject *obj = GetChild(0);
-
- m_current_info->children_removed++;
-
- return obj;
-}
-
-wxObject *wxObjectInputStream::GetChild(int no) const
-{
- wxNode *node;
- wxObjectStreamInfo *info;
-
- if (m_current_info->children_removed >= m_current_info->n_children)
- return (wxObject *) NULL;
-
- node = m_current_info->children.Nth(m_current_info->children_removed+no);
-
- if (!node)
- return (wxObject *) NULL;
-
- info = (wxObjectStreamInfo *)node->Data();
-
- return info->object;
-}
-
-void wxObjectInputStream::RemoveChildren(int nb)
-{
- m_current_info->children_removed += nb;
-}
-
-bool wxObjectInputStream::ReadObjectDef(wxObjectStreamInfo *info)
-{
- wxDataInputStream data_s(*this);
- char sig[WXOBJ_BEG_LEN+1];
- wxString class_name;
-
- Read(sig, WXOBJ_BEG_LEN);
- sig[WXOBJ_BEG_LEN] = 0;
- if (wxString(sig) != WXOBJ_BEGIN)
- return FALSE;
-
- class_name = data_s.ReadString();
- info->children_removed = 0;
- info->n_children = 0;
-
- if (class_name == TAG_EMPTY_OBJECT)
- info->object = (wxObject *) NULL;
- else if (class_name == TAG_DUPLICATE_OBJECT) {
- info->object_name = data_s.ReadString();
- info->object = SolveName(info->object_name);
- } else {
- info->object_name = data_s.ReadString();
- info->object = wxCreateDynamicObject( WXSTRINGCAST class_name);
- info->n_children = data_s.Read32();
- }
- return TRUE;
-}
-
-wxObjectStreamInfo *wxObjectInputStream::ProcessObjectDef(wxObjectStreamInfo *parent)
-{
- wxObjectStreamInfo *info, *c_info;
- int c;
-
- info = new wxObjectStreamInfo;
- info->parent = parent;
- info->children.DeleteContents(TRUE);
-
- m_solver.Append(info);
-
- if (!ReadObjectDef(info))
- return (wxObjectStreamInfo *) NULL;
-
- for (c=0;c<info->n_children;c++) {
- c_info = ProcessObjectDef(info);
- if (!c_info)
- return (wxObjectStreamInfo *) NULL;
- info->children.Append(c_info);
- }
-
- return info;
-}
-
-void wxObjectInputStream::ProcessObjectData(wxObjectStreamInfo *info)
-{
- wxNode *node = info->children.First();
-
- m_current_info = info;
-
- if (info->object)
- info->object->LoadObject(*this);
- while (node) {
- ProcessObjectData((wxObjectStreamInfo *)node->Data());
- node = node->Next();
- }
-
- m_current_info = info;
-
- if (info->recall) {
- m_secondcall = TRUE;
- info->object->LoadObject(*this);
- m_secondcall = FALSE;
- }
-}
-
-wxObject *wxObjectInputStream::LoadObject()
-{
- wxObjectStreamInfo *info;
- wxObject *object;
-
- info = ProcessObjectDef((wxObjectStreamInfo *) NULL);
- if (!info)
- return (wxObject *) NULL;
- ProcessObjectData(info);
-
- object = info->object;
-
- delete info; // It's magic ! The whole tree is destroyed.
-
- return object;
-}
-
-#endif // wxUSE_SERIAL && wxUSE_STREAMS
-
+++ /dev/null
-/////////////////////////////////////////////////////////////////////////////
-// Name: serbase.cpp
-// Purpose: wxStream base classes
-// Author: Robert Roebling
-// Modified by:
-// Created: 11/07/98
-// RCS-ID: $Id$
-// Copyright: (c) Robert Roebling
-// Licence: wxWindows license
-/////////////////////////////////////////////////////////////////////////////
-
-#ifdef __GNUG__
-#pragma implementation "serbase.h"
-#endif
-
-// For compilers that support precompilation, includes "wx.h".
-#include "wx/wxprec.h"
-#if defined(__WINDOWS__)
-#include "wx/msw/private.h"
-#endif
-
-#include "wx/serbase.h"
-#include "wx/datstrm.h"
-#include "wx/objstrm.h"
-
-#ifdef __BORLANDC__
-#pragma hdrstop
-#endif
-
-#if wxUSE_SERIAL
-
-// ----------------------------------------------------------------------------
-// wxObject_Serialize
-// ----------------------------------------------------------------------------
-
-IMPLEMENT_DYNAMIC_CLASS(wxObject_Serialize,wxObject)
-
-IMPLEMENT_SERIAL_CLASS(wxList, wxObject)
-IMPLEMENT_SERIAL_CLASS(wxHashTable, wxObject)
-
-void WXSERIAL(wxList)::StoreObject(wxObjectOutputStream& s)
-{
- wxList *lst_object = (wxList *)Object();
- wxNode *node = lst_object->First();
-
- if (s.FirstStage()) {
- while (node) {
- s.AddChild(node->Data());
- node = node->Next();
- }
- return;
- }
-
- wxDataOutputStream data_s(s);
-
- data_s.Write8(lst_object->GetDeleteContents());
- data_s.Write8(lst_object->GetKeyType());
- data_s.Write32( lst_object->Number() );
-
- if (lst_object->GetKeyType() == wxKEY_INTEGER) {
- while (node) {
- data_s.Write32((size_t)node->GetKeyInteger());
- node = node->Next();
- }
- } else {
- while (node) {
- data_s.WriteString(node->GetKeyString());
- node = node->Next();
- }
- }
-}
-
-void WXSERIAL(wxList)::LoadObject(wxObjectInputStream& s)
-{
- wxDataInputStream data_s(s);
- wxList *list = (wxList *)Object();
- int number, i;
-
- list->DeleteContents( data_s.Read8() != 0 );
- list->SetKeyType( (wxKeyType) data_s.Read8() );
- number = data_s.Read32();
-
- if (list->GetKeyType() == wxKEY_INTEGER) {
- for (i=0;i<number;i++)
- list->Append( data_s.Read32(), s.GetChild() );
- } else {
- for (i=0;i<number;i++)
- list->Append( data_s.ReadString(), s.GetChild() );
- }
-}
-
-// ----------------------------------------------------------------------------
-
-void WXSERIAL(wxHashTable)::StoreObject(wxObjectOutputStream& s)
-{
- wxHashTable *table = (wxHashTable *)Object();
- int i;
-
- if (s.FirstStage()) {
- for (i=0;i<table->n;i++)
- s.AddChild(table->hash_table[i]);
- return;
- }
-
- wxDataOutputStream data_s(s);
-
- data_s.Write8(table->key_type);
- data_s.Write32(table->n);
-}
-
-void WXSERIAL(wxHashTable)::LoadObject(wxObjectInputStream& s)
-{
- wxHashTable *table = (wxHashTable *)Object();
- wxDataInputStream data_s(s);
- int i, key, n;
-
- key = data_s.Read8();
- n = data_s.Read32();
-
- table->Create(key, n);
-
- for (i=0;i<n;i++)
- table->hash_table[i] = (wxList *)s.GetChild();
-}
-
-#endif // wxUSE_SERIAL
#include <ctype.h>
#include "wx/stream.h"
#include "wx/datstrm.h"
-#include "wx/objstrm.h"
#include "wx/textfile.h"
// ----------------------------------------------------------------------------
return pos;
}
-// --------------------
-// Overloaded operators
-// --------------------
-
-#if wxUSE_SERIAL
-wxInputStream& wxInputStream::operator>>(wxObject *& obj)
-{
- wxObjectInputStream obj_s(*this);
- obj = obj_s.LoadObject();
- return *this;
-}
-#endif // wxUSE_SERIAL
-
// ----------------------------------------------------------------------------
// wxOutputStream
{
}
-#if wxUSE_SERIAL
-wxOutputStream& wxOutputStream::operator<<(wxObject& obj)
-{
- wxObjectOutputStream obj_s(*this);
- obj_s.SaveObject(obj);
- return *this;
-}
-#endif // wxUSE_SERIAL
// ----------------------------------------------------------------------------
// wxCountingOutputStream
-# This file was automatically generated by tmake at 16:36, 2001/11/20
+# This file was automatically generated by tmake at 11:19, 2001/12/15
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE BASE.T!
ALL_SOURCES = \
common/init.cpp \
common/dircmn.cpp \
common/dynarray.cpp \
common/dynlib.cpp \
+ common/dynload.cpp \
common/encconv.cpp \
common/event.cpp \
common/extended.c \
common/module.cpp \
common/mstream.cpp \
common/object.cpp \
- common/objstrm.cpp \
common/process.cpp \
common/protocol.cpp \
common/regex.cpp \
common/sckfile.cpp \
common/sckipc.cpp \
common/sckstrm.cpp \
- common/serbase.cpp \
common/socket.cpp \
common/strconv.cpp \
common/stream.cpp \
dir.h \
dynarray.h \
dynlib.h \
+ dynload.h \
encconv.h \
event.h \
ffile.h \
module.h \
mstream.h \
object.h \
- objstrm.h \
platform.h \
process.h \
regex.h \
sckaddr.h \
sckipc.h \
sckstrm.h \
- serbase.h \
snglinst.h \
socket.h \
strconv.h \
dircmn.o \
dynarray.o \
dynlib.o \
+ dynload.o \
encconv.o \
event.o \
extended.o \
module.o \
mstream.o \
object.o \
- objstrm.o \
process.o \
protocol.o \
regex.o \
sckfile.o \
sckipc.o \
sckstrm.o \
- serbase.o \
socket.o \
strconv.o \
stream.o \
-# This file was automatically generated by tmake at 16:36, 2001/11/20
+# This file was automatically generated by tmake at 11:19, 2001/12/15
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE GTK.T!
ALL_SOURCES = \
generic/accel.cpp \
common/dseldlg.cpp \
common/dynarray.cpp \
common/dynlib.cpp \
+ common/dynload.cpp \
common/effects.cpp \
common/encconv.cpp \
common/event.cpp \
common/mstream.cpp \
common/nbkbase.cpp \
common/object.cpp \
- common/objstrm.cpp \
common/paper.cpp \
common/popupcmn.cpp \
common/prntbase.cpp \
common/sckfile.cpp \
common/sckipc.cpp \
common/sckstrm.cpp \
- common/serbase.cpp \
common/sizer.cpp \
common/socket.cpp \
common/statbar.cpp \
dragimag.h \
dynarray.h \
dynlib.h \
+ dynload.h \
encconv.h \
event.h \
expr.h \
mstream.h \
notebook.h \
object.h \
- objstrm.h \
odbc.h \
ownerdrw.h \
palette.h \
sckstrm.h \
scrolbar.h \
scrolwin.h \
- serbase.h \
settings.h \
sizer.h \
slider.h \
dseldlg.o \
dynarray.o \
dynlib.o \
+ dynload.o \
effects.o \
encconv.o \
event.o \
mstream.o \
nbkbase.o \
object.o \
- objstrm.o \
paper.o \
popupcmn.o \
prntbase.o \
sckfile.o \
sckipc.o \
sckstrm.o \
- serbase.o \
sizer.o \
socket.o \
statbar.o \
-# This file was automatically generated by tmake at 16:36, 2001/11/20
+# This file was automatically generated by tmake at 11:19, 2001/12/15
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE GTK.T!
ALL_SOURCES = \
generic/accel.cpp \
common/dseldlg.cpp \
common/dynarray.cpp \
common/dynlib.cpp \
+ common/dynload.cpp \
common/effects.cpp \
common/encconv.cpp \
common/event.cpp \
common/mstream.cpp \
common/nbkbase.cpp \
common/object.cpp \
- common/objstrm.cpp \
common/paper.cpp \
common/popupcmn.cpp \
common/prntbase.cpp \
common/sckfile.cpp \
common/sckipc.cpp \
common/sckstrm.cpp \
- common/serbase.cpp \
common/sizer.cpp \
common/socket.cpp \
common/statbar.cpp \
dragimag.h \
dynarray.h \
dynlib.h \
+ dynload.h \
encconv.h \
event.h \
expr.h \
mstream.h \
notebook.h \
object.h \
- objstrm.h \
odbc.h \
ownerdrw.h \
palette.h \
sckstrm.h \
scrolbar.h \
scrolwin.h \
- serbase.h \
settings.h \
sizer.h \
slider.h \
dseldlg.o \
dynarray.o \
dynlib.o \
+ dynload.o \
effects.o \
encconv.o \
event.o \
mstream.o \
nbkbase.o \
object.o \
- objstrm.o \
paper.o \
popupcmn.o \
prntbase.o \
sckfile.o \
sckipc.o \
sckstrm.o \
- serbase.o \
sizer.o \
socket.o \
statbar.o \
-# This file was automatically generated by tmake at 16:36, 2001/11/20
+# This file was automatically generated by tmake at 11:19, 2001/12/15
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE MAC.T!
ALL_SOURCES = \
generic/busyinfo.cpp \
common/dseldlg.cpp \
common/dynarray.cpp \
common/dynlib.cpp \
+ common/dynload.cpp \
common/effects.cpp \
common/encconv.cpp \
common/event.cpp \
common/mstream.cpp \
common/nbkbase.cpp \
common/object.cpp \
- common/objstrm.cpp \
common/odbc.cpp \
common/paper.cpp \
common/popupcmn.cpp \
common/sckfile.cpp \
common/sckipc.cpp \
common/sckstrm.cpp \
- common/serbase.cpp \
common/sizer.cpp \
common/socket.cpp \
common/statbar.cpp \
dragimag.h \
dynarray.h \
dynlib.h \
+ dynload.h \
encconv.h \
event.h \
expr.h \
mstream.h \
notebook.h \
object.h \
- objstrm.h \
odbc.h \
ownerdrw.h \
palette.h \
sckstrm.h \
scrolbar.h \
scrolwin.h \
- serbase.h \
settings.h \
sizer.h \
slider.h \
dseldlg.o \
dynarray.o \
dynlib.o \
+ dynload.o \
effects.o \
encconv.o \
event.o \
mstream.o \
nbkbase.o \
object.o \
- objstrm.o \
odbc.o \
paper.o \
popupcmn.o \
sckfile.o \
sckipc.o \
sckstrm.o \
- serbase.o \
sizer.o \
socket.o \
statbar.o \
-# This file was automatically generated by tmake at 16:36, 2001/11/20
+# This file was automatically generated by tmake at 11:19, 2001/12/15
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE MAC.T!
ALL_SOURCES = \
generic/busyinfo.cpp \
common/dseldlg.cpp \
common/dynarray.cpp \
common/dynlib.cpp \
+ common/dynload.cpp \
common/effects.cpp \
common/encconv.cpp \
common/event.cpp \
common/mstream.cpp \
common/nbkbase.cpp \
common/object.cpp \
- common/objstrm.cpp \
common/odbc.cpp \
common/paper.cpp \
common/popupcmn.cpp \
common/sckfile.cpp \
common/sckipc.cpp \
common/sckstrm.cpp \
- common/serbase.cpp \
common/sizer.cpp \
common/socket.cpp \
common/statbar.cpp \
dragimag.h \
dynarray.h \
dynlib.h \
+ dynload.h \
encconv.h \
event.h \
expr.h \
mstream.h \
notebook.h \
object.h \
- objstrm.h \
odbc.h \
ownerdrw.h \
palette.h \
sckstrm.h \
scrolbar.h \
scrolwin.h \
- serbase.h \
settings.h \
sizer.h \
slider.h \
dseldlg.o \
dynarray.o \
dynlib.o \
+ dynload.o \
effects.o \
encconv.o \
event.o \
mstream.o \
nbkbase.o \
object.o \
- objstrm.o \
odbc.o \
paper.o \
popupcmn.o \
sckfile.o \
sckipc.o \
sckstrm.o \
- serbase.o \
sizer.o \
socket.o \
statbar.o \
-# This file was automatically generated by tmake at 20:44, 2001/12/09
+# This file was automatically generated by tmake at 11:19, 2001/12/15
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE GTK.T!
ALL_SOURCES = \
generic/accel.cpp \
common/dseldlg.cpp \
common/dynarray.cpp \
common/dynlib.cpp \
+ common/dynload.cpp \
common/effects.cpp \
common/encconv.cpp \
common/event.cpp \
common/mstream.cpp \
common/nbkbase.cpp \
common/object.cpp \
- common/objstrm.cpp \
common/odbc.cpp \
common/paper.cpp \
common/popupcmn.cpp \
common/sckfile.cpp \
common/sckipc.cpp \
common/sckstrm.cpp \
- common/serbase.cpp \
common/sizer.cpp \
common/socket.cpp \
common/statbar.cpp \
dragimag.h \
dynarray.h \
dynlib.h \
+ dynload.h \
encconv.h \
event.h \
expr.h \
mstream.h \
notebook.h \
object.h \
- objstrm.h \
odbc.h \
ownerdrw.h \
palette.h \
sckstrm.h \
scrolbar.h \
scrolwin.h \
- serbase.h \
settings.h \
sizer.h \
slider.h \
dseldlg.o \
dynarray.o \
dynlib.o \
+ dynload.o \
effects.o \
encconv.o \
event.o \
mstream.o \
nbkbase.o \
object.o \
- objstrm.o \
odbc.o \
paper.o \
popupcmn.o \
sckfile.o \
sckipc.o \
sckstrm.o \
- serbase.o \
sizer.o \
socket.o \
statbar.o \
#!/binb/wmake.exe
-# This file was automatically generated by tmake at 20:44, 2001/12/09
+# This file was automatically generated by tmake at 11:19, 2001/12/15
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE WAT.T!
#
dseldlg.obj &
dynarray.obj &
dynlib.obj &
+ dynload.obj &
effects.obj &
encconv.obj &
event.obj &
mstream.obj &
nbkbase.obj &
object.obj &
- objstrm.obj &
odbc.obj &
paper.obj &
popupcmn.obj &
sckfile.obj &
sckipc.obj &
sckstrm.obj &
- serbase.obj &
sizer.obj &
socket.obj &
statbar.obj &
dynlib.obj: $(COMMDIR)\dynlib.cpp
*$(CCC) $(CPPFLAGS) $(IFLAGS) $<
+dynload.obj: $(COMMDIR)\dynload.cpp
+ *$(CCC) $(CPPFLAGS) $(IFLAGS) $<
+
effects.obj: $(COMMDIR)\effects.cpp
*$(CCC) $(CPPFLAGS) $(IFLAGS) $<
object.obj: $(COMMDIR)\object.cpp
*$(CCC) $(CPPFLAGS) $(IFLAGS) $<
-objstrm.obj: $(COMMDIR)\objstrm.cpp
- *$(CCC) $(CPPFLAGS) $(IFLAGS) $<
-
odbc.obj: $(COMMDIR)\odbc.cpp
*$(CCC) $(CPPFLAGS) $(IFLAGS) $<
sckstrm.obj: $(COMMDIR)\sckstrm.cpp
*$(CCC) $(CPPFLAGS) $(IFLAGS) $<
-serbase.obj: $(COMMDIR)\serbase.cpp
- *$(CCC) $(CPPFLAGS) $(IFLAGS) $<
-
sizer.obj: $(COMMDIR)\sizer.cpp
*$(CCC) $(CPPFLAGS) $(IFLAGS) $<
-# This file was automatically generated by tmake at 21:46, 2001/11/21
+# This file was automatically generated by tmake at 11:19, 2001/12/15
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE MOTIF.T!
ALL_SOURCES = \
generic/busyinfo.cpp \
common/dseldlg.cpp \
common/dynarray.cpp \
common/dynlib.cpp \
+ common/dynload.cpp \
common/effects.cpp \
common/encconv.cpp \
common/event.cpp \
common/mstream.cpp \
common/nbkbase.cpp \
common/object.cpp \
- common/objstrm.cpp \
common/paper.cpp \
common/popupcmn.cpp \
common/prntbase.cpp \
common/sckfile.cpp \
common/sckipc.cpp \
common/sckstrm.cpp \
- common/serbase.cpp \
common/sizer.cpp \
common/socket.cpp \
common/statbar.cpp \
dragimag.h \
dynarray.h \
dynlib.h \
+ dynload.h \
encconv.h \
event.h \
expr.h \
mstream.h \
notebook.h \
object.h \
- objstrm.h \
odbc.h \
ownerdrw.h \
palette.h \
sckstrm.h \
scrolbar.h \
scrolwin.h \
- serbase.h \
settings.h \
sizer.h \
slider.h \
dseldlg.o \
dynarray.o \
dynlib.o \
+ dynload.o \
effects.o \
encconv.o \
event.o \
mstream.o \
nbkbase.o \
object.o \
- objstrm.o \
paper.o \
popupcmn.o \
prntbase.o \
sckfile.o \
sckipc.o \
sckstrm.o \
- serbase.o \
sizer.o \
socket.o \
statbar.o \
#include "wx/msw/private.h" // must be before #include "dynlib.h"
-#if !wxUSE_DYNLIB_CLASS
- #error You need wxUSE_DYNLIB_CLASS to be 1 to compile dialup.cpp.
-#endif
-
+#if wxUSE_DYNAMIC_LOADER || wxUSE_DYNLIB_CLASS
#include "wx/dynlib.h"
+#else
+#error You need wxUSE_DYNAMIC_LOADER to be 1 to compile dialup.cpp.
+#endif
#include "wx/dialup.h"
if ( !ms_nDllCount++ )
{
// load the RAS library
- ms_dllRas = wxDllLoader::LoadLibrary("RASAPI32");
+ ms_dllRas = wxDllLoader::LoadLibrary(_T("RASAPI32"));
if ( !ms_dllRas )
{
wxLogError(_("Dial up functions are unavailable because the remote access service (RAS) is not installed on this machine. Please install it."));
}
// try to use WinInet function first
- bool ok;
- wxDllType hDll = wxDllLoader::LoadLibrary(_T("WININET"), &ok);
- if ( ok )
+ wxDllType hDll = wxDllLoader::LoadLibrary(_T("WININET"));
+ if ( hDll )
{
typedef BOOL (WINAPI *INTERNETGETCONNECTEDSTATE)(LPDWORD, DWORD);
INTERNETGETCONNECTEDSTATE pfnInternetGetConnectedState;
-# This file was automatically generated by tmake at 16:36, 2001/11/20
+# This file was automatically generated by tmake at 11:19, 2001/12/15
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE MSW.T!
ALL_SOURCES = \
generic/busyinfo.cpp \
common/dseldlg.cpp \
common/dynarray.cpp \
common/dynlib.cpp \
+ common/dynload.cpp \
common/effects.cpp \
common/encconv.cpp \
common/event.cpp \
common/mstream.cpp \
common/nbkbase.cpp \
common/object.cpp \
- common/objstrm.cpp \
common/paper.cpp \
common/popupcmn.cpp \
common/prntbase.cpp \
common/sckfile.cpp \
common/sckipc.cpp \
common/sckstrm.cpp \
- common/serbase.cpp \
common/sizer.cpp \
common/socket.cpp \
common/statbar.cpp \
dragimag.h \
dynarray.h \
dynlib.h \
+ dynload.h \
encconv.h \
event.h \
expr.h \
mstream.h \
notebook.h \
object.h \
- objstrm.h \
odbc.h \
ownerdrw.h \
palette.h \
sckstrm.h \
scrolbar.h \
scrolwin.h \
- serbase.h \
settings.h \
sizer.h \
slider.h \
dseldlg.o \
dynarray.o \
dynlib.o \
+ dynload.o \
effects.o \
encconv.o \
event.o \
mstream.o \
nbkbase.o \
object.o \
- objstrm.o \
paper.o \
popupcmn.o \
prntbase.o \
sckfile.o \
sckipc.o \
sckstrm.o \
- serbase.o \
sizer.o \
socket.o \
statbar.o \
#if wxUSE_HELP && wxUSE_MS_HTML_HELP && defined(__WIN95__)
#include "wx/msw/helpchm.h"
+
+#if wxUSE_DYNAMIC_LOADER || wxUSE_DYNLIB_CLASS
#include "wx/dynlib.h"
-
+#endif
+
#ifndef WX_PRECOMP
#include <windows.h>
#endif
-# This file was automatically generated by tmake at 16:36, 2001/11/20
+# This file was automatically generated by tmake at 11:19, 2001/12/15
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE B32.T!
#
$(MSWDIR)\dseldlg.obj \
$(MSWDIR)\dynarray.obj \
$(MSWDIR)\dynlib.obj \
+ $(MSWDIR)\dynload.obj \
$(MSWDIR)\effects.obj \
$(MSWDIR)\encconv.obj \
$(MSWDIR)\event.obj \
$(MSWDIR)\mstream.obj \
$(MSWDIR)\nbkbase.obj \
$(MSWDIR)\object.obj \
- $(MSWDIR)\objstrm.obj \
$(MSWDIR)\odbc.obj \
$(MSWDIR)\paper.obj \
$(MSWDIR)\popupcmn.obj \
$(MSWDIR)\sckfile.obj \
$(MSWDIR)\sckipc.obj \
$(MSWDIR)\sckstrm.obj \
- $(MSWDIR)\serbase.obj \
$(MSWDIR)\sizer.obj \
$(MSWDIR)\socket.obj \
$(MSWDIR)\statbar.obj \
$(MSWDIR)\dynlib.obj: $(COMMDIR)\dynlib.$(SRCSUFF)
+$(MSWDIR)\dynload.obj: $(COMMDIR)\dynload.$(SRCSUFF)
+
$(MSWDIR)\effects.obj: $(COMMDIR)\effects.$(SRCSUFF)
$(MSWDIR)\encconv.obj: $(COMMDIR)\encconv.$(SRCSUFF)
$(MSWDIR)\object.obj: $(COMMDIR)\object.$(SRCSUFF)
-$(MSWDIR)\objstrm.obj: $(COMMDIR)\objstrm.$(SRCSUFF)
-
$(MSWDIR)\odbc.obj: $(COMMDIR)\odbc.$(SRCSUFF)
$(MSWDIR)\paper.obj: $(COMMDIR)\paper.$(SRCSUFF)
$(MSWDIR)\sckstrm.obj: $(COMMDIR)\sckstrm.$(SRCSUFF)
-$(MSWDIR)\serbase.obj: $(COMMDIR)\serbase.$(SRCSUFF)
-
$(MSWDIR)\sizer.obj: $(COMMDIR)\sizer.$(SRCSUFF)
$(MSWDIR)\socket.obj: $(COMMDIR)\socket.$(SRCSUFF)
-# This file was automatically generated by tmake at 16:36, 2001/11/20
+# This file was automatically generated by tmake at 11:19, 2001/12/15
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE BCC.T!
#
$(MSWDIR)\dseldlg.obj \
$(MSWDIR)\dynarray.obj \
$(MSWDIR)\dynlib.obj \
+ $(MSWDIR)\dynload.obj \
$(MSWDIR)\effects.obj \
$(MSWDIR)\encconv.obj \
$(MSWDIR)\event.obj \
$(MSWDIR)\mstream.obj \
$(MSWDIR)\nbkbase.obj \
$(MSWDIR)\object.obj \
- $(MSWDIR)\objstrm.obj \
$(MSWDIR)\paper.obj \
$(MSWDIR)\popupcmn.obj \
$(MSWDIR)\prntbase.obj \
$(MSWDIR)\radiocmn.obj \
$(MSWDIR)\regex.obj \
$(MSWDIR)\resource.obj \
- $(MSWDIR)\serbase.obj \
$(MSWDIR)\sizer.obj \
$(MSWDIR)\statbar.obj \
$(MSWDIR)\strconv.obj \
$(MSWDIR)\dynlib.obj: $(COMMDIR)\dynlib.$(SRCSUFF)
+$(MSWDIR)\dynload.obj: $(COMMDIR)\dynload.$(SRCSUFF)
+
$(MSWDIR)\effects.obj: $(COMMDIR)\effects.$(SRCSUFF)
$(MSWDIR)\encconv.obj: $(COMMDIR)\encconv.$(SRCSUFF)
$(MSWDIR)\object.obj: $(COMMDIR)\object.$(SRCSUFF)
-$(MSWDIR)\objstrm.obj: $(COMMDIR)\objstrm.$(SRCSUFF)
-
$(MSWDIR)\paper.obj: $(COMMDIR)\paper.$(SRCSUFF)
$(MSWDIR)\popupcmn.obj: $(COMMDIR)\popupcmn.$(SRCSUFF)
$(MSWDIR)\resource.obj: $(COMMDIR)\resource.$(SRCSUFF)
-$(MSWDIR)\serbase.obj: $(COMMDIR)\serbase.$(SRCSUFF)
-
$(MSWDIR)\sizer.obj: $(COMMDIR)\sizer.$(SRCSUFF)
$(MSWDIR)\statbar.obj: $(COMMDIR)\statbar.$(SRCSUFF)
-# This file was automatically generated by tmake at 16:36, 2001/11/20
+# This file was automatically generated by tmake at 11:19, 2001/12/15
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE DOS.T!
#
$(COMMDIR)\dseldlg.obj \
$(COMMDIR)\dynarray.obj \
$(COMMDIR)\dynlib.obj \
+ $(COMMDIR)\dynload.obj \
$(COMMDIR)\effects.obj \
$(COMMDIR)\encconv.obj \
$(COMMDIR)\event.obj \
$(COMMDIR)\mstream.obj \
$(COMMDIR)\nbkbase.obj \
$(COMMDIR)\object.obj \
- $(COMMDIR)\objstrm.obj \
$(COMMDIR)\odbc.obj
COMMONOBJS2 = \
$(COMMDIR)\radiocmn.obj \
$(COMMDIR)\regex.obj \
$(COMMDIR)\resource.obj \
- $(COMMDIR)\serbase.obj \
$(COMMDIR)\sizer.obj \
$(COMMDIR)\statbar.obj \
$(COMMDIR)\strconv.obj \
$(CPPFLAGS) /Fo$@ /c /Tp $*.$(SRCSUFF)
<<
+$(COMMDIR)/dynload.obj: $*.$(SRCSUFF)
+ cl @<<
+$(CPPFLAGS) /Fo$@ /c /Tp $*.$(SRCSUFF)
+<<
+
$(COMMDIR)/effects.obj: $*.$(SRCSUFF)
cl @<<
$(CPPFLAGS) /Fo$@ /c /Tp $*.$(SRCSUFF)
$(CPPFLAGS) /Fo$@ /c /Tp $*.$(SRCSUFF)
<<
-$(COMMDIR)/objstrm.obj: $*.$(SRCSUFF)
- cl @<<
-$(CPPFLAGS) /Fo$@ /c /Tp $*.$(SRCSUFF)
-<<
-
$(COMMDIR)/odbc.obj: $*.$(SRCSUFF)
cl @<<
$(CPPFLAGS) /Fo$@ /c /Tp $*.$(SRCSUFF)
$(CPPFLAGS) /Fo$@ /c /Tp $*.$(SRCSUFF)
<<
-$(COMMDIR)/serbase.obj: $*.$(SRCSUFF)
- cl @<<
-$(CPPFLAGS) /Fo$@ /c /Tp $*.$(SRCSUFF)
-<<
-
$(COMMDIR)/sizer.obj: $*.$(SRCSUFF)
cl @<<
$(CPPFLAGS) /Fo$@ /c /Tp $*.$(SRCSUFF)
-# This file was automatically generated by tmake at 16:36, 2001/11/20
+# This file was automatically generated by tmake at 11:19, 2001/12/15
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE G95.T!
#
$(COMMDIR)/dseldlg.$(OBJSUFF) \
$(COMMDIR)/dynarray.$(OBJSUFF) \
$(COMMDIR)/dynlib.$(OBJSUFF) \
+ $(COMMDIR)/dynload.$(OBJSUFF) \
$(COMMDIR)/effects.$(OBJSUFF) \
$(COMMDIR)/encconv.$(OBJSUFF) \
$(COMMDIR)/event.$(OBJSUFF) \
$(COMMDIR)/mstream.$(OBJSUFF) \
$(COMMDIR)/nbkbase.$(OBJSUFF) \
$(COMMDIR)/object.$(OBJSUFF) \
- $(COMMDIR)/objstrm.$(OBJSUFF) \
$(COMMDIR)/paper.$(OBJSUFF) \
$(COMMDIR)/popupcmn.$(OBJSUFF) \
$(COMMDIR)/prntbase.$(OBJSUFF) \
$(COMMDIR)/sckfile.$(OBJSUFF) \
$(COMMDIR)/sckipc.$(OBJSUFF) \
$(COMMDIR)/sckstrm.$(OBJSUFF) \
- $(COMMDIR)/serbase.$(OBJSUFF) \
$(COMMDIR)/sizer.$(OBJSUFF) \
$(COMMDIR)/socket.$(OBJSUFF) \
$(COMMDIR)/statbar.$(OBJSUFF) \
endif
#ARCHINCDIR=$(subst $(PATH_SUBST),$(PATH_SEPARATOR),$(WXDIR)/lib/msw$(INCEXT))
-ARCHINCDIR=$(WXDIR)/lib/msw$(INCEXT)
+ARCHINCDIR=(WXDIR)/lib/msw$(INCEXT)
SETUP_H=$(ARCHINCDIR)/wx/setup.h
-# This file was automatically generated by tmake at 16:36, 2001/11/20
+# This file was automatically generated by tmake at 11:19, 2001/12/15
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE SC.T!
# Symantec C++ makefile for the msw objects
$(COMMDIR)\dseldlg.obj \
$(COMMDIR)\dynarray.obj \
$(COMMDIR)\dynlib.obj \
+ $(COMMDIR)\dynload.obj \
$(COMMDIR)\effects.obj \
$(COMMDIR)\encconv.obj \
$(COMMDIR)\event.obj \
$(COMMDIR)\mstream.obj \
$(COMMDIR)\nbkbase.obj \
$(COMMDIR)\object.obj \
- $(COMMDIR)\objstrm.obj \
$(COMMDIR)\odbc.obj \
$(COMMDIR)\paper.obj \
$(COMMDIR)\popupcmn.obj \
$(COMMDIR)\sckfile.obj \
$(COMMDIR)\sckipc.obj \
$(COMMDIR)\sckstrm.obj \
- $(COMMDIR)\serbase.obj \
$(COMMDIR)\sizer.obj \
$(COMMDIR)\socket.obj \
$(COMMDIR)\statbar.obj \
-# This file was automatically generated by tmake at 12:26, 2001/12/01
+# This file was automatically generated by tmake at 11:19, 2001/12/15
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE VC.T!
# File: makefile.vc
$(COMMDIR)\$D\dseldlg.obj \
$(COMMDIR)\$D\dynarray.obj \
$(COMMDIR)\$D\dynlib.obj \
+ $(COMMDIR)\$D\dynload.obj \
$(COMMDIR)\$D\effects.obj \
$(COMMDIR)\$D\encconv.obj \
$(COMMDIR)\$D\event.obj \
$(COMMDIR)\$D\mstream.obj \
$(COMMDIR)\$D\nbkbase.obj \
$(COMMDIR)\$D\object.obj \
- $(COMMDIR)\$D\objstrm.obj \
$(COMMDIR)\$D\odbc.obj \
$(COMMDIR)\$D\paper.obj \
$(COMMDIR)\$D\popupcmn.obj \
$(COMMDIR)\$D\sckfile.obj \
$(COMMDIR)\$D\sckipc.obj \
$(COMMDIR)\$D\sckstrm.obj \
- $(COMMDIR)\$D\serbase.obj \
$(COMMDIR)\$D\sizer.obj \
$(COMMDIR)\$D\socket.obj \
$(COMMDIR)\$D\statbar.obj \
#!/binb/wmake.exe
-# This file was automatically generated by tmake at 00:10, 2001/12/09
+# This file was automatically generated by tmake at 11:19, 2001/12/15
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE WAT.T!
#
dseldlg.obj &
dynarray.obj &
dynlib.obj &
+ dynload.obj &
effects.obj &
encconv.obj &
event.obj &
mstream.obj &
nbkbase.obj &
object.obj &
- objstrm.obj &
odbc.obj &
paper.obj &
popupcmn.obj &
sckfile.obj &
sckipc.obj &
sckstrm.obj &
- serbase.obj &
sizer.obj &
socket.obj &
statbar.obj &
dynlib.obj: $(COMMDIR)\dynlib.cpp
*$(CCC) $(CPPFLAGS) $(IFLAGS) $<
+dynload.obj: $(COMMDIR)\dynload.cpp
+ *$(CCC) $(CPPFLAGS) $(IFLAGS) $<
+
effects.obj: $(COMMDIR)\effects.cpp
*$(CCC) $(CPPFLAGS) $(IFLAGS) $<
object.obj: $(COMMDIR)\object.cpp
*$(CCC) $(CPPFLAGS) $(IFLAGS) $<
-objstrm.obj: $(COMMDIR)\objstrm.cpp
- *$(CCC) $(CPPFLAGS) $(IFLAGS) $<
-
odbc.obj: $(COMMDIR)\odbc.cpp
*$(CCC) $(CPPFLAGS) $(IFLAGS) $<
sckstrm.obj: $(COMMDIR)\sckstrm.cpp
*$(CCC) $(CPPFLAGS) $(IFLAGS) $<
-serbase.obj: $(COMMDIR)\serbase.cpp
- *$(CCC) $(CPPFLAGS) $(IFLAGS) $<
-
sizer.obj: $(COMMDIR)\sizer.cpp
*$(CCC) $(CPPFLAGS) $(IFLAGS) $<
-# This file was automatically generated by tmake at 14:59, 2001/10/09
+# This file was automatically generated by tmake at 18:48, 2001/12/10
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE OS2.T!
ALL_SOURCES = \
generic/busyinfo.cpp \
common/dobjcmn.cpp \
common/docmdi.cpp \
common/docview.cpp \
+ common/dseldlg.cpp \
common/dynarray.cpp \
common/dynlib.cpp \
+ common/dynload.cpp \
common/effects.cpp \
common/encconv.cpp \
common/event.cpp \
common/mstream.cpp \
common/nbkbase.cpp \
common/object.cpp \
- common/objstrm.cpp \
common/paper.cpp \
common/popupcmn.cpp \
common/prntbase.cpp \
common/sckfile.cpp \
common/sckipc.cpp \
common/sckstrm.cpp \
- common/serbase.cpp \
common/sizer.cpp \
common/socket.cpp \
+ common/statbar.cpp \
common/strconv.cpp \
common/stream.cpp \
common/string.cpp \
common/sysopt.cpp \
common/tbarbase.cpp \
+ common/textbuf.cpp \
common/textcmn.cpp \
common/textfile.cpp \
common/timercmn.cpp \
dragimag.h \
dynarray.h \
dynlib.h \
+ dynload.h \
encconv.h \
event.h \
expr.h \
mdi.h \
memconf.h \
memory.h \
+ memtext.h \
menu.h \
menuitem.h \
metafile.h \
mstream.h \
notebook.h \
object.h \
- objstrm.h \
odbc.h \
ownerdrw.h \
palette.h \
panel.h \
paper.h \
pen.h \
+ platform.h \
popupwin.h \
print.h \
printdlg.h \
sckstrm.h \
scrolbar.h \
scrolwin.h \
- serbase.h \
settings.h \
- setup.h \
sizer.h \
slider.h \
snglinst.h \
taskbar.h \
tbarbase.h \
tbarsmpl.h \
+ textbuf.h \
textctrl.h \
textdlg.h \
textfile.h \
dobjcmn.o \
docmdi.o \
docview.o \
+ dseldlg.o \
dynarray.o \
dynlib.o \
+ dynload.o \
effects.o \
encconv.o \
event.o \
mstream.o \
nbkbase.o \
object.o \
- objstrm.o \
paper.o \
popupcmn.o \
prntbase.o \
sckfile.o \
sckipc.o \
sckstrm.o \
- serbase.o \
sizer.o \
socket.o \
+ statbar.o \
strconv.o \
stream.o \
string.o \
sysopt.o \
tbarbase.o \
+ textbuf.o \
textcmn.o \
textfile.o \
timercmn.o \
-# This file was automatically generated by tmake at 16:36, 2001/11/20
+# This file was automatically generated by tmake at 11:19, 2001/12/15
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE UNIV.T!
UNIVOBJS = \
bmpbuttn.o \
# End Source File
# Begin Source File
+SOURCE=.\common\dynload.cpp
+# End Source File
+# Begin Source File
+
SOURCE=.\common\encconv.cpp
# End Source File
# Begin Source File
# End Source File
# Begin Source File
-SOURCE=.\common\objstrm.cpp
-# End Source File
-# Begin Source File
-
SOURCE=.\common\process.cpp
# End Source File
# Begin Source File
# End Source File
# Begin Source File
-SOURCE=.\common\serbase.cpp
-# End Source File
-# Begin Source File
-
SOURCE=.\common\socket.cpp
# End Source File
# Begin Source File
# End Source File
# Begin Source File
+SOURCE=..\include\wx\dynload.h
+# End Source File
+# Begin Source File
+
SOURCE=..\include\wx\encconv.h
# End Source File
# Begin Source File
# End Source File
# Begin Source File
-SOURCE=..\include\wx\objstrm.h
-# End Source File
-# Begin Source File
-
SOURCE=..\include\wx\platform.h
# End Source File
# Begin Source File
# End Source File
# Begin Source File
-SOURCE=..\include\wx\serbase.h
-# End Source File
-# Begin Source File
-
SOURCE=..\include\wx\snglinst.h
# End Source File
# Begin Source File
# End Source File
# Begin Source File
+SOURCE=.\common\dynload.cpp
+# End Source File
+# Begin Source File
+
SOURCE=.\common\effects.cpp
# End Source File
# Begin Source File
# End Source File
# Begin Source File
-SOURCE=.\common\objstrm.cpp
-# End Source File
-# Begin Source File
-
SOURCE=.\common\odbc.cpp
# End Source File
# Begin Source File
# End Source File
# Begin Source File
-SOURCE=.\common\serbase.cpp
-# End Source File
-# Begin Source File
-
SOURCE=.\common\sizer.cpp
# End Source File
# Begin Source File
# End Source File
# Begin Source File
+SOURCE=..\include\wx\dynload.h
+# End Source File
+# Begin Source File
+
SOURCE=..\include\wx\encconv.h
# End Source File
# Begin Source File
# End Source File
# Begin Source File
-SOURCE=..\include\wx\objstrm.h
-# End Source File
-# Begin Source File
-
SOURCE=..\include\wx\odbc.h
# End Source File
# Begin Source File
# End Source File
# Begin Source File
-SOURCE=..\include\wx\serbase.h
-# End Source File
-# Begin Source File
-
SOURCE=..\include\wx\settings.h
# End Source File
# Begin Source File
# Microsoft Developer Studio Generated Build File, Format Version 6.00
# ** DO NOT EDIT **
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
# TARGTYPE "Win32 (x86) Static Library" 0x0104
+# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
CFG=wxWindows - Win32 Debug
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
# PROP AllowPerConfigDependencies 0
# PROP Scc_ProjName ""
# PROP Scc_LocalPath ""
+CPP=cl.exe
+RSC=rc.exe
!IF "$(CFG)" == "wxWindows - Win32 Release Unicode DLL"
# PROP Intermediate_Dir "../ReleaseUnicodeDll"
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
-CPP=cl.exe
# ADD BASE CPP /nologo /MD /W4 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "WXWINDLL_EXPORTS" /YX /FD /c
# ADD CPP /nologo /MD /W4 /O2 /I "../lib/mswdllu" /I "../include" /I "./zlib" /I "./jpeg" /I "./png" /I "./regex" /I "./tiff" /D "_USRDLL" /D "WIN32" /D "NDEBUG" /D WINVER=0x0400 /D "STRICT" /D "WXMAKINGDLL" /D "_UNICODE" /D "UNICODE" /Yu"wx/wxprec.h" /FD /c
-MTL=midl.exe
# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-RSC=rc.exe
# ADD BASE RSC /l 0x409 /d "NDEBUG"
# ADD RSC /l 0x409 /i "../include" /d "NDEBUG"
BSC32=bscmake.exe
# PROP Intermediate_Dir "../DebugUnicodeDll"
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
-CPP=cl.exe
# ADD BASE CPP /nologo /MDd /W4 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "WXWINDLL_EXPORTS" /YX /FD /GZ /c
# ADD CPP /nologo /MDd /W4 /Zi /Od /I "../lib/mswdllud" /I "../include" /I "./zlib" /I "./jpeg" /I "./png" /I "./regex" /I "./tiff" /D "_USRDLL" /D "WIN32" /D "_DEBUG" /D WINVER=0x0400 /D "STRICT" /D "WXMAKINGDLL" /D "_UNICODE" /D "UNICODE" /Yu"wx/wxprec.h" /FD /c
-MTL=midl.exe
# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-RSC=rc.exe
# ADD BASE RSC /l 0x409 /d "_DEBUG"
# ADD RSC /l 0x409 /i "../include" /d "_DEBUG"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib winmm.lib ..\lib\jpegd.lib ..\lib\tiffd.lib ..\lib\pngd.lib ..\lib\regexd.lib ..\lib\zlibd.lib /dll /debug /machine:I386 /out:"../lib/wxmsw232ud.dll" /pdbtype:sept
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib advapi32.lib comdlg32.lib shell32.lib ole32.lib oleaut32.lib odbc32.lib uuid.lib rpcrt4.lib comctl32.lib wsock32.lib winmm.lib ..\lib\jpegd.lib ..\lib\tiffd.lib ..\lib\pngd.lib ..\lib\regexd.lib ..\lib\zlibd.lib /nologo /version:2.3 /dll /debug /machine:I386 /out:"../lib/wxmsw232ud.dll" /pdbtype:sept
+# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib winmm.lib ..\lib\jpegd.lib ..\lib\tiffd.lib ..\lib\pngd.lib ..\lib\regexd.lib ..\lib\zlibd.lib /dll /debug /machine:I386 /pdbtype:sept /out:"../lib/wxmsw232ud.dll"
+# ADD LINK32 kernel32.lib user32.lib gdi32.lib advapi32.lib comdlg32.lib shell32.lib ole32.lib oleaut32.lib odbc32.lib uuid.lib rpcrt4.lib comctl32.lib wsock32.lib winmm.lib ..\lib\jpegd.lib ..\lib\tiffd.lib ..\lib\pngd.lib ..\lib\regexd.lib ..\lib\zlibd.lib /nologo /version:2.3 /dll /debug /machine:I386 /pdbtype:sept /out:"../lib/wxmsw232ud.dll"
!ELSEIF "$(CFG)" == "wxWindows - Win32 Release Unicode"
# PROP Output_Dir "../lib"
# PROP Intermediate_Dir "../ReleaseUnicode"
# PROP Target_Dir ""
-CPP=cl.exe
# ADD BASE CPP /nologo /MD /W4 /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /YX /FD /c
# ADD CPP /nologo /MD /W4 /O2 /I "../lib/mswu" /I "../include" /I "./zlib" /I "./jpeg" /I "./png" /I "./regex" /I "./tiff" /D "WIN32" /D "NDEBUG" /D WINVER=0x0400 /D "STRICT" /D "_UNICODE" /D "UNICODE" /Yu"wx/wxprec.h" /FD /c
-RSC=rc.exe
# ADD BASE RSC /l 0x409
# ADD RSC /l 0x409
BSC32=bscmake.exe
# PROP Output_Dir "../lib"
# PROP Intermediate_Dir "../DebugUnicode"
# PROP Target_Dir ""
-CPP=cl.exe
# ADD BASE CPP /nologo /MDd /W4 /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /YX /FD /c
# ADD CPP /nologo /MDd /W4 /Zi /Od /I "../lib/mswud" /I "../include" /I "./zlib" /I "./jpeg" /I "./png" /I "./regex" /I "./tiff" /D "WIN32" /D "_DEBUG" /D "__WXDEBUG__" /D WINVER=0x0400 /D "STRICT" /D "_UNICODE" /D "UNICODE" /Yu"wx/wxprec.h" /FD /c
-RSC=rc.exe
# ADD BASE RSC /l 0x409
# ADD RSC /l 0x409
BSC32=bscmake.exe
# PROP Intermediate_Dir "../ReleaseDll"
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
-CPP=cl.exe
# ADD BASE CPP /nologo /MD /W4 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "WXWINDLL_EXPORTS" /YX /FD /c
# ADD CPP /nologo /MD /W4 /O2 /I "../lib/mswdll" /I "../include" /I "./zlib" /I "./jpeg" /I "./png" /I "./regex" /I "./tiff" /D "_USRDLL" /D "WIN32" /D "NDEBUG" /D WINVER=0x0400 /D "STRICT" /D "WXMAKINGDLL" /Yu"wx/wxprec.h" /FD /c
-MTL=midl.exe
# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-RSC=rc.exe
# ADD BASE RSC /l 0x409 /d "NDEBUG"
# ADD RSC /l 0x409 /i "../include" /d "NDEBUG"
BSC32=bscmake.exe
# PROP Intermediate_Dir "../DebugDll"
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
-CPP=cl.exe
# ADD BASE CPP /nologo /MDd /W4 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "WXWINDLL_EXPORTS" /YX /FD /GZ /c
# ADD CPP /nologo /MDd /W4 /Zi /Od /I "../lib/mswdlld" /I "../include" /I "./zlib" /I "./jpeg" /I "./png" /I "./regex" /I "./tiff" /D "_USRDLL" /D "WIN32" /D "_DEBUG" /D WINVER=0x0400 /D "STRICT" /D "WXMAKINGDLL" /Yu"wx/wxprec.h" /FD /c
-MTL=midl.exe
# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-RSC=rc.exe
# ADD BASE RSC /l 0x409 /d "_DEBUG"
# ADD RSC /l 0x409 /i "../include" /d "_DEBUG"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib winmm.lib ..\lib\jpegd.lib ..\lib\tiffd.lib ..\lib\pngd.lib ..\lib\regexd.lib ..\lib\zlibd.lib /dll /debug /machine:I386 /out:"../lib/wxmsw232d.dll" /pdbtype:sept
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib advapi32.lib comdlg32.lib shell32.lib ole32.lib oleaut32.lib odbc32.lib uuid.lib rpcrt4.lib comctl32.lib wsock32.lib winmm.lib ..\lib\jpegd.lib ..\lib\tiffd.lib ..\lib\pngd.lib ..\lib\regexd.lib ..\lib\zlibd.lib /nologo /version:2.3 /dll /debug /machine:I386 /out:"../lib/wxmsw232d.dll" /pdbtype:sept
+# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib winmm.lib ..\lib\jpegd.lib ..\lib\tiffd.lib ..\lib\pngd.lib ..\lib\regexd.lib ..\lib\zlibd.lib /dll /debug /machine:I386 /pdbtype:sept /out:"../lib/wxmsw232d.dll"
+# ADD LINK32 kernel32.lib user32.lib gdi32.lib advapi32.lib comdlg32.lib shell32.lib ole32.lib oleaut32.lib odbc32.lib uuid.lib rpcrt4.lib comctl32.lib wsock32.lib winmm.lib ..\lib\jpegd.lib ..\lib\tiffd.lib ..\lib\pngd.lib ..\lib\regexd.lib ..\lib\zlibd.lib /nologo /version:2.3 /dll /debug /machine:I386 /pdbtype:sept /out:"../lib/wxmsw232d.dll"
!ELSEIF "$(CFG)" == "wxWindows - Win32 Release"
# PROP Output_Dir "../lib"
# PROP Intermediate_Dir "../Release"
# PROP Target_Dir ""
-CPP=cl.exe
# ADD BASE CPP /nologo /MD /W4 /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /YX /FD /c
# ADD CPP /nologo /MD /W4 /O2 /I "../lib/msw" /I "../include" /I "./zlib" /I "./jpeg" /I "./png" /I "./regex" /I "./tiff" /D "WIN32" /D "NDEBUG" /D WINVER=0x0400 /D "STRICT" /Yu"wx/wxprec.h" /FD /c
-RSC=rc.exe
# ADD BASE RSC /l 0x409
# ADD RSC /l 0x409
BSC32=bscmake.exe
# PROP Output_Dir "../lib"
# PROP Intermediate_Dir "../Debug"
# PROP Target_Dir ""
-CPP=cl.exe
# ADD BASE CPP /nologo /MDd /W4 /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /YX /FD /c
# ADD CPP /nologo /MDd /W4 /Zi /Od /I "../lib/mswd" /I "../include" /I "./zlib" /I "./jpeg" /I "./png" /I "./regex" /I "./tiff" /D "WIN32" /D "_DEBUG" /D "__WXDEBUG__" /D WINVER=0x0400 /D "STRICT" /Yu"wx/wxprec.h" /FD /c
-RSC=rc.exe
# ADD BASE RSC /l 0x409
# ADD RSC /l 0x409
BSC32=bscmake.exe
# End Source File
# Begin Source File
-SOURCE=.\common\dosyacc.c
-# ADD CPP /W1 /D "USE_DEFINE" /D "IDE_INVOKED"
-# SUBTRACT CPP /YX /Yc /Yu
-# End Source File
-# Begin Source File
-
SOURCE=.\common\dseldlg.cpp
# End Source File
# Begin Source File
# End Source File
# Begin Source File
-SOURCE=.\common\effects.cpp
+SOURCE=.\common\dynload.cpp
# End Source File
# Begin Source File
-SOURCE=.\common\encconv.cpp
+SOURCE=.\common\effects.cpp
# End Source File
# Begin Source File
-SOURCE=.\common\event.cpp
+SOURCE=.\common\encconv.cpp
# End Source File
# Begin Source File
-SOURCE=.\common\extended.c
-# SUBTRACT CPP /YX /Yc /Yu
+SOURCE=.\common\event.cpp
# End Source File
# Begin Source File
# End Source File
# Begin Source File
-SOURCE=.\common\objstrm.cpp
-# End Source File
-# Begin Source File
-
SOURCE=.\common\odbc.cpp
# End Source File
# Begin Source File
# End Source File
# Begin Source File
-SOURCE=.\common\serbase.cpp
-# End Source File
-# Begin Source File
-
SOURCE=.\common\sizer.cpp
# End Source File
# Begin Source File
# End Source File
# Begin Source File
-SOURCE=.\common\unzip.c
-# SUBTRACT CPP /YX /Yc /Yu
-# End Source File
-# Begin Source File
-
SOURCE=.\common\url.cpp
# End Source File
# Begin Source File
SOURCE=.\common\zstream.cpp
# End Source File
+
+# Begin Source File
+
+SOURCE=.\common\extended.c
+# SUBTRACT CPP /YX /Yc /Yu
+# End Source File
+# Begin Source File
+
+SOURCE=.\common\unzip.c
+# SUBTRACT CPP /YX /Yc /Yu
+# End Source File
+
+# Begin Source File
+
+SOURCE=.\common\dosyacc.c
+# ADD CPP /W1 /D "USE_DEFINE" /D "IDE_INVOKED"
+# SUBTRACT CPP /YX /Yc /Yu
+# End Source File
# End Group
# Begin Group "Generic Files"
SOURCE=.\generic\wizard.cpp
# End Source File
+
# End Group
# Begin Group "wxHTML Files"
SOURCE=.\html\winpars.cpp
# End Source File
+
# End Group
# Begin Group "MSW Files"
# PROP Default_Filter ""
# Begin Source File
+SOURCE=.\msw\dummy.cpp
+# ADD CPP /Yc"wx/wxprec.h"
+# End Source File
+# Begin Source File
+
SOURCE=.\msw\accel.cpp
# End Source File
# Begin Source File
# End Source File
# Begin Source File
-SOURCE=.\msw\dummy.cpp
-# ADD CPP /Yc"wx/wxprec.h"
-# End Source File
-# Begin Source File
-
SOURCE=.\msw\enhmeta.cpp
# End Source File
# Begin Source File
# End Source File
# Begin Source File
-SOURCE=.\msw\gsocket.c
-# SUBTRACT CPP /YX /Yc /Yu
-# End Source File
-# Begin Source File
-
-SOURCE=.\msw\gsockmsw.c
-# SUBTRACT CPP /YX /Yc /Yu
-# End Source File
-# Begin Source File
-
SOURCE=.\msw\helpbest.cpp
# End Source File
# Begin Source File
# End Source File
# Begin Source File
-SOURCE=.\msw\iniconf.cpp
-# End Source File
-# Begin Source File
-
SOURCE=.\msw\joystick.cpp
# End Source File
# Begin Source File
SOURCE=.\msw\window.cpp
# End Source File
+
+# Begin Source File
+
+SOURCE=.\msw\gsocket.c
+# SUBTRACT CPP /YX /Yc /Yu
+# End Source File
+# Begin Source File
+
+SOURCE=.\msw\gsockmsw.c
+# SUBTRACT CPP /YX /Yc /Yu
+# End Source File
+
# End Group
# Begin Group "OLE Files"
SOURCE=.\msw\ole\uuid.cpp
# End Source File
+
# End Group
# Begin Group "Headers"
# Begin Source File
SOURCE=..\include\wx\msw\setup.h
-
!IF "$(CFG)" == "wxWindows - Win32 Release Unicode DLL"
-
# Begin Custom Build - Creating $(TargetPath) from $(InputPath)
InputPath=..\include\wx\msw\setup.h
copy $(InputPath) ..\lib\mswdllu\wx\setup.h
# End Custom Build
-
!ELSEIF "$(CFG)" == "wxWindows - Win32 Debug Unicode DLL"
-
# Begin Custom Build - Creating $(TargetPath) from $(InputPath)
InputPath=..\include\wx\msw\setup.h
copy $(InputPath) ..\lib\mswdllud\wx\setup.h
# End Custom Build
-
!ELSEIF "$(CFG)" == "wxWindows - Win32 Release Unicode"
-
# Begin Custom Build - Creating $(TargetPath) from $(InputPath)
InputPath=..\include\wx\msw\setup.h
copy $(InputPath) ..\lib\mswu\wx\setup.h
# End Custom Build
-
!ELSEIF "$(CFG)" == "wxWindows - Win32 Debug Unicode"
-
# Begin Custom Build - Creating $(TargetPath) from $(InputPath)
InputPath=..\include\wx\msw\setup.h
copy $(InputPath) ..\lib\mswud\wx\setup.h
# End Custom Build
-
!ELSEIF "$(CFG)" == "wxWindows - Win32 Release DLL"
-
# Begin Custom Build - Creating $(TargetPath) from $(InputPath)
InputPath=..\include\wx\msw\setup.h
copy $(InputPath) ..\lib\mswdll\wx\setup.h
# End Custom Build
-
!ELSEIF "$(CFG)" == "wxWindows - Win32 Debug DLL"
-
# Begin Custom Build - Creating $(TargetPath) from $(InputPath)
InputPath=..\include\wx\msw\setup.h
copy $(InputPath) ..\lib\mswdlld\wx\setup.h
# End Custom Build
-
!ELSEIF "$(CFG)" == "wxWindows - Win32 Release"
-
# Begin Custom Build - Creating $(TargetPath) from $(InputPath)
InputPath=..\include\wx\msw\setup.h
copy $(InputPath) ..\lib\msw\wx\setup.h
# End Custom Build
-
!ELSEIF "$(CFG)" == "wxWindows - Win32 Debug"
-
# Begin Custom Build - Creating $(TargetPath) from $(InputPath)
InputPath=..\include\wx\msw\setup.h
copy $(InputPath) ..\lib\mswd\wx\setup.h
# End Custom Build
-
!ENDIF
-
# End Source File
# End Group
# Begin Group "Common"
# End Source File
# Begin Source File
+SOURCE=..\include\wx\dynload.h
+# End Source File
+# Begin Source File
+
SOURCE=..\include\wx\encconv.h
# End Source File
# Begin Source File
# End Source File
# Begin Source File
-SOURCE=..\include\wx\objstrm.h
-# End Source File
-# Begin Source File
-
SOURCE=..\include\wx\odbc.h
# End Source File
# Begin Source File
# End Source File
# Begin Source File
-SOURCE=..\include\wx\serbase.h
-# End Source File
-# Begin Source File
-
SOURCE=..\include\wx\settings.h
# End Source File
# Begin Source File
SOURCE=..\include\wx\zstream.h
# End Source File
+
# End Group
# Begin Group "MSW"
SOURCE=..\include\wx\msw\winundef.h
# End Source File
+
# End Group
# Begin Group "Generic"
SOURCE=..\include\wx\generic\wizard.h
# End Source File
+
# End Group
# Begin Group "HTML"
SOURCE=..\include\wx\html\winpars.h
# End Source File
+
# End Group
# End Group
# End Target
+++ /dev/null
-Linux
-linux-gnu
-linux
+++ /dev/null
-#
-# File: makefile.b32
-# Author: Patrick Halke, modified by Guilhem Lavaux
-# Created: 1997
-# Updated:
-# Copyright: (c) 1993, AIAI, University of Edinburgh
-#
-# "%W% %G%"
-#
-# Makefile : Builds 32bit wxstring library for Windows 3.1
-# and Borland C++ 4.x
-
-WXDIR = $(WXWIN)
-
-!if "$(DLL)" == "1"
-WXBUILDDLL=1
-WXUSINGDLL=1
-!endif
-
-!include $(WXDIR)\src\makeb32.env
-
-WXLIBDIR = $(WXDIR)\lib
-LIBS=$(WXLIB) cw32 import32 ole2w32
-
-!ifndef DEBUG
-DEBUG=0
-!endif
-
-LIBTARGET= $(WXLIBDIR)\wxserial.dll
-CPPFLAGS= $(CPPFLAGS) -Od
-
-.c.obj:
- bcc32 $(CPPFLAGS) -P- -c {$< }
-
-OBJECTS = sermain.obj sercore.obj serwnd.obj serctrl.obj sergdi.obj serext.obj
-
-all: $(LIBTARGET)
-
-sermain.obj: sermain.$(SRCSUFF)
- bcc32 $(CPPFLAGS) -P- -u- -c sermain.$(SRCSUFF)
-
-$(LIBTARGET): $(OBJECTS)
- erase $(LIBTARGET)
- tlink32 $(LINK_FLAGS) /v @&&!
-c0d32.obj $(OBJECTS)
-$(LIBTARGET)
-nul
-$(LIBS)
-serial
-!
-
-clean:
- -erase *.obj
- -erase $(LIBTARGET)
- -erase *.exe
- -erase *.res
- -erase *.map
- -erase *.rws
+++ /dev/null
-/////////////////////////////////////////////////////////////////////////////
-// Name: sercore.cpp
-// Purpose: Serialization: core classes
-// Author: Guilhem Lavaux
-// Modified by:
-// Created: July 1998
-// RCS-ID: $Id$
-// Copyright: (c) 1998 Guilhem Lavaux
-// Licence: wxWindows license
-/////////////////////////////////////////////////////////////////////////////
-
-#ifdef __GNUG__
-#pragma implementation "sercore.h"
-#endif
-#include <wx/objstrm.h>
-#include <wx/datstrm.h>
-#include <wx/list.h>
-#include <wx/hash.h>
-#include "sercore.h"
-
-IMPLEMENT_SERIAL_CLASS(wxList, wxObject)
-IMPLEMENT_SERIAL_CLASS(wxHashTable, wxObject)
-
-void WXSERIAL(wxList)::StoreObject(wxObjectOutputStream& s)
-{
- wxList *lst_object = (wxList *)Object();
- wxNode *node = lst_object->First();
-
- if (s.FirstStage()) {
- while (node) {
- s.AddChild(node->Data());
- node = node->Next();
- }
- return;
- }
-
- wxDataOutputStream data_s(s);
-
- data_s.Write8(lst_object->destroy_data);
- data_s.Write8(lst_object->key_type);
- data_s.Write32( lst_object->Number() );
-
- if (lst_object->key_type == wxKEY_INTEGER) {
- while (node) {
- data_s.Write32(node->key.integer);
- node = node->Next();
- }
- } else {
- while (node) {
- data_s.WriteString(node->key.string);
- node = node->Next();
- }
- }
-}
-
-void WXSERIAL(wxList)::LoadObject(wxObjectInputStream& s)
-{
- wxDataInputStream data_s(s);
- wxList *list = (wxList *)Object();
- int number, i;
-
- list->DeleteContents( data_s.Read8() );
- list->key_type = data_s.Read8();
- number = data_s.Read32();
-
- if (list->key_type == wxKEY_INTEGER) {
- for (i=0;i<number;i++)
- list->Append( data_s.Read32(), s.GetChild() );
- } else {
- for (i=0;i<number;i++)
- list->Append( data_s.ReadString(), s.GetChild() );
- }
-}
-
-// ----------------------------------------------------------------------------
-
-void WXSERIAL(wxHashTable)::StoreObject(wxObjectOutputStream& s)
-{
- wxHashTable *table = (wxHashTable *)Object();
- int i;
-
- if (s.FirstStage()) {
- for (i=0;i<table->n;i++)
- s.AddChild(table->hash_table[i]);
- return;
- }
-
- wxDataOutputStream data_s(s);
-
- data_s.Write8(table->key_type);
- data_s.Write32(table->n);
-}
-
-void WXSERIAL(wxHashTable)::LoadObject(wxObjectInputStream& s)
-{
- wxHashTable *table = (wxHashTable *)Object();
- wxDataInputStream data_s(s);
- int i, key, n;
-
- key = data_s.Read8();
- n = data_s.Read32();
-
- table->Create(key, n);
-
- for (i=0;i<n;i++)
- table->hash_table[i] = (wxList *)s.GetChild();
-}
+++ /dev/null
-/////////////////////////////////////////////////////////////////////////////
-// Name: sercore.h
-// Purpose: Serialization: core classes
-// Author: Guilhem Lavaux
-// Modified by:
-// Created: July 1998
-// RCS-ID: $Id$
-// Copyright: (c) 1998 Guilhem Lavaux
-// Licence: wxWindows license
-/////////////////////////////////////////////////////////////////////////////
-
-#ifndef __SERCORE_H__
-#define __SERCORE_H__
-
-#ifdef __GNUG__
-#pragma interface
-#endif
-
-#include <wx/serbase.h>
-
-DECLARE_SERIAL_CLASS(wxList, wxObject)
-DECLARE_SERIAL_CLASS(wxHashTable, wxObject)
-
-#endif
+++ /dev/null
-/////////////////////////////////////////////////////////////////////////////
-// Name: serctrl.cpp
-// Purpose: Serialization: control classes
-// Author: Guilhem Lavaux
-// Modified by:
-// Created: July 1998
-// RCS-ID: $Id$
-// Copyright: (c) 1998 Guilhem Lavaux
-// Licence: wxWindows license
-/////////////////////////////////////////////////////////////////////////////
-
-#ifdef __GNUG__
-#pragma implementation "serctrl.h"
-#endif
-
-#include <wx/window.h>
-#include <wx/control.h>
-#include <wx/button.h>
-#include <wx/checkbox.h>
-#include <wx/slider.h>
-#include <wx/gauge.h>
-#include <wx/choice.h>
-#include <wx/listbox.h>
-#include <wx/notebook.h>
-#include <wx/radiobox.h>
-#include <wx/radiobut.h>
-#include <wx/stattext.h>
-#include <wx/statbox.h>
-#include <wx/combobox.h>
-#include <wx/imaglist.h>
-#include <wx/objstrm.h>
-#include <wx/datstrm.h>
-#include <wx/serbase.h>
-#include "serwnd.h"
-#include "serctrl.h"
-
-IMPLEMENT_ALIAS_SERIAL_CLASS(wxControl, wxWindow)
-#ifdef __WINDOWS__
-IMPLEMENT_SERIAL_CLASS(wxSlider95, wxControl)
-IMPLEMENT_SERIAL_CLASS(wxGauge95, wxControl)
-#else
-IMPLEMENT_SERIAL_CLASS(wxSlider, wxControl)
-IMPLEMENT_SERIAL_CLASS(wxGauge, wxControl)
-#endif
-IMPLEMENT_SERIAL_CLASS(wxCheckBox, wxControl)
-IMPLEMENT_SERIAL_CLASS(wxChoice, wxControl)
-IMPLEMENT_SERIAL_CLASS(wxComboBox, wxControl)
-IMPLEMENT_SERIAL_CLASS(wxListBox, wxControl)
-IMPLEMENT_SERIAL_CLASS(wxNotebook, wxControl)
-IMPLEMENT_SERIAL_CLASS(wxRadioBox, wxControl)
-IMPLEMENT_SERIAL_CLASS(wxRadioButton, wxControl)
-IMPLEMENT_SERIAL_CLASS(wxButton, wxControl)
-IMPLEMENT_SERIAL_CLASS(wxStaticText, wxControl)
-IMPLEMENT_SERIAL_CLASS(wxStaticBox, wxControl)
-
-//-----------------------------------------------------------------------------
-
-void WXSERIAL(wxButton)::StoreObject(wxObjectOutputStream& s)
-{
- WXSERIAL(wxControl)::StoreObject(s);
-}
-
-void WXSERIAL(wxButton)::LoadObject(wxObjectInputStream& s)
-{
- WXSERIAL(wxControl)::LoadObject(s);
-
- if (s.SecondCall())
- return;
-
- wxButton *button = (wxButton *)Object();
-
- printf("label = %s\n", WXSTRINGCAST m_label);
- button->Create(m_parent, m_id, m_label, wxPoint(m_x, m_y), wxSize(m_w, m_h),
- m_style, *m_validator, m_name);
-}
-
-//-----------------------------------------------------------------------------
-
-void WXSERIAL(wxCheckBox)::StoreObject(wxObjectOutputStream& s)
-{
- WXSERIAL(wxControl)::StoreObject(s);
-
- if (s.FirstStage())
- return;
-
- wxDataOutputStream data_s(s);
- data_s.Write8( ((wxCheckBox *)Object())->GetValue() );
-}
-
-void WXSERIAL(wxCheckBox)::LoadObject(wxObjectInputStream& s)
-{
- WXSERIAL(wxControl)::LoadObject(s);
-
- if (s.SecondCall())
- return;
-
- wxDataInputStream data_s(s);
- wxCheckBox *chkbox = (wxCheckBox *)Object();
-
- chkbox->Create(m_parent, m_id, m_label, wxPoint(m_x, m_y), wxSize(m_w, m_h),
- m_style, *m_validator, m_name);
-
- chkbox->SetValue(data_s.Read8());
-}
-
-//-----------------------------------------------------------------------------
-
-#ifdef __WXMSW__
-void WXSERIAL(wxSlider95)::StoreObject(wxObjectOutputStream& s)
-#else
-void WXSERIAL(wxSlider)::StoreObject(wxObjectOutputStream& s)
-#endif
-{
- WXSERIAL(wxControl)::StoreObject(s);
-
- if (s.FirstStage())
- return;
-
- wxDataOutputStream data_s(s);
- wxSlider *slider = (wxSlider *)Object();
-
- data_s.Write32( slider->GetMin() );
- data_s.Write32( slider->GetMax() );
- data_s.Write32( slider->GetValue() );
- data_s.Write32( slider->GetTickFreq() );
- data_s.Write32( slider->GetPageSize() );
- data_s.Write32( slider->GetLineSize() );
- data_s.Write32( slider->GetSelStart() );
- data_s.Write32( slider->GetSelEnd() );
- data_s.Write32( slider->GetThumbLength() );
-}
-
-#ifdef __WXMSW__
-void WXSERIAL(wxSlider95)::LoadObject(wxObjectInputStream& s)
-#else
-void WXSERIAL(wxSlider)::LoadObject(wxObjectInputStream& s)
-#endif
-{
- WXSERIAL(wxControl)::LoadObject(s);
-
- if (s.SecondCall())
- return;
-
- wxDataInputStream data_s(s);
- wxSlider *slider = (wxSlider *)Object();
- int value, min, max;
-
- min = data_s.Read32();
- max = data_s.Read32();
- value = data_s.Read32();
-
- slider->Create(m_parent, m_id, value, min, max, wxPoint(m_x, m_y),
- wxSize(m_w, m_h), m_style, *m_validator, m_name);
-
- slider->SetTickFreq( 0, data_s.Read32() );
- slider->SetPageSize( data_s.Read32() );
- slider->SetLineSize( data_s.Read32() );
- min = data_s.Read32();
- max = data_s.Read32();
- slider->SetSelection(min, max);
- slider->SetThumbLength( data_s.Read32() );
-}
-
-//-----------------------------------------------------------------------------
-
-#ifdef __WXMSW__
-void WXSERIAL(wxGauge95)::StoreObject(wxObjectOutputStream& s)
-#else
-void WXSERIAL(wxGauge)::StoreObject(wxObjectOutputStream& s)
-#endif
-{
- WXSERIAL(wxControl)::StoreObject(s);
-
- if (s.FirstStage())
- return;
-
- wxDataOutputStream data_s(s);
- wxGauge *gauge = (wxGauge *)Object();
-
- data_s.Write32( gauge->GetRange() );
- data_s.Write8( gauge->GetShadowWidth() );
- data_s.Write8( gauge->GetBezelFace() );
- data_s.Write32( gauge->GetValue() );
-}
-
-#ifdef __WXMSW__
-void WXSERIAL(wxGauge95)::LoadObject(wxObjectInputStream& s)
-#else
-void WXSERIAL(wxGauge)::LoadObject(wxObjectInputStream& s)
-#endif
-{
- WXSERIAL(wxControl)::LoadObject(s);
-
- if (s.SecondCall())
- return;
-
- wxDataInputStream data_s(s);
- wxGauge *gauge = (wxGauge *)Object();
- int range;
-
- range = data_s.Read32();
- gauge->Create(m_parent, m_id, range, wxPoint(m_x, m_y), wxSize(m_w, m_h),
- m_style, *m_validator, m_name);
-
- gauge->SetShadowWidth( data_s.Read8() );
- gauge->SetBezelFace( data_s.Read8() );
- gauge->SetValue( data_s.Read32() );
-}
-
-//-----------------------------------------------------------------------------
-
-void WXSERIAL(wxChoice)::StoreObject(wxObjectOutputStream& s)
-{
- WXSERIAL(wxControl)::StoreObject(s);
-
- if (s.FirstStage())
- return;
-
- wxDataOutputStream data_s(s);
- wxChoice *choice = (wxChoice *)Object();
- int i, num = choice->Number();
-
- data_s.Write32(num);
- for (i=0;i<num;i++)
- data_s.WriteString( choice->GetString(i) );
-}
-
-void WXSERIAL(wxChoice)::LoadObject(wxObjectInputStream& s)
-{
- WXSERIAL(wxControl)::LoadObject(s);
-
- if (s.SecondCall())
- return;
-
- wxDataInputStream data_s(s);
- wxChoice *choice = (wxChoice *)Object();
- int i,num = data_s.Read32();
-
- choice->Create(m_parent, m_id, wxPoint(m_x, m_y), wxSize(m_w, m_h), 0, NULL,
- m_style, *m_validator, m_name);
-
- for (i=0;i<num;i++)
- choice->Append( data_s.ReadString() );
-}
-
-//-----------------------------------------------------------------------------
-
-void WXSERIAL(wxListBox)::StoreObject(wxObjectOutputStream& s)
-{
- WXSERIAL(wxControl)::StoreObject(s);
-
- if (s.FirstStage())
- return;
-
- wxDataOutputStream data_s(s);
- wxListBox *listbox = (wxListBox *)Object();
- int i, num = listbox->Number();
-
- data_s.Write32(num);
- for (i=0;i<num;i++)
- data_s.WriteString( listbox->GetString(i) );
-}
-
-void WXSERIAL(wxListBox)::LoadObject(wxObjectInputStream& s)
-{
- WXSERIAL(wxListBox)::LoadObject(s);
-
- if (s.SecondCall())
- return;
-
- wxDataInputStream data_s(s);
- wxListBox *listbox = (wxListBox *)Object();
- int i, num = data_s.Read32();
-
- for (i=0;i<num;i++)
- listbox->Append( data_s.ReadString() );
-}
-
-//-----------------------------------------------------------------------------
-
-void WXSERIAL(wxNotebook)::StoreObject(wxObjectOutputStream& s)
-{
- wxNotebook *notebook = (wxNotebook *)Object();
- wxImageList *imaglist = notebook->GetImageList();
- int i, pcount = notebook->GetPageCount();
-
- WXSERIAL(wxControl)::StoreObject(s);
- if (s.FirstStage()) {
- s.AddChild(imaglist);
- return;
- }
-
- wxDataOutputStream data_s(s);
-
- data_s.Write8( pcount );
-
- for (i=0;i<pcount;i++)
- data_s.WriteString( notebook->GetPageText(i) );
-}
-
-void WXSERIAL(wxNotebook)::LoadObject(wxObjectInputStream& s)
-{
- wxNotebook *notebook = (wxNotebook *)Object();
- int i;
- wxImageList *imaglist;
-
- WXSERIAL(wxControl)::LoadObject(s);
-
- if (s.SecondCall()) {
- for (i=0;i<m_pcount;i++)
- notebook->AddPage( (wxWindow *)s.GetChild(), m_stringlist[i] );
- return;
- }
-
- imaglist = (wxImageList *)s.GetChild();
-
- notebook->Create(m_parent, m_id, wxPoint(m_x, m_y), wxSize(m_w, m_h),
- m_style, m_name);
-
- wxDataInputStream data_s(s);
-
- m_pcount = data_s.Read8();
- for (i=0;i<m_pcount;i++)
- m_stringlist.Add(data_s.ReadString());
- s.Recall();
-}
-
-//-----------------------------------------------------------------------------
-
-void WXSERIAL(wxRadioBox)::StoreObject(wxObjectOutputStream& s)
-{
- wxRadioBox *box = (wxRadioBox *)Object();
- WXSERIAL(wxControl)::StoreObject(s);
-
- if (s.FirstStage())
- return;
-
- wxDataOutputStream data_s(s);
- int i, n_items = box->Number();
-
- data_s.Write8( n_items );
- data_s.Write8( box->GetNumberOfRowsOrCols() );
-
- for (i=0;i<n_items;i++)
- data_s.WriteString( box->GetString(i) );
-}
-
-void WXSERIAL(wxRadioBox)::LoadObject(wxObjectInputStream& s)
-{
- wxRadioBox *box = (wxRadioBox *)Object();
-
- WXSERIAL(wxControl)::LoadObject(s);
-
- if (s.SecondCall())
- return;
-
- wxDataInputStream data_s(s);
- int i, n_rows_cols, n_items;
- wxString *items;
-
- n_items = data_s.Read8();
- n_rows_cols = data_s.Read8();
-
- items = new wxString[n_items];
- for (i=0;i<n_items;i++)
- items[i] = data_s.ReadString();
-
- box->Create(m_parent, m_id, m_title, wxPoint(m_x, m_y), wxSize(m_w, m_h),
- n_items, items, 0, m_style, *m_validator, m_name);
-}
-
-//-----------------------------------------------------------------------------
-
-void WXSERIAL(wxRadioButton)::StoreObject(wxObjectOutputStream& s)
-{
- WXSERIAL(wxControl)::StoreObject(s);
-
- if (s.FirstStage())
- return;
-
- wxDataOutputStream data_s(s);
- data_s.Write8( (char) ((wxRadioButton *)Object())->GetValue() );
-}
-
-void WXSERIAL(wxRadioButton)::LoadObject(wxObjectInputStream& s)
-{
- wxDataInputStream data_s(s);
-
- WXSERIAL(wxControl)::LoadObject(s);
-
- if (s.SecondCall())
- return;
-
- ((wxRadioButton *)Object())->SetValue( (bool)data_s.Read8() );
-}
-
-//-----------------------------------------------------------------------------
-
-void WXSERIAL(wxComboBox)::StoreObject(wxObjectOutputStream& s)
-{
- WXSERIAL(wxControl)::StoreObject(s);
-
- if (s.FirstStage())
- return;
-
- wxDataOutputStream data_s(s);
- wxComboBox *box = (wxComboBox *)Object();
- int i, num = box->Number();
-
- data_s.Write8( num );
- data_s.Write8( box->GetSelection() );
- for (i=0;i<num;i++)
- data_s.WriteString( box->GetString(i) );
-
- data_s.WriteString( box->GetValue() );
-
- // TODO: Editable flag
-}
-
-void WXSERIAL(wxComboBox)::LoadObject(wxObjectInputStream& s)
-{
- WXSERIAL(wxControl)::LoadObject(s);
-
- if (s.SecondCall())
- return;
-
- wxDataInputStream data_s(s);
- wxComboBox *box = (wxComboBox *)Object();
- int i, num, selection;
-
- box->Create(m_parent, m_id, wxEmptyString, wxPoint(m_x, m_y), wxSize(m_w, m_h),
- 0, NULL, m_style, *m_validator, m_name);
-
- num = data_s.Read8();
- selection = data_s.Read8();
-
- for (i=0;i<num;i++)
- box->Append( data_s.ReadString() );
-
- box->SetSelection( selection );
- box->SetValue( data_s.ReadString() );
-}
-
-//-----------------------------------------------------------------------------
-
-void WXSERIAL(wxStaticText)::StoreObject(wxObjectOutputStream& s)
-{
- WXSERIAL(wxControl)::StoreObject(s);
-}
-
-void WXSERIAL(wxStaticText)::LoadObject(wxObjectInputStream& s)
-{
- WXSERIAL(wxControl)::LoadObject(s);
-
- if (s.SecondCall())
- return;
-
- ((wxStaticText *)Object())->Create(m_parent, m_id, m_label, wxPoint(m_x, m_y),
- wxSize(m_w, m_h), m_style, m_name);
-}
-
-//-----------------------------------------------------------------------------
-
-void WXSERIAL(wxStaticBox)::StoreObject(wxObjectOutputStream& s)
-{
- WXSERIAL(wxControl)::StoreObject(s);
-}
-
-void WXSERIAL(wxStaticBox)::LoadObject(wxObjectInputStream& s)
-{
- WXSERIAL(wxControl)::LoadObject(s);
-
- if (s.SecondCall())
- return;
-
- ((wxStaticBox *)Object())->Create(m_parent, m_id, m_label, wxPoint(m_x, m_y),
- wxSize(m_w, m_h), m_style, m_name);
-}
+++ /dev/null
-/////////////////////////////////////////////////////////////////////////////
-// Name: serctrl.h
-// Purpose: Serialization: control classes
-// Author: Guilhem Lavaux
-// Modified by:
-// Created: July 1998
-// RCS-ID: $Id$
-// Copyright: (c) 1998 Guilhem Lavaux
-// Licence: wxWindows license
-/////////////////////////////////////////////////////////////////////////////
-
-#ifndef __SERCTRL_H__
-#define __SERCTRL_H__
-
-#ifdef __GNUG__
-#pragma interface
-#endif
-
-#include <wx/serbase.h>
-#include "serwnd.h"
-
-DECLARE_ALIAS_SERIAL_CLASS(wxControl, wxWindow)
-DECLARE_SERIAL_CLASS(wxButton, wxControl)
-#ifdef __WINDOWS__
-DECLARE_SERIAL_CLASS(wxSlider95, wxControl)
-DECLARE_SERIAL_CLASS(wxGauge95, wxControl)
-#else
-DECLARE_SERIAL_CLASS(wxSlider, wxControl)
-DECLARE_SERIAL_CLASS(wxGauge, wxControl)
-#endif
-DECLARE_SERIAL_CLASS(wxCheckBox, wxControl)
-DECLARE_SERIAL_CLASS(wxChoice, wxControl)
-DECLARE_SERIAL_CLASS(wxComboBox, wxControl)
-DECLARE_SERIAL_CLASS(wxListBox, wxControl)
-DECLARE_SERIAL_CLASS(wxRadioBox, wxControl)
-DECLARE_SERIAL_CLASS(wxRadioButton, wxControl)
-DECLARE_SERIAL_CLASS(wxStaticText, wxControl)
-DECLARE_SERIAL_CLASS(wxStaticBox, wxControl)
-
-
-class WXSERIAL(wxNotebook) : public WXSERIAL(wxControl) {
- DECLARE_DYNAMIC_CLASS( wxNotebook_Serialize )
-public:
- void StoreObject(wxObjectOutputStream& s);
- void LoadObject(wxObjectInputStream& s);
-
-protected:
- int m_pcount;
- wxArrayString m_stringlist;
-};
-
-#endif
+++ /dev/null
-/////////////////////////////////////////////////////////////////////////////
-// Name: serext.cpp
-// Purpose: Serialization: Other classes
-// Author: Guilhem Lavaux
-// Modified by:
-// Created: July 1998
-// RCS-ID: $Id$
-// Copyright: (c) 1998 Guilhem Lavaux
-// Licence: wxWindows license
-/////////////////////////////////////////////////////////////////////////////
-
-#ifdef __GNUG__
-#pragma implementation "serext.h"
-#endif
-
-#include "serext.h"
-#include <wx/wx.h>
-#include <wx/splitter.h>
-#include <wx/grid.h>
-#include <wx/objstrm.h>
-#include <wx/datstrm.h>
-
-IMPLEMENT_SERIAL_CLASS(wxSplitterWindow, wxWindow)
-IMPLEMENT_SERIAL_CLASS(wxGridCell, wxObject)
-IMPLEMENT_SERIAL_CLASS(wxGrid, wxPanel)
-
-void WXSERIAL(wxSplitterWindow)::StoreObject(wxObjectOutputStream& s)
-{
- wxSplitterWindow *splitter = (wxSplitterWindow *)Object();
- WXSERIAL(wxWindow)::StoreObject(s);
-
- if (s.FirstStage()) {
- s.AddChild( splitter->GetWindow1() );
- s.AddChild( splitter->GetWindow2() );
- return;
- }
-
- wxDataOutputStream data_s(s);
- data_s.Write8( splitter->GetSplitMode() );
- data_s.Write32( splitter->GetSashSize() );
- data_s.Write8( splitter->GetBorderSize() );
- data_s.Write32( splitter->GetSashPosition() );
- data_s.Write32( splitter->GetMinimumPaneSize() );
-}
-
-void WXSERIAL(wxSplitterWindow)::LoadObject(wxObjectInputStream& s)
-{
- wxSplitterWindow *splitter = (wxSplitterWindow *)Object();
- WXSERIAL(wxWindow)::LoadObject(s);
-
- wxDataInputStream data_s(s);
- int split_mode, sash_size, border_size, sash_position, min_pane_size;
-
- split_mode = data_s.Read8();
- sash_size = data_s.Read32();
- border_size = data_s.Read8();
- sash_position = data_s.Read32();
- min_pane_size = data_s.Read32();
-
- splitter->Create(m_parent, m_id, wxPoint(m_x, m_y), wxSize(m_w, m_h), m_style,
- m_name);
-
- if (s.GetChild(1)) {
- if (data_s.Read8() == wxSPLIT_VERTICAL)
- splitter->SplitVertically((wxWindow *)s.GetChild(0),
- (wxWindow *)s.GetChild(1), sash_position);
- else
- splitter->SplitHorizontally((wxWindow *)s.GetChild(0),
- (wxWindow *)s.GetChild(1), sash_position);
- }
-
- splitter->SetSashSize(sash_size);
- splitter->SetBorderSize(border_size);
- splitter->SetMinimumPaneSize(min_pane_size);
-}
-
-void WXSERIAL(wxGridCell)::StoreObject(wxObjectOutputStream& s)
-{
- wxGridCell *cell = (wxGridCell *)Object();
- wxDataOutputStream data_s(s);
-
- if (s.FirstStage()) {
- s.AddChild( cell->GetFont() );
- s.AddChild( cell->GetBackgroundBrush() );
- s.AddChild( cell->GetCellBitmap() );
- s.AddChild( &(cell->GetTextColour()) );
- s.AddChild( &(cell->GetBackgroundColour()) );
- return;
- }
-
- data_s.WriteString( cell->GetTextValue() );
- data_s.Write16( cell->GetAlignment() );
-}
-
-void WXSERIAL(wxGridCell)::LoadObject(wxObjectInputStream& s)
-{
- wxGridCell *cell = (wxGridCell *)Object();
- wxDataInputStream data_s(s);
-
- cell->SetTextValue( data_s.ReadString() );
- cell->SetAlignment( data_s.Read16() );
- cell->SetFont( (wxFont *)s.GetChild() );
- cell->SetBackgroundBrush( (wxBrush *)s.GetChild() );
- cell->SetCellBitmap( (wxBitmap *)s.GetChild() );
- cell->SetTextColour( *((wxColour *)s.GetChild()) );
- cell->SetBackgroundColour( *((wxColour *)s.GetChild()) );
-}
-
-void WXSERIAL(wxGrid)::StoreObject(wxObjectOutputStream& s)
-{
- wxDataOutputStream data_s(s);
- wxGrid *grid = (wxGrid *)Object();
- int n_rows = grid->GetRows(), n_cols = grid->GetCols();
- int r, c;
-
- if (s.FirstStage()) {
- for (r=0;r<n_rows;r++)
- for (c=0;c<n_cols;c++)
- s.AddChild( grid->GetCell(r, c) );
-
- s.AddChild( grid->GetDividerPen() );
- WXSERIAL(wxPanel)::StoreObject(s);
- return;
- }
-
- data_s.Write16( n_rows );
- data_s.Write16( n_cols );
- data_s.Write16( grid->GetCursorRow() );
- data_s.Write16( grid->GetCursorColumn() );
-
- WXSERIAL(wxPanel)::StoreObject(s);
-}
-
-void WXSERIAL(wxGrid)::LoadObject(wxObjectInputStream& s)
-{
- WXSERIAL(wxPanel)::LoadObject(s);
-}
+++ /dev/null
-/////////////////////////////////////////////////////////////////////////////
-// Name: serext.cpp
-// Purpose: Serialization: Other classes
-// Author: Guilhem Lavaux
-// Modified by:
-// Created: July 1998
-// RCS-ID: $Id$
-// Copyright: (c) 1998 Guilhem Lavaux
-// Licence: wxWindows license
-/////////////////////////////////////////////////////////////////////////////
-
-#ifndef __SEREXT_H__
-#define __SEREXT_H__
-
-#ifdef __GNUG__
-#pragma interface
-#endif
-
-#include <wx/serbase.h>
-#include "serwnd.h"
-
-DECLARE_SERIAL_CLASS(wxSplitterWindow, wxWindow)
-DECLARE_SERIAL_CLASS(wxGrid, wxPanel)
-DECLARE_SERIAL_CLASS(wxGridCell, wxObject)
-
-#endif
+++ /dev/null
-/////////////////////////////////////////////////////////////////////////////
-// Name: sergdi.cpp
-// Purpose: Serialization: GDI classes
-// Author: Guilhem Lavaux
-// Modified by:
-// Created: July 1998
-// RCS-ID: $Id$
-// Copyright: (c) 1998 Guilhem Lavaux
-// Licence: wxWindows license
-/////////////////////////////////////////////////////////////////////////////
-
-#ifdef __GNUG__
-#pragma implementation "sergdi.h"
-#endif
-#include <wx/objstrm.h>
-#include <wx/datstrm.h>
-#include <wx/gdicmn.h>
-#include <wx/bitmap.h>
-#include <wx/font.h>
-#include <wx/pen.h>
-#include <wx/brush.h>
-#include <wx/serbase.h>
-#include <wx/imaglist.h>
-#include <wx/region.h>
-#include <wx/colour.h>
-#include <wx/palette.h>
-#include <wx/dcmemory.h>
-#include <wx/log.h>
-#include "sergdi.h"
-
-IMPLEMENT_SERIAL_CLASS(wxBitmap, wxObject)
-IMPLEMENT_SERIAL_CLASS(wxGDIObject, wxObject)
-IMPLEMENT_SERIAL_CLASS(wxRegion, wxGDIObject)
-IMPLEMENT_SERIAL_CLASS(wxColour, wxObject)
-IMPLEMENT_SERIAL_CLASS(wxFont, wxGDIObject)
-IMPLEMENT_SERIAL_CLASS(wxPen, wxGDIObject)
-IMPLEMENT_SERIAL_CLASS(wxBrush, wxGDIObject)
-IMPLEMENT_SERIAL_CLASS(wxImageList, wxObject)
-
-IMPLEMENT_ALIAS_SERIAL_CLASS(wxPenList, wxList)
-IMPLEMENT_ALIAS_SERIAL_CLASS(wxBrushList, wxList)
-IMPLEMENT_ALIAS_SERIAL_CLASS(wxFontList, wxList)
-IMPLEMENT_ALIAS_SERIAL_CLASS(wxColourDatabase, wxList)
-IMPLEMENT_ALIAS_SERIAL_CLASS(wxBitmapList, wxList)
-
-// ----------------------------------------------------------------------------
-
-void WXSERIAL(wxBitmap)::StoreObject(wxObjectOutputStream& s)
-{
- // TODO
- // I implemented a basic image saving (maybe I'll need to improve wxWin API).
-
- int x, y, w, h;
- wxDataOutputStream data_s(s);
- wxBitmap *bitmap = (wxBitmap *)Object();
- wxColour col;
- wxMemoryDC dc;
-
- w = bitmap->GetWidth();
- h = bitmap->GetHeight();
-
- if (s.FirstStage()) {
- s.AddChild(bitmap->GetMask());
- }
-
- dc.SelectObject(*bitmap);
-
- data_s.Write16(w);
- data_s.Write16(h);
- for (y=0;y<h;y++)
- for (x=0;x<w;x++) {
- dc.GetPixel(x, y, &col);
- data_s.Write8( col.Red() );
- data_s.Write8( col.Green() );
- data_s.Write8( col.Blue() );
- }
-}
-
-void WXSERIAL(wxBitmap)::LoadObject(wxObjectInputStream& s)
-{
- // TODO
- // I implemented a basic image loading (maybe I'll need to improve wxWin API).
- wxDataInputStream data_s(s);
- wxBitmap *bitmap = (wxBitmap *)Object();
- wxMemoryDC dc;
- wxPen pen;
- int x, y, w, h;
- int r, g, b;
-
- w = data_s.Read16();
- h = data_s.Read16();
-
- bitmap->SetWidth(w);
- bitmap->SetHeight(h);
- dc.SelectObject(*bitmap);
-
- for (y=0;y<h;y++)
- for (x=0;x<w;x++) {
- r = data_s.Read8();
- g = data_s.Read8();
- b = data_s.Read8();
- pen.SetColour(r, g, b);
- dc.SetPen(pen);
- dc.DrawPoint(x,y);
- }
-}
-
-// ----------------------------------------------------------------------------
-
-void WXSERIAL(wxGDIObject)::StoreObject(wxObjectOutputStream& s)
-{
- if (s.FirstStage())
- return;
-
- bool visible = ((wxGDIObject *)Object())->GetVisible();
-
- wxDataOutputStream data_s(s);
- data_s.Write8(visible);
-}
-
-void WXSERIAL(wxGDIObject)::LoadObject(wxObjectInputStream& s)
-{
- wxDataInputStream data_s(s);
-
- ((wxGDIObject *)Object())->SetVisible( data_s.Read8() );
-}
-
-// ----------------------------------------------------------------------------
-
-void WXSERIAL(wxRegion)::StoreObject(wxObjectOutputStream& s)
-{
- WXSERIAL(wxGDIObject)::StoreObject(s);
-
- if (s.FirstStage())
- return;
-
- wxDataOutputStream data_s(s);
- wxRect rect = ((wxRegion *)Object())->GetBox();
-
- data_s.Write16( rect.GetX() );
- data_s.Write16( rect.GetY() );
- data_s.Write16( rect.GetWidth() );
- data_s.Write16( rect.GetHeight() );
-}
-
-void WXSERIAL(wxRegion)::LoadObject(wxObjectInputStream& s)
-{
- WXSERIAL(wxGDIObject)::LoadObject(s);
-
- wxDataInputStream data_s(s);
- wxRegion *region = (wxRegion *)Object();
- wxRect rect;
-
- rect.SetX( data_s.Read16() );
- rect.SetY( data_s.Read16() );
- rect.SetWidth( data_s.Read16() );
- rect.SetHeight( data_s.Read16() );
-
- *region = wxRegion(rect);
-}
-
-// ----------------------------------------------------------------------------
-
-void WXSERIAL(wxColour)::StoreObject(wxObjectOutputStream& s)
-{
- if (s.FirstStage())
- return;
-
- wxDataOutputStream data_s(s);
- wxColour *colour = (wxColour *)Object();
-
- if (!colour->Ok()) {
- data_s.Write8(0);
- data_s.Write8(0);
- data_s.Write8(0);
- wxLogDebug("wxColour (0x%x) isn't ready.\n", colour);
- return;
- }
-
- data_s.Write8(colour->Red());
- data_s.Write8(colour->Green());
- data_s.Write8(colour->Blue());
-}
-
-void WXSERIAL(wxColour)::LoadObject(wxObjectInputStream& s)
-{
- wxDataInputStream data_s(s);
- wxColour *colour = (wxColour *)Object();
- int r, g, b;
-
- r = data_s.Read8();
- g = data_s.Read8();
- b = data_s.Read8();
-
- colour->Set(r, g, b);
-}
-
-// ----------------------------------------------------------------------------
-
-void WXSERIAL(wxPen)::StoreObject(wxObjectOutputStream& s)
-{
- wxPen *pen = (wxPen *)Object();
- WXSERIAL(wxGDIObject)::StoreObject(s);
-
- if (s.FirstStage()) {
- s.AddChild(& (pen->GetColour()) );
- return;
- }
-
- wxDataOutputStream data_s(s);
-
- data_s.Write8( pen->GetCap() );
- data_s.Write8( pen->GetJoin() );
- data_s.Write8( pen->GetStyle() );
- data_s.Write8( pen->GetWidth() );
-}
-
-void WXSERIAL(wxPen)::LoadObject(wxObjectInputStream& s)
-{
- wxPen *pen = (wxPen *)Object();
- wxColour *col = (wxColour *) s.GetChild();
-
- WXSERIAL(wxGDIObject)::LoadObject(s);
-
- wxDataInputStream data_s(s);
-
- pen->SetColour(*col);
- pen->SetCap( data_s.Read8() );
- pen->SetJoin( data_s.Read8() );
- pen->SetStyle( data_s.Read8() );
- pen->SetWidth( data_s.Read8() );
-}
-
-// ----------------------------------------------------------------------------
-void WXSERIAL(wxBrush)::StoreObject(wxObjectOutputStream& s)
-{
- wxBrush *brush = (wxBrush *)Object();
- WXSERIAL(wxGDIObject)::StoreObject(s);
-
- if (s.FirstStage()) {
- s.AddChild( &(brush->GetColour()) );
- s.AddChild( brush->GetStipple() );
- return;
- }
-
- wxDataOutputStream data_s(s);
- data_s.Write8( brush->GetStyle() );
-}
-
-void WXSERIAL(wxBrush)::LoadObject(wxObjectInputStream& s)
-{
- wxBrush *brush = (wxBrush *)Object();
- wxColour *col = (wxColour *)s.GetChild();
- wxBitmap *bmap = (wxBitmap *)s.GetChild();
-
- WXSERIAL(wxGDIObject)::LoadObject(s);
-
- wxDataInputStream data_s(s);
- if (bmap)
- *brush = wxBrush(*col, data_s.Read8());
- else
- *brush = wxBrush(bmap);
-}
-
-// ----------------------------------------------------------------------------
-void WXSERIAL(wxFont)::StoreObject(wxObjectOutputStream& s)
-{
- wxFont *font = (wxFont *)Object();
-
- WXSERIAL(wxGDIObject)::StoreObject(s);
-
- if (s.FirstStage())
- return;
-
- wxDataOutputStream data_s(s);
-
- data_s.Write8( font->GetPointSize() );
- data_s.WriteString( font->GetFaceName() );
- data_s.Write8( font->GetFamily() );
- data_s.Write8( font->GetStyle() );
- data_s.Write8( font->GetWeight() );
- data_s.Write8( font->GetUnderlined() );
-}
-
-void WXSERIAL(wxFont)::LoadObject(wxObjectInputStream& s)
-{
- wxFont *font = (wxFont *)Object();
-
- WXSERIAL(wxGDIObject)::LoadObject(s);
-
- wxDataInputStream data_s(s);
- int psize, family, style, weight;
- bool underlined;
- wxString face_name;
-
- psize = data_s.Read8();
- face_name = data_s.ReadString();
- family = data_s.Read8();
- style = data_s.Read8();
- weight = data_s.Read8();
- underlined = data_s.Read8();
-
- *font = wxFont(psize, face_name, family, style, weight, underlined);
-}
-
-// ----------------------------------------------------------------------------
-
-void WXSERIAL(wxImageList)::StoreObject(wxObjectOutputStream& s)
-{
- wxImageList *list = (wxImageList *)Object();
- int i;
-
- if (s.FirstStage()) {
-#ifdef __WXGTK__
- for (i=0;i<list->GetImageCount();i++)
- s.AddChild(list->GetBitmap(i));
-#endif
- }
-
- wxDataOutputStream data_s(s);
-
- data_s.Write32(list->GetImageCount());
-}
-
-void WXSERIAL(wxImageList)::LoadObject(wxObjectInputStream& s)
-{
- int i, count;
- wxImageList *list = (wxImageList *)Object();
- wxDataInputStream data_s(s);
-
- count = data_s.Read32();
- for (i=0;i<count;i++)
- list->Add(*((wxBitmap *)s.GetChild()));
-}
+++ /dev/null
-/////////////////////////////////////////////////////////////////////////////
-// Name: sergdi.h
-// Purpose: Serialization: GDI classes
-// Author: Guilhem Lavaux
-// Modified by:
-// Created: July 1998
-// RCS-ID: $Id$
-// Copyright: (c) 1998 Guilhem Lavaux
-// Licence: wxWindows license
-/////////////////////////////////////////////////////////////////////////////
-
-#ifndef __SERGDI_H__
-#define __SERGDI_H__
-
-#ifdef __GNUG__
-#pragma interface
-#endif
-
-#include <wx/serbase.h>
-#include "sercore.h"
-
-DECLARE_SERIAL_CLASS(wxBitmap, wxObject)
-DECLARE_SERIAL_CLASS(wxGDIObject, wxObject)
-DECLARE_SERIAL_CLASS(wxRegion, wxGDIObject)
-DECLARE_SERIAL_CLASS(wxColour, wxObject)
-DECLARE_SERIAL_CLASS(wxFont, wxGDIObject)
-DECLARE_SERIAL_CLASS(wxPen, wxGDIObject)
-DECLARE_SERIAL_CLASS(wxBrush, wxGDIObject)
-DECLARE_SERIAL_CLASS(wxImageList, wxObject)
-
-DECLARE_ALIAS_SERIAL_CLASS(wxPenList, wxList)
-DECLARE_ALIAS_SERIAL_CLASS(wxBrushList, wxList)
-DECLARE_ALIAS_SERIAL_CLASS(wxFontList, wxList)
-DECLARE_ALIAS_SERIAL_CLASS(wxColourDatabase, wxList)
-DECLARE_ALIAS_SERIAL_CLASS(wxBitmapList, wxList)
-
-#endif
+++ /dev/null
-/////////////////////////////////////////////////////////////////////////////
-// Name: sermain.cpp
-// Purpose: Serialization: main
-// Author: Guilhem Lavaux
-// Modified by:
-// Created: July 1998
-// RCS-ID: $Id$
-// Copyright: (c) 1998 Guilhem Lavaux
-// Licence: wxWindows license
-/////////////////////////////////////////////////////////////////////////////
-
-#ifdef __GNUG__
-#pragma implementation "serbase.h"
-#endif
-
-#include <wx/dynlib.h>
-#include <wx/serbase.h>
-
-#include "sercore.h"
-#include "serwnd.h"
-#include "sergdi.h"
-#include "serctrl.h"
-#include "serext.h"
-
-IMPLEMENT_DYNAMIC_CLASS(wxObject_Serialize, wxObject)
-
-WXDLL_ENTRY_FUNCTION()
+++ /dev/null
-/////////////////////////////////////////////////////////////////////////////
-// Name: serwnd.cpp
-// Purpose: Serialization: wxWindow classes
-// Author: Guilhem Lavaux
-// Modified by:
-// Created: July 1998
-// RCS-ID: $Id$
-// Copyright: (c) 1998 Guilhem Lavaux
-// Licence: wxWindows license
-/////////////////////////////////////////////////////////////////////////////
-
-#ifdef __GNUG__
-#pragma implementation "serwnd.h"
-#endif
-
-#include <wx/window.h>
-#include <wx/layout.h>
-#include <wx/stream.h>
-#include <wx/datstrm.h>
-#include <wx/objstrm.h>
-#include <wx/utils.h>
-#include <wx/frame.h>
-#include <wx/panel.h>
-#include <wx/menu.h>
-#include <wx/dialog.h>
-#include <wx/serbase.h>
-#include <wx/statusbr.h>
-#include <wx/mdi.h>
-#include "wx/log.h"
-#include "serwnd.h"
-
-
-IMPLEMENT_SERIAL_CLASS(wxWindow, wxObject)
-IMPLEMENT_SERIAL_CLASS(wxIndividualLayoutConstraint, wxObject)
-IMPLEMENT_SERIAL_CLASS(wxLayoutConstraints, wxObject)
-IMPLEMENT_ALIAS_SERIAL_CLASS(wxValidator, wxObject)
-IMPLEMENT_SERIAL_CLASS(wxFrame, wxWindow)
-IMPLEMENT_SERIAL_CLASS(wxPanel, wxWindow)
-IMPLEMENT_SERIAL_CLASS(wxDialog, wxWindow)
-IMPLEMENT_SERIAL_CLASS(wxMenuBar, wxWindow)
-IMPLEMENT_SERIAL_CLASS(wxMenuItem, wxObject)
-IMPLEMENT_SERIAL_CLASS(wxMenu, wxObject)
-
-IMPLEMENT_SERIAL_CLASS(wxMDIParentFrame, wxFrame)
-IMPLEMENT_SERIAL_CLASS(wxMDIChildFrame, wxFrame)
-IMPLEMENT_SERIAL_CLASS(wxMDIClientWindow, wxWindow)
-
-/////////////////////////////////////////////////////////////////////////////
-
-void WXSERIAL(wxWindow)::StoreObject(wxObjectOutputStream& s)
-{
- wxWindow *win_object = (wxWindow *)Object();
-
- if (s.FirstStage()) {
- wxNode *node = win_object->GetChildren()->First();
-
- s.AddChild(win_object->GetConstraints());
- s.AddChild(win_object->GetValidator());
-
- // BAD HACK, but I don't have access to the internal variable of wxWindow.
- m_bg_colour = win_object->GetBackgroundColour();
- m_fg_colour = win_object->GetForegroundColour();
- s.AddChild(&m_bg_colour);
- s.AddChild(&m_fg_colour);
- s.AddChild(win_object->GetFont());
- while (node) {
- s.AddChild(node->Data());
- node = node->Next();
- }
- return;
- }
-
- wxDataOutputStream data(s);
- int x,y,w,h;
-
- data.WriteString( win_object->GetName() );
- data.WriteString( win_object->GetLabel() );
- data.WriteString( win_object->GetTitle() );
-
- data.Write8( win_object->GetAutoLayout() );
- data.Write8( win_object->IsShown() );
- data.Write32( win_object->GetWindowStyleFlag() );
- data.Write32( win_object->GetId() );
- wxLogDebug( "Number = %d", win_object->GetChildren()->Number() );
- data.Write8( win_object->GetChildren()->Number() );
-
- win_object->GetSize(&w, &h);
- win_object->GetPosition(&x, &y);
- data.Write16(x);
- data.Write16(y);
- data.Write16(w);
- data.Write16(h);
-}
-
-void WXSERIAL(wxWindow)::LoadObject(wxObjectInputStream& s)
-{
- wxDataInputStream data_s(s);
- wxWindow *win_object = (wxWindow *)Object();
- wxColour *colour;
- wxFont *font;
-
- if (s.SecondCall()) {
- /* I assume we will never create raw wxWindow object */
- (void)s.GetChild(); // We pass wxLayoutConstraints.
- (void)s.GetChild(); // We pass wxValidator.
-
- colour = (wxColour *)s.GetChild();
- if (colour)
- win_object->SetBackgroundColour(*colour);
- colour = (wxColour *)s.GetChild();
- if (colour)
- win_object->SetForegroundColour(*colour);
- font = (wxFont *)s.GetChild();
- if (font)
- win_object->SetFont(*font);
- s.RemoveChildren(m_number);
- return;
- }
-
- m_parent = (wxWindow *)s.GetParent();
-
- m_name = data_s.ReadString();
- m_label = data_s.ReadString();
- m_title = data_s.ReadString();
-
- m_auto_layout = data_s.Read8();
- m_shown = data_s.Read8();
- m_style = data_s.Read32();
- m_id = data_s.Read32();
- m_number = data_s.Read8();
-
- m_x = data_s.Read16();
- m_y = data_s.Read16();
- m_w = data_s.Read16();
- m_h = data_s.Read16();
-
- (void)s.GetChild(); // We pass wxLayoutConstraints.
-
- m_validator = (wxValidator *)s.GetChild();
- if (!m_validator)
- m_validator = (wxValidator *)&wxDefaultValidator;
-
- s.RemoveChildren(m_number+3);
-
- s.Recall();
-
- return;
-}
-
-/////////////////////////////////////////////////////////////////////////////
-
-void WXSERIAL(wxIndividualLayoutConstraint)::StoreObject
- (wxObjectOutputStream& s)
-{
- wxIndividualLayoutConstraint *lay_object =
- (wxIndividualLayoutConstraint *)Object();
- if (s.FirstStage())
- return;
-
- wxDataOutputStream data_s(s);
-
- data_s.WriteString(s.GetObjectName(lay_object->GetOtherWindow()));
- data_s.Write8(lay_object->GetMyEdge());
- data_s.Write8(lay_object->GetRelationship());
- data_s.Write16(lay_object->GetMargin());
- data_s.Write16(lay_object->GetValue());
- data_s.Write8(lay_object->GetPercent());
- data_s.Write8(lay_object->GetOtherEdge());
-}
-
-void WXSERIAL(wxIndividualLayoutConstraint)::
- LoadObject(wxObjectInputStream& s)
-{
- wxIndividualLayoutConstraint *lay_object =
- (wxIndividualLayoutConstraint *)Object();
- wxDataInputStream data_s(s);
- wxString win_name;
-
- win_name = data_s.ReadString();
- lay_object->otherWin = (wxWindow *)s.SolveName(win_name);
- lay_object->myEdge = (wxEdge)data_s.Read8();
- lay_object->relationship = (wxRelationship)data_s.Read8();
- lay_object->margin = data_s.Read16();
- lay_object->value = data_s.Read16();
- lay_object->percent = data_s.Read8();
- lay_object->otherEdge = (wxEdge)data_s.Read8();
-}
-
-/////////////////////////////////////////////////////////////////////////////
-
-void WXSERIAL(wxLayoutConstraints)::StoreObject(wxObjectOutputStream& s)
-{
- wxLayoutConstraints *lay_object = (wxLayoutConstraints *)Object();
- WXSERIAL(wxIndividualLayoutConstraint) c;
-
-#define STORE(obj) c.SetObject(&(lay_object->obj)); c.StoreObject(s);
-
- // I simplify the process for this object
- STORE(left);
- STORE(right);
- STORE(bottom);
- STORE(top);
-
- STORE(width);
- STORE(height);
-
- STORE(centreX);
- STORE(centreY);
-
-#undef STORE
-}
-
-void WXSERIAL(wxLayoutConstraints)::LoadObject(wxObjectInputStream& s)
-{
- wxLayoutConstraints *lay_object = (wxLayoutConstraints *)Object();
- WXSERIAL(wxIndividualLayoutConstraint) c;
-
-#define LOAD(obj) c.SetObject(&(lay_object->obj)); c.LoadObject(s);
-
- // I simplify the process for this object
- LOAD(left);
- LOAD(right);
- LOAD(bottom);
- LOAD(top);
-
- LOAD(width);
- LOAD(height);
-
- LOAD(centreX);
- LOAD(centreY);
-
-#undef LOAD
-
- // Initialize constraints
- ((wxWindow *)s.GetParent())->SetConstraints(lay_object);
-}
-
-/////////////////////////////////////////////////////////////////////////////
-
-void WXSERIAL(wxFrame)::StoreObject(wxObjectOutputStream& s)
-{
- wxFrame *frame = (wxFrame *)Object();
-
- if (s.FirstStage()) {
- s.AddChild(frame->GetMenuBar());
- WXSERIAL(wxWindow)::StoreObject(s);
- return;
- }
-
- WXSERIAL(wxWindow)::StoreObject(s);
-
- wxDataOutputStream data_s(s);
- wxStatusBar *statbar = frame->GetStatusBar();
-
- // AAARGH !! I absolutely need to be able to modify internal fields of
- // wxFrame (wxToolBar and wxStatusBar)
-
- if (statbar)
- data_s.Write8(statbar->GetFieldsCount());
- else
- data_s.Write8(0);
- // HOW CAN I ACCESS TO THIS FIELD ?
- // for (...) { data_s.Write8(statbar->m_statusWidths[i]); }
-}
-
-void WXSERIAL(wxFrame)::LoadObject(wxObjectInputStream& s)
-{
- wxFrame *frame = (wxFrame *)Object();
- wxMenuBar *mbar = (wxMenuBar *)s.GetChild();
-
- WXSERIAL(wxWindow)::LoadObject(s);
-
- if (s.SecondCall())
- return;
-
- wxDataInputStream data_s(s);
-
- if (frame->GetClassInfo() == CLASSINFO(wxFrame))
- frame->Create(m_parent, m_id, m_title, wxPoint(m_x, m_y),
- wxSize(m_w, m_h), m_style, m_name);
- frame->SetMenuBar(mbar);
-
- frame->CreateStatusBar(data_s.Read8());
-}
-
-/////////////////////////////////////////////////////////////////////////////
-
-void WXSERIAL(wxMenuBar)::StoreObject(wxObjectOutputStream& s)
-{
- wxMenuBar *mbar = (wxMenuBar *)Object();
- int i, mcount = mbar->GetMenuCount();
-
- if (s.FirstStage()) {
- for (i=0;i<mcount;i++)
- s.AddChild( mbar->GetMenu(i) );
- WXSERIAL(wxWindow)::StoreObject(s);
- return;
- }
-
- wxDataOutputStream data_s(s);
- data_s.Write8( mcount );
-
- // It isn't necessary for this object.
- // WXSERIAL(wxWindow)::StoreObject(s);
-}
-
-void WXSERIAL(wxMenuBar)::LoadObject(wxObjectInputStream& s)
-{
- wxMenuBar *mbar = (wxMenuBar *)Object();
- int i, mcount;
- wxDataInputStream data_s(s);
-
- mcount = data_s.Read8();
- for (i=0;i<mcount;i++) {
- wxMenu *menu = (wxMenu *)s.GetChild();
- mbar->Append( menu, menu->GetTitle() );
- }
-
- // It isn't necessary for this object.
- // WXSERIAL(wxWindow)::LoadObject(s);
-}
-
-/////////////////////////////////////////////////////////////////////////////
-
-void WXSERIAL(wxMenu)::StoreObject(wxObjectOutputStream& s)
-{
- wxMenu *menu = (wxMenu *)Object();
-
- if (s.FirstStage()) {
- s.AddChild( &menu->GetItems() );
- return;
- }
-
- wxDataOutputStream data_s(s);
- data_s.WriteString( menu->GetTitle() );
-}
-
-void WXSERIAL(wxMenu)::LoadObject(wxObjectInputStream& s)
-{
- wxMenu *menu = (wxMenu *)Object();
- wxList *items = (wxList *)s.GetChild();
- wxNode *node = items->First();
-
- wxDataInputStream data_s(s);
-
- menu->SetTitle( data_s.ReadString() );
-
- while (node) {
-// NOT IMPLEMENTED in wxGTK
-// menu->Append( (wxMenuItem *)node->Data() );
- node = node->Next();
- }
-}
-
-/////////////////////////////////////////////////////////////////////////////
-
-void WXSERIAL(wxMenuItem)::StoreObject(wxObjectOutputStream& s)
-{
- wxMenuItem *item = (wxMenuItem *)Object();
-
- if (s.FirstStage()) {
-#ifdef __WXGTK__
- s.AddChild(item->GetSubMenu());
-#endif
- return;
- }
-
- wxDataOutputStream data_s(s);
-
-#ifdef __WXGTK__
- data_s.Write8( item->GetId() );
- data_s.WriteString( item->GetText() );
- data_s.Write8( item->IsCheckable() );
- data_s.Write8( item->IsEnabled() );
- data_s.Write8( item->IsChecked() );
-#endif
-}
-
-void WXSERIAL(wxMenuItem)::LoadObject(wxObjectInputStream& s)
-{
- wxMenuItem *item = (wxMenuItem *)Object();
- wxDataInputStream data_s(s);
-
-#ifdef __WXGTK__
- item->SetId( data_s.Read8() );
- item->SetText( data_s.ReadString() );
- item->SetCheckable( data_s.Read8() );
- item->Enable( data_s.Read8() );
- item->Check( data_s.Read8() );
- item->SetSubMenu( (wxMenu *)s.GetChild() );
-#endif
-}
-
-/////////////////////////////////////////////////////////////////////////////
-
-void WXSERIAL(wxPanel)::StoreObject(wxObjectOutputStream& s)
-{
- WXSERIAL(wxWindow)::StoreObject(s);
-}
-
-void WXSERIAL(wxPanel)::LoadObject(wxObjectInputStream& s)
-{
- WXSERIAL(wxWindow)::LoadObject(s);
-
- if (s.SecondCall())
- return;
-
- ((wxPanel *)Object())->Create(m_parent, m_id, wxPoint(m_x, m_y),
- wxSize(m_w, m_h), m_style, m_name);
-}
-
-/////////////////////////////////////////////////////////////////////////////
-
-void WXSERIAL(wxDialog)::StoreObject(wxObjectOutputStream& s)
-{
- WXSERIAL(wxWindow)::StoreObject(s);
-}
-
-void WXSERIAL(wxDialog)::LoadObject(wxObjectInputStream& s)
-{
- WXSERIAL(wxWindow)::LoadObject(s);
-
- if (s.SecondCall())
- return;
-
- ((wxDialog *)Object())->Create(m_parent, m_id, m_title, wxPoint(m_x, m_y),
- wxSize(m_w, m_h), m_style, m_name);
-}
-
-/////////////////////////////////////////////////////////////////////////////
-
-void WXSERIAL(wxMDIParentFrame)::StoreObject(wxObjectOutputStream& s)
-{
- wxMDIParentFrame *frame = (wxMDIParentFrame *)Object();
-
- if (s.FirstStage()) {
- s.AddChild(frame->GetClientWindow());
- WXSERIAL(wxMDIParentFrame)::StoreObject(s);
- return;
- }
-
- WXSERIAL(wxMDIParentFrame)::StoreObject(s);
-}
-
-void WXSERIAL(wxMDIParentFrame)::LoadObject(wxObjectInputStream& s)
-{
- wxMDIParentFrame *frame = (wxMDIParentFrame *)Object();
- wxMDIClientWindow *client;
-
- if (s.SecondCall()) {
- WXSERIAL(wxFrame)::LoadObject(s);
- return;
- }
-
- client = (wxMDIClientWindow *) s.GetChild();
-
- frame->Create(m_parent, m_id, m_title, wxPoint(m_x, m_y),
- wxSize(m_w, m_h), m_style, m_name);
-
- WXSERIAL(wxFrame)::LoadObject(s);
-}
-
-/////////////////////////////////////////////////////////////////////////////
-
-void WXSERIAL(wxMDIChildFrame)::StoreObject(wxObjectOutputStream& s)
-{
- WXSERIAL(wxFrame)::StoreObject(s);
-}
-
-void WXSERIAL(wxMDIChildFrame)::LoadObject(wxObjectInputStream& s)
-{
- WXSERIAL(wxFrame)::LoadObject(s);
-
- if (s.SecondCall())
- return;
-
- ((wxMDIChildFrame *)Object())->Create((wxMDIParentFrame *)m_parent,
- m_id, m_title,
- wxPoint(m_x, m_y), wxSize(m_w, m_h),
- m_style, m_name);
-}
-
-/////////////////////////////////////////////////////////////////////////////
-
-void WXSERIAL(wxMDIClientWindow)::StoreObject(wxObjectOutputStream& s)
-{
- WXSERIAL(wxWindow)::StoreObject(s);
-}
-
-void WXSERIAL(wxMDIClientWindow)::LoadObject(wxObjectInputStream& s)
-{
- WXSERIAL(wxWindow)::LoadObject(s);
-
- if (s.SecondCall())
- return;
-
- ((wxMDIClientWindow *)Object())->CreateClient((wxMDIParentFrame *)m_parent, m_style);
-}
+++ /dev/null
-/////////////////////////////////////////////////////////////////////////////
-// Name: serwnd.h
-// Purpose: Serialization: wxWindow classes
-// Author: Guilhem Lavaux
-// Modified by:
-// Created: July 1998
-// RCS-ID: $Id$
-// Copyright: (c) 1998 Guilhem Lavaux
-// Licence: wxWindows license
-/////////////////////////////////////////////////////////////////////////////
-
-#ifndef _SERIALIZE_SERWND_H_
-#define _SERIALIZE_SERWND_H_
-
-#ifdef __GNUG__
-#pragma interface
-#endif
-
-#include <wx/window.h>
-#include <wx/serbase.h>
-
-class WXSERIAL(wxWindow) : public WXSERIAL(wxObject)
-{
- DECLARE_DYNAMIC_CLASS( wxWindow_Serialize )
- public:
- WXSERIAL(wxWindow)() { }
- virtual ~WXSERIAL(wxWindow)() { };
-
- void StoreObject(wxObjectOutputStream& s);
- void LoadObject(wxObjectInputStream& s);
-
- public:
- int m_x, m_y, m_w, m_h;
- bool m_shown, m_auto_layout;
- wxWindowID m_id;
- wxString m_name, m_title, m_label;
- wxWindow *m_parent;
- wxValidator *m_validator;
- wxColour m_bg_colour, m_fg_colour;
- long m_style;
- int m_number;
-};
-
-DECLARE_SERIAL_CLASS(wxIndividualLayoutConstraint, wxObject)
-DECLARE_SERIAL_CLASS(wxLayoutConstraints, wxObject)
-DECLARE_ALIAS_SERIAL_CLASS(wxValidator, wxObject)
-DECLARE_SERIAL_CLASS(wxFrame, wxWindow)
-DECLARE_SERIAL_CLASS(wxPanel, wxWindow)
-DECLARE_SERIAL_CLASS(wxDialog, wxWindow)
-DECLARE_SERIAL_CLASS(wxMenuBar, wxWindow)
-DECLARE_SERIAL_CLASS(wxMenuItem, wxObject)
-DECLARE_SERIAL_CLASS(wxMenu, wxObject)
-DECLARE_SERIAL_CLASS(wxMDIParentFrame, wxFrame)
-DECLARE_SERIAL_CLASS(wxMDIChildFrame, wxFrame)
-DECLARE_SERIAL_CLASS(wxMDIClientWindow, wxFrame)
-
-#endif