the library and the sample build with everything off, various wxUSE_XXX

options now really take effect (i.e. can be disabled without breaking
compilation)


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/wxUNIVERSAL@8027 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2000-08-11 13:16:58 +00:00
parent 65ab4b2f93
commit eeb2c17a67
92 changed files with 3000 additions and 1435 deletions

1911
configure vendored

File diff suppressed because it is too large Load Diff

View File

@@ -680,13 +680,14 @@ WX_ARG_CACHE_INIT
dnl useful to test the compilation with minimum options, define as 0 for normal dnl useful to test the compilation with minimum options, define as 0 for normal
dnl usage dnl usage
DEBUG_CONFIGURE=0 DEBUG_CONFIGURE=1
if test $DEBUG_CONFIGURE = 1; then if test $DEBUG_CONFIGURE = 1; then
DEFAULT_wxUSE_THREADS=yes DEFAULT_wxUSE_UNIVERSAL=no
DEFAULT_wxUSE_THREADS=no
DEFAULT_wxUSE_SHARED=yes DEFAULT_wxUSE_SHARED=yes
DEFAULT_wxUSE_BURNT_NAME=no DEFAULT_wxUSE_BURNT_NAME=no
DEFAULT_wxUSE_OPTIMISE=yes DEFAULT_wxUSE_OPTIMISE=no
DEFAULT_wxUSE_PROFILE=no DEFAULT_wxUSE_PROFILE=no
DEFAULT_wxUSE_NO_DEPS=no DEFAULT_wxUSE_NO_DEPS=no
DEFAULT_wxUSE_NO_RTTI=no DEFAULT_wxUSE_NO_RTTI=no
@@ -701,8 +702,11 @@ if test $DEBUG_CONFIGURE = 1; then
DEFAULT_wxUSE_APPLE_IEEE=no DEFAULT_wxUSE_APPLE_IEEE=no
DEFAULT_wxUSE_LOG=yes DEFAULT_wxUSE_LOG=yes
DEFAULT_wxUSE_LOGWINDOW=no
DEFAULT_wxUSE_LOGGUI=no
DEFAULT_wxUSE_GUI=yes DEFAULT_wxUSE_GUI=yes
DEFAULT_wxUSE_CONTROLS=no
DEFAULT_wxUSE_ZLIB=no DEFAULT_wxUSE_ZLIB=no
DEFAULT_wxUSE_LIBPNG=no DEFAULT_wxUSE_LIBPNG=no
@@ -713,12 +717,16 @@ if test $DEBUG_CONFIGURE = 1; then
DEFAULT_wxUSE_ON_FATAL_EXCEPTION=no DEFAULT_wxUSE_ON_FATAL_EXCEPTION=no
DEFAULT_wxUSE_STD_IOSTREAM=no DEFAULT_wxUSE_STD_IOSTREAM=no
DEFAULT_wxUSE_CMDLINE_PARSER=no
DEFAULT_wxUSE_DATETIME=no
DEFAULT_wxUSE_STOPWATCH=no
DEFAULT_wxUSE_FILE=no DEFAULT_wxUSE_FILE=no
DEFAULT_wxUSE_TEXTFILE=no DEFAULT_wxUSE_TEXTFILE=no
DEFAULT_wxUSE_TIMEDATE=no DEFAULT_wxUSE_TIMEDATE=no
DEFAULT_wxUSE_WAVE=no DEFAULT_wxUSE_WAVE=no
DEFAULT_wxUSE_INTL=no DEFAULT_wxUSE_INTL=no
DEFAULT_wxUSE_CONFIG=no DEFAULT_wxUSE_CONFIG=no
DEFAULT_wxUSE_FONTMAP=no
DEFAULT_wxUSE_STREAMS=no DEFAULT_wxUSE_STREAMS=no
DEFAULT_wxUSE_SOCKETS=no DEFAULT_wxUSE_SOCKETS=no
DEFAULT_wxUSE_DIALUP_MANAGER=no DEFAULT_wxUSE_DIALUP_MANAGER=no
@@ -750,7 +758,13 @@ if test $DEBUG_CONFIGURE = 1; then
DEFAULT_wxUSE_METAFILE=no DEFAULT_wxUSE_METAFILE=no
DEFAULT_wxUSE_COMMONDLGS=no DEFAULT_wxUSE_COMMONDLGS=no
DEFAULT_wxUSE_CHOICEDLG=no
DEFAULT_wxUSE_COLOURDLG=no
DEFAULT_wxUSE_DIRDLG=no DEFAULT_wxUSE_DIRDLG=no
DEFAULT_wxUSE_FILEDLG=no
DEFAULT_wxUSE_FONTDLG=no
DEFAULT_wxUSE_MSGDLG=no
DEFAULT_wxUSE_NUMBERDLG=no
DEFAULT_wxUSE_TEXTDLG=no DEFAULT_wxUSE_TEXTDLG=no
DEFAULT_wxUSE_STARTUP_TIPS=no DEFAULT_wxUSE_STARTUP_TIPS=no
DEFAULT_wxUSE_PROGRESSDLG=no DEFAULT_wxUSE_PROGRESSDLG=no
@@ -761,14 +775,15 @@ if test $DEBUG_CONFIGURE = 1; then
DEFAULT_wxUSE_FS_ZIP=no DEFAULT_wxUSE_FS_ZIP=no
DEFAULT_wxUSE_BUSYINFO=no DEFAULT_wxUSE_BUSYINFO=no
DEFAULT_wxUSE_ZIPSTREAM=no DEFAULT_wxUSE_ZIPSTREAM=no
DEFAULT_wxUSE_VALIDATORS=yes DEFAULT_wxUSE_VALIDATORS=no
DEFAULT_wxUSE_ACCEL=no DEFAULT_wxUSE_ACCEL=no
DEFAULT_wxUSE_BUTTON=no
DEFAULT_wxUSE_CARET=no DEFAULT_wxUSE_CARET=no
DEFAULT_wxUSE_BMPBUTTON=no DEFAULT_wxUSE_BMPBUTTON=no
DEFAULT_wxUSE_CHECKBOX=no DEFAULT_wxUSE_CHECKBOX=no
DEFAULT_wxUSE_CHECKLST=no DEFAULT_wxUSE_CHECKLST=no
DEFAULT_wxUSE_CHOICE=yes DEFAULT_wxUSE_CHOICE=no
DEFAULT_wxUSE_COMBOBOX=no DEFAULT_wxUSE_COMBOBOX=no
DEFAULT_wxUSE_GAUGE=no DEFAULT_wxUSE_GAUGE=no
DEFAULT_wxUSE_GRID=no DEFAULT_wxUSE_GRID=no
@@ -789,8 +804,9 @@ if test $DEBUG_CONFIGURE = 1; then
DEFAULT_wxUSE_STATBMP=no DEFAULT_wxUSE_STATBMP=no
DEFAULT_wxUSE_STATBOX=no DEFAULT_wxUSE_STATBOX=no
DEFAULT_wxUSE_STATLINE=no DEFAULT_wxUSE_STATLINE=no
DEFAULT_wxUSE_STATUSBAR=yes DEFAULT_wxUSE_STATUSBAR=no
DEFAULT_wxUSE_TABDIALOG=no DEFAULT_wxUSE_TABDIALOG=no
DEFAULT_wxUSE_TEXTCTRL=no
DEFAULT_wxUSE_TOOLBAR=no DEFAULT_wxUSE_TOOLBAR=no
DEFAULT_wxUSE_TOOLBAR_NATIVE=no DEFAULT_wxUSE_TOOLBAR_NATIVE=no
DEFAULT_wxUSE_TOOLBAR_SIMPLE=no DEFAULT_wxUSE_TOOLBAR_SIMPLE=no
@@ -803,6 +819,7 @@ if test $DEBUG_CONFIGURE = 1; then
DEFAULT_wxUSE_PCX=no DEFAULT_wxUSE_PCX=no
DEFAULT_wxUSE_PNM=no DEFAULT_wxUSE_PNM=no
else else
DEFAULT_wxUSE_UNIVERSAL=no
DEFAULT_wxUSE_THREADS=yes DEFAULT_wxUSE_THREADS=yes
DEFAULT_wxUSE_SHARED=yes DEFAULT_wxUSE_SHARED=yes
@@ -822,8 +839,11 @@ else
DEFAULT_wxUSE_APPLE_IEEE=yes DEFAULT_wxUSE_APPLE_IEEE=yes
DEFAULT_wxUSE_LOG=yes DEFAULT_wxUSE_LOG=yes
DEFAULT_wxUSE_LOGWINDOW=yes
DEFAULT_wxUSE_LOGGUI=yes
DEFAULT_wxUSE_GUI=yes DEFAULT_wxUSE_GUI=yes
DEFAULT_wxUSE_CONTROLS=yes
DEFAULT_wxUSE_ZLIB=yes DEFAULT_wxUSE_ZLIB=yes
DEFAULT_wxUSE_LIBPNG=yes DEFAULT_wxUSE_LIBPNG=yes
@@ -834,12 +854,16 @@ else
DEFAULT_wxUSE_ON_FATAL_EXCEPTION=yes DEFAULT_wxUSE_ON_FATAL_EXCEPTION=yes
DEFAULT_wxUSE_STD_IOSTREAM=no DEFAULT_wxUSE_STD_IOSTREAM=no
DEFAULT_wxUSE_CMDLINE_PARSER=yes
DEFAULT_wxUSE_DATETIME=yes
DEFAULT_wxUSE_STOPWATCH=yes
DEFAULT_wxUSE_FILE=yes DEFAULT_wxUSE_FILE=yes
DEFAULT_wxUSE_TEXTFILE=yes DEFAULT_wxUSE_TEXTFILE=yes
DEFAULT_wxUSE_TIMEDATE=yes DEFAULT_wxUSE_TIMEDATE=yes
DEFAULT_wxUSE_WAVE=no DEFAULT_wxUSE_WAVE=no
DEFAULT_wxUSE_INTL=yes DEFAULT_wxUSE_INTL=yes
DEFAULT_wxUSE_CONFIG=yes DEFAULT_wxUSE_CONFIG=yes
DEFAULT_wxUSE_FONTMAP=yes
DEFAULT_wxUSE_STREAMS=yes DEFAULT_wxUSE_STREAMS=yes
DEFAULT_wxUSE_SOCKETS=yes DEFAULT_wxUSE_SOCKETS=yes
DEFAULT_wxUSE_DIALUP_MANAGER=yes DEFAULT_wxUSE_DIALUP_MANAGER=yes
@@ -871,7 +895,13 @@ else
DEFAULT_wxUSE_METAFILE=yes DEFAULT_wxUSE_METAFILE=yes
DEFAULT_wxUSE_COMMONDLGS=yes DEFAULT_wxUSE_COMMONDLGS=yes
DEFAULT_wxUSE_CHOICEDLG=yes
DEFAULT_wxUSE_COLOURDLG=yes
DEFAULT_wxUSE_DIRDLG=yes DEFAULT_wxUSE_DIRDLG=yes
DEFAULT_wxUSE_FILEDLG=yes
DEFAULT_wxUSE_FONTDLG=yes
DEFAULT_wxUSE_MSGDLG=yes
DEFAULT_wxUSE_NUMBERDLG=yes
DEFAULT_wxUSE_TEXTDLG=yes DEFAULT_wxUSE_TEXTDLG=yes
DEFAULT_wxUSE_STARTUP_TIPS=yes DEFAULT_wxUSE_STARTUP_TIPS=yes
DEFAULT_wxUSE_PROGRESSDLG=yes DEFAULT_wxUSE_PROGRESSDLG=yes
@@ -885,6 +915,7 @@ else
DEFAULT_wxUSE_VALIDATORS=yes DEFAULT_wxUSE_VALIDATORS=yes
DEFAULT_wxUSE_ACCEL=yes DEFAULT_wxUSE_ACCEL=yes
DEFAULT_wxUSE_BUTTON=yes
DEFAULT_wxUSE_CARET=yes DEFAULT_wxUSE_CARET=yes
DEFAULT_wxUSE_BMPBUTTON=yes DEFAULT_wxUSE_BMPBUTTON=yes
DEFAULT_wxUSE_CHECKBOX=yes DEFAULT_wxUSE_CHECKBOX=yes
@@ -912,6 +943,7 @@ else
DEFAULT_wxUSE_STATLINE=yes DEFAULT_wxUSE_STATLINE=yes
DEFAULT_wxUSE_STATUSBAR=yes DEFAULT_wxUSE_STATUSBAR=yes
DEFAULT_wxUSE_TABDIALOG=no DEFAULT_wxUSE_TABDIALOG=no
DEFAULT_wxUSE_TEXTCTRL=yes
DEFAULT_wxUSE_TOOLBAR=yes DEFAULT_wxUSE_TOOLBAR=yes
DEFAULT_wxUSE_TOOLBAR_NATIVE=yes DEFAULT_wxUSE_TOOLBAR_NATIVE=yes
DEFAULT_wxUSE_TOOLBAR_SIMPLE=yes DEFAULT_wxUSE_TOOLBAR_SIMPLE=yes
@@ -956,6 +988,7 @@ WX_ARG_ENABLE(gui, [ --enable-gui use GUI classes], wxUSE_GU
if test "$wxUSE_GUI" = "yes"; then if test "$wxUSE_GUI" = "yes"; then
WX_ARG_ENABLE(universal, [ --enable-universal use wxWindows GUI controls instead of native ones], wxUSE_UNIVERSAL)
AC_ARG_WITH(gtk, [ --with-gtk use GTK+], [wxUSE_GTK="$withval" CACHE_GTK=1 TOOLKIT_GIVEN=1]) AC_ARG_WITH(gtk, [ --with-gtk use GTK+], [wxUSE_GTK="$withval" CACHE_GTK=1 TOOLKIT_GIVEN=1])
AC_ARG_WITH(motif, [ --with-motif use Motif/Lesstif], [wxUSE_MOTIF="$withval" CACHE_MOTIF=1 TOOLKIT_GIVEN=1]) AC_ARG_WITH(motif, [ --with-motif use Motif/Lesstif], [wxUSE_MOTIF="$withval" CACHE_MOTIF=1 TOOLKIT_GIVEN=1])
AC_ARG_WITH(wine, [ --with-wine use WINE], [wxUSE_WINE="$withval" CACHE_WINE=1 TOOLKIT_GIVEN=1]) AC_ARG_WITH(wine, [ --with-wine use WINE], [wxUSE_WINE="$withval" CACHE_WINE=1 TOOLKIT_GIVEN=1])
@@ -1023,9 +1056,12 @@ WX_ARG_ENABLE(sockets, [ --enable-sockets use socket/network class
WX_ARG_ENABLE(ipc, [ --enable-ipc use interprocess communication (wxSocket etc.)], wxUSE_IPC) WX_ARG_ENABLE(ipc, [ --enable-ipc use interprocess communication (wxSocket etc.)], wxUSE_IPC)
WX_ARG_ENABLE(cmdline, [ --enable-cmdline use wxCmdLineParser class], wxUSE_CMDLINE_PARSER)
WX_ARG_ENABLE(datetime, [ --enable-datetime use wxDateTime class], wxUSE_DATETIME)
WX_ARG_ENABLE(stopwatch, [ --enable-stopwatch use wxStopWatch class], wxUSE_STOPWATCH)
WX_ARG_ENABLE(dialupman, [ --enable-dialupman use dialup network classes], wxUSE_DIALUP_MANAGER) WX_ARG_ENABLE(dialupman, [ --enable-dialupman use dialup network classes], wxUSE_DIALUP_MANAGER)
WX_ARG_ENABLE(apple_ieee, [ --enable-apple_ieee use the Apple IEEE codec], wxUSE_APPLE_IEEE) WX_ARG_ENABLE(apple_ieee, [ --enable-apple_ieee use the Apple IEEE codec], wxUSE_APPLE_IEEE)
WX_ARG_ENABLE(timedate, [ --enable-timedate use date/time classes], wxUSE_TIMEDATE) WX_ARG_ENABLE(timer, [ --enable-timer use wxTimer class], wxUSE_TIMER)
WX_ARG_ENABLE(wave, [ --enable-wave use wxWave class], wxUSE_WAVE) 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(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(dynlib, [ --enable-dynlib use wxLibrary class for DLL loading], wxUSE_DYNLIB_CLASS)
@@ -1034,6 +1070,7 @@ WX_ARG_ENABLE(log, [ --enable-log use logging system], wxU
WX_ARG_ENABLE(streams, [ --enable-streams use wxStream etc classes], wxUSE_STREAMS) WX_ARG_ENABLE(streams, [ --enable-streams use wxStream etc classes], wxUSE_STREAMS)
WX_ARG_ENABLE(file, [ --enable-file use wxFile classes], wxUSE_FILE) WX_ARG_ENABLE(file, [ --enable-file use wxFile classes], wxUSE_FILE)
WX_ARG_ENABLE(textfile, [ --enable-textfile use wxTextFile classes], wxUSE_TEXTFILE) WX_ARG_ENABLE(textfile, [ --enable-textfile use wxTextFile classes], wxUSE_TEXTFILE)
WX_ARG_ENABLE(fontmap, [ --enable-fontmap use font encodings conversion classes], wxUSE_FONTMAP)
WX_ARG_ENABLE(unicode, [ --enable-unicode compile wxString with Unicode support], wxUSE_UNICODE) WX_ARG_ENABLE(unicode, [ --enable-unicode compile wxString with Unicode support], wxUSE_UNICODE)
WX_ARG_ENABLE(wcsrtombs, [ --enable-wcsrtombs use wcsrtombs instead of buggy (GNU libc1/Linux libc5) wcstombs], wxUSE_WCSRTOMBS) WX_ARG_ENABLE(wcsrtombs, [ --enable-wcsrtombs use wcsrtombs instead of buggy (GNU libc1/Linux libc5) wcstombs], wxUSE_WCSRTOMBS)
WX_ARG_ENABLE(wxprintfv, [ --enable-wxprintfv use wxWindows implementation of vprintf()], wxUSE_EXPERIMENTAL_PRINTF) WX_ARG_ENABLE(wxprintfv, [ --enable-wxprintfv use wxWindows implementation of vprintf()], wxUSE_EXPERIMENTAL_PRINTF)
@@ -1063,6 +1100,8 @@ WX_ARG_ENABLE(help, [ --enable-help use help (using external b
WX_ARG_ENABLE(constraints, [ --enable-constraints use layout-constraints system], wxUSE_CONSTRAINTS) WX_ARG_ENABLE(constraints, [ --enable-constraints use layout-constraints system], wxUSE_CONSTRAINTS)
WX_ARG_ENABLE(printarch, [ --enable-printarch use printing architecture], wxUSE_PRINTING_ARCHITECTURE) WX_ARG_ENABLE(printarch, [ --enable-printarch use printing architecture], wxUSE_PRINTING_ARCHITECTURE)
WX_ARG_ENABLE(mdi, [ --enable-mdi use multiple document interface architecture], wxUSE_MDI_ARCHITECTURE) WX_ARG_ENABLE(mdi, [ --enable-mdi use multiple document interface architecture], wxUSE_MDI_ARCHITECTURE)
WX_ARG_ENABLE(loggui, [ --enable-loggui use standard GUI logger], wxUSE_LOGGUI)
WX_ARG_ENABLE(logwin, [ --enable-logwin use wxLogWindow], wxUSE_LOGWINDOW)
dnl --------------------------------------------------------------------------- dnl ---------------------------------------------------------------------------
dnl PostScript options dnl PostScript options
@@ -1102,6 +1141,7 @@ dnl --disable-<control> later on the command line - but by default all will be
dnl used (and vice versa) dnl used (and vice versa)
if test "$wxUSE_CONTROLS" = "yes"; then if test "$wxUSE_CONTROLS" = "yes"; then
DEFAULT_wxUSE_ACCEL=yes DEFAULT_wxUSE_ACCEL=yes
DEFAULT_wxUSE_BUTTON=yes
DEFAULT_wxUSE_CARET=yes DEFAULT_wxUSE_CARET=yes
DEFAULT_wxUSE_COMBOBOX=yes DEFAULT_wxUSE_COMBOBOX=yes
DEFAULT_wxUSE_BMPBUTTON=yes DEFAULT_wxUSE_BMPBUTTON=yes
@@ -1135,6 +1175,7 @@ if test "$wxUSE_CONTROLS" = "yes"; then
DEFAULT_wxUSE_TREECTRL=yes DEFAULT_wxUSE_TREECTRL=yes
elif test "$wxUSE_CONTROLS" = "no"; then elif test "$wxUSE_CONTROLS" = "no"; then
DEFAULT_wxUSE_ACCEL=no DEFAULT_wxUSE_ACCEL=no
DEFAULT_wxUSE_BUTTON=no
DEFAULT_wxUSE_CARET=no DEFAULT_wxUSE_CARET=no
DEFAULT_wxUSE_COMBOBOX=no DEFAULT_wxUSE_COMBOBOX=no
DEFAULT_wxUSE_BMPBUTTON=no DEFAULT_wxUSE_BMPBUTTON=no
@@ -1169,8 +1210,9 @@ elif test "$wxUSE_CONTROLS" = "no"; then
fi fi
WX_ARG_ENABLE(accel, [ --enable-accel use accelerators], wxUSE_ACCEL) WX_ARG_ENABLE(accel, [ --enable-accel use accelerators], wxUSE_ACCEL)
WX_ARG_ENABLE(caret, [ --enable-caret use wxCaret class], wxUSE_CARET) WX_ARG_ENABLE(button, [ --enable-button use wxButton class], wxUSE_BUTTON)
WX_ARG_ENABLE(bmpbutton, [ --enable-bmpbutton use wxBitmapButton class], wxUSE_BMPBUTTON) WX_ARG_ENABLE(bmpbutton, [ --enable-bmpbutton use wxBitmapButton class], wxUSE_BMPBUTTON)
WX_ARG_ENABLE(caret, [ --enable-caret use wxCaret class], wxUSE_CARET)
WX_ARG_ENABLE(checkbox, [ --enable-checkbox use wxCheckBox class], wxUSE_CHECKBOX) WX_ARG_ENABLE(checkbox, [ --enable-checkbox use wxCheckBox class], wxUSE_CHECKBOX)
WX_ARG_ENABLE(checklst, [ --enable-checklst use wxCheckListBox (listbox with checkboxes) class], wxUSE_CHECKLST) WX_ARG_ENABLE(checklst, [ --enable-checklst use wxCheckListBox (listbox with checkboxes) class], wxUSE_CHECKLST)
WX_ARG_ENABLE(choice, [ --enable-choice use wxChoice class], wxUSE_CHOICE) WX_ARG_ENABLE(choice, [ --enable-choice use wxChoice class], wxUSE_CHOICE)
@@ -1195,6 +1237,7 @@ WX_ARG_ENABLE(statbox, [ --enable-statbox use wxStaticBox class], wx
WX_ARG_ENABLE(statline, [ --enable-statline use wxStaticLine class], wxUSE_STATLINE) WX_ARG_ENABLE(statline, [ --enable-statline use wxStaticLine class], wxUSE_STATLINE)
WX_ARG_ENABLE(statusbar, [ --enable-statusbar use wxStatusBar class], wxUSE_STATUSBAR) WX_ARG_ENABLE(statusbar, [ --enable-statusbar use wxStatusBar class], wxUSE_STATUSBAR)
WX_ARG_ENABLE(tabdialog, [ --enable-tabdialog use wxTabControl class], wxUSE_TABDIALOG) WX_ARG_ENABLE(tabdialog, [ --enable-tabdialog use wxTabControl class], wxUSE_TABDIALOG)
WX_ARG_ENABLE(textctrl, [ --enable-textctrl use wxTextCtrl class], wxUSE_TEXTCTRL)
WX_ARG_ENABLE(toolbar, [ --enable-toolbar use wxToolBar class], wxUSE_TOOLBAR) WX_ARG_ENABLE(toolbar, [ --enable-toolbar use wxToolBar class], wxUSE_TOOLBAR)
WX_ARG_ENABLE(tbarnative, [ --enable-tbarnative use native wxToolBar class], wxUSE_TOOLBAR_NATIVE) WX_ARG_ENABLE(tbarnative, [ --enable-tbarnative use native wxToolBar class], wxUSE_TOOLBAR_NATIVE)
WX_ARG_ENABLE(tbarsmpl, [ --enable-tbarsmpl use wxToolBarSimple class], wxUSE_TOOLBAR_SIMPLE) WX_ARG_ENABLE(tbarsmpl, [ --enable-tbarsmpl use wxToolBarSimple class], wxUSE_TOOLBAR_SIMPLE)
@@ -1205,7 +1248,13 @@ dnl misc GUI options
dnl --------------------------------------------------------------------------- dnl ---------------------------------------------------------------------------
WX_ARG_ENABLE(commondlg, [ --enable-commondlg use common dialogs (wxDirDialog, wxProgressDialog, wxTextDialog, ...)], wxUSE_COMMONDLGS) WX_ARG_ENABLE(commondlg, [ --enable-commondlg use common dialogs (wxDirDialog, wxProgressDialog, wxTextDialog, ...)], wxUSE_COMMONDLGS)
WX_ARG_ENABLE(choicedlg, [ --enable-choicedlg use wxChoiceDialog], wxUSE_CHOICEDLG)
WX_ARG_ENABLE(coldlg, [ --enable-coldlg use wxColourDialog], wxUSE_COLOURDLG)
WX_ARG_ENABLE(filedlg, [ --enable-filedlg use wxFileDialog], wxUSE_FILEDLG)
WX_ARG_ENABLE(fontdlg, [ --enable-fontdlg use wxFontDialog], wxUSE_FONTDLG)
WX_ARG_ENABLE(dirdlg, [ --enable-dirdlg use wxDirDialog], wxUSE_DIRDLG) WX_ARG_ENABLE(dirdlg, [ --enable-dirdlg use wxDirDialog], wxUSE_DIRDLG)
WX_ARG_ENABLE(msgdlg, [ --enable-msgdlg use wxMessageDialog], wxUSE_MSGDLG)
WX_ARG_ENABLE(numberdlg, [ --enable-numberdlg use wxNumberEntryDialog], wxUSE_NUMBERDLG)
WX_ARG_ENABLE(textdlg, [ --enable-textdlg use wxTextDialog], wxUSE_TEXTDLG) WX_ARG_ENABLE(textdlg, [ --enable-textdlg use wxTextDialog], wxUSE_TEXTDLG)
WX_ARG_ENABLE(tipdlg, [ --enable-tipdlg use startup tips], wxUSE_STARTUP_TIPS) WX_ARG_ENABLE(tipdlg, [ --enable-tipdlg use startup tips], wxUSE_STARTUP_TIPS)
WX_ARG_ENABLE(progressdlg, [ --enable-progressdlg use wxProgressDialog], wxUSE_PROGRESSDLG) WX_ARG_ENABLE(progressdlg, [ --enable-progressdlg use wxProgressDialog], wxUSE_PROGRESSDLG)
@@ -1526,7 +1575,6 @@ dnl ----------------------------------------------------------------
AFMINSTALL= AFMINSTALL=
if test "$wxUSE_GUI" = "yes"; then if test "$wxUSE_GUI" = "yes"; then
USE_GUI=1 USE_GUI=1
TOOLKIT= TOOLKIT=
@@ -1595,7 +1643,6 @@ if test "$wxUSE_CYGWIN" = 1 || test "$wxUSE_MINGW" = 1 ; then
dnl set optinal RES_PROGRAM_OPT to RES_PROGRAM dnl set optinal RES_PROGRAM_OPT to RES_PROGRAM
RESPROGRAM="\$(RES_PROGRAM)" RESPROGRAM="\$(RES_PROGRAM)"
fi fi
if test "$wxUSE_GTK" = 1; then if test "$wxUSE_GTK" = 1; then
@@ -1910,20 +1957,37 @@ else
fi fi
dnl the (base) name of the library and support files for this toolkit dnl the (base) name of the library and support files for this toolkit
if test "$wxUSE_DEBUG_FLAG" = "yes"; then
TOOLKIT_NAME="${TOOLKIT_DIR}d"
else
TOOLKIT_NAME="${TOOLKIT_DIR}" TOOLKIT_NAME="${TOOLKIT_DIR}"
dnl are we using the generic version with this low level toolkit?
if test "$wxUSE_UNIVERSAL" = "yes"; then
TOOLKIT_NAME="${TOOLKIT_NAME}univ"
fi
dnl append 'd' to the debug library name
if test "$wxUSE_DEBUG_FLAG" = "yes"; then
TOOLKIT_NAME="${TOOLKIT_NAME}d"
fi fi
dnl the symbol which allows conditional compilation for the given toolkit dnl the symbol which allows conditional compilation for the given toolkit
TOOLKIT_DEF="-D__WX${TOOLKIT}__" TOOLKIT_DEF="-D__WX${TOOLKIT}__"
if test "$wxUSE_UNIVERSAL" = "yes"; then
TOOLKIT_DEF="${TOOLKIT_DEF} -D__WXUNIVERSAL__"
fi
dnl the name of the (libtool) library dnl the name of the (libtool) library
WX_LIBRARY="wx_${TOOLKIT_NAME}" WX_LIBRARY="wx_${TOOLKIT_NAME}"
dnl the sources, their dependenices and the headers dnl the sources, their dependenices and the headers
ALL_OBJECTS="\$(GUIOBJS) \$(COMMONOBJS) \$(GENERICOBJS) \$(UNIXOBJS) \$(HTMLOBJS) \$(OGLOBJS)" if test "$wxUSE_UNIVERSAL" = "yes"; then
ALL_OBJECTS="\$(GUI_LOWLEVEL_OBJS)"
else
ALL_OBJECTS="\$(GUIOBJS)"
fi
ALL_OBJECTS="${ALL_OBJECTS} \$(COMMONOBJS) \$(GENERICOBJS) \$(UNIXOBJS)"
if test "$wxUSE_HTML" = "yes"; then
ALL_OBJECTS="${ALL_OBJECTS} \$(HTMLOBJS)"
fi
dnl ODBC objects are Unix only dnl ODBC objects are Unix only
if test "$TOOLKIT" != "MSW"; then if test "$TOOLKIT" != "MSW"; then
@@ -1944,7 +2008,14 @@ fi
if test "$wxUSE_ZLIB" = "yes" ; then if test "$wxUSE_ZLIB" = "yes" ; then
ALL_OBJECTS="${ALL_OBJECTS} \$(ZLIBOBJS)" ALL_OBJECTS="${ALL_OBJECTS} \$(ZLIBOBJS)"
fi fi
ALL_DEPFILES="\$(GUIDEPS) \$(COMMONDEPS) \$(GENERICDEPS) \$(UNIXDEPS) \$(HTMLDEPS) \$(OGLDEPS)"
if test "$wxUSE_UNIVERSAL" = "yes"; then
ALL_DEPFILES="\$(GUI_LOWLEVEL_DEPS)"
else
ALL_DEPFILES="\$(GUIDEPS)"
fi
ALL_DEPFILES="${ALL_DEPFILES} \$(COMMONDEPS) \$(GENERICDEPS) \$(UNIXDEPS) \$(HTMLDEPS) \$(OGLDEPS)"
PORT_FILES="src/\$(TOOLKITDIR)/files.lst" PORT_FILES="src/\$(TOOLKITDIR)/files.lst"
RPM_FILES="src/\$(TOOLKITDIR)/rpmfiles.lst" RPM_FILES="src/\$(TOOLKITDIR)/rpmfiles.lst"
@@ -2901,6 +2972,18 @@ if test "$wxUSE_WAVE" = "yes"; then
AC_DEFINE(wxUSE_WAVE) AC_DEFINE(wxUSE_WAVE)
fi fi
if test "$wxUSE_CMDLINE_PARSER" = "yes"; then
AC_DEFINE(wxUSE_CMDLINE_PARSER)
fi
if test "$wxUSE_STOPWATCH" = "yes"; then
AC_DEFINE(wxUSE_STOPWATCH)
fi
if test "$wxUSE_DATETIME" = "yes"; then
AC_DEFINE(wxUSE_DATETIME)
fi
if test "$wxUSE_FILE" = "yes"; then if test "$wxUSE_FILE" = "yes"; then
AC_DEFINE(wxUSE_FILE) AC_DEFINE(wxUSE_FILE)
fi fi
@@ -2962,6 +3045,18 @@ fi
if test "$wxUSE_LOG" = "yes"; then if test "$wxUSE_LOG" = "yes"; then
AC_DEFINE(wxUSE_LOG) AC_DEFINE(wxUSE_LOG)
if test "$wxUSE_LOGGUI" = "yes"; then
AC_DEFINE(wxUSE_LOGGUI)
fi
if test "$wxUSE_LOGWINDOW" = "yes"; then
AC_DEFINE(wxUSE_LOGWINDOW)
fi
fi
if test "$wxUSE_FONTMAP" = "yes"; then
AC_DEFINE(wxUSE_FONTMAP)
fi fi
if test "$wxUSE_LONGLONG" = "yes"; then if test "$wxUSE_LONGLONG" = "yes"; then
@@ -2985,7 +3080,7 @@ dnl ------------------------------------------------------------------------
dnl time/date functions dnl time/date functions
dnl ------------------------------------------------------------------------ dnl ------------------------------------------------------------------------
if test "$wxUSE_TIMEDATE" = "yes"; then if test "$wxUSE_DATETIME" = "yes"; then
dnl check for strptime dnl check for strptime
AC_CHECK_FUNCS(strptime) AC_CHECK_FUNCS(strptime)
@@ -3108,7 +3203,7 @@ if test "$wxUSE_TIMEDATE" = "yes"; then
fi fi
fi fi
AC_DEFINE(wxUSE_TIMEDATE) AC_DEFINE(wxUSE_DATETIME)
SAMPLES_SUBDIRS="$SAMPLES_SUBDIRS typetest" SAMPLES_SUBDIRS="$SAMPLES_SUBDIRS typetest"
fi fi
@@ -3451,10 +3546,22 @@ dnl ---------------------------------------------------------------------------
dnl GUI controls dnl GUI controls
dnl --------------------------------------------------------------------------- dnl ---------------------------------------------------------------------------
if test "$wxUSE_CONTROLS" = "yes"; then
AC_DEFINE(wxUSE_CONTROLS)
fi
if test "$wxUSE_ACCEL" = "yes"; then if test "$wxUSE_ACCEL" = "yes"; then
AC_DEFINE(wxUSE_ACCEL) AC_DEFINE(wxUSE_ACCEL)
fi fi
if test "$wxUSE_BUTTON" = "yes"; then
AC_DEFINE(wxUSE_BUTTON)
fi
if test "$wxUSE_BMPBUTTON" = "yes"; then
AC_DEFINE(wxUSE_BMPBUTTON)
fi
if test "$wxUSE_CARET" = "yes"; then if test "$wxUSE_CARET" = "yes"; then
AC_DEFINE(wxUSE_CARET) AC_DEFINE(wxUSE_CARET)
SAMPLES_SUBDIRS="$SAMPLES_SUBDIRS caret" SAMPLES_SUBDIRS="$SAMPLES_SUBDIRS caret"
@@ -3468,10 +3575,6 @@ if test "$wxUSE_CHOICE" = "yes"; then
AC_DEFINE(wxUSE_CHOICE) AC_DEFINE(wxUSE_CHOICE)
fi fi
if test "$wxUSE_BMPBUTTON" = "yes"; then
AC_DEFINE(wxUSE_BMPBUTTON)
fi
if test "$wxUSE_CHECKBOX" = "yes"; then if test "$wxUSE_CHECKBOX" = "yes"; then
AC_DEFINE(wxUSE_CHECKBOX) AC_DEFINE(wxUSE_CHECKBOX)
fi fi
@@ -3580,6 +3683,11 @@ if test "$wxUSE_TABDIALOG" = "yes"; then
SAMPLES_SUBDIRS="$SAMPLES_SUBDIRS tab" SAMPLES_SUBDIRS="$SAMPLES_SUBDIRS tab"
fi fi
if test "$wxUSE_TEXTCTRL" = "yes"; then
AC_DEFINE(wxUSE_TEXTCTRL)
SAMPLES_SUBDIRS="$SAMPLES_SUBDIRS text"
fi
if test "$wxUSE_TOOLBAR_SIMPLE" = "yes"; then if test "$wxUSE_TOOLBAR_SIMPLE" = "yes"; then
AC_DEFINE(wxUSE_TOOLBAR_SIMPLE) AC_DEFINE(wxUSE_TOOLBAR_SIMPLE)
wxUSE_TOOLBAR="yes" wxUSE_TOOLBAR="yes"
@@ -3634,6 +3742,22 @@ if test "$wxUSE_METAFILE" = "yes"; then
AC_DEFINE(wxUSE_METAFILE) AC_DEFINE(wxUSE_METAFILE)
fi fi
if test "$wxUSE_CHOICEDLG" = "yes"; then
AC_DEFINE(wxUSE_CHOICEDLG)
fi
if test "$wxUSE_COLOURDLG" = "yes"; then
AC_DEFINE(wxUSE_COLOURDLG)
fi
if test "$wxUSE_FILEDLG" = "yes"; then
AC_DEFINE(wxUSE_FILEDLG)
fi
if test "$wxUSE_FONTDLG" = "yes"; then
AC_DEFINE(wxUSE_FONTDLG)
fi
if test "$wxUSE_DIRDLG" = "yes"; then if test "$wxUSE_DIRDLG" = "yes"; then
if test "$wxUSE_CONSTRAINTS" != "yes"; then if test "$wxUSE_CONSTRAINTS" != "yes"; then
AC_MSG_WARN(wxDirDialog requires constraints so it won't be compiled without them) AC_MSG_WARN(wxDirDialog requires constraints so it won't be compiled without them)
@@ -3646,6 +3770,14 @@ if test "$wxUSE_DIRDLG" = "yes"; then
fi fi
fi fi
if test "$wxUSE_MSGDLG" = "yes"; then
AC_DEFINE(wxUSE_MSGDLG)
fi
if test "$wxUSE_NUMBERDLG" = "yes"; then
AC_DEFINE(wxUSE_NUMBERDLG)
fi
if test "$wxUSE_TEXTDLG" = "yes"; then if test "$wxUSE_TEXTDLG" = "yes"; then
AC_DEFINE(wxUSE_TEXTDLG) AC_DEFINE(wxUSE_TEXTDLG)
fi fi
@@ -3762,6 +3894,10 @@ if test "$wxUSE_GUI" = "yes"; then
SAMPLES_SUBDIRS="$SAMPLES_SUBDIRS controls dialogs dragimag drawing dynamic \ SAMPLES_SUBDIRS="$SAMPLES_SUBDIRS controls dialogs dragimag drawing dynamic \
font fractal image menu minimal richedit" font fractal image menu minimal richedit"
if test "$wxUSE_UNICODE" = "yes" ; then
SAMPLES_SUBDIRS="$SAMPLES_SUBDIRS univ"
fi
dnl this is needed to be able to find AFM files dnl this is needed to be able to find AFM files
CPPFLAGS="$CPPFLAGS \$(EXTRADEFS) \$(APPEXTRADEFS)" CPPFLAGS="$CPPFLAGS \$(EXTRADEFS) \$(APPEXTRADEFS)"
else else
@@ -3876,7 +4012,7 @@ AC_SUBST(RESPROGRAM)
AC_SUBST(RESCOMP) AC_SUBST(RESCOMP)
AC_SUBST(RESFLAGS) AC_SUBST(RESFLAGS)
dnl These seam to be missing dnl These seem to be missing
AC_SUBST(DLLTOOL) AC_SUBST(DLLTOOL)
AC_SUBST(AS) AC_SUBST(AS)
AC_SUBST(NM) AC_SUBST(NM)

View File

@@ -1,7 +1,8 @@
# FIXME we'll generate this makefile with configure later, but for now please # FIXME we'll generate this makefile with configure later, but for now please
# change it manually # change it manually
TMAKEDIR=/home/zeitlin/build/tmake #TMAKEDIR=/home/zeitlin/build/tmake
TMAKE=$(TMAKEDIR)/bin/tmake #TMAKE=$(TMAKEDIR)/bin/tmake
TMAKE=tmake
WXDIR=../../.. WXDIR=../../..
MSW_MAKEFILES_DIR=$(WXDIR)/src/msw MSW_MAKEFILES_DIR=$(WXDIR)/src/msw

View File

@@ -44,6 +44,7 @@
# P Not required for the os2Pm port # P Not required for the os2Pm port
# (unfortunately I can't use O since that is # (unfortunately I can't use O since that is
# in use already - and above I can't use P :-( ) # in use already - and above I can't use P :-( )
# L Low level GUI toolkit file, used by wxUniversal as well
# #
# WX Base header # WX Base header
# GTK GTK header # GTK GTK header
@@ -326,49 +327,49 @@ gsocket.c U B
mimetype.cpp U B mimetype.cpp U B
gsockgtk.c R gsockgtk.c R
win_gtk.c R win_gtk.c R L
accel.cpp R accel.cpp R
app.cpp R app.cpp R L
bitmap.cpp R bitmap.cpp R L
bmpbuttn.cpp R bmpbuttn.cpp R
brush.cpp R brush.cpp R L
button.cpp R button.cpp R
checkbox.cpp R checkbox.cpp R
checklst.cpp R checklst.cpp R
choice.cpp R choice.cpp R
clipbrd.cpp R clipbrd.cpp R
colour.cpp R colour.cpp R L
combobox.cpp R combobox.cpp R
control.cpp R control.cpp R
cursor.cpp R cursor.cpp R L
data.cpp R data.cpp R L
dataobj.cpp R dataobj.cpp R
dc.cpp R dc.cpp R L
dcclient.cpp R dcclient.cpp R L
dcmemory.cpp R dcmemory.cpp R L
dcscreen.cpp R dcscreen.cpp R L
dialog.cpp R dialog.cpp R L
dnd.cpp R dnd.cpp R
font.cpp R font.cpp R L
fontdlg.cpp R fontdlg.cpp R
frame.cpp R frame.cpp R L
gauge.cpp R gauge.cpp R
gdiobj.cpp R gdiobj.cpp R L
icon.cpp R icon.cpp R L
joystick.cpp R joystick.cpp R
listbox.cpp R listbox.cpp R
main.cpp R main.cpp R L
mdi.cpp R mdi.cpp R
menu.cpp R menu.cpp R
minifram.cpp R minifram.cpp R
notebook.cpp R notebook.cpp R
palette.cpp R palette.cpp R L
pen.cpp R pen.cpp R L
radiobox.cpp R radiobox.cpp R
radiobut.cpp R radiobut.cpp R
region.cpp R region.cpp R L
scrolbar.cpp R scrolbar.cpp R
settings.cpp R settings.cpp R L
slider.cpp R slider.cpp R
spinbutt.cpp R spinbutt.cpp R
spinctrl.cpp R spinctrl.cpp R
@@ -380,10 +381,10 @@ tbargtk.cpp R
textctrl.cpp R textctrl.cpp R
timer.cpp R timer.cpp R
tooltip.cpp R tooltip.cpp R
utilsgtk.cpp R utilsgtk.cpp R L
utilsres.cpp R utilsres.cpp R
wave.cpp R wave.cpp R
window.cpp R window.cpp R L
gsockmot.c X S gsockmot.c X S
accel.cpp X accel.cpp X

View File

@@ -44,7 +44,12 @@
$project{"GTK_SOURCES"} .= "gtk/" . $file . " "; $project{"GTK_SOURCES"} .= "gtk/" . $file . " ";
$project{"GUIOBJS"} .= $fileobj . " "; $project{"GUIOBJS"} .= $fileobj . " ";
$project{"GUIDEPS"} .= $filedep . " " $project{"GUIDEPS"} .= $filedep . " ";
if ( $wxGTK{$file} =~ /\bL\b/ ) {
$project{"GUI_LOWLEVEL_OBJS"} .= $fileobj . " ";
$project{"GUI_LOWLEVEL_DEPS"} .= $filedep . " ";
}
} }
foreach $file (sort keys %wxUNIX) { foreach $file (sort keys %wxUNIX) {
@@ -116,6 +121,12 @@ GUIOBJS = \
GUIDEPS = \ GUIDEPS = \
#$ ExpandList("GUIDEPS"); #$ ExpandList("GUIDEPS");
GUI_LOWLEVEL_OBJS = \
#$ ExpandList("GUI_LOWLEVEL_OBJS");
GUI_LOWLEVEL_DEPS = \
#$ ExpandList("GUI_LOWLEVEL_DEPS");
UNIXOBJS = \ UNIXOBJS = \
#$ ExpandList("UNIXOBJS"); #$ ExpandList("UNIXOBJS");

View File

@@ -198,7 +198,7 @@ public:
// object) - this log object is used by default by all wxLogXXX() // object) - this log object is used by default by all wxLogXXX()
// functions. // functions.
virtual wxLog *CreateLogTarget() virtual wxLog *CreateLogTarget()
#if wxUSE_GUI #if wxUSE_GUI && wxUSE_LOGGUI
{ return new wxLogGui; } { return new wxLogGui; }
#else // !GUI #else // !GUI
{ return new wxLogStderr; } { return new wxLogStderr; }

View File

@@ -1,6 +1,8 @@
#ifndef _WX_BUTTON_H_BASE_ #ifndef _WX_BUTTON_H_BASE_
#define _WX_BUTTON_H_BASE_ #define _WX_BUTTON_H_BASE_
#if wxUSE_BUTTON
#if defined(__WXMSW__) #if defined(__WXMSW__)
#include "wx/msw/button.h" #include "wx/msw/button.h"
#elif defined(__WXMOTIF__) #elif defined(__WXMOTIF__)
@@ -17,5 +19,7 @@
#include "wx/stubs/button.h" #include "wx/stubs/button.h"
#endif #endif
#endif // wxUSE_BUTTON
#endif #endif
// _WX_BUTTON_H_BASE_ // _WX_BUTTON_H_BASE_

70
include/wx/chkconf.h Normal file
View File

@@ -0,0 +1,70 @@
/*
* Name: wx/chkconf.h
* Purpose: check the config settings for consistency
* Author: Vadim Zeitlin
* Modified by:
* Created: 09.08.00
* RCS-ID: $Id$
* Copyright: (c) 2000 Vadim Zeitlin <vadim@wxwindows.org>
* Licence: wxWindows license
*/
/*
this global setting determintes what should we do if the setting FOO
requires BAR and BAR is not set: we can either silently define BAR
(default, recommended) or give an error and abort (mainly useful for
developpers only)
*/
#define wxABORT_ON_CONFIG_ERROR
#if wxUSE_BUTTON || \
wxUSE_CARET || \
wxUSE_COMBOBOX || \
wxUSE_BMPBUTTON || \
wxUSE_CHECKBOX || \
wxUSE_CHECKLISTBOX || \
wxUSE_CHOICE || \
wxUSE_GAUGE || \
wxUSE_GRID || \
wxUSE_NEW_GRID || \
wxUSE_IMAGLIST || \
wxUSE_LISTBOX || \
wxUSE_LISTCTRL || \
wxUSE_NOTEBOOK || \
wxUSE_RADIOBOX || \
wxUSE_RADIOBTN || \
wxUSE_SASH || \
wxUSE_SCROLLBAR || \
wxUSE_SLIDER || \
wxUSE_SPINBTN || \
wxUSE_SPINCTRL || \
wxUSE_SPLITTER || \
wxUSE_STATBMP || \
wxUSE_STATBOX || \
wxUSE_STATLINE || \
wxUSE_STATUSBAR || \
wxUSE_TAB_DIALOG || \
wxUSE_TOOLBAR || \
wxUSE_TOOLTIPS || \
wxUSE_TREECTRL
#if !wxUSE_CONTROLS
#if wxABORT_ON_CONFIG_ERROR
#error "wxUSE_CONTROLS unset but some controls used"
#else
#undef wxUSE_CONTROLS
#define wxUSE_CONTROLS 1
#endif
#endif
#endif /* controls */
#if wxUSE_STOPWATCH
#if !wxUSE_LONGLONG
#if wxABORT_ON_CONFIG_ERROR
#error "wxUSE_STOPWATCH requires wxUSE_LONGLONG"
#else
#undef wxUSE_LONGLONG
#define wxUSE_LONGLONG 1
#endif
#endif
#endif /* wxUSE_STOPWATCH */

View File

@@ -20,6 +20,8 @@
#pragma interface "choicebase.h" #pragma interface "choicebase.h"
#endif #endif
#if wxUSE_CHOICE
#include "wx/ctrlsub.h" // the base class #include "wx/ctrlsub.h" // the base class
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
@@ -74,5 +76,7 @@ public:
#include "wx/stubs/choice.h" #include "wx/stubs/choice.h"
#endif #endif
#endif // wxUSE_CHOICE
#endif #endif
// _WX_CHOICE_H_BASE_ // _WX_CHOICE_H_BASE_

View File

@@ -20,6 +20,8 @@
#pragma interface "controlbase.h" #pragma interface "controlbase.h"
#endif #endif
#if wxUSE_CONTROLS
#include "wx/window.h" // base class #include "wx/window.h" // base class
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
@@ -71,5 +73,7 @@ protected:
#include "wx/stubs/control.h" #include "wx/stubs/control.h"
#endif #endif
#endif // wxUSE_CONTROLS
#endif #endif
// _WX_CONTROL_H_BASE_ // _WX_CONTROL_H_BASE_

View File

@@ -16,6 +16,8 @@
#pragma interface "controlwithitems.h" #pragma interface "controlwithitems.h"
#endif #endif
#if wxUSE_CONTROLS
#include "wx/control.h" // base class #include "wx/control.h" // base class
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
@@ -93,6 +95,7 @@ protected:
wxClientDataType m_clientDataItemsType; wxClientDataType m_clientDataItemsType;
}; };
#endif // wxUSE_CONTROLS
#endif // _WX_CTRLSUB_H_BASE_ #endif // _WX_CTRLSUB_H_BASE_

View File

@@ -27,12 +27,16 @@ public:
void SetReturnCode(int returnCode) { m_returnCode = returnCode; } void SetReturnCode(int returnCode) { m_returnCode = returnCode; }
int GetReturnCode() const { return m_returnCode; } int GetReturnCode() const { return m_returnCode; }
#if wxUSE_STATTEXT && wxUSE_TEXTCTRL
// splits text up at newlines and places the // splits text up at newlines and places the
// lines into a vertical wxBoxSizer // lines into a vertical wxBoxSizer
wxSizer *CreateTextSizer( const wxString &message ); wxSizer *CreateTextSizer( const wxString &message );
#endif // wxUSE_STATTEXT && wxUSE_TEXTCTRL
#if wxUSE_BUTTON
// places buttons into a horizontal wxBoxSizer // places buttons into a horizontal wxBoxSizer
wxSizer *CreateButtonSizer( long flags ); wxSizer *CreateButtonSizer( long flags );
#endif // wxUSE_BUTTON
protected: protected:
// the return code from modal dialog // the return code from modal dialog

View File

@@ -1,6 +1,8 @@
#ifndef _WX_DIRDLG_H_BASE_ #ifndef _WX_DIRDLG_H_BASE_
#define _WX_DIRDLG_H_BASE_ #define _WX_DIRDLG_H_BASE_
#if wxUSE_DIRDLG
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// constants // constants
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
@@ -29,5 +31,7 @@ WXDLLEXPORT_DATA(extern const wxChar*) wxEmptyString;
#include "wx/stubs/dirdlg.h" #include "wx/stubs/dirdlg.h"
#endif #endif
#endif // wxUSE_DIRDLG
#endif #endif
// _WX_DIRDLG_H_BASE_ // _WX_DIRDLG_H_BASE_

View File

@@ -15,6 +15,9 @@
#endif #endif
#include "wx/defs.h" #include "wx/defs.h"
#if wxUSE_FONTMAP
#include "wx/object.h" #include "wx/object.h"
#include "wx/fontenc.h" #include "wx/fontenc.h"
#include "wx/dynarray.h" #include "wx/dynarray.h"
@@ -147,5 +150,6 @@ class WXDLLEXPORT wxEncodingConverter : public wxObject
}; };
#endif // wxUSE_FONTMAP
#endif // _WX_ENCCONV_H_ #endif // _WX_ENCCONV_H_

View File

@@ -1,6 +1,8 @@
#ifndef _WX_FILEDLG_H_BASE_ #ifndef _WX_FILEDLG_H_BASE_
#define _WX_FILEDLG_H_BASE_ #define _WX_FILEDLG_H_BASE_
#if wxUSE_FILEDLG
enum enum
{ {
wxOPEN = 1, wxOPEN = 1,
@@ -27,6 +29,7 @@ enum
#include "wx/stubs/filedlg.h" #include "wx/stubs/filedlg.h"
#endif #endif
#endif // wxUSE_FILEDLG
#endif #endif
// _WX_FILEDLG_H_BASE_ // _WX_FILEDLG_H_BASE_

View File

@@ -1,6 +1,8 @@
#ifndef _WX_FONTDLG_H_BASE_ #ifndef _WX_FONTDLG_H_BASE_
#define _WX_FONTDLG_H_BASE_ #define _WX_FONTDLG_H_BASE_
#if wxUSE_FONTDLG
#if defined(__WXMSW__) #if defined(__WXMSW__)
#include "wx/msw/fontdlg.h" #include "wx/msw/fontdlg.h"
#elif defined(__WXMOTIF__) #elif defined(__WXMOTIF__)
@@ -25,5 +27,7 @@
# define sm_classwxFontDialog sm_classwxGenericFontDialog # define sm_classwxFontDialog sm_classwxGenericFontDialog
#endif #endif
#endif // wxUSE_FONTDLG
#endif #endif
// _WX_FONTDLG_H_BASE_ // _WX_FONTDLG_H_BASE_

View File

@@ -20,7 +20,10 @@
// headers // headers
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
#if wxUSE_FONTMAP
#include "wx/fontenc.h" // for wxFontEncoding #include "wx/fontenc.h" // for wxFontEncoding
#if wxUSE_GUI #if wxUSE_GUI
#include "wx/fontutil.h" // for wxNativeEncodingInfo #include "wx/fontutil.h" // for wxNativeEncodingInfo
#endif // wxUSE_GUI #endif // wxUSE_GUI
@@ -185,4 +188,6 @@ protected:
// the default font mapper for wxWindows programs // the default font mapper for wxWindows programs
WXDLLEXPORT_DATA(extern wxFontMapper *) wxTheFontMapper; WXDLLEXPORT_DATA(extern wxFontMapper *) wxTheFontMapper;
#endif // wxUSE_FONTMAP
#endif // _WX_FONTMAPPER_H_ #endif // _WX_FONTMAPPER_H_

View File

@@ -101,8 +101,10 @@ public:
// menu bar functions // menu bar functions
// ------------------ // ------------------
#if wxUSE_MENUS
virtual void SetMenuBar(wxMenuBar *menubar) = 0; virtual void SetMenuBar(wxMenuBar *menubar) = 0;
virtual wxMenuBar *GetMenuBar() const { return m_frameMenuBar; } virtual wxMenuBar *GetMenuBar() const { return m_frameMenuBar; }
#endif // wxUSE_MENUS
// call this to simulate a menu command // call this to simulate a menu command
bool Command(int id) { return ProcessCommand(id); } bool Command(int id) { return ProcessCommand(id); }
@@ -173,9 +175,11 @@ public:
// so should be there for all platforms // so should be there for all platforms
void OnActivate(wxActivateEvent &WXUNUSED(event)) { } void OnActivate(wxActivateEvent &WXUNUSED(event)) { }
#if wxUSE_MENUS
// send wxUpdateUIEvents for all menu items (called from OnIdle()) // send wxUpdateUIEvents for all menu items (called from OnIdle())
void DoMenuUpdates(); void DoMenuUpdates();
void DoMenuUpdates(wxMenu* menu, wxWindow* focusWin); void DoMenuUpdates(wxMenu* menu, wxWindow* focusWin);
#endif // wxUSE_MENUS
protected: protected:
// the frame main menu/status/tool bars // the frame main menu/status/tool bars
@@ -185,7 +189,9 @@ protected:
// main menubar, statusbar and toolbar (if any) // main menubar, statusbar and toolbar (if any)
void DeleteAllBars(); void DeleteAllBars();
#if wxUSE_MENUS
wxMenuBar *m_frameMenuBar; wxMenuBar *m_frameMenuBar;
#endif // wxUSE_MENUS
#if wxUSE_STATUSBAR #if wxUSE_STATUSBAR
// override to update status bar position (or anything else) when // override to update status bar position (or anything else) when

View File

@@ -19,6 +19,8 @@
#pragma interface "dirctrlg.h" #pragma interface "dirctrlg.h"
#endif #endif
#if wxUSE_DIRDLG
#include "wx/treectrl.h" #include "wx/treectrl.h"
#include "wx/dirdlg.h" #include "wx/dirdlg.h"
#include "wx/choice.h" #include "wx/choice.h"
@@ -243,5 +245,7 @@ protected:
}; };
#endif // wxUSE_DIRDLG
#endif #endif
// _WX_DIRCTRLG_H_ // _WX_DIRCTRLG_H_

View File

@@ -19,6 +19,9 @@
#endif #endif
#include "wx/defs.h" #include "wx/defs.h"
#if wxUSE_GRID
#include "wx/panel.h" #include "wx/panel.h"
#include "wx/string.h" #include "wx/string.h"
#include "wx/scrolbar.h" #include "wx/scrolbar.h"
@@ -420,5 +423,7 @@ typedef void (wxEvtHandler::*wxGridEventFunction)(wxGridEvent&);
#define EVT_GRID_LABEL_LCLICK(fn) { wxEVT_GRID_LABEL_LCLICK, -1, -1, (wxObjectEventFunction) (wxEventFunction) (wxGridEventFunction) &fn, NULL }, #define EVT_GRID_LABEL_LCLICK(fn) { wxEVT_GRID_LABEL_LCLICK, -1, -1, (wxObjectEventFunction) (wxEventFunction) (wxGridEventFunction) &fn, NULL },
#define EVT_GRID_LABEL_RCLICK(fn) { wxEVT_GRID_LABEL_RCLICK, -1, -1, (wxObjectEventFunction) (wxEventFunction) (wxGridEventFunction) &fn, NULL }, #define EVT_GRID_LABEL_RCLICK(fn) { wxEVT_GRID_LABEL_RCLICK, -1, -1, (wxObjectEventFunction) (wxEventFunction) (wxGridEventFunction) &fn, NULL },
#endif // wxUSE_GRID
#endif // __GRIDH_G__ #endif // __GRIDH_G__

View File

@@ -194,8 +194,10 @@ class WXDLLEXPORT wxLayoutAlgorithm: public wxObject
public: public:
wxLayoutAlgorithm() {} wxLayoutAlgorithm() {}
#if wxUSE_MDI_ARCHITECTURE
// The MDI client window is sized to whatever's left over. // The MDI client window is sized to whatever's left over.
bool LayoutMDIFrame(wxMDIParentFrame* frame, wxRect* rect = (wxRect*) NULL); bool LayoutMDIFrame(wxMDIParentFrame* frame, wxRect* rect = (wxRect*) NULL);
#endif // wxUSE_MDI_ARCHITECTURE
// mainWindow is sized to whatever's left over. This function for backward // mainWindow is sized to whatever's left over. This function for backward
// compatibility; use LayoutWindow. // compatibility; use LayoutWindow.

View File

@@ -71,9 +71,11 @@ public:
// to the dialog via validators. // to the dialog via validators.
virtual void InitDialog(); virtual void InitDialog();
#if wxUSE_BUTTON
// a default button is activated when Enter is pressed // a default button is activated when Enter is pressed
wxButton *GetDefaultItem() const { return m_btnDefault; } wxButton *GetDefaultItem() const { return m_btnDefault; }
void SetDefaultItem(wxButton *btn) { m_btnDefault = btn; } void SetDefaultItem(wxButton *btn) { m_btnDefault = btn; }
#endif // wxUSE_BUTTON
// implementation from now on // implementation from now on
// -------------------------- // --------------------------
@@ -107,8 +109,10 @@ protected:
// the child which had the focus last time this panel was activated // the child which had the focus last time this panel was activated
wxWindow *m_winLastFocused; wxWindow *m_winLastFocused;
#if wxUSE_BUTTON
// a default button or NULL // a default button or NULL
wxButton *m_btnDefault; wxButton *m_btnDefault;
#endif // wxUSE_BUTTON
private: private:
DECLARE_DYNAMIC_CLASS(wxPanel) DECLARE_DYNAMIC_CLASS(wxPanel)

View File

@@ -16,6 +16,8 @@
#pragma interface "treectlg.h" #pragma interface "treectlg.h"
#endif #endif
#if wxUSE_TREECTRL
#include "wx/defs.h" #include "wx/defs.h"
#include "wx/string.h" #include "wx/string.h"
#include "wx/object.h" #include "wx/object.h"
@@ -426,5 +428,7 @@ public:
#endif #endif
#endif // wxUSE_TREECTRL
#endif // _GENERIC_TREECTRL_H_ #endif // _GENERIC_TREECTRL_H_

View File

@@ -69,7 +69,9 @@ public:
virtual void MakeModal(bool modal = TRUE); virtual void MakeModal(bool modal = TRUE);
virtual void Restore(); virtual void Restore();
#if wxUSE_MENUS
virtual void SetMenuBar( wxMenuBar *menuBar ); virtual void SetMenuBar( wxMenuBar *menuBar );
#endif // wxUSE_MENUS
#if wxUSE_STATUSBAR #if wxUSE_STATUSBAR
virtual void PositionStatusBar(); virtual void PositionStatusBar();

View File

@@ -86,7 +86,9 @@ public:
const wxFont *theFont = (const wxFont *) NULL) const wxFont *theFont = (const wxFont *) NULL)
const; const;
#if wxUSE_MENUS
virtual bool DoPopupMenu( wxMenu *menu, int x, int y ); virtual bool DoPopupMenu( wxMenu *menu, int x, int y );
#endif // wxUSE_MENUS
virtual void SetScrollbar( int orient, int pos, int thumbVisible, virtual void SetScrollbar( int orient, int pos, int thumbVisible,
int range, bool refresh = TRUE ); int range, bool refresh = TRUE );

View File

@@ -69,7 +69,9 @@ public:
virtual void MakeModal(bool modal = TRUE); virtual void MakeModal(bool modal = TRUE);
virtual void Restore(); virtual void Restore();
#if wxUSE_MENUS
virtual void SetMenuBar( wxMenuBar *menuBar ); virtual void SetMenuBar( wxMenuBar *menuBar );
#endif // wxUSE_MENUS
#if wxUSE_STATUSBAR #if wxUSE_STATUSBAR
virtual void PositionStatusBar(); virtual void PositionStatusBar();

View File

@@ -86,7 +86,9 @@ public:
const wxFont *theFont = (const wxFont *) NULL) const wxFont *theFont = (const wxFont *) NULL)
const; const;
#if wxUSE_MENUS
virtual bool DoPopupMenu( wxMenu *menu, int x, int y ); virtual bool DoPopupMenu( wxMenu *menu, int x, int y );
#endif // wxUSE_MENUS
virtual void SetScrollbar( int orient, int pos, int thumbVisible, virtual void SetScrollbar( int orient, int pos, int thumbVisible,
int range, bool refresh = TRUE ); int range, bool refresh = TRUE );

View File

@@ -16,6 +16,8 @@
#pragma interface "listctrlbase.h" #pragma interface "listctrlbase.h"
#endif #endif
#if wxUSE_LISTCTRL
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// types // types
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
@@ -316,5 +318,7 @@ typedef void (wxEvtHandler::*wxListEventFunction)(wxListEvent&);
#define EVT_LIST_ITEM_MIDDLE_CLICK(id, fn) { wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, (wxObject *) NULL }, #define EVT_LIST_ITEM_MIDDLE_CLICK(id, fn) { wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, (wxObject *) NULL },
#define EVT_LIST_ITEM_ACTIVATED(id, fn) { wxEVT_COMMAND_LIST_ITEM_ACTIVATED, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, (wxObject *) NULL }, #define EVT_LIST_ITEM_ACTIVATED(id, fn) { wxEVT_COMMAND_LIST_ITEM_ACTIVATED, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, (wxObject *) NULL },
#endif // wxUSE_LISTCTRL
#endif #endif
// _WX_LISTCTRL_H_BASE_ // _WX_LISTCTRL_H_BASE_

View File

@@ -266,6 +266,8 @@ protected:
#if wxUSE_GUI #if wxUSE_GUI
#if wxUSE_TEXTCTRL
// log everything to a text window (GUI only of course) // log everything to a text window (GUI only of course)
class WXDLLEXPORT wxLogTextCtrl : public wxLog class WXDLLEXPORT wxLogTextCtrl : public wxLog
{ {
@@ -280,9 +282,14 @@ private:
wxTextCtrl *m_pTextCtrl; wxTextCtrl *m_pTextCtrl;
}; };
#endif // wxUSE_TEXTCTRL
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// GUI log target, the default one for wxWindows programs // GUI log target, the default one for wxWindows programs
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
#if wxUSE_LOGGUI
class WXDLLEXPORT wxLogGui : public wxLog class WXDLLEXPORT wxLogGui : public wxLog
{ {
public: public:
@@ -305,12 +312,17 @@ protected:
m_bWarnings; // any warnings? m_bWarnings; // any warnings?
}; };
#endif // wxUSE_LOGGUI
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// (background) log window: this class forwards all log messages to the log // (background) log window: this class forwards all log messages to the log
// target which was active when it was instantiated, but also collects them // target which was active when it was instantiated, but also collects them
// to the log window. This window has it's own menu which allows the user to // to the log window. This window has it's own menu which allows the user to
// close it, clear the log contents or save it to the file. // close it, clear the log contents or save it to the file.
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
#if wxUSE_LOGWINDOW
class WXDLLEXPORT wxLogWindow : public wxLog class WXDLLEXPORT wxLogWindow : public wxLog
{ {
public: public:
@@ -364,6 +376,8 @@ private:
wxLogFrame *m_pLogFrame; // the log frame wxLogFrame *m_pLogFrame; // the log frame
}; };
#endif // wxUSE_LOGWINDOW
#endif // wxUSE_GUI #endif // wxUSE_GUI
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------

View File

@@ -26,13 +26,9 @@
// classes // classes
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
class wxStaticBox;
class wxNotebook;
class wxSizerItem; class wxSizerItem;
class wxSizer; class wxSizer;
class wxBoxSizer; class wxBoxSizer;
class wxStaticBoxSizer;
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
// wxSizerItem // wxSizerItem
@@ -297,6 +293,10 @@ private:
// wxStaticBoxSizer // wxStaticBoxSizer
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
#if wxUSE_STATBOX
class WXDLLEXPORT wxStaticBox;
class WXDLLEXPORT wxStaticBoxSizer: public wxBoxSizer class WXDLLEXPORT wxStaticBoxSizer: public wxBoxSizer
{ {
public: public:
@@ -315,12 +315,16 @@ private:
DECLARE_CLASS(wxStaticBoxSizer); DECLARE_CLASS(wxStaticBoxSizer);
}; };
#endif // wxUSE_STATBOX
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
// wxNotebookSizer // wxNotebookSizer
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
#if wxUSE_NOTEBOOK #if wxUSE_NOTEBOOK
class WXDLLEXPORT wxNotebook;
class WXDLLEXPORT wxNotebookSizer: public wxSizer class WXDLLEXPORT wxNotebookSizer: public wxSizer
{ {
public: public:
@@ -339,7 +343,7 @@ private:
DECLARE_CLASS(wxNotebookSizer); DECLARE_CLASS(wxNotebookSizer);
}; };
#endif #endif // wxUSE_NOTEBOOK
#endif #endif

View File

@@ -1,6 +1,8 @@
#ifndef _WX_STATTEXT_H_BASE_ #ifndef _WX_STATTEXT_H_BASE_
#define _WX_STATTEXT_H_BASE_ #define _WX_STATTEXT_H_BASE_
#if wxUSE_STATTEXT
#if defined(__WXMSW__) #if defined(__WXMSW__)
#include "wx/msw/stattext.h" #include "wx/msw/stattext.h"
#elif defined(__WXMOTIF__) #elif defined(__WXMOTIF__)
@@ -17,5 +19,7 @@
#include "wx/stubs/stattext.h" #include "wx/stubs/stattext.h"
#endif #endif
#endif // wxUSE_STATTEXT
#endif #endif
// _WX_STATTEXT_H_BASE_ // _WX_STATTEXT_H_BASE_

View File

@@ -22,6 +22,8 @@
#include "wx/defs.h" #include "wx/defs.h"
#if wxUSE_TOOLBAR
#include "wx/bitmap.h" #include "wx/bitmap.h"
#include "wx/list.h" #include "wx/list.h"
#include "wx/control.h" #include "wx/control.h"
@@ -466,6 +468,8 @@ private:
DECLARE_EVENT_TABLE() DECLARE_EVENT_TABLE()
}; };
#endif // wxUSE_TOOLBAR
#endif #endif
// _WX_TBARBASE_H_ // _WX_TBARBASE_H_

View File

@@ -15,11 +15,15 @@
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// headers // headers
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
#ifdef __GNUG__ #ifdef __GNUG__
#pragma interface "textctrlbase.h" #pragma interface "textctrlbase.h"
#endif #endif
#include "wx/defs.h" #include "wx/defs.h"
#if wxUSE_TEXTCTRL
#include "wx/control.h" // the base class #include "wx/control.h" // the base class
// 16-bit Borland 4.0 doesn't seem to allow multiple inheritance with wxWindow // 16-bit Borland 4.0 doesn't seem to allow multiple inheritance with wxWindow
@@ -189,5 +193,7 @@ private:
#include "wx/stubs/textctrl.h" #include "wx/stubs/textctrl.h"
#endif #endif
#endif // wxUSE_TEXTCTRL
#endif #endif
// _WX_TEXTCTRL_H_BASE_ // _WX_TEXTCTRL_H_BASE_

View File

@@ -25,14 +25,8 @@
#define wxUSE_TEXTFILE 0 #define wxUSE_TEXTFILE 0
#endif // wxUSE_FILE #endif // wxUSE_FILE
#if wxUSE_TEXTFILE
#include "wx/string.h"
#include "wx/file.h"
#include "wx/dynarray.h"
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// wxTextFile // constants
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// the line termination type // the line termination type
@@ -45,6 +39,16 @@ enum wxTextFileType
wxTextFileType_Os2 // 'CR' 'LF' wxTextFileType_Os2 // 'CR' 'LF'
}; };
#if wxUSE_TEXTFILE
#include "wx/string.h"
#include "wx/file.h"
#include "wx/dynarray.h"
// ----------------------------------------------------------------------------
// wxTextFile
// ----------------------------------------------------------------------------
WX_DEFINE_EXPORTED_ARRAY(wxTextFileType, ArrayFileType); WX_DEFINE_EXPORTED_ARRAY(wxTextFileType, ArrayFileType);
class WXDLLEXPORT wxTextFile class WXDLLEXPORT wxTextFile
@@ -184,6 +188,12 @@ private:
// copy ctor/assignment operator not implemented // copy ctor/assignment operator not implemented
wxTextFile(const wxTextFile&); wxTextFile(const wxTextFile&);
wxTextFile& operator=(const wxTextFile&); wxTextFile& operator=(const wxTextFile&);
// suppress the gcc warning: 'class defines only private constructors and
// has no friends'
#ifdef __GNUG__
friend class wxTextFileDummyFriend;
#endif // gcc
}; };
#endif // wxUSE_TEXTFILE #endif // wxUSE_TEXTFILE

View File

@@ -22,7 +22,7 @@
#include "wx/longlong.h" #include "wx/longlong.h"
#include "wx/event.h" #include "wx/event.h"
#if wxUSE_GUI #if wxUSE_GUI && wxUSE_TIMER
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// wxTimer // wxTimer
@@ -181,12 +181,14 @@ typedef void (wxEvtHandler::*wxTimerEventFunction)(wxTimerEvent&);
#define EVT_TIMER(id, func) { wxEVT_TIMER, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxTimerEventFunction) & func, NULL}, #define EVT_TIMER(id, func) { wxEVT_TIMER, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxTimerEventFunction) & func, NULL},
#endif // wxUSE_GUI #endif // wxUSE_GUI && wxUSE_TIMER
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// wxStopWatch: measure time intervals with up to 1ms resolution // wxStopWatch: measure time intervals with up to 1ms resolution
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
#if wxUSE_STOPWATCH
class WXDLLEXPORT wxStopWatch class WXDLLEXPORT wxStopWatch
{ {
public: public:
@@ -208,6 +210,9 @@ private:
long m_pause; // the time of the last Pause() or 0 long m_pause; // the time of the last Pause() or 0
}; };
#endif // wxUSE_STOPWATCH
#if wxUSE_LONGLONG
// Starts a global timer // Starts a global timer
// -- DEPRECATED: use wxStopWatch instead // -- DEPRECATED: use wxStopWatch instead
@@ -217,6 +222,8 @@ void WXDLLEXPORT wxStartTimer();
// -- DEPRECATED: use wxStopWatch instead // -- DEPRECATED: use wxStopWatch instead
long WXDLLEXPORT wxGetElapsedTime(bool resetTimer = TRUE); long WXDLLEXPORT wxGetElapsedTime(bool resetTimer = TRUE);
#endif // wxUSE_LONGLONG
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// global time functions // global time functions
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
@@ -227,8 +234,10 @@ extern long WXDLLEXPORT wxGetLocalTime();
// Get number of seconds since GMT 00:00:00, Jan 1st 1970. // Get number of seconds since GMT 00:00:00, Jan 1st 1970.
extern long WXDLLEXPORT wxGetUTCTime(); extern long WXDLLEXPORT wxGetUTCTime();
#if wxUSE_LONGLONG
// Get number of milliseconds since local time 00:00:00 Jan 1st 1970 // Get number of milliseconds since local time 00:00:00 Jan 1st 1970
extern wxLongLong WXDLLEXPORT wxGetLocalTimeMillis(); extern wxLongLong WXDLLEXPORT wxGetLocalTimeMillis();
#endif // wxUSE_LONGLONG
#define wxGetCurrentTime() wxGetLocalTime() #define wxGetCurrentTime() wxGetLocalTime()

View File

@@ -20,6 +20,8 @@
// headers // headers
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
#if wxUSE_TREECTRL
#include "wx/control.h" #include "wx/control.h"
#include "wx/event.h" #include "wx/event.h"
@@ -280,6 +282,8 @@ typedef void (wxEvtHandler::*wxTreeEventFunction)(wxTreeEvent&);
#define EVT_TREE_ITEM_RIGHT_CLICK(id, fn) { wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxTreeEventFunction) & fn, NULL }, #define EVT_TREE_ITEM_RIGHT_CLICK(id, fn) { wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxTreeEventFunction) & fn, NULL },
#define EVT_TREE_ITEM_MIDDLE_CLICK(id, fn) { wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxTreeEventFunction) & fn, NULL }, #define EVT_TREE_ITEM_MIDDLE_CLICK(id, fn) { wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxTreeEventFunction) & fn, NULL },
#endif // wxUSE_TREECTRL
#endif #endif
// _WX_TREEBASE_H_ // _WX_TREEBASE_H_

View File

@@ -556,10 +556,12 @@ public:
void UpdateWindowUI(); void UpdateWindowUI();
#if wxUSE_MENUS
bool PopupMenu( wxMenu *menu, const wxPoint& pos ) bool PopupMenu( wxMenu *menu, const wxPoint& pos )
{ return DoPopupMenu(menu, pos.x, pos.y); } { return DoPopupMenu(menu, pos.x, pos.y); }
bool PopupMenu( wxMenu *menu, int x, int y ) bool PopupMenu( wxMenu *menu, int x, int y )
{ return DoPopupMenu(menu, x, y); } { return DoPopupMenu(menu, x, y); }
#endif // wxUSE_MENUS
// scrollbars // scrollbars
// ---------- // ----------
@@ -831,7 +833,9 @@ protected:
virtual void DoSetToolTip( wxToolTip *tip ); virtual void DoSetToolTip( wxToolTip *tip );
#endif // wxUSE_TOOLTIPS #endif // wxUSE_TOOLTIPS
#if wxUSE_MENUS
virtual bool DoPopupMenu( wxMenu *menu, int x, int y ) = 0; virtual bool DoPopupMenu( wxMenu *menu, int x, int y ) = 0;
#endif // wxUSE_MENUS
// client data accessors // client data accessors
virtual void DoSetClientObject( wxClientData *data ); virtual void DoSetClientObject( wxClientData *data );

View File

@@ -14,6 +14,8 @@
#ifndef _WX_WIZARD_H_ #ifndef _WX_WIZARD_H_
#define _WX_WIZARD_H_ #define _WX_WIZARD_H_
#if wxUSE_WIZARDDLG
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// headers and other simple declarations // headers and other simple declarations
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
@@ -188,4 +190,6 @@ typedef void (wxEvtHandler::*wxWizardEventFunction)(wxWizardEvent&);
// unless the event handler vetoes the event // unless the event handler vetoes the event
#define EVT_WIZARD_CANCEL(id, fn) { wxEVT_WIZARD_CANCEL, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxWizardEventFunction) & fn, (wxObject *)NULL }, #define EVT_WIZARD_CANCEL(id, fn) { wxEVT_WIZARD_CANCEL, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxWizardEventFunction) & fn, (wxObject *)NULL },
#endif // wxUSE_WIZARDDLG
#endif // _WX_WIZARD_H_ #endif // _WX_WIZARD_H_

2
samples/configure vendored
View File

@@ -700,6 +700,7 @@ trap 'rm -fr `echo "
typetest/Makefile typetest/Makefile
validate/Makefile validate/Makefile
sockets/Makefile sockets/Makefile
univ/Makefile
wizard/Makefile wizard/Makefile
html/Makefile html/Makefile
html/about/Makefile html/about/Makefile
@@ -844,6 +845,7 @@ CONFIG_FILES=\${CONFIG_FILES-"Makefile
typetest/Makefile typetest/Makefile
validate/Makefile validate/Makefile
sockets/Makefile sockets/Makefile
univ/Makefile
wizard/Makefile wizard/Makefile
html/Makefile html/Makefile
html/about/Makefile html/about/Makefile

View File

@@ -68,6 +68,7 @@ AC_OUTPUT([
typetest/Makefile typetest/Makefile
validate/Makefile validate/Makefile
sockets/Makefile sockets/Makefile
univ/Makefile
wizard/Makefile wizard/Makefile
html/Makefile html/Makefile
html/about/Makefile html/about/Makefile

View File

@@ -185,11 +185,36 @@
*/ */
#define wxUSE_VALIDATORS 0 #define wxUSE_VALIDATORS 0
/*
* Use wxControl
*/
#define wxUSE_CONTROLS 0
/* /*
* Use accelerators * Use accelerators
*/ */
#define wxUSE_ACCEL 0 #define wxUSE_ACCEL 0
/*
* Use wxFileDialog
*/
#define wxUSE_FILEDLG 0
/*
* Use wxFontDialog
*/
#define wxUSE_FONTDLG 0
/*
* Use wxMessageDialog (and wxMessageBox)
*/
#define wxUSE_MSGDLG 0
/*
* Use wxNumberEntryDialog
*/
#define wxUSE_NUMBERDLG 0
/* /*
* Use wxTextEntryDialog * Use wxTextEntryDialog
*/ */
@@ -205,16 +230,45 @@
*/ */
#define wxUSE_PROGRESSDLG 0 #define wxUSE_PROGRESSDLG 0
/*
* Use chooser dialog
*/
#define wxUSE_CHOICEDLG 0
/*
* Use colour picker dialog
*/
#define wxUSE_COLOURDLG 0
/* /*
* Use directory chooser dialog * Use directory chooser dialog
*/ */
#define wxUSE_DIRDLG 0 #define wxUSE_DIRDLG 0
/*
* Use property sheet classes
*/
#define wxUSE_PROPSHEET 0
/*
* Use wxWizard
*/
#define wxUSE_WIZARDDLG 0
/*
* Use splash screen
*/
#define wxUSE_SPLASH 0
/* /*
* Joystick support (Linux/GTK only) * Joystick support (Linux/GTK only)
*/ */
#define wxUSE_JOYSTICK 0 #define wxUSE_JOYSTICK 0
/*
* Use this control
*/
#define wxUSE_BUTTON 0
/* /*
* Use this control * Use this control
*/ */
@@ -264,6 +318,10 @@
* Use this control * Use this control
*/ */
#define wxUSE_LISTCTRL 0 #define wxUSE_LISTCTRL 0
/*
* Use wxMenuBar, wxMenuItem and wxMenu
*/
#define wxUSE_MENUS 0
/* /*
* Use this control * Use this control
*/ */
@@ -327,6 +385,11 @@
/* compatibility */ /* compatibility */
#define wxUSE_TABDIALOG wxUSE_TAB_DIALOG #define wxUSE_TABDIALOG wxUSE_TAB_DIALOG
/*
* Use wxTextCtrl
*/
#define wxUSE_TEXTCTRL 0
/* /*
* Use wxToollBar * Use wxToollBar
*/ */
@@ -360,6 +423,14 @@
*/ */
#define wxUSE_LONGLONG 0 #define wxUSE_LONGLONG 0
/*
* Use wxCmdLineParser class
*/
#define wxUSE_CMDLINE_PARSER 0
/*
* Use wxDateTime
*/
#define wxUSE_DATETIME 0
/* /*
* Use wxFile class * Use wxFile class
*/ */
@@ -372,6 +443,18 @@
* Use log classes and logging functions * Use log classes and logging functions
*/ */
#define wxUSE_LOG 0 #define wxUSE_LOG 0
/*
* Use log window
*/
#define wxUSE_LOGWINDOW 0
/*
* Use standard GUI logger
*/
#define wxUSE_LOGGUI 0
/*
* Use wxStopWatch
*/
#define wxUSE_STOPWATCH 0
/* /*
* Use time and date classes * Use time and date classes
*/ */
@@ -384,6 +467,10 @@
* Use config system * Use config system
*/ */
#define wxUSE_CONFIG 0 #define wxUSE_CONFIG 0
/*
* Use font mapping/conversion classes
*/
#define wxUSE_FONTMAP 0
/* /*
* Use intl system * Use intl system
*/ */
@@ -414,6 +501,11 @@
*/ */
#define wxUSE_DYNLIB_CLASS 0 #define wxUSE_DYNLIB_CLASS 0
/*
* Use wxTimer
*/
#define wxUSE_TIMER 0
/* /*
* Use font metric files in GetTextExtent for wxPostScriptDC * Use font metric files in GetTextExtent for wxPostScriptDC
* Use consistent PostScript fonts for AFM and printing (!) * Use consistent PostScript fonts for AFM and printing (!)
@@ -793,4 +885,7 @@
/* Define this if you are using gtk and gdk contains support for X11R6 XIM */ /* Define this if you are using gtk and gdk contains support for X11R6 XIM */
#undef HAVE_XIM #undef HAVE_XIM
/* now check the settings self consistency */
#include "wx/chkconf.h"
#endif /* __WX_SETUP_H__ */ #endif /* __WX_SETUP_H__ */

View File

@@ -28,6 +28,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_CHOICE
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/choice.h" #include "wx/choice.h"
#endif #endif
@@ -60,3 +62,6 @@ void wxChoiceBase::Command(wxCommandEvent& event)
SetSelection(event.m_commandInt); SetSelection(event.m_commandInt);
(void)ProcessEvent(event); (void)ProcessEvent(event);
} }
#endif // wxUSE_CHOICE

View File

@@ -28,6 +28,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_CMDLINE_PARSER
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/string.h" #include "wx/string.h"
#include "wx/log.h" #include "wx/log.h"
@@ -912,3 +914,5 @@ static wxString GetTypeName(wxCmdLineParamType type)
return s; return s;
} }
#endif // wxUSE_CMDLINE_PARSER

View File

@@ -28,6 +28,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_CONTROLS
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/control.h" #include "wx/control.h"
#include "wx/log.h" #include "wx/log.h"
@@ -93,3 +95,5 @@ void wxControlBase::InitCommandEvent(wxCommandEvent& event) const
} }
} }
#endif // wxUSE_CONTROLS

View File

@@ -28,6 +28,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_CONTROLS
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/ctrlsub.h" #include "wx/ctrlsub.h"
#endif #endif
@@ -92,3 +94,4 @@ void *wxControlWithItems::GetClientData(int n) const
return DoGetItemClientData(n); return DoGetItemClientData(n);
} }
#endif // wxUSE_CONTROLS

View File

@@ -63,6 +63,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if !defined(wxUSE_DATETIME) || wxUSE_DATETIME
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/string.h" #include "wx/string.h"
#include "wx/intl.h" #include "wx/intl.h"
@@ -3598,4 +3600,4 @@ size_t wxDateTimeWorkDays::DoGetHolidaysInRange(const wxDateTime& dtStart,
return holidays.GetCount(); return holidays.GetCount();
} }
#endif // wxUSE_DATETIME

View File

@@ -43,6 +43,8 @@
// wxDialogBase // wxDialogBase
//-------------------------------------------------------------------------- //--------------------------------------------------------------------------
#if wxUSE_STATTEXT && wxUSE_TEXTCTRL
wxSizer *wxDialogBase::CreateTextSizer( const wxString &message ) wxSizer *wxDialogBase::CreateTextSizer( const wxString &message )
{ {
wxBoxSizer *box = new wxBoxSizer( wxVERTICAL ); wxBoxSizer *box = new wxBoxSizer( wxVERTICAL );
@@ -86,6 +88,10 @@ wxSizer *wxDialogBase::CreateTextSizer( const wxString &message )
return box; return box;
} }
#endif // wxUSE_STATTEXT && wxUSE_TEXTCTRL
#if wxUSE_BUTTON
wxSizer *wxDialogBase::CreateButtonSizer( long flags ) wxSizer *wxDialogBase::CreateButtonSizer( long flags )
{ {
wxBoxSizer *box = new wxBoxSizer( wxHORIZONTAL ); wxBoxSizer *box = new wxBoxSizer( wxHORIZONTAL );
@@ -174,3 +180,4 @@ wxSizer *wxDialogBase::CreateButtonSizer( long flags )
return box; return box;
} }
#endif // wxUSE_BUTTON

View File

@@ -27,6 +27,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_DATAOBJ
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/app.h" #include "wx/app.h"
#include "wx/debug.h" #include "wx/debug.h"
@@ -364,5 +366,6 @@ wxDragResult wxFileDropTarget::OnData(wxCoord x, wxCoord y, wxDragResult def)
return OnDropFiles(x, y, dobj->GetFilenames()) ? def : wxDragNone; return OnDropFiles(x, y, dobj->GetFilenames()) ? def : wxDragNone;
} }
#endif #endif // wxUSE_DRAG_AND_DROP
#endif // wxUSE_DATAOBJ

View File

@@ -18,6 +18,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_FONTMAP
#include "wx/encconv.h" #include "wx/encconv.h"
#include <stdlib.h> #include <stdlib.h>
@@ -446,3 +448,5 @@ wxFontEncodingArray wxEncodingConverter::GetAllEquivalents(wxFontEncoding enc)
return arr; return arr;
} }
#endif // wxUSE_FONTMAP

View File

@@ -28,6 +28,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_FONTMAP
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/app.h" #include "wx/app.h"
#include "wx/log.h" #include "wx/log.h"
@@ -54,12 +56,14 @@
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// the config paths we use // the config paths we use
#if wxUSE_CONFIG
static const wxChar* FONTMAPPER_ROOT_PATH = wxT("/wxWindows/FontMapper"); static const wxChar* FONTMAPPER_ROOT_PATH = wxT("/wxWindows/FontMapper");
static const wxChar* FONTMAPPER_CHARSET_PATH = wxT("Charsets"); static const wxChar* FONTMAPPER_CHARSET_PATH = wxT("Charsets");
static const wxChar* FONTMAPPER_CHARSET_ALIAS_PATH = wxT("Aliases"); static const wxChar* FONTMAPPER_CHARSET_ALIAS_PATH = wxT("Aliases");
#if wxUSE_GUI #if wxUSE_GUI
static const wxChar* FONTMAPPER_FONT_FROM_ENCODING_PATH = wxT("Encodings"); static const wxChar* FONTMAPPER_FONT_FROM_ENCODING_PATH = wxT("Encodings");
#endif // wxUSE_GUI #endif // wxUSE_GUI
#endif // wxUSE_CONFIG
// encodings supported by GetEncodingDescription // encodings supported by GetEncodingDescription
static wxFontEncoding gs_encodings[] = static wxFontEncoding gs_encodings[] =
@@ -746,3 +750,5 @@ bool wxFontMapper::IsEncodingAvailable(wxFontEncoding encoding,
} }
#endif // wxUSE_GUI #endif // wxUSE_GUI
#endif // wxUSE_FONTMAP

View File

@@ -60,7 +60,9 @@ END_EVENT_TABLE()
wxFrameBase::wxFrameBase() wxFrameBase::wxFrameBase()
{ {
#if wxUSE_MENUS
m_frameMenuBar = NULL; m_frameMenuBar = NULL;
#endif // wxUSE_MENUS
#if wxUSE_TOOLBAR #if wxUSE_TOOLBAR
m_frameToolBar = NULL; m_frameToolBar = NULL;
@@ -94,11 +96,13 @@ wxFrame *wxFrameBase::New(wxWindow *parent,
void wxFrameBase::DeleteAllBars() void wxFrameBase::DeleteAllBars()
{ {
#if wxUSE_MENUS
if ( m_frameMenuBar ) if ( m_frameMenuBar )
{ {
delete m_frameMenuBar; delete m_frameMenuBar;
m_frameMenuBar = (wxMenuBar *) NULL; m_frameMenuBar = (wxMenuBar *) NULL;
} }
#endif // wxUSE_MENUS
#if wxUSE_STATUSBAR #if wxUSE_STATUSBAR
if ( m_frameStatusBar ) if ( m_frameStatusBar )
@@ -192,6 +196,7 @@ void wxFrameBase::MakeModal(bool modal)
bool wxFrameBase::ProcessCommand(int id) bool wxFrameBase::ProcessCommand(int id)
{ {
#if wxUSE_MENUS
wxMenuBar *bar = GetMenuBar(); wxMenuBar *bar = GetMenuBar();
if ( !bar ) if ( !bar )
return FALSE; return FALSE;
@@ -209,6 +214,9 @@ bool wxFrameBase::ProcessCommand(int id)
} }
return GetEventHandler()->ProcessEvent(commandEvent); return GetEventHandler()->ProcessEvent(commandEvent);
#else // !wxUSE_MENUS
return FALSE;
#endif // wxUSE_MENUS/!wxUSE_MENUS
} }
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
@@ -419,9 +427,13 @@ wxToolBar* wxFrameBase::OnCreateToolBar(long style,
void wxFrameBase::OnIdle(wxIdleEvent& WXUNUSED(event) ) void wxFrameBase::OnIdle(wxIdleEvent& WXUNUSED(event) )
{ {
#if wxUSE_MENUS
DoMenuUpdates(); DoMenuUpdates();
#endif // wxUSE_MENUS
} }
#if wxUSE_MENUS
// update all menus // update all menus
void wxFrameBase::DoMenuUpdates() void wxFrameBase::DoMenuUpdates()
{ {
@@ -465,3 +477,5 @@ void wxFrameBase::DoMenuUpdates(wxMenu* menu, wxWindow* WXUNUSED(focusWin))
node = node->GetNext(); node = node->GetNext();
} }
} }
#endif // wxUSE_MENUS

View File

@@ -28,6 +28,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_LISTBOX
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/listbox.h" #include "wx/listbox.h"
#endif #endif
@@ -96,3 +98,5 @@ void wxListBoxBase::SetFirstItem(const wxString& s)
DoSetFirstItem(n); DoSetFirstItem(n);
} }
#endif // wxUSE_LISTBOX

View File

@@ -745,12 +745,12 @@ void wxOnAssert(const wxChar *szFile, int nLine, const wxChar *szMsg)
// send it to the normal log destination // send it to the normal log destination
wxLogDebug(szBuf); wxLogDebug(szBuf);
#if wxUSE_GUI || defined(__WXMSW__) #if (wxUSE_GUI && wxUSE_MSGDLG) || defined(__WXMSW__)
// this message is intentionally not translated - it is for // this message is intentionally not translated - it is for
// developpers only // developpers only
wxStrcat(szBuf, wxT("\nDo you want to stop the program?\nYou can also choose [Cancel] to suppress further warnings.")); wxStrcat(szBuf, wxT("\nDo you want to stop the program?\nYou can also choose [Cancel] to suppress further warnings."));
#if wxUSE_GUI #if wxUSE_GUI && wxUSE_MSGDLG
switch ( wxMessageBox(szBuf, wxT("Debug"), switch ( wxMessageBox(szBuf, wxT("Debug"),
wxYES_NO | wxCANCEL | wxICON_STOP ) ) { wxYES_NO | wxCANCEL | wxICON_STOP ) ) {
case wxYES: case wxYES:
@@ -763,7 +763,7 @@ void wxOnAssert(const wxChar *szFile, int nLine, const wxChar *szMsg)
//case wxNO: nothing to do //case wxNO: nothing to do
} }
#else // !GUI, but MSW #else // no wxMessageBox, but we still have the native MessageBox
switch ( ::MessageBox(NULL, szBuf, _T("Debug"), switch ( ::MessageBox(NULL, szBuf, _T("Debug"),
MB_YESNOCANCEL | MB_ICONSTOP ) ) { MB_YESNOCANCEL | MB_ICONSTOP ) ) {
case IDYES: case IDYES:
@@ -778,9 +778,9 @@ void wxOnAssert(const wxChar *szFile, int nLine, const wxChar *szMsg)
} }
#endif // GUI or MSW #endif // GUI or MSW
#else // !GUI #else // no message box
Trap(); Trap();
#endif // GUI/!GUI #endif // message boxes
} }
s_bInAssert = FALSE; s_bInAssert = FALSE;

View File

@@ -24,12 +24,14 @@
// For compilers that support precompilation, includes "wx.h". // For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h" #include "wx/wxprec.h"
#include <ctype.h>
#ifdef __BORLANDC__ #ifdef __BORLANDC__
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_MENUS
#include <ctype.h>
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/menu.h" #include "wx/menu.h"
#endif #endif
@@ -643,3 +645,4 @@ wxString wxMenuBarBase::GetHelpString(int id) const
return item->GetHelp(); return item->GetHelp();
} }
#endif // wxUSE_MENUS

View File

@@ -32,7 +32,9 @@ IMPLEMENT_ABSTRACT_CLASS(wxSizer, wxObject);
IMPLEMENT_ABSTRACT_CLASS(wxGridSizer, wxSizer); IMPLEMENT_ABSTRACT_CLASS(wxGridSizer, wxSizer);
IMPLEMENT_ABSTRACT_CLASS(wxFlexGridSizer, wxGridSizer); IMPLEMENT_ABSTRACT_CLASS(wxFlexGridSizer, wxGridSizer);
IMPLEMENT_ABSTRACT_CLASS(wxBoxSizer, wxSizer); IMPLEMENT_ABSTRACT_CLASS(wxBoxSizer, wxSizer);
#if wxUSE_STATBOX
IMPLEMENT_ABSTRACT_CLASS(wxStaticBoxSizer, wxBoxSizer); IMPLEMENT_ABSTRACT_CLASS(wxStaticBoxSizer, wxBoxSizer);
#endif
#if wxUSE_NOTEBOOK #if wxUSE_NOTEBOOK
IMPLEMENT_ABSTRACT_CLASS(wxNotebookSizer, wxSizer); IMPLEMENT_ABSTRACT_CLASS(wxNotebookSizer, wxSizer);
#endif #endif
@@ -942,6 +944,8 @@ wxSize wxBoxSizer::CalcMin()
// wxStaticBoxSizer // wxStaticBoxSizer
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
#if wxUSE_STATBOX
wxStaticBoxSizer::wxStaticBoxSizer( wxStaticBox *box, int orient ) wxStaticBoxSizer::wxStaticBoxSizer( wxStaticBox *box, int orient )
: wxBoxSizer( orient ) : wxBoxSizer( orient )
{ {
@@ -991,6 +995,8 @@ wxSize wxStaticBoxSizer::CalcMin()
return ret; return ret;
} }
#endif // wxUSE_STATBOX
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
// wxNotebookSizer // wxNotebookSizer
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------

View File

@@ -28,6 +28,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_TOOLBAR
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/wx.h" #include "wx/wx.h"
#endif #endif
@@ -39,19 +41,15 @@
#include <windows.h> #include <windows.h>
#endif #endif
#if wxUSE_TOOLBAR
#include "wx/tbarbase.h" #include "wx/tbarbase.h"
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// wxWindows macros // wxWindows macros
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
#if !USE_SHARED_LIBRARY
BEGIN_EVENT_TABLE(wxToolBarBase, wxControl) BEGIN_EVENT_TABLE(wxToolBarBase, wxControl)
EVT_IDLE(wxToolBarBase::OnIdle) EVT_IDLE(wxToolBarBase::OnIdle)
END_EVENT_TABLE() END_EVENT_TABLE()
#endif
#include "wx/listimpl.cpp" #include "wx/listimpl.cpp"

View File

@@ -12,6 +12,7 @@
// ============================================================================ // ============================================================================
// declarations // declarations
// ============================================================================ // ============================================================================
#ifdef __GNUG__ #ifdef __GNUG__
#pragma implementation "textctrlbase.h" #pragma implementation "textctrlbase.h"
#endif #endif
@@ -23,6 +24,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_TEXTCTRL
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/intl.h" #include "wx/intl.h"
#include "wx/log.h" #include "wx/log.h"
@@ -207,3 +210,5 @@ int wxTextCtrlBase::underflow()
#endif // NO_TEXT_WINDOW_STREAM #endif // NO_TEXT_WINDOW_STREAM
#endif // wxUSE_TEXTCTRL

View File

@@ -76,7 +76,7 @@
// wxWin macros // wxWin macros
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
#if wxUSE_GUI #if wxUSE_GUI && wxUSE_TIMER
IMPLEMENT_DYNAMIC_CLASS(wxTimerEvent, wxEvent) IMPLEMENT_DYNAMIC_CLASS(wxTimerEvent, wxEvent)
#endif // wxUSE_GUI #endif // wxUSE_GUI
@@ -103,7 +103,7 @@
// wxTimerBase // wxTimerBase
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
#if wxUSE_GUI #if wxUSE_GUI && wxUSE_TIMER
void wxTimerBase::Notify() void wxTimerBase::Notify()
{ {
@@ -121,6 +121,8 @@ void wxTimerBase::Notify()
// wxStopWatch // wxStopWatch
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
#if wxUSE_LONGLONG
void wxStopWatch::Start(long t) void wxStopWatch::Start(long t)
{ {
m_t0 = wxGetLocalTimeMillis() - t; m_t0 = wxGetLocalTimeMillis() - t;
@@ -137,10 +139,14 @@ long wxStopWatch::Time() const
return (m_pause ? m_pause : GetElapsedTime()); return (m_pause ? m_pause : GetElapsedTime());
} }
#endif // wxUSE_LONGLONG
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// old timer functions superceded by wxStopWatch // old timer functions superceded by wxStopWatch
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
#if wxUSE_LONGLONG
static wxLongLong wxStartTime = 0l; static wxLongLong wxStartTime = 0l;
// starts the global timer // starts the global timer
@@ -161,6 +167,7 @@ long wxGetElapsedTime(bool resetTimer)
return (newTime - oldTime).GetLo(); return (newTime - oldTime).GetLo();
} }
#endif // wxUSE_LONGLONG
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// the functions to get the current time and timezone info // the functions to get the current time and timezone info
@@ -246,6 +253,7 @@ long wxGetUTCTime()
return -1; return -1;
} }
#if wxUSE_LONGLONG
// Get local time as milliseconds since 00:00:00, Jan 1st 1970 // Get local time as milliseconds since 00:00:00, Jan 1st 1970
wxLongLong wxGetLocalTimeMillis() wxLongLong wxGetLocalTimeMillis()
@@ -314,3 +322,6 @@ wxLongLong wxGetLocalTimeMillis()
#endif // time functions #endif // time functions
} }
#endif // wxUSE_LONGLONG

View File

@@ -28,6 +28,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_TREECTRL
#include "wx/treebase.h" #include "wx/treebase.h"
#include "wx/settings.h" #include "wx/settings.h"
#include "wx/log.h" #include "wx/log.h"
@@ -50,4 +52,5 @@ wxTreeEvent::wxTreeEvent(wxEventType commandType, int id)
m_itemOld = 0; m_itemOld = 0;
} }
#endif // wxUSE_TREECTRL

View File

@@ -661,10 +661,12 @@ wxFindWindowByName1 (const wxString& title, wxWindow * parent)
int int
wxFindMenuItemId (wxFrame * frame, const wxString& menuString, const wxString& itemString) wxFindMenuItemId (wxFrame * frame, const wxString& menuString, const wxString& itemString)
{ {
#if wxUSE_MENUS
wxMenuBar *menuBar = frame->GetMenuBar (); wxMenuBar *menuBar = frame->GetMenuBar ();
if (!menuBar) if (menuBar)
return -1;
return menuBar->FindMenuItem (menuString, itemString); return menuBar->FindMenuItem (menuString, itemString);
#endif // wxUSE_MENUS
return -1;
} }
#endif // wxUSE_GUI #endif // wxUSE_GUI
@@ -873,6 +875,8 @@ whereami(name)
* since otherwise the generic code may be pulled in unnecessarily. * since otherwise the generic code may be pulled in unnecessarily.
*/ */
#if wxUSE_MSGDLG
int wxMessageBox(const wxString& message, const wxString& caption, long style, int wxMessageBox(const wxString& message, const wxString& caption, long style,
wxWindow *parent, int WXUNUSED(x), int WXUNUSED(y) ) wxWindow *parent, int WXUNUSED(x), int WXUNUSED(y) )
{ {
@@ -896,7 +900,10 @@ int wxMessageBox(const wxString& message, const wxString& caption, long style,
return wxCANCEL; return wxCANCEL;
} }
#endif // wxUSE_MSGDLG
#if wxUSE_TEXTDLG #if wxUSE_TEXTDLG
wxString wxGetTextFromUser(const wxString& message, const wxString& caption, wxString wxGetTextFromUser(const wxString& message, const wxString& caption,
const wxString& defaultValue, wxWindow *parent, const wxString& defaultValue, wxWindow *parent,
int x, int y, bool WXUNUSED(centre) ) int x, int y, bool WXUNUSED(centre) )
@@ -929,6 +936,8 @@ wxString wxGetPasswordFromUser(const wxString& message,
#endif // wxUSE_TEXTDLG #endif // wxUSE_TEXTDLG
#if wxUSE_COLOURDLG
wxColour wxGetColourFromUser(wxWindow *parent, const wxColour& colInit) wxColour wxGetColourFromUser(wxWindow *parent, const wxColour& colInit)
{ {
wxColourData data; wxColourData data;
@@ -949,6 +958,8 @@ wxColour wxGetColourFromUser(wxWindow *parent, const wxColour& colInit)
return colRet; return colRet;
} }
#endif // wxUSE_COLOURDLG
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// missing C RTL functions (FIXME shouldn't be here at all) // missing C RTL functions (FIXME shouldn't be here at all)
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------

View File

@@ -409,7 +409,11 @@ wxSize wxWindowBase::DoGetBestSize() const
node = node->GetNext() ) node = node->GetNext() )
{ {
wxWindow *win = node->GetData(); wxWindow *win = node->GetData();
if ( win->IsTopLevel() || wxDynamicCast(win, wxStatusBar) ) if ( win->IsTopLevel()
#if wxUSE_STATUSBAR
|| wxDynamicCast(win, wxStatusBar)
#endif // wxUSE_STATUSBAR
)
{ {
// dialogs and frames lie in different top level windows - // dialogs and frames lie in different top level windows -
// don't deal with them here; as for the status bars, they // don't deal with them here; as for the status bars, they
@@ -1256,6 +1260,7 @@ void wxWindowBase::GetPositionConstraint(int *x, int *y) const
// of control classes. // of control classes.
void wxWindowBase::UpdateWindowUI() void wxWindowBase::UpdateWindowUI()
{ {
#if wxUSE_CONTROLS
wxUpdateUIEvent event(GetId()); wxUpdateUIEvent event(GetId());
event.m_eventObject = this; event.m_eventObject = this;
@@ -1269,10 +1274,12 @@ void wxWindowBase::UpdateWindowUI()
wxControl *control = wxDynamicCast(this, wxControl); wxControl *control = wxDynamicCast(this, wxControl);
if ( control ) if ( control )
{ {
#if wxUSE_TEXTCTRL
wxTextCtrl *text = wxDynamicCast(control, wxTextCtrl); wxTextCtrl *text = wxDynamicCast(control, wxTextCtrl);
if ( text ) if ( text )
text->SetValue(event.GetText()); text->SetValue(event.GetText());
else else
#endif // wxUSE_TEXTCTRL
control->SetLabel(event.GetText()); control->SetLabel(event.GetText());
} }
} }
@@ -1295,6 +1302,7 @@ void wxWindowBase::UpdateWindowUI()
} }
#endif // wxUSE_RADIOBTN #endif // wxUSE_RADIOBTN
} }
#endif // wxUSE_CONTROLS
} }
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
@@ -1404,6 +1412,7 @@ void wxWindowBase::OnInitDialog( wxInitDialogEvent &WXUNUSED(event) )
// process Ctrl-Alt-mclick // process Ctrl-Alt-mclick
void wxWindowBase::OnMiddleClick( wxMouseEvent& event ) void wxWindowBase::OnMiddleClick( wxMouseEvent& event )
{ {
#if wxUSE_MSGDLG
if ( event.ControlDown() && event.AltDown() ) if ( event.ControlDown() && event.AltDown() )
{ {
// don't translate these strings // don't translate these strings
@@ -1448,6 +1457,7 @@ void wxWindowBase::OnMiddleClick( wxMouseEvent& event )
(wxWindow *)this); (wxWindow *)this);
} }
else else
#endif // wxUSE_MSGDLG
{ {
event.Skip(); event.Skip();
} }

View File

@@ -28,6 +28,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_CARET
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/window.h" #include "wx/window.h"
#include "wx/dcclient.h" #include "wx/dcclient.h"
@@ -205,3 +207,5 @@ void wxCaret::DoDraw(wxDC *dc)
dc->DrawRectangle( m_x, m_y, m_width, m_height ); dc->DrawRectangle( m_x, m_y, m_width, m_height );
#endif // 0/1 #endif // 0/1
} }
#endif // wxUSE_CARET

View File

@@ -20,6 +20,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_CHOICEDLG
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include <stdio.h> #include <stdio.h>
#include "wx/utils.h" #include "wx/utils.h"
@@ -315,3 +317,4 @@ void wxSingleChoiceDialog::OnListBoxDClick(wxCommandEvent& WXUNUSED(event))
EndModal(wxID_OK); EndModal(wxID_OK);
} }
#endif // wxUSE_CHOICEDLG

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: colrdlgg.cpp // Name: generic/colrdlgg.cpp
// Purpose: Choice dialogs // Purpose: Choice dialogs
// Author: Julian Smart // Author: Julian Smart
// Modified by: // Modified by:
@@ -20,9 +20,9 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_COLOURDLG
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include <stdio.h>
#include <stdio.h>
#include "wx/utils.h" #include "wx/utils.h"
#include "wx/intl.h" #include "wx/intl.h"
#include "wx/dialog.h" #include "wx/dialog.h"
@@ -504,4 +504,5 @@ void wxGenericColourDialog::OnBlueSlider(wxCommandEvent& WXUNUSED(event))
PaintCustomColour(dc); PaintCustomColour(dc);
} }
#endif // wxUSE_COLOURDLG

View File

@@ -20,7 +20,7 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#include "wx/defs.h" #if wxUSE_GRID
#include "wx/utils.h" #include "wx/utils.h"
#include "wx/dialog.h" #include "wx/dialog.h"
@@ -1244,3 +1244,5 @@ wxString wxGenericDirDialog::GetPath(void) const
{ {
return m_dirCtrl->GetPath(); return m_dirCtrl->GetPath();
} }
#endif // wxUSE_GRID

View File

@@ -28,6 +28,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_DRAGIMAGE
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include <stdio.h> #include <stdio.h>
#include "wx/setup.h" #include "wx/setup.h"
@@ -497,3 +499,4 @@ wxRect wxGenericDragImage::GetImageRect(const wxPoint& pos) const
} }
} }
#endif // wxUSE_DRAGIMAGE

View File

@@ -20,6 +20,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_FILEDLG
#ifndef __UNIX__ #ifndef __UNIX__
#error wxFileDialog currently only supports unix #error wxFileDialog currently only supports unix
#endif #endif
@@ -1310,3 +1312,5 @@ public:
}; };
IMPLEMENT_DYNAMIC_CLASS(wxFileDialogGenericModule, wxModule) IMPLEMENT_DYNAMIC_CLASS(wxFileDialogGenericModule, wxModule)
#endif // wxUSE_FILEDLG

View File

@@ -25,6 +25,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_GRID
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/utils.h" #include "wx/utils.h"
#include "wx/dcclient.h" #include "wx/dcclient.h"
@@ -2852,3 +2854,4 @@ void *wxGenericGrid::GetCellData(int row, int col)
return rc; return rc;
} }
#endif // wxUSE_GRID

View File

@@ -176,6 +176,8 @@ void wxSashLayoutWindow::OnCalculateLayout(wxCalculateLayoutEvent& event)
* wxLayoutAlgorithm * wxLayoutAlgorithm
*/ */
#if wxUSE_MDI_ARCHITECTURE
// Lays out windows for an MDI frame. The MDI client area gets what's left // Lays out windows for an MDI frame. The MDI client area gets what's left
// over. // over.
bool wxLayoutAlgorithm::LayoutMDIFrame(wxMDIParentFrame* frame, wxRect* r) bool wxLayoutAlgorithm::LayoutMDIFrame(wxMDIParentFrame* frame, wxRect* r)
@@ -213,6 +215,8 @@ bool wxLayoutAlgorithm::LayoutMDIFrame(wxMDIParentFrame* frame, wxRect* r)
return TRUE; return TRUE;
} }
#endif // wxUSE_MDI_ARCHITECTURE
// Layout algorithm for any window. mainWindow gets what's left over. // Layout algorithm for any window. mainWindow gets what's left over.
bool wxLayoutAlgorithm::LayoutWindow(wxWindow* parent, wxWindow* mainWindow) bool wxLayoutAlgorithm::LayoutWindow(wxWindow* parent, wxWindow* mainWindow)
{ {

View File

@@ -19,6 +19,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_LISTCTRL
#include "wx/dcscreen.h" #include "wx/dcscreen.h"
#include "wx/app.h" #include "wx/app.h"
#include "wx/listctrl.h" #include "wx/listctrl.h"
@@ -3728,3 +3730,5 @@ void wxListCtrl::SetFocus()
if ( FindFocus() != this ) if ( FindFocus() != this )
m_mainWin->SetFocus(); m_mainWin->SetFocus();
} }
#endif // wxUSE_LISTCTRL

View File

@@ -31,6 +31,8 @@
#error "This file can't be compiled without GUI!" #error "This file can't be compiled without GUI!"
#endif #endif
#if wxUSE_LOGGUI || wxUSE_LOGWINDOW
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/app.h" #include "wx/app.h"
#include "wx/button.h" #include "wx/button.h"
@@ -1052,3 +1054,4 @@ static int OpenLogFile(wxFile& file, wxString *pFilename)
#endif // wxUSE_FILE #endif // wxUSE_FILE
#endif // !(wxUSE_LOGGUI || wxUSE_LOGWINDOW)

View File

@@ -20,6 +20,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_MSGDLG
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/utils.h" #include "wx/utils.h"
#include "wx/dialog.h" #include "wx/dialog.h"
@@ -127,4 +129,5 @@ void wxGenericMessageDialog::OnCancel(wxCommandEvent& WXUNUSED(event))
} }
} }
#endif // wxUSE_MSGDLG

View File

@@ -29,6 +29,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_NUMBERDLG
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include <stdio.h> #include <stdio.h>
@@ -206,3 +208,5 @@ long wxGetNumberFromUser(const wxString& msg,
return dialog.GetValue(); return dialog.GetValue();
} }
#endif // wxUSE_NUMBERDLG

View File

@@ -65,7 +65,9 @@ END_EVENT_TABLE()
void wxPanel::Init() void wxPanel::Init()
{ {
m_winLastFocused = (wxWindow *)NULL; m_winLastFocused = (wxWindow *)NULL;
#if wxUSE_BUTTON
m_btnDefault = (wxButton *)NULL; m_btnDefault = (wxButton *)NULL;
#endif // wxUSE_BUTTON
} }
bool wxPanel::Create(wxWindow *parent, wxWindowID id, bool wxPanel::Create(wxWindow *parent, wxWindowID id,

View File

@@ -20,6 +20,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_PROPSHEET
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/wx.h" #include "wx/wx.h"
#endif #endif
@@ -1155,3 +1157,5 @@ wxChar *wxPropertyValidator::IntToString (int number) {
wxChar *wxPropertyValidator::LongToString (long number) { wxChar *wxPropertyValidator::LongToString (long number) {
return ::LongToString (number); return ::LongToString (number);
} }
#endif // wxUSE_PROPSHEET

View File

@@ -20,6 +20,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_PROPSHEET
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/wx.h" #include "wx/wx.h"
#endif #endif
@@ -755,3 +757,4 @@ bool wxStringFormValidator::OnDisplayValue(wxProperty *property, wxPropertyFormV
return TRUE; return TRUE;
} }
#endif // wxUSE_PROPSHEET

View File

@@ -28,6 +28,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_PROPSHEET
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/window.h" #include "wx/window.h"
#include "wx/font.h" #include "wx/font.h"
@@ -1880,3 +1882,4 @@ static wxBitmap *GetCrossBitmap()
return s_crossBitmap; return s_crossBitmap;
} }
#endif // wxUSE_PROPSHEET

View File

@@ -20,6 +20,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_SPLASH
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/wx.h" #include "wx/wx.h"
#endif #endif
@@ -156,3 +158,4 @@ void wxSplashScreenWindow::OnChar(wxKeyEvent& event)
GetParent()->Close(TRUE); GetParent()->Close(TRUE);
} }
#endif // wxUSE_SPLASH

View File

@@ -20,7 +20,7 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
//#if !defined(__WIN32__) || !wxUSE_NATIVE_STATUSBAR #if wxUSE_STATUSBAR
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/setup.h" #include "wx/setup.h"
@@ -359,4 +359,4 @@ void wxStatusBarGeneric::SetMinHeight(int height)
} }
} }
//#endif // Win32 && wxUSE_NATIVE_STATUSBAR #endif // wxUSE_STATUSBAR

View File

@@ -28,6 +28,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_TEXTDLG
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include <stdio.h> #include <stdio.h>
@@ -119,3 +121,5 @@ void wxTextEntryDialog::OnOK(wxCommandEvent& WXUNUSED(event) )
EndModal(wxID_OK); EndModal(wxID_OK);
} }
#endif // wxUSE_TEXTDLG

View File

@@ -28,6 +28,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_TREECTRL
#include "wx/generic/treectlg.h" #include "wx/generic/treectlg.h"
#include "wx/imaglist.h" #include "wx/imaglist.h"
#include "wx/settings.h" #include "wx/settings.h"
@@ -2530,3 +2532,4 @@ void wxGenericTreeCtrl::RefreshLine( wxGenericTreeItem *item )
Refresh( TRUE, &rect ); Refresh( TRUE, &rect );
} }
#endif // wxUSE_TREECTRL

View File

@@ -28,6 +28,8 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#if wxUSE_WIZARDDLG
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/dynarray.h" #include "wx/dynarray.h"
#include "wx/intl.h" #include "wx/intl.h"
@@ -389,3 +391,4 @@ wxWizardEvent::wxWizardEvent(wxEventType type, int id, bool direction)
m_direction = direction; m_direction = direction;
} }
#endif // wxUSE_WIZARDDLG

View File

@@ -1,4 +1,4 @@
# This file was automatically generated by tmake at 15:57, 2000/08/04 # This file was automatically generated by tmake at 14:01, 2000/08/11
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE GTK.T! # DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE GTK.T!
ALL_SOURCES = \ ALL_SOURCES = \
generic/busyinfo.cpp \ generic/busyinfo.cpp \
@@ -972,6 +972,56 @@ GUIDEPS = \
win_gtk.d \ win_gtk.d \
window.d window.d
GUI_LOWLEVEL_OBJS = \
app.o \
bitmap.o \
brush.o \
colour.o \
cursor.o \
data.o \
dc.o \
dcclient.o \
dcmemory.o \
dcscreen.o \
dialog.o \
font.o \
frame.o \
gdiobj.o \
icon.o \
main.o \
palette.o \
pen.o \
region.o \
settings.o \
utilsgtk.o \
win_gtk.o \
window.o
GUI_LOWLEVEL_DEPS = \
app.d \
bitmap.d \
brush.d \
colour.d \
cursor.d \
data.d \
dc.d \
dcclient.d \
dcmemory.d \
dcscreen.d \
dialog.d \
font.d \
frame.d \
gdiobj.d \
icon.d \
main.d \
palette.d \
pen.d \
region.d \
settings.d \
utilsgtk.d \
win_gtk.d \
window.d
UNIXOBJS = \ UNIXOBJS = \
dialup.o \ dialup.o \
dir.o \ dir.o \

View File

@@ -146,6 +146,7 @@ static gint gtk_frame_delete_callback( GtkWidget *WXUNUSED(widget), GdkEvent *WX
return TRUE; return TRUE;
} }
#if wxUSE_MENUS
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
// "child_attached" of menu bar // "child_attached" of menu bar
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
@@ -169,6 +170,7 @@ static void gtk_menu_detached_callback( GtkWidget *WXUNUSED(widget), GtkWidget *
win->m_menuBarDetached = TRUE; win->m_menuBarDetached = TRUE;
win->GtkUpdateSize(); win->GtkUpdateSize();
} }
#endif // wxUSE_MENUS
#if wxUSE_TOOLBAR #if wxUSE_TOOLBAR
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
@@ -612,6 +614,7 @@ void wxFrame::DoGetClientSize( int *width, int *height ) const
wxWindow::DoGetClientSize( width, height ); wxWindow::DoGetClientSize( width, height );
if (height) if (height)
{ {
#if wxUSE_MENUS
/* menu bar */ /* menu bar */
if (m_frameMenuBar) if (m_frameMenuBar)
{ {
@@ -620,6 +623,7 @@ void wxFrame::DoGetClientSize( int *width, int *height ) const
else else
(*height) -= wxPLACE_HOLDER; (*height) -= wxPLACE_HOLDER;
} }
#endif // wxUSE_MENUS
#if wxUSE_STATUSBAR #if wxUSE_STATUSBAR
/* status bar */ /* status bar */
@@ -663,6 +667,7 @@ void wxFrame::DoSetClientSize( int width, int height )
{ {
wxASSERT_MSG( (m_widget != NULL), wxT("invalid frame") ); wxASSERT_MSG( (m_widget != NULL), wxT("invalid frame") );
#if wxUSE_MENUS
/* menu bar */ /* menu bar */
if (m_frameMenuBar) if (m_frameMenuBar)
{ {
@@ -671,6 +676,7 @@ void wxFrame::DoSetClientSize( int width, int height )
else else
height += wxPLACE_HOLDER; height += wxPLACE_HOLDER;
} }
#endif // wxUSE_MENUS
#if wxUSE_STATUSBAR #if wxUSE_STATUSBAR
/* status bar */ /* status bar */
@@ -759,6 +765,7 @@ void wxFrame::GtkOnSize( int WXUNUSED(x), int WXUNUSED(y),
* this hurts in the eye, but I don't want to call SetSize() * this hurts in the eye, but I don't want to call SetSize()
* because I don't want to call any non-native functions here. */ * because I don't want to call any non-native functions here. */
#if wxUSE_MENUS
if (m_frameMenuBar) if (m_frameMenuBar)
{ {
int xx = m_miniEdge; int xx = m_miniEdge;
@@ -775,6 +782,7 @@ void wxFrame::GtkOnSize( int WXUNUSED(x), int WXUNUSED(y),
xx, yy, ww, hh ); xx, yy, ww, hh );
client_area_y_offset += hh; client_area_y_offset += hh;
} }
#endif // wxUSE_MENUS
#if wxUSE_TOOLBAR #if wxUSE_TOOLBAR
if ((m_frameToolBar) && if ((m_frameToolBar) &&
@@ -782,6 +790,7 @@ void wxFrame::GtkOnSize( int WXUNUSED(x), int WXUNUSED(y),
{ {
int xx = m_miniEdge; int xx = m_miniEdge;
int yy = m_miniEdge + m_miniTitle; int yy = m_miniEdge + m_miniTitle;
#if wxUSE_MENUS
if (m_frameMenuBar) if (m_frameMenuBar)
{ {
if (!m_menuBarDetached) if (!m_menuBarDetached)
@@ -789,6 +798,7 @@ void wxFrame::GtkOnSize( int WXUNUSED(x), int WXUNUSED(y),
else else
yy += wxPLACE_HOLDER; yy += wxPLACE_HOLDER;
} }
#endif // wxUSE_MENUS
m_frameToolBar->m_x = xx; m_frameToolBar->m_x = xx;
m_frameToolBar->m_y = yy; m_frameToolBar->m_y = yy;
@@ -848,7 +858,7 @@ void wxFrame::GtkOnSize( int WXUNUSED(x), int WXUNUSED(y),
xx, yy, ww, hh ); xx, yy, ww, hh );
gtk_widget_draw( m_frameStatusBar->m_widget, (GdkRectangle*) NULL ); gtk_widget_draw( m_frameStatusBar->m_widget, (GdkRectangle*) NULL );
} }
#endif #endif // wxUSE_STATUSBAR
m_sizeSet = TRUE; m_sizeSet = TRUE;
@@ -857,6 +867,7 @@ void wxFrame::GtkOnSize( int WXUNUSED(x), int WXUNUSED(y),
event.SetEventObject( this ); event.SetEventObject( this );
GetEventHandler()->ProcessEvent( event ); GetEventHandler()->ProcessEvent( event );
#if wxUSE_STATUSBAR
// send size event to status bar // send size event to status bar
if (m_frameStatusBar) if (m_frameStatusBar)
{ {
@@ -864,6 +875,7 @@ void wxFrame::GtkOnSize( int WXUNUSED(x), int WXUNUSED(y),
event2.SetEventObject( m_frameStatusBar ); event2.SetEventObject( m_frameStatusBar );
m_frameStatusBar->GetEventHandler()->ProcessEvent( event2 ); m_frameStatusBar->GetEventHandler()->ProcessEvent( event2 );
} }
#endif // wxUSE_STATUSBAR
m_resizing = FALSE; m_resizing = FALSE;
} }
@@ -888,7 +900,9 @@ void wxFrame::OnInternalIdle()
return; return;
} }
#if wxUSE_MENUS
if (m_frameMenuBar) m_frameMenuBar->OnInternalIdle(); if (m_frameMenuBar) m_frameMenuBar->OnInternalIdle();
#endif // wxUSE_MENUS
#if wxUSE_TOOLBAR #if wxUSE_TOOLBAR
if (m_frameToolBar) m_frameToolBar->OnInternalIdle(); if (m_frameToolBar) m_frameToolBar->OnInternalIdle();
#endif #endif
@@ -903,6 +917,8 @@ void wxFrame::OnInternalIdle()
// menu/tool/status bar stuff // menu/tool/status bar stuff
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
#if wxUSE_MENUS
void wxFrame::SetMenuBar( wxMenuBar *menuBar ) void wxFrame::SetMenuBar( wxMenuBar *menuBar )
{ {
wxASSERT_MSG( (m_widget != NULL), wxT("invalid frame") ); wxASSERT_MSG( (m_widget != NULL), wxT("invalid frame") );
@@ -959,7 +975,10 @@ void wxFrame::SetMenuBar( wxMenuBar *menuBar )
m_sizeSet = FALSE; m_sizeSet = FALSE;
} }
#endif // wxUSE_MENUS
#if wxUSE_TOOLBAR #if wxUSE_TOOLBAR
wxToolBar* wxFrame::CreateToolBar( long style, wxWindowID id, const wxString& name ) wxToolBar* wxFrame::CreateToolBar( long style, wxWindowID id, const wxString& name )
{ {
wxASSERT_MSG( (m_widget != NULL), wxT("invalid frame") ); wxASSERT_MSG( (m_widget != NULL), wxT("invalid frame") );

View File

@@ -1530,7 +1530,7 @@ static gint gtk_window_focus_in_callback( GtkWidget *widget, GdkEvent *WXUNUSED(
gdk_im_begin(win->m_ic, win->m_wxwindow->window); gdk_im_begin(win->m_ic, win->m_wxwindow->window);
#endif #endif
#ifdef wxUSE_CARET #if wxUSE_CARET
// caret needs to be informed about focus change // caret needs to be informed about focus change
wxCaret *caret = win->GetCaret(); wxCaret *caret = win->GetCaret();
if ( caret ) if ( caret )
@@ -1588,7 +1588,7 @@ static gint gtk_window_focus_out_callback( GtkWidget *widget, GdkEvent *WXUNUSED
gdk_im_end(); gdk_im_end();
#endif #endif
#ifdef wxUSE_CARET #if wxUSE_CARET
// caret needs to be informed about focus change // caret needs to be informed about focus change
wxCaret *caret = win->GetCaret(); wxCaret *caret = win->GetCaret();
if ( caret ) if ( caret )
@@ -3351,6 +3351,8 @@ void wxWindow::ApplyWidgetStyle()
// Pop-up menu stuff // Pop-up menu stuff
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
#if wxUSE_MENUS
static void gtk_pop_hide_callback( GtkWidget *WXUNUSED(widget), bool* is_waiting ) static void gtk_pop_hide_callback( GtkWidget *WXUNUSED(widget), bool* is_waiting )
{ {
*is_waiting = FALSE; *is_waiting = FALSE;
@@ -3421,6 +3423,8 @@ bool wxWindow::DoPopupMenu( wxMenu *menu, int x, int y )
return TRUE; return TRUE;
} }
#endif // wxUSE_MENUS
#if wxUSE_DRAG_AND_DROP #if wxUSE_DRAG_AND_DROP
void wxWindow::SetDropTarget( wxDropTarget *dropTarget ) void wxWindow::SetDropTarget( wxDropTarget *dropTarget )

View File

@@ -1,4 +1,4 @@
# This file was automatically generated by tmake at 15:57, 2000/08/04 # This file was automatically generated by tmake at 14:01, 2000/08/11
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE GTK.T! # DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE GTK.T!
ALL_SOURCES = \ ALL_SOURCES = \
generic/busyinfo.cpp \ generic/busyinfo.cpp \
@@ -972,6 +972,56 @@ GUIDEPS = \
win_gtk.d \ win_gtk.d \
window.d window.d
GUI_LOWLEVEL_OBJS = \
app.o \
bitmap.o \
brush.o \
colour.o \
cursor.o \
data.o \
dc.o \
dcclient.o \
dcmemory.o \
dcscreen.o \
dialog.o \
font.o \
frame.o \
gdiobj.o \
icon.o \
main.o \
palette.o \
pen.o \
region.o \
settings.o \
utilsgtk.o \
win_gtk.o \
window.o
GUI_LOWLEVEL_DEPS = \
app.d \
bitmap.d \
brush.d \
colour.d \
cursor.d \
data.d \
dc.d \
dcclient.d \
dcmemory.d \
dcscreen.d \
dialog.d \
font.d \
frame.d \
gdiobj.d \
icon.d \
main.d \
palette.d \
pen.d \
region.d \
settings.d \
utilsgtk.d \
win_gtk.d \
window.d
UNIXOBJS = \ UNIXOBJS = \
dialup.o \ dialup.o \
dir.o \ dir.o \

View File

@@ -146,6 +146,7 @@ static gint gtk_frame_delete_callback( GtkWidget *WXUNUSED(widget), GdkEvent *WX
return TRUE; return TRUE;
} }
#if wxUSE_MENUS
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
// "child_attached" of menu bar // "child_attached" of menu bar
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
@@ -169,6 +170,7 @@ static void gtk_menu_detached_callback( GtkWidget *WXUNUSED(widget), GtkWidget *
win->m_menuBarDetached = TRUE; win->m_menuBarDetached = TRUE;
win->GtkUpdateSize(); win->GtkUpdateSize();
} }
#endif // wxUSE_MENUS
#if wxUSE_TOOLBAR #if wxUSE_TOOLBAR
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
@@ -612,6 +614,7 @@ void wxFrame::DoGetClientSize( int *width, int *height ) const
wxWindow::DoGetClientSize( width, height ); wxWindow::DoGetClientSize( width, height );
if (height) if (height)
{ {
#if wxUSE_MENUS
/* menu bar */ /* menu bar */
if (m_frameMenuBar) if (m_frameMenuBar)
{ {
@@ -620,6 +623,7 @@ void wxFrame::DoGetClientSize( int *width, int *height ) const
else else
(*height) -= wxPLACE_HOLDER; (*height) -= wxPLACE_HOLDER;
} }
#endif // wxUSE_MENUS
#if wxUSE_STATUSBAR #if wxUSE_STATUSBAR
/* status bar */ /* status bar */
@@ -663,6 +667,7 @@ void wxFrame::DoSetClientSize( int width, int height )
{ {
wxASSERT_MSG( (m_widget != NULL), wxT("invalid frame") ); wxASSERT_MSG( (m_widget != NULL), wxT("invalid frame") );
#if wxUSE_MENUS
/* menu bar */ /* menu bar */
if (m_frameMenuBar) if (m_frameMenuBar)
{ {
@@ -671,6 +676,7 @@ void wxFrame::DoSetClientSize( int width, int height )
else else
height += wxPLACE_HOLDER; height += wxPLACE_HOLDER;
} }
#endif // wxUSE_MENUS
#if wxUSE_STATUSBAR #if wxUSE_STATUSBAR
/* status bar */ /* status bar */
@@ -759,6 +765,7 @@ void wxFrame::GtkOnSize( int WXUNUSED(x), int WXUNUSED(y),
* this hurts in the eye, but I don't want to call SetSize() * this hurts in the eye, but I don't want to call SetSize()
* because I don't want to call any non-native functions here. */ * because I don't want to call any non-native functions here. */
#if wxUSE_MENUS
if (m_frameMenuBar) if (m_frameMenuBar)
{ {
int xx = m_miniEdge; int xx = m_miniEdge;
@@ -775,6 +782,7 @@ void wxFrame::GtkOnSize( int WXUNUSED(x), int WXUNUSED(y),
xx, yy, ww, hh ); xx, yy, ww, hh );
client_area_y_offset += hh; client_area_y_offset += hh;
} }
#endif // wxUSE_MENUS
#if wxUSE_TOOLBAR #if wxUSE_TOOLBAR
if ((m_frameToolBar) && if ((m_frameToolBar) &&
@@ -782,6 +790,7 @@ void wxFrame::GtkOnSize( int WXUNUSED(x), int WXUNUSED(y),
{ {
int xx = m_miniEdge; int xx = m_miniEdge;
int yy = m_miniEdge + m_miniTitle; int yy = m_miniEdge + m_miniTitle;
#if wxUSE_MENUS
if (m_frameMenuBar) if (m_frameMenuBar)
{ {
if (!m_menuBarDetached) if (!m_menuBarDetached)
@@ -789,6 +798,7 @@ void wxFrame::GtkOnSize( int WXUNUSED(x), int WXUNUSED(y),
else else
yy += wxPLACE_HOLDER; yy += wxPLACE_HOLDER;
} }
#endif // wxUSE_MENUS
m_frameToolBar->m_x = xx; m_frameToolBar->m_x = xx;
m_frameToolBar->m_y = yy; m_frameToolBar->m_y = yy;
@@ -848,7 +858,7 @@ void wxFrame::GtkOnSize( int WXUNUSED(x), int WXUNUSED(y),
xx, yy, ww, hh ); xx, yy, ww, hh );
gtk_widget_draw( m_frameStatusBar->m_widget, (GdkRectangle*) NULL ); gtk_widget_draw( m_frameStatusBar->m_widget, (GdkRectangle*) NULL );
} }
#endif #endif // wxUSE_STATUSBAR
m_sizeSet = TRUE; m_sizeSet = TRUE;
@@ -857,6 +867,7 @@ void wxFrame::GtkOnSize( int WXUNUSED(x), int WXUNUSED(y),
event.SetEventObject( this ); event.SetEventObject( this );
GetEventHandler()->ProcessEvent( event ); GetEventHandler()->ProcessEvent( event );
#if wxUSE_STATUSBAR
// send size event to status bar // send size event to status bar
if (m_frameStatusBar) if (m_frameStatusBar)
{ {
@@ -864,6 +875,7 @@ void wxFrame::GtkOnSize( int WXUNUSED(x), int WXUNUSED(y),
event2.SetEventObject( m_frameStatusBar ); event2.SetEventObject( m_frameStatusBar );
m_frameStatusBar->GetEventHandler()->ProcessEvent( event2 ); m_frameStatusBar->GetEventHandler()->ProcessEvent( event2 );
} }
#endif // wxUSE_STATUSBAR
m_resizing = FALSE; m_resizing = FALSE;
} }
@@ -888,7 +900,9 @@ void wxFrame::OnInternalIdle()
return; return;
} }
#if wxUSE_MENUS
if (m_frameMenuBar) m_frameMenuBar->OnInternalIdle(); if (m_frameMenuBar) m_frameMenuBar->OnInternalIdle();
#endif // wxUSE_MENUS
#if wxUSE_TOOLBAR #if wxUSE_TOOLBAR
if (m_frameToolBar) m_frameToolBar->OnInternalIdle(); if (m_frameToolBar) m_frameToolBar->OnInternalIdle();
#endif #endif
@@ -903,6 +917,8 @@ void wxFrame::OnInternalIdle()
// menu/tool/status bar stuff // menu/tool/status bar stuff
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
#if wxUSE_MENUS
void wxFrame::SetMenuBar( wxMenuBar *menuBar ) void wxFrame::SetMenuBar( wxMenuBar *menuBar )
{ {
wxASSERT_MSG( (m_widget != NULL), wxT("invalid frame") ); wxASSERT_MSG( (m_widget != NULL), wxT("invalid frame") );
@@ -959,7 +975,10 @@ void wxFrame::SetMenuBar( wxMenuBar *menuBar )
m_sizeSet = FALSE; m_sizeSet = FALSE;
} }
#endif // wxUSE_MENUS
#if wxUSE_TOOLBAR #if wxUSE_TOOLBAR
wxToolBar* wxFrame::CreateToolBar( long style, wxWindowID id, const wxString& name ) wxToolBar* wxFrame::CreateToolBar( long style, wxWindowID id, const wxString& name )
{ {
wxASSERT_MSG( (m_widget != NULL), wxT("invalid frame") ); wxASSERT_MSG( (m_widget != NULL), wxT("invalid frame") );

View File

@@ -1530,7 +1530,7 @@ static gint gtk_window_focus_in_callback( GtkWidget *widget, GdkEvent *WXUNUSED(
gdk_im_begin(win->m_ic, win->m_wxwindow->window); gdk_im_begin(win->m_ic, win->m_wxwindow->window);
#endif #endif
#ifdef wxUSE_CARET #if wxUSE_CARET
// caret needs to be informed about focus change // caret needs to be informed about focus change
wxCaret *caret = win->GetCaret(); wxCaret *caret = win->GetCaret();
if ( caret ) if ( caret )
@@ -1588,7 +1588,7 @@ static gint gtk_window_focus_out_callback( GtkWidget *widget, GdkEvent *WXUNUSED
gdk_im_end(); gdk_im_end();
#endif #endif
#ifdef wxUSE_CARET #if wxUSE_CARET
// caret needs to be informed about focus change // caret needs to be informed about focus change
wxCaret *caret = win->GetCaret(); wxCaret *caret = win->GetCaret();
if ( caret ) if ( caret )
@@ -3351,6 +3351,8 @@ void wxWindow::ApplyWidgetStyle()
// Pop-up menu stuff // Pop-up menu stuff
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
#if wxUSE_MENUS
static void gtk_pop_hide_callback( GtkWidget *WXUNUSED(widget), bool* is_waiting ) static void gtk_pop_hide_callback( GtkWidget *WXUNUSED(widget), bool* is_waiting )
{ {
*is_waiting = FALSE; *is_waiting = FALSE;
@@ -3421,6 +3423,8 @@ bool wxWindow::DoPopupMenu( wxMenu *menu, int x, int y )
return TRUE; return TRUE;
} }
#endif // wxUSE_MENUS
#if wxUSE_DRAG_AND_DROP #if wxUSE_DRAG_AND_DROP
void wxWindow::SetDropTarget( wxDropTarget *dropTarget ) void wxWindow::SetDropTarget( wxDropTarget *dropTarget )

View File

@@ -73,11 +73,13 @@ static char **CreateFontList(wxChar spacing,
wxNativeEncodingInfo info; wxNativeEncodingInfo info;
wxGetNativeFontEncoding(encoding, &info); wxGetNativeFontEncoding(encoding, &info);
#if wxUSE_FONTMAP
if ( !wxTestFontEncoding(info) ) if ( !wxTestFontEncoding(info) )
{ {
// ask font mapper for a replacement // ask font mapper for a replacement
(void)wxTheFontMapper->GetAltForEncoding(encoding, &info); (void)wxTheFontMapper->GetAltForEncoding(encoding, &info);
} }
#endif // wxUSE_FONTMAP
wxString pattern; wxString pattern;
pattern.Printf(wxT("-*-*-*-*-*-*-*-*-*-*-%c-*-%s-%s"), pattern.Printf(wxT("-*-*-*-*-*-*-*-*-*-*-%c-*-%s-%s"),

View File

@@ -260,7 +260,9 @@ wxNativeFont wxLoadQueryNearestFont(int pointSize,
if ( !wxGetNativeFontEncoding(encoding, &info) || if ( !wxGetNativeFontEncoding(encoding, &info) ||
!wxTestFontEncoding(info) ) !wxTestFontEncoding(info) )
{ {
#if wxUSE_FONTMAP
if ( !wxTheFontMapper->GetAltForEncoding(encoding, &info) ) if ( !wxTheFontMapper->GetAltForEncoding(encoding, &info) )
#endif // wxUSE_FONTMAP
{ {
// unspported encoding - replace it with the default // unspported encoding - replace it with the default
// //

View File

@@ -847,7 +847,7 @@ void wxThread::Sleep(unsigned long milliseconds)
int wxThread::GetCPUCount() int wxThread::GetCPUCount()
{ {
#if defined(__LINUX__) #if defined(__LINUX__) && wxUSE_FFILE
// read from proc (can't use wxTextFile here because it's a special file: // read from proc (can't use wxTextFile here because it's a special file:
// it has 0 size but still can be read from) // it has 0 size but still can be read from)
wxLogNull nolog; wxLogNull nolog;

View File

@@ -303,6 +303,8 @@ void wxHandleProcessTermination(wxEndProcessData *proc_data)
// wxStream classes to support IO redirection in wxExecute // wxStream classes to support IO redirection in wxExecute
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
#if wxUSE_STREAMS
class wxProcessFileInputStream : public wxInputStream class wxProcessFileInputStream : public wxInputStream
{ {
public: public:
@@ -399,12 +401,14 @@ size_t wxProcessFileOutputStream::OnSysWrite(const void *buffer, size_t bufsize)
return ret; return ret;
} }
#endif // wxUSE_STREAMS
long wxExecute(wxChar **argv, long wxExecute(wxChar **argv,
bool sync, bool sync,
wxProcess *process) wxProcess *process)
{ {
// for the sync execution, we return -1 to indicate failure, but for async // for the sync execution, we return -1 to indicate failure, but for async
// cse we return 0 which is never a valid PID // case we return 0 which is never a valid PID
long errorRetCode = sync ? -1 : 0; long errorRetCode = sync ? -1 : 0;
wxCHECK_MSG( *argv, errorRetCode, wxT("can't exec empty command") ); wxCHECK_MSG( *argv, errorRetCode, wxT("can't exec empty command") );
@@ -557,16 +561,18 @@ long wxExecute(wxChar **argv,
// pipe initialization: construction of the wxStreams // pipe initialization: construction of the wxStreams
if ( process && process->IsRedirected() ) if ( process && process->IsRedirected() )
{ {
#if wxUSE_STREAMS
// These two streams are relative to this process. // These two streams are relative to this process.
wxOutputStream *outStream = new wxProcessFileOutputStream(pipeIn[1]); wxOutputStream *outStream = new wxProcessFileOutputStream(pipeIn[1]);
wxInputStream *inStream = new wxProcessFileInputStream(pipeOut[0]); wxInputStream *inStream = new wxProcessFileInputStream(pipeOut[0]);
wxInputStream *errStream = new wxProcessFileInputStream(pipeErr[0]); wxInputStream *errStream = new wxProcessFileInputStream(pipeErr[0]);
process->SetPipeStreams(inStream, outStream, errStream);
#endif // wxUSE_STREAMS
close(pipeIn[0]); // close reading side close(pipeIn[0]); // close reading side
close(pipeOut[1]); // close writing side close(pipeOut[1]); // close writing side
close(pipeErr[1]); // close writing side close(pipeErr[1]); // close writing side
process->SetPipeStreams(inStream, outStream, errStream);
} }
#if wxUSE_GUI #if wxUSE_GUI