wxChoiceDialog fix.

Distribution and build things.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@2933 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robert Roebling
1999-06-29 23:16:45 +00:00
parent 7b8bd8182c
commit a533f5c122
37 changed files with 1693 additions and 450 deletions

View File

@@ -59,12 +59,15 @@
#include <stdio.h>
#include <string.h>
#include "wx/ioswrap.h"
#if wxUSE_IOSTREAMH
#if wxUSE_STD_IOSTREAM
#include "wx/ioswrap.h"
#if wxUSE_IOSTREAMH
#include <fstream.h>
#else
#else
#include <fstream>
#endif
#else
#include "wx/wfstream.h"
#endif
// ----------------------------------------------------------------------------
@@ -277,8 +280,13 @@ bool wxDocument::OnSaveDocument(const wxString& file)
else
msgTitle = wxString(_("File error"));
#if wxUSE_STD_IOSTREAM
ofstream store(file.fn_str());
if (store.fail() || store.bad())
#else
wxFileOutputStream store(file.fn_str());
if (store.LastError() == 0)
#endif
{
(void)wxMessageBox(_("Sorry, could not open this file for saving."), msgTitle, wxOK | wxICON_EXCLAMATION,
GetDocumentWindow());
@@ -308,8 +316,13 @@ bool wxDocument::OnOpenDocument(const wxString& file)
else
msgTitle = wxString(_("File error"));
#if wxUSE_STD_IOSTREAM
ifstream store(file.fn_str());
if (store.fail() || store.bad())
#else
wxFileInputStream store(file.fn_str());
if (store.LastError() == 0)
#endif
{
(void)wxMessageBox(_("Sorry, could not open this file."), msgTitle, wxOK|wxICON_EXCLAMATION,
GetDocumentWindow());
@@ -330,19 +343,27 @@ bool wxDocument::OnOpenDocument(const wxString& file)
return TRUE;
}
#if wxUSE_STD_IOSTREAM
istream& wxDocument::LoadObject(istream& stream)
{
// wxObject::LoadObject(stream);
return stream;
}
ostream& wxDocument::SaveObject(ostream& stream)
{
// wxObject::SaveObject(stream);
return stream;
}
#else
bool wxDocument::LoadObject(wxInputStream& stream)
{
return TRUE;
}
bool wxDocument::SaveObject(wxOutputStream& stream)
{
return TRUE;
}
#endif
bool wxDocument::Revert()
{
@@ -1943,6 +1964,7 @@ void wxFileHistory::AddFilesToMenu(wxMenu* menu)
// manipulate files directly
// ----------------------------------------------------------------------------
#if wxUSE_STD_IOSTREAM
bool wxTransferFileToStream(const wxString& filename, ostream& stream)
{
FILE *fd1;
@@ -1977,6 +1999,7 @@ bool wxTransferStreamToFile(istream& stream, const wxString& filename)
fclose (fd1);
return TRUE;
}
#endif
#endif // wxUSE_DOC_VIEW_ARCHITECTURE

View File

@@ -138,7 +138,7 @@ extern const wxChar WXDLLEXPORT *g_szNul = &g_strEmpty.dummy;
// global functions
// ----------------------------------------------------------------------------
#ifdef wxSTD_STRING_COMPATIBILITY
#if defined(wxSTD_STRING_COMPATIBILITY) && wxUSE_STD_IOSTREAM
// MS Visual C++ version 5.0 provides the new STL headers as well as the old
// iostream ones.

View File

@@ -88,9 +88,9 @@ libwx_gtk_la_SOURCES = \
textfile.cpp \
time.cpp \
timercmn.cpp \
utilscmn.cpp \
tokenzr.cpp \
url.cpp \
utilscmn.cpp \
valgen.cpp \
validate.cpp \
valtext.cpp \
@@ -127,6 +127,7 @@ libwx_gtk_la_SOURCES = \
splitter.cpp \
statusbr.cpp \
tabg.cpp \
tipdlg.cpp \
treectrl.cpp \
\
threadpsx.cpp \
@@ -185,7 +186,6 @@ libwx_gtk_la_SOURCES = \
textctrl.cpp \
textdlg.cpp \
timer.cpp \
tipdlg.cpp \
tooltip.cpp \
utilsgtk.cpp \
utilsres.cpp \

View File

@@ -248,7 +248,7 @@ bool wxSingleChoiceDialog::Create( wxWindow *WXUNUSED(parent), const wxString& m
int y = message_size.y + 15;
int listbox_height = wxMin( 160, n*20 );
int listbox_height = 100;
wxListBox *listBox = new wxListBox( this, wxID_LISTBOX, wxPoint(10, y), wxSize(240, listbox_height),
n, choices, wxLB_ALWAYS_SB );

View File

@@ -3,74 +3,17 @@
# Author: Robert Roebling
# Created: 1998
# Updated:
# Copyright: (c) 1998
# Copyright: (c) 1998, 1999
#
#
# Makefile for wxGtk library, Unix
# Makefile for wxWindows library, GTK 1.2, Unix
#
EXTRACFLAGS=-DLEX_SCANNER
include ../make.env
LIB_CPP_SRC=\
\
../common/cmndata.cpp \
../common/config.cpp \
../common/date.cpp \
../common/docmdi.cpp \
../common/docview.cpp \
../common/dynarray.cpp \
../common/dynlib.cpp \
../common/event.cpp \
../common/file.cpp \
../common/fileconf.cpp \
../common/filefn.cpp \
../common/gdicmn.cpp \
../common/hash.cpp \
../common/helpbase.cpp \
../common/intl.cpp \
../common/image.cpp \
../common/imagjpeg.cpp \
../common/imagpng.cpp \
../common/ipcbase.cpp \
../common/layout.cpp \
../common/list.cpp \
../common/log.cpp \
../common/matrix.cpp \
../common/memory.cpp \
../common/module.cpp \
../common/object.cpp \
../common/odbc.cpp \
../common/postscrp.cpp \
../common/prntbase.cpp \
../common/resource.cpp \
../common/serbase.cpp \
../common/string.cpp \
../common/textfile.cpp \
../common/time.cpp \
../common/timercmn.cpp \
../common/utilscmn.cpp \
../common/wincmn.cpp \
../common/framecmn.cpp \
../common/stream.cpp \
../common/datstrm.cpp \
../common/wfstream.cpp \
../common/mstream.cpp \
../common/zstream.cpp \
../common/objstrm.cpp \
../common/sckstrm.cpp \
../common/validate.cpp \
../common/valtext.cpp \
../common/variant.cpp \
../common/wxexpr.cpp \
../common/socket.cpp \
../common/sckaddr.cpp \
../common/sckipc.cpp \
../common/protocol.cpp \
../common/ftp.cpp \
../common/http.cpp \
../common/url.cpp \
../common/tokenzr.cpp \
\
accel.cpp \
app.cpp \
@@ -81,10 +24,11 @@ LIB_CPP_SRC=\
checkbox.cpp \
checklst.cpp \
choice.cpp \
choicdlg.cpp \
clipbrd.cpp \
colour.cpp \
control.cpp \
combobox.cpp \
control.cpp \
cursor.cpp \
data.cpp \
dataobj.cpp \
@@ -92,7 +36,6 @@ LIB_CPP_SRC=\
dcclient.cpp \
dcmemory.cpp \
dcscreen.cpp \
dcps.cpp \
dialog.cpp \
dnd.cpp \
filedlg.cpp \
@@ -106,6 +49,7 @@ LIB_CPP_SRC=\
mdi.cpp \
menu.cpp \
minifram.cpp \
msgdlg.cpp \
notebook.cpp \
palette.cpp \
pen.cpp \
@@ -116,37 +60,121 @@ LIB_CPP_SRC=\
settings.cpp \
slider.cpp \
spinbutt.cpp \
statbox.cpp \
statbmp.cpp \
statbox.cpp \
statline.cpp \
stattext.cpp \
tbargtk.cpp \
threadpsx.cpp \
textctrl.cpp \
textdlg.cpp \
timer.cpp \
tooltip.cpp \
utilsgtk.cpp \
utilsres.cpp \
wave.cpp \
window.cpp \
\
../generic/choicdgg.cpp \
../common/cmndata.cpp \
../common/config.cpp \
../common/date.cpp \
../common/datstrm.cpp \
../common/dcbase.cpp \
../common/dlgcmn.cpp \
../common/docmdi.cpp \
../common/docview.cpp \
../common/dynarray.cpp \
../common/dynlib.cpp \
../common/event.cpp \
../common/file.cpp \
../common/fileconf.cpp \
../common/filefn.cpp \
../common/framecmn.cpp \
../common/ftp.cpp \
../common/gdicmn.cpp \
../common/hash.cpp \
../common/helpbase.cpp \
../common/http.cpp \
../common/image.cpp \
../common/imagjpeg.cpp \
../common/imagbmp.cpp \
../common/imaggif.cpp \
../common/imagpng.cpp \
../common/intl.cpp \
../common/ipcbase.cpp \
../common/layout.cpp \
../common/list.cpp \
../common/log.cpp \
../common/longlong.cpp \
../common/matrix.cpp \
../common/memory.cpp \
../common/mimetype.cpp \
../common/module.cpp \
../common/mstream.cpp \
../common/object.cpp \
../common/objstrm.cpp \
../common/odbc.cpp \
../common/paper.cpp \
../common/prntbase.cpp \
../common/process.cpp \
../common/protocol.cpp \
../common/resource.cpp \
../common/sckaddr.cpp \
../common/sckfile.cpp \
../common/sckint.cpp \
../common/sckipc.cpp \
../common/sckstrm.cpp \
../common/serbase.cpp \
../common/socket.cpp \
../common/stream.cpp \
../common/string.cpp \
../common/tbarbase.cpp \
../common/tbarsmpl.cpp \
../common/textfile.cpp \
../common/time.cpp \
../common/timercmn.cpp \
../common/tokenzr.cpp \
../common/url.cpp \
../common/utilscmn.cpp \
../common/valgen.cpp \
../common/validate.cpp \
../common/valtext.cpp \
../common/variant.cpp \
../common/wfstream.cpp \
../common/wincmn.cpp \
../common/wxchar.cpp \
../common/wxexpr.cpp \
../common/zstream.cpp \
\
../common/db.cpp \
../common/dbtable.cpp \
\
../unix/threadpsx.cpp \
../unix/utilsunx.cpp \
\
../generic/caret.cpp \
../generic/colrdlgg.cpp \
../generic/dcpsg.cpp \
../generic/dirdlgg.cpp \
../generic/fontdlgg.cpp \
../generic/gridg.cpp \
../generic/helpext.cpp \
../generic/helphtml.cpp \
../generic/imaglist.cpp \
../generic/listctrl.cpp \
../generic/laywin.cpp \
../generic/msgdlgg.cpp \
../generic/listctrl.cpp \
../generic/panelg.cpp \
../generic/printps.cpp \
../generic/prntdlgg.cpp \
../generic/progdlgg.cpp \
../generic/prop.cpp \
../generic/propform.cpp \
../generic/proplist.cpp \
../generic/sashwin.cpp \
../generic/scrolwin.cpp \
../generic/splitter.cpp \
../generic/statusbr.cpp \
../generic/tabg.cpp \
../generic/textdlgg.cpp \
../generic/tipdlg.cpp \
../generic/treectrl.cpp
@@ -173,6 +201,54 @@ PNG_SRC=\
../png/pngmem.c \
../png/pngerror.c \
../png/pngpread.c
JPEG_SRC=\
../jpeg/jcomapi.c \
../jpeg/jutils.c \
../jpeg/jerror.c \
../jpeg/jmemmgr.c \
../jpeg/jmemnobs.c \
../jpeg/jcapimin.c \
../jpeg/jcapistd.c \
../jpeg/jctrans.c \
../jpeg/jcparam.c \
../jpeg/jdatadst.c \
../jpeg/jcinit.c \
../jpeg/jcmaster.c \
../jpeg/jcmarker.c \
../jpeg/jcmainct.c \
../jpeg/jcprepct.c \
../jpeg/jccoefct.c \
../jpeg/jccolor.c \
../jpeg/jcsample.c \
../jpeg/jchuff.c \
../jpeg/jcphuff.c \
../jpeg/jcdctmgr.c \
../jpeg/jfdctfst.c \
../jpeg/jfdctflt.c \
../jpeg/jfdctint.c \
../jpeg/jdapimin.c \
../jpeg/jdapistd.c \
../jpeg/jdtrans.c \
../jpeg/jdatasrc.c \
../jpeg/jdmaster.c \
../jpeg/jdinput.c \
../jpeg/jdmarker.c \
../jpeg/jdhuff.c \
../jpeg/jdphuff.c \
../jpeg/jdmainct.c \
../jpeg/jdcoefct.c \
../jpeg/jdpostct.c \
../jpeg/jddctmgr.c \
../jpeg/jidctfst.c \
../jpeg/jidctflt.c \
../jpeg/jidctint.c \
../jpeg/jidctred.c \
../jpeg/jdsample.c \
../jpeg/jdcolor.c \
../jpeg/jquant1.c \
../jpeg/jquant2.c \
../jpeg/jdmerge.c
LIB_C_SRC=\
\
@@ -184,7 +260,7 @@ LIB_C_SRC=\
# already have a zlib library installed on our system
# (or we wish to statically link them for some reason)
EXTRA_C_SRC=\
$(ZLIB_SRC) $(PNG_SRC)
$(ZLIB_SRC) $(PNG_SRC) $(JPEG_SRC)
all: $(WXLIB)

View File

@@ -184,9 +184,11 @@ void wxMenuBar::Append( wxMenu *menu, const wxString &title )
{
m_menus.Append( menu );
const wxChar *pc;
/* GTK 1.2 wants to have "_" instead of "&" for accelerators */
wxString str;
for ( const wxChar *pc = title; *pc != _T('\0'); pc++ )
for ( pc = title; *pc != _T('\0'); pc++ )
{
if (*pc == _T('&'))
{
@@ -230,7 +232,7 @@ void wxMenuBar::Append( wxMenu *menu, const wxString &title )
/* in order to get the pointer to the item we need the item text _without_ underscores */
wxString tmp = _T("<main>/");
for ( const wxChar *pc = str; *pc != _T('\0'); pc++ )
for ( pc = str; *pc != _T('\0'); pc++ )
{
if (*pc == _T('_')) pc++; /* skip it */
tmp << *pc;

View File

@@ -88,9 +88,9 @@ libwx_gtk_la_SOURCES = \
textfile.cpp \
time.cpp \
timercmn.cpp \
utilscmn.cpp \
tokenzr.cpp \
url.cpp \
utilscmn.cpp \
valgen.cpp \
validate.cpp \
valtext.cpp \
@@ -127,6 +127,7 @@ libwx_gtk_la_SOURCES = \
splitter.cpp \
statusbr.cpp \
tabg.cpp \
tipdlg.cpp \
treectrl.cpp \
\
threadpsx.cpp \
@@ -185,7 +186,6 @@ libwx_gtk_la_SOURCES = \
textctrl.cpp \
textdlg.cpp \
timer.cpp \
tipdlg.cpp \
tooltip.cpp \
utilsgtk.cpp \
utilsres.cpp \

View File

@@ -248,7 +248,7 @@ bool wxSingleChoiceDialog::Create( wxWindow *WXUNUSED(parent), const wxString& m
int y = message_size.y + 15;
int listbox_height = wxMin( 160, n*20 );
int listbox_height = 100;
wxListBox *listBox = new wxListBox( this, wxID_LISTBOX, wxPoint(10, y), wxSize(240, listbox_height),
n, choices, wxLB_ALWAYS_SB );

View File

@@ -3,74 +3,17 @@
# Author: Robert Roebling
# Created: 1998
# Updated:
# Copyright: (c) 1998
# Copyright: (c) 1998, 1999
#
#
# Makefile for wxGtk library, Unix
# Makefile for wxWindows library, GTK 1.2, Unix
#
EXTRACFLAGS=-DLEX_SCANNER
include ../make.env
LIB_CPP_SRC=\
\
../common/cmndata.cpp \
../common/config.cpp \
../common/date.cpp \
../common/docmdi.cpp \
../common/docview.cpp \
../common/dynarray.cpp \
../common/dynlib.cpp \
../common/event.cpp \
../common/file.cpp \
../common/fileconf.cpp \
../common/filefn.cpp \
../common/gdicmn.cpp \
../common/hash.cpp \
../common/helpbase.cpp \
../common/intl.cpp \
../common/image.cpp \
../common/imagjpeg.cpp \
../common/imagpng.cpp \
../common/ipcbase.cpp \
../common/layout.cpp \
../common/list.cpp \
../common/log.cpp \
../common/matrix.cpp \
../common/memory.cpp \
../common/module.cpp \
../common/object.cpp \
../common/odbc.cpp \
../common/postscrp.cpp \
../common/prntbase.cpp \
../common/resource.cpp \
../common/serbase.cpp \
../common/string.cpp \
../common/textfile.cpp \
../common/time.cpp \
../common/timercmn.cpp \
../common/utilscmn.cpp \
../common/wincmn.cpp \
../common/framecmn.cpp \
../common/stream.cpp \
../common/datstrm.cpp \
../common/wfstream.cpp \
../common/mstream.cpp \
../common/zstream.cpp \
../common/objstrm.cpp \
../common/sckstrm.cpp \
../common/validate.cpp \
../common/valtext.cpp \
../common/variant.cpp \
../common/wxexpr.cpp \
../common/socket.cpp \
../common/sckaddr.cpp \
../common/sckipc.cpp \
../common/protocol.cpp \
../common/ftp.cpp \
../common/http.cpp \
../common/url.cpp \
../common/tokenzr.cpp \
\
accel.cpp \
app.cpp \
@@ -81,10 +24,11 @@ LIB_CPP_SRC=\
checkbox.cpp \
checklst.cpp \
choice.cpp \
choicdlg.cpp \
clipbrd.cpp \
colour.cpp \
control.cpp \
combobox.cpp \
control.cpp \
cursor.cpp \
data.cpp \
dataobj.cpp \
@@ -92,7 +36,6 @@ LIB_CPP_SRC=\
dcclient.cpp \
dcmemory.cpp \
dcscreen.cpp \
dcps.cpp \
dialog.cpp \
dnd.cpp \
filedlg.cpp \
@@ -106,6 +49,7 @@ LIB_CPP_SRC=\
mdi.cpp \
menu.cpp \
minifram.cpp \
msgdlg.cpp \
notebook.cpp \
palette.cpp \
pen.cpp \
@@ -116,37 +60,121 @@ LIB_CPP_SRC=\
settings.cpp \
slider.cpp \
spinbutt.cpp \
statbox.cpp \
statbmp.cpp \
statbox.cpp \
statline.cpp \
stattext.cpp \
tbargtk.cpp \
threadpsx.cpp \
textctrl.cpp \
textdlg.cpp \
timer.cpp \
tooltip.cpp \
utilsgtk.cpp \
utilsres.cpp \
wave.cpp \
window.cpp \
\
../generic/choicdgg.cpp \
../common/cmndata.cpp \
../common/config.cpp \
../common/date.cpp \
../common/datstrm.cpp \
../common/dcbase.cpp \
../common/dlgcmn.cpp \
../common/docmdi.cpp \
../common/docview.cpp \
../common/dynarray.cpp \
../common/dynlib.cpp \
../common/event.cpp \
../common/file.cpp \
../common/fileconf.cpp \
../common/filefn.cpp \
../common/framecmn.cpp \
../common/ftp.cpp \
../common/gdicmn.cpp \
../common/hash.cpp \
../common/helpbase.cpp \
../common/http.cpp \
../common/image.cpp \
../common/imagjpeg.cpp \
../common/imagbmp.cpp \
../common/imaggif.cpp \
../common/imagpng.cpp \
../common/intl.cpp \
../common/ipcbase.cpp \
../common/layout.cpp \
../common/list.cpp \
../common/log.cpp \
../common/longlong.cpp \
../common/matrix.cpp \
../common/memory.cpp \
../common/mimetype.cpp \
../common/module.cpp \
../common/mstream.cpp \
../common/object.cpp \
../common/objstrm.cpp \
../common/odbc.cpp \
../common/paper.cpp \
../common/prntbase.cpp \
../common/process.cpp \
../common/protocol.cpp \
../common/resource.cpp \
../common/sckaddr.cpp \
../common/sckfile.cpp \
../common/sckint.cpp \
../common/sckipc.cpp \
../common/sckstrm.cpp \
../common/serbase.cpp \
../common/socket.cpp \
../common/stream.cpp \
../common/string.cpp \
../common/tbarbase.cpp \
../common/tbarsmpl.cpp \
../common/textfile.cpp \
../common/time.cpp \
../common/timercmn.cpp \
../common/tokenzr.cpp \
../common/url.cpp \
../common/utilscmn.cpp \
../common/valgen.cpp \
../common/validate.cpp \
../common/valtext.cpp \
../common/variant.cpp \
../common/wfstream.cpp \
../common/wincmn.cpp \
../common/wxchar.cpp \
../common/wxexpr.cpp \
../common/zstream.cpp \
\
../common/db.cpp \
../common/dbtable.cpp \
\
../unix/threadpsx.cpp \
../unix/utilsunx.cpp \
\
../generic/caret.cpp \
../generic/colrdlgg.cpp \
../generic/dcpsg.cpp \
../generic/dirdlgg.cpp \
../generic/fontdlgg.cpp \
../generic/gridg.cpp \
../generic/helpext.cpp \
../generic/helphtml.cpp \
../generic/imaglist.cpp \
../generic/listctrl.cpp \
../generic/laywin.cpp \
../generic/msgdlgg.cpp \
../generic/listctrl.cpp \
../generic/panelg.cpp \
../generic/printps.cpp \
../generic/prntdlgg.cpp \
../generic/progdlgg.cpp \
../generic/prop.cpp \
../generic/propform.cpp \
../generic/proplist.cpp \
../generic/sashwin.cpp \
../generic/scrolwin.cpp \
../generic/splitter.cpp \
../generic/statusbr.cpp \
../generic/tabg.cpp \
../generic/textdlgg.cpp \
../generic/tipdlg.cpp \
../generic/treectrl.cpp
@@ -173,6 +201,54 @@ PNG_SRC=\
../png/pngmem.c \
../png/pngerror.c \
../png/pngpread.c
JPEG_SRC=\
../jpeg/jcomapi.c \
../jpeg/jutils.c \
../jpeg/jerror.c \
../jpeg/jmemmgr.c \
../jpeg/jmemnobs.c \
../jpeg/jcapimin.c \
../jpeg/jcapistd.c \
../jpeg/jctrans.c \
../jpeg/jcparam.c \
../jpeg/jdatadst.c \
../jpeg/jcinit.c \
../jpeg/jcmaster.c \
../jpeg/jcmarker.c \
../jpeg/jcmainct.c \
../jpeg/jcprepct.c \
../jpeg/jccoefct.c \
../jpeg/jccolor.c \
../jpeg/jcsample.c \
../jpeg/jchuff.c \
../jpeg/jcphuff.c \
../jpeg/jcdctmgr.c \
../jpeg/jfdctfst.c \
../jpeg/jfdctflt.c \
../jpeg/jfdctint.c \
../jpeg/jdapimin.c \
../jpeg/jdapistd.c \
../jpeg/jdtrans.c \
../jpeg/jdatasrc.c \
../jpeg/jdmaster.c \
../jpeg/jdinput.c \
../jpeg/jdmarker.c \
../jpeg/jdhuff.c \
../jpeg/jdphuff.c \
../jpeg/jdmainct.c \
../jpeg/jdcoefct.c \
../jpeg/jdpostct.c \
../jpeg/jddctmgr.c \
../jpeg/jidctfst.c \
../jpeg/jidctflt.c \
../jpeg/jidctint.c \
../jpeg/jidctred.c \
../jpeg/jdsample.c \
../jpeg/jdcolor.c \
../jpeg/jquant1.c \
../jpeg/jquant2.c \
../jpeg/jdmerge.c
LIB_C_SRC=\
\
@@ -184,7 +260,7 @@ LIB_C_SRC=\
# already have a zlib library installed on our system
# (or we wish to statically link them for some reason)
EXTRA_C_SRC=\
$(ZLIB_SRC) $(PNG_SRC)
$(ZLIB_SRC) $(PNG_SRC) $(JPEG_SRC)
all: $(WXLIB)

View File

@@ -184,9 +184,11 @@ void wxMenuBar::Append( wxMenu *menu, const wxString &title )
{
m_menus.Append( menu );
const wxChar *pc;
/* GTK 1.2 wants to have "_" instead of "&" for accelerators */
wxString str;
for ( const wxChar *pc = title; *pc != _T('\0'); pc++ )
for ( pc = title; *pc != _T('\0'); pc++ )
{
if (*pc == _T('&'))
{
@@ -230,7 +232,7 @@ void wxMenuBar::Append( wxMenu *menu, const wxString &title )
/* in order to get the pointer to the item we need the item text _without_ underscores */
wxString tmp = _T("<main>/");
for ( const wxChar *pc = str; *pc != _T('\0'); pc++ )
for ( pc = str; *pc != _T('\0'); pc++ )
{
if (*pc == _T('_')) pc++; /* skip it */
tmp << *pc;

View File

@@ -40,18 +40,19 @@ GUISUFFIX = _stubs
# Misc options
OPTIONS = -D__LINUX__ -D__WXDEBUG__
COPTIONS =
DEBUGFLAGS = -ggdb
DEBUGFLAGS = # -ggdb
INCLUDE =
WARN = -Wall -Wno-unused # -w
CWARN = -Wall -Wno-unused # -w
OPT = # -O2
OPT = -O2
############################ Includes #################################
# Compiler or system-specific include paths
COMPPATHS =
XINCLUDE = -I/usr/openwin/include -I/usr/include/X11 -I/usr/include/Xm \
-I/usr/include/X11/Xm -I/usr/include
-I/usr/include/X11/Xm -I/usr/include -I/usr/local/include \
-I/usr/lib/glib/include -I/usr/local/lib/glib/include
XLIB = -L/usr/local/X11/lib -L/usr/openwin/lib -L/usr/X11/lib -L/usr/X11R6/lib
############################ Libraries ################################
@@ -72,7 +73,7 @@ MAINSUFF =cpp
WXINC = $(WXDIR)/include
WXLIB = $(WXDIR)/lib/libwx$(GUISUFFIX).a
INC = -I$(WXINC) -I$(WXDIR)/src/png -I$(WXDIR)/src/zlib $(COMPPATHS)
INC = -I$(WXINC) -I$(WXDIR)/src/png -I$(WXDIR)/src/jpeg -I$(WXDIR)/src/zlib $(COMPPATHS)
# Directory for object files
OBJDIR = objects$(GUISUFFIX)
@@ -106,7 +107,7 @@ motif:
make -f makefile.unx all GUI='-D__WXMOTIF__ -D__UNIX__' GUISUFFIX='_motif' GUILDLIBS='-lwx_motif $(COMPLIBS) -lpng -lzlib -lXm -lXmu -lXt -lXpm -lX11 -lm'
gtk:
make -f makefile.unx all GUI='-D__WXGTK__ -D__UNIX__' GUISUFFIX='_gtk' GUILDLIBS='-lwx_gtk2 $(COMPLIBS) -ldl -lgtk -lgdk -lglib -lpng -lzlib -lX11 -lm -pthread'
make -f makefile.unx all GUI='-D__WXGTK__ -D__UNIX__' GUISUFFIX='_gtk' GUILDLIBS='-lwx_gtk $(COMPLIBS) -ldl `gtk-config --libs` -lX11 -lm -pthread'
cleanstubs:
make -f makefile.unx clean GUI='-D__WXSTUBS__ -D__UNIX__' GUISUFFIX='_stubs' GUILDLIBS='-lwx_stubs $(COMPLIBS) -lXm -lXmu -lXt -lX11 -lm'