From c3b177ae6310ed80f054ae227513ef681f9c3dad Mon Sep 17 00:00:00 2001 From: Julian Smart Date: Fri, 11 Feb 2000 13:29:43 +0000 Subject: [PATCH] Some BC++ 5.4 fixes git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@5962 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- distrib/msw/bc.rsp | 1 + distrib/msw/vc.rsp | 94 ++++++++++++++++++++++++++++++++++---- docs/html/index.htm | 1 + docs/msw/install.txt | 3 ++ include/wx/buffer.h | 2 +- include/wx/msw/private.h | 4 ++ src/common/strconv.cpp | 2 +- src/makeb32.env | 3 ++ src/makeprog.b32 | 4 +- src/msw/ole/dataobj.cpp | 2 +- utils/projgen/makeproj.cpp | 13 ++++-- 11 files changed, 111 insertions(+), 18 deletions(-) diff --git a/distrib/msw/bc.rsp b/distrib/msw/bc.rsp index 6388546049..204f24beee 100644 --- a/distrib/msw/bc.rsp +++ b/distrib/msw/bc.rsp @@ -1,2 +1,3 @@ src/bc32.ide samples/bc32.ide +demos/bc32.ide diff --git a/distrib/msw/vc.rsp b/distrib/msw/vc.rsp index 58d97b2e38..6dfac1820e 100644 --- a/distrib/msw/vc.rsp +++ b/distrib/msw/vc.rsp @@ -6,6 +6,12 @@ src/wxvc_dll.dsw src/jpeg/jpeg.dsp src/jpeg/jpeg.dsw +samples/calendar/CalendarVC.dsp +samples/calendar/CalendarVC.dsw + +samples/caret/CaretVC.dsp +samples/caret/CaretVC.dsw + samples/checklst/ChecklstVC.dsp samples/checklst/ChecklstVC.dsw @@ -21,6 +27,9 @@ samples/db/DbVC.dsw samples/dialogs/DialogsVC.dsp samples/dialogs/DialogsVC.dsw +samples/dialup/DialupVC.dsp +samples/dialup/DialupVC.dsw + samples/dnd/DndVC.dsp samples/dnd/DndVC.dsw @@ -30,11 +39,17 @@ samples/docview/DocviewVC.dsw samples/docvwmdi/DocVwVC.dsp samples/docvwmdi/DocVwVC.dsw +samples/drawing/DrawingVC.dsp +samples/drawing/DrawingVC.dsw + samples/dynamic/DynamicVC.dsp samples/dynamic/DynamicVC.dsw -samples/forty/FortyVC.dsp -samples/forty/FortyVC.dsw +samples/exec/ExecVC.dsp +samples/exec/ExecVC.dsw + +samples/font/FontVC.dsp +samples/font/FontVC.dsw samples/grid/GridVC.dsp samples/grid/GridVC.dsw @@ -42,12 +57,34 @@ samples/grid/GridVC.dsw samples/help/HelpVC.dsp samples/help/HelpVC.dsw +samples/html/AboutVC.dsp +samples/html/AboutVC.dsw +samples/html/HelpVC.dsp +samples/html/HelpVC.dsw +samples/html/HelpViewVC.dsp +samples/html/HelpViewVC.dsw +samples/html/PrintingVC.dsp +samples/html/PrintingVC.dsw +samples/html/TestVC.dsp +samples/html/TestVC.dsw +samples/html/VirtualVC.dsp +samples/html/VirtualVC.dsw +samples/html/WidgetVC.dsp +samples/html/WidgetVC.dsw +samples/html/ZipVC.dsp +samples/html/ZipVC.dsw + samples/image/ImageVC.dsp samples/image/ImageVC.dsw samples/internat/InternatVC.dsp samples/internat/InternatVC.dsw +samples/ipc/ClientVC.dsp +samples/ipc/ClientVC.dsw +samples/ipc/ServerVC.dsp +samples/ipc/ServerVC.dsw + samples/joytest/JoytestVC.dsp samples/joytest/JoytestVC.dsw @@ -63,6 +100,9 @@ samples/mdi/MdiVC.dsw samples/memcheck/MemcheckVC.dsp samples/memcheck/MemcheckVC.dsw +samples/menu/MenuVC.dsp +samples/menu/MenuVC.dsw + samples/mfc/MfcVC.dsp samples/mfc/MfcVC.dsw @@ -75,27 +115,51 @@ samples/minifram/MiniframVC.dsw samples/nativdlg/NativdlgVC.dsp samples/nativdlg/NativdlgVC.dsw +samples/newgrid/NewgridVC.dsp +samples/newgrid/NewgridVC.dsw + samples/notebook/NotebookVC.dsp samples/notebook/NotebookVC.dsw samples/ownerdrw/OwnerDrwVC.dsp samples/ownerdrw/OwnerDrwVC.dsw +samples/plot/PlotVC.dsp +samples/plot/PlotVC.dsw + samples/png/PngVC.dsp samples/png/PngVC.dsw samples/printing/PrintingVC.dsp samples/printing/PrintingVC.dsw +samples/propsize/PropsizeVC.dsp +samples/propsize/PropsizeVC.dsw + samples/Regtest/RegtestVC.dsp samples/Regtest/RegtestVC.dsw samples/resource/ResourceVC.dsp samples/resource/ResourceVC.dsw +samples/richedit/RichEditVC.dsp +samples/richedit/RichEditVC.dsw + +samples/rotate/RotateVC.dsp +samples/rotate/RotateVC.dsw + samples/sashtest/SashtestVC.dsp samples/sashtest/SashtestVC.dsw +samples/scroll/ScrollVC.dsp +samples/scroll/ScrollVC.dsw + +samples/scrollsub/ScrollVC.dsp +samples/scrollsub/ScrollVC.dsw + +samples/sockets/ClientVC.dsp +samples/sockets/ServerVC.dsw + samples/splitter/SplitterVC.dsp samples/splitter/SplitterVC.dsw @@ -120,16 +184,26 @@ samples/typetest/TypetestVC.dsw samples/validate/ValidateVC.dsp samples/validate/ValidateVC.dsw -samples/wxsocket/ClientVC.dsp -samples/wxsocket/ServerVC.dsw +samples/wizard/WizardVC.dsp +samples/wizard/WizardVC.dsw + +demos/bombs/BombsVC.dsp +demos/bombs/BombsVC.dsw + +demos/dbbrowse/DbbrowseVC.dsp +demos/dbbrowse/DbbrowseVC.dsw + +demos/forty/FortyVC.dsp +demos/forty/FortyVC.dsw + +demos/fractal/FractalVC.dsp +demos/fractal/FractalVC.dsw -samples/wxpoem/PoemVC.dsp -samples/wxpoem/PoemVC.dsw +demos/life/LifeVC.dsp +demos/life/LifeVC.dsw -utils/wxprop/src/PropVC.dsp -utils/wxprop/src/PropVC.dsw -utils/wxprop/src/PropSampleVC.dsp -utils/wxprop/src/PropSampleVC.dsw +demos/poem/PoemVC.dsp +demos/poem/PoemVC.dsw utils/dialoged/src/DialogEdVC.dsp utils/dialoged/src/DialogEdVC.dsw diff --git a/docs/html/index.htm b/docs/html/index.htm index a13ea2ab32..6a75978b15 100644 --- a/docs/html/index.htm +++ b/docs/html/index.htm @@ -229,6 +229,7 @@ Excel to be present).
  • png: demonstrates PNG loading.
  • printing: shows printing and previewing.
  • proplist: demonstrates the property list classes (a VB-style property editor). +
  • propsize: demonstrates proportional sizer classes.
  • regtest: tests the low-level Windows registry functions (Windows only).
  • resource: shows how to use wxWindows resources (.wxr files).
  • richedit: a work-in-progress rich text editor with plain text and HTML export diff --git a/docs/msw/install.txt b/docs/msw/install.txt index cad4365402..7c183ba75e 100644 --- a/docs/msw/install.txt +++ b/docs/msw/install.txt @@ -241,6 +241,9 @@ Note (5): BC++ 4.5 (not 5.0) trips up over jdmerge.c in the JPEG folder; you will therefore need to set wxUSE_LIBJPEG to 0 in setup.h and remove the jpeg target from src\msw\makefile.b32. +Note (6): If using C++Builder 4 and above (BC++ 5.4), change LINK=tlink32 to +LINK=ilink32 in src\makeb32.env. + Compiling using the IDE files: 1. Load src\bc32.ide (Release settings) diff --git a/include/wx/buffer.h b/include/wx/buffer.h index b91a6cfc78..9f9eb174b7 100644 --- a/include/wx/buffer.h +++ b/include/wx/buffer.h @@ -70,7 +70,7 @@ public: wxASSERT_MSG( wcs, wxT("NULL string in wxWCharBuffer") ); if (wcs) { - size_t siz = (wcslen(wcs)+1)*sizeof(wchar_t); + size_t siz = (::wcslen(wcs)+1)*sizeof(wchar_t); m_wcs = (wchar_t *)malloc(siz); memcpy(m_wcs, wcs, siz); } diff --git a/include/wx/msw/private.h b/include/wx/msw/private.h index 15d89886ce..f932c659c0 100644 --- a/include/wx/msw/private.h +++ b/include/wx/msw/private.h @@ -73,7 +73,11 @@ WXDLLEXPORT_DATA(extern HFONT) wxSTATUS_LINE_FONT; # ifdef __BORLANDC__ # ifdef __WIN32__ +#if __BORLANDC__ > 0x530 + typedef long (__stdcall * WndProcCast)( HWND__*, unsigned int, unsigned int, long) ; +#else typedef int (pascal * WndProcCast) (); +#endif # define CASTWNDPROC (WndProcCast) // # define CASTWNDPROC # else diff --git a/src/common/strconv.cpp b/src/common/strconv.cpp index 609f6f2b4d..9c423ebda5 100644 --- a/src/common/strconv.cpp +++ b/src/common/strconv.cpp @@ -454,7 +454,7 @@ size_t wxCSConv::WC2MB(char *buf, const wchar_t *psz, size_t n) const } return n; } - return wcslen(psz); + return ::wcslen(psz); } #endif diff --git a/src/makeb32.env b/src/makeb32.env index 7eae33781e..16f2b3f469 100644 --- a/src/makeb32.env +++ b/src/makeb32.env @@ -6,6 +6,9 @@ WXLIBDIR = $(WXDIR)\lib WXINC = $(WXDIR)\include;$(WXDIR)\src\iodbc WIN95FLAG = -D__WIN95__ -D__WINDOWS__ +# This should be changed to ilink32 for C++Builder 4 and above +LINK=tlink32 + !ifndef FINAL FINAL=0 !endif diff --git a/src/makeprog.b32 b/src/makeprog.b32 index e24021fef5..e77f76d4ba 100644 --- a/src/makeprog.b32 +++ b/src/makeprog.b32 @@ -30,7 +30,7 @@ CPPFLAGS=$(DEBUG_FLAGS) $(EXTRACPPFLAGS) $(OPT) @$(CFG) all: $(TARGET).exe $(EXTRATARGETS) $(TARGET).exe: $(OBJECTS) $(TARGET).res - tlink32 $(LINKFLAGS) @&&! + $(LINK) $(LINKFLAGS) @&&! c0w32.obj $(OBJECTS) $(TARGET) nul @@ -54,4 +54,6 @@ clean: -erase *.res -erase *.map -erase *.rws + -erase *.tds + -erase *.il? diff --git a/src/msw/ole/dataobj.cpp b/src/msw/ole/dataobj.cpp index da186dcf9c..f94872ee06 100644 --- a/src/msw/ole/dataobj.cpp +++ b/src/msw/ole/dataobj.cpp @@ -464,7 +464,7 @@ STDMETHODIMP wxIDataObject::SetData(FORMATETC *pformatetc, break; #if !defined(__WATCOMC__) && ! (defined(__BORLANDC__) && (__BORLANDC__ < 0x500)) case CF_UNICODETEXT: - size = wcslen((const wchar_t *)pBuf); + size = ::wcslen((const wchar_t *)pBuf); break; #endif case CF_BITMAP: diff --git a/utils/projgen/makeproj.cpp b/utils/projgen/makeproj.cpp index 51e16013dd..1963b4294f 100644 --- a/utils/projgen/makeproj.cpp +++ b/utils/projgen/makeproj.cpp @@ -263,12 +263,14 @@ void MyApp::GenerateSamples(const wxString& dir) GenerateSample("PngVC", "pngdemo", dir + wxString("/samples/png"), wxStringList("pngdemo.cpp", "pngdemo.h", 0)); GenerateSample("PrintingVC", "printing", dir + wxString("/samples/printing"), wxStringList("printing.cpp", "printing.h", 0)); GenerateSample("ProplistVC", "test", dir + wxString("/samples/proplist"), wxStringList("test.cpp", "test.h", 0)); + GenerateSample("PropsizeVC", "propsize", dir + wxString("/samples/propsize"), wxStringList("propsize.cpp", 0)); GenerateSample("RegtestVC", "regtest", dir + wxString("/samples/regtest"), wxStringList("regtest.cpp", 0)); GenerateSample("ResourceVC", "resource", dir + wxString("/samples/resource"), wxStringList("resource.cpp", "resource.h", 0)); GenerateSample("RichEditVC", "wxLayout", dir + wxString("/samples/richedit"), wxStringList("wxLayout.cpp", "kbList.cpp", "wxllist.cpp", "wxlparser.cpp", "wxlwindow.cpp", 0)); GenerateSample("SashtestVC", "sashtest", dir + wxString("/samples/sashtest"), wxStringList("sashtest.cpp", "sashtest.h", 0)); GenerateSample("ScrollVC", "scroll", dir + wxString("/samples/scroll"), wxStringList("scroll.cpp", 0)); + GenerateSample("ScrollsubVC", "scrollsub", dir + wxString("/samples/scrollsub"), wxStringList("scrollsub.cpp", 0)); GenerateSample("SplitterVC", "test", dir + wxString("/samples/splitter"), wxStringList("test.cpp", 0)); GenerateSample("TabVC", "test", dir + wxString("/samples/tab"), wxStringList("test.cpp", "test.h", 0)); GenerateSample("TaskbarVC", "tbtest", dir + wxString("/samples/taskbar"), wxStringList("tbtest.cpp", "tbtest.h", 0)); @@ -278,15 +280,18 @@ void MyApp::GenerateSamples(const wxString& dir) GenerateSample("TreectrlVC", "treetest", dir + wxString("/samples/treectrl"), wxStringList("treetest.cpp", "treetest.h", 0)); GenerateSample("TypetestVC", "typetest", dir + wxString("/samples/typetest"), wxStringList("typetest.cpp", "typetest.h", 0)); GenerateSample("ValidateVC", "validate", dir + wxString("/samples/validate"), wxStringList("validate.cpp", "validate.h", 0)); - GenerateSample("ClientVC", "client", dir + wxString("/samples/socket"), wxStringList("client.cpp", 0)); - GenerateSample("ServerVC", "server", dir + wxString("/samples/socket"), wxStringList("server.cpp", 0)); - GenerateSample("ClientVC", "client", dir + wxString("/samples/dde"), wxStringList("client.cpp", "client.h", "ddesetup.h", 0)); - GenerateSample("ServerVC", "server", dir + wxString("/samples/dde"), wxStringList("server.cpp", "server.h", "ddesetup.h", 0)); + GenerateSample("ClientVC", "client", dir + wxString("/samples/sockets"), wxStringList("client.cpp", 0)); + GenerateSample("ServerVC", "server", dir + wxString("/samples/sockets"), wxStringList("server.cpp", 0)); + GenerateSample("ClientVC", "client", dir + wxString("/samples/ipc"), wxStringList("client.cpp", "client.h", "ddesetup.h", 0)); + GenerateSample("ServerVC", "server", dir + wxString("/samples/ipc"), wxStringList("server.cpp", "server.h", "ddesetup.h", 0)); GenerateSample("CaretVC", "caret", dir + wxString("/samples/caret"), wxStringList("caret.cpp", 0)); GenerateSample("DrawingVC", "drawing", dir + wxString("/samples/drawing"), wxStringList("drawing.cpp", 0)); GenerateSample("ScrollVC", "scroll", dir + wxString("/samples/scroll"), wxStringList("scroll.cpp", 0)); GenerateSample("WizardVC", "wizard", dir + wxString("/samples/wizard"), wxStringList("wiztest.cpp", 0)); GenerateSample("RotateVC", "rotate", dir + wxString("/samples/rotate"), wxStringList("rotate.cpp", 0)); + GenerateSample("ExecVC", "exec", dir + wxString("/samples/exec"), wxStringList("exec.cpp", 0)); + GenerateSample("FontVC", "font", dir + wxString("/samples/font"), wxStringList("font.cpp", 0)); + GenerateSample("MenuVC", "menu", dir + wxString("/samples/menu"), wxStringList("menu.cpp", 0)); //// Demos -- 2.45.2