Commit Graph

10163 Commits

Author SHA1 Message Date
Vadim Zeitlin
b1c673942d moved Write(const wxString&) to .cpp files as they're going to be changed again soon; removed unnecessary casts
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45043 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-24 14:42:29 +00:00
Julian Smart
bd3f83f763 Test for encoding conversion success in wxFile::Write to avoid crash
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45042 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-24 10:21:48 +00:00
Julian Smart
f3140390f9 Test for encoding conversion success in wxFFile::Write to avoid crash
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45041 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-24 10:20:14 +00:00
Vadim Zeitlin
c961c0cfca fixed compilation for Windows compilers now after last change: replaced conversions to ushort and uint with a conversion to wint_t but do it for (non-Apple) gcc only
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45037 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-23 15:16:08 +00:00
Vadim Zeitlin
2a686bd333 added conversions to unsigned short: this fixes compilation for some platforms where wint_t is ushort (mingw32)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45036 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-23 15:00:12 +00:00
Vadim Zeitlin
47a8a4d5cc make IsEnabled() return false even if the window parent, and not the window itself, is disabled and added IsThisEnabled() implementing the old IsEnabled() behaviour; also significantly simplify the window state management code in all ports by factoring out the common parts in wxWindowBase
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45031 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-23 14:01:53 +00:00
Vadim Zeitlin
1a81eea8d4 also removed WXDLLIMPEXP_BASE from friend declaration of wxCStrData
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45029 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-23 12:27:51 +00:00
Václav Slavík
90adbcca75 wxLogGeneric usage compilation fix
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45028 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-23 09:31:07 +00:00
Vadim Zeitlin
bb650010c8 removed dll export declaration for wxCStrData: it's unneeded because the class is fully inline and creates problems with mingw32 3.4.2 which wanrs about functions defined locally after being declared with dll linkage and then fails to link wxBase DLL
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45027 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-23 01:45:17 +00:00
Vadim Zeitlin
ccd4deab6b fix DLL build with MSVC: it wasn't happy that some functions of a template class were not implemented, so get rid of FromCStrData() and implement its logic in one of the 2 derived classes ctors instead
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45026 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-23 00:04:15 +00:00
Václav Slavík
d18c8d3d94 reimplemented wx[W]CharBuffer using templates
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45025 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-22 23:31:08 +00:00
Vadim Zeitlin
17709275f9 added explicit conversion of wxCStrData to const void * to resolve ambiguity between const char * and const unsigned char * conversion when passing s.c_str() to e.g. file output functions
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45024 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-22 19:24:41 +00:00
Vadim Zeitlin
98c4eb3910 remove wxWINT_T_IS_TYPEDEF as it seems wint_t is always a typedef (although it can be either unsigned short or unsigned int or possibly something else)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45023 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-22 19:13:50 +00:00
Vadim Zeitlin
fb52c2b671 added macros to avoid code repetition when defining comparison operators; use them to replace existing operators in wxUniChar and wxUniCharRef (fixing bug in the operator== and != of the latter) and added comparison operators for const wxChar * and wxCStrData which are needed to compile existing code comparing pointers with s.c_str()
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45019 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-22 18:03:02 +00:00
Vadim Zeitlin
dbea442a15 added wxCStrData conversion to const unsigned char * too
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45018 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-22 17:28:00 +00:00
Vadim Zeitlin
b77afb41f3 add operator+=(unsigned char) for backwards compatibility and because we generally handle both signed and unisnged chars everywhere; added wxString(const wxCStrData&, size_t) ctor to resolve ambiguity between wxString(const char *, size_t) and wxString(const unsigned char *, size_t) and wxString(const wxString&, size_t) to resolved embiguity for string parameter of ctor
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45017 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-22 17:26:09 +00:00
Vadim Zeitlin
bd72306dc8 added conversion to unsigned int too: this is needed to be able to pass s[n] to standard toxxx/isyyy() functions under Windows when _MBCS is defined as they're mapped to _mbzzz(unsigned int) in this case
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45016 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-22 15:24:28 +00:00
Vadim Zeitlin
6346588525 removed Matches(const wxChar *, int=0) overload: it creates ambiguity with Matches(const wxString&, int=0) one when re.Matches(s.c_str()) is called now that c_str() returns wxCStrData which can be converted to both const wxChar * and wxString
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45015 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-22 15:20:50 +00:00
Paul Cornett
83dcd78142 revert use of AllocExclusive
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45003 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-21 04:29:57 +00:00
Vadim Zeitlin
05cc594ad2 removed extraneous comma at the end of wxGridDirection enum
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44991 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-20 21:06:06 +00:00
Vadim Zeitlin
a7f8eb6d0f removed extraneous semicolons
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44990 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-20 21:05:09 +00:00
Václav Slavík
9f1b1b78e1 added wxUniChar <-> unsigned char conversion
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44976 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-20 15:49:45 +00:00
Václav Slavík
76046d7390 compilation fix after STL fixes if 2.8 compatibility is enabled
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44967 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-20 08:14:06 +00:00
Vadim Zeitlin
d642a7226f deprecate wxTR_EXTENDED and remove it from the docs
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44964 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-19 20:35:49 +00:00
Václav Slavík
992527a573 fixed compilation if wxUSE_STL=1
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44959 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-19 19:23:33 +00:00
Václav Slavík
6580df1b72 fixed missing ; after class declaration
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44947 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-19 17:27:08 +00:00
Václav Slavík
c7554da8a9 tagged IsEmpty(), Strlen() and Stricmp() global functions as deprecated, 2.8-compat (they're documented as compatibility only)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44945 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-19 16:47:10 +00:00
Václav Slavík
dbecee02ed use wxUin32 for wxUniChar::value_type: we need 32bit for it regardless of the platform
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44941 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-19 16:22:11 +00:00
Václav Slavík
d1b7ed6792 wxUniChar::unicode_type -> value_type
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44940 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-19 16:17:37 +00:00
Václav Slavík
e3f6cbd99c split wxchar.h into several smaller headers
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44927 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-19 14:45:38 +00:00
Vadim Zeitlin
c8eb817283 added wxString::operator=(const wxCStrData&) to make it possible to compile code like "wxString s = s.c_str() + 1" again (also fixes wxGTK1 compilation)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44925 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-19 13:19:56 +00:00
Vadim Zeitlin
414b7b4016 added ctor for wxChar/WCharBuffer from wxCStrData in ANSI/Unicode build to make it possible to compile code like "wxCharBuffer buf = s.c_str()" again (in particular, fixes wxGTK1 compilation)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44924 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-19 13:18:02 +00:00
Václav Slavík
e229d82e0e fixed wxDataViewCtrl compilation with DigitalMars
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44923 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-19 13:03:02 +00:00
Vadim Zeitlin
8cdd754651 initialize m_maxFD to avoid passing invalid values to select()
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44918 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-19 02:27:34 +00:00
Vadim Zeitlin
d8b48f4de9 compilation fix after wxUniChar changes
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44912 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-19 01:21:07 +00:00
Vadim Zeitlin
551fe9528a added wxXmString ctor from wxCStrData to fix compilation errors after c_str() changes
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44910 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-19 00:53:06 +00:00
Vadim Zeitlin
c1df0a3b58 add overloads of wxString and wxCStrData::operator[] taking long, for consistency with std::string classes
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44908 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-19 00:06:17 +00:00
Vadim Zeitlin
acf0c9acfc added wxCStrData::operator+(long) overload (this fixes some compilation errors in wxGTK1 and probably not only there)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44907 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-18 23:59:09 +00:00
Vadim Zeitlin
07d02e9ee0 fixed all the other ports broken by controls labels in wxToolBar patch commit
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44906 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-18 23:57:20 +00:00
Vadim Zeitlin
2a015b8917 replaced c_str() with mb_str() to fix compilation after c_str() changes
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44905 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-18 23:52:35 +00:00
Vadim Zeitlin
cdb11cb99e added labels support for toolbar controls for wxMac and wxMSW (modified patch 1613603)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44903 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-18 23:13:18 +00:00
Vadim Zeitlin
466e87bd8c use wxStandardPaths and wxFileName in wxFileConfig resulting in big code simplification and cleanup but also in change of the default file locations under Windows (replaces patch 1620492)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44893 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-18 17:34:11 +00:00
Vadim Zeitlin
e3b81044ee wxDC::StretchBlit() for wxMac and wxMSW (patch 1611973)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44892 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-18 15:32:27 +00:00
Vadim Zeitlin
abbb59e8eb added wxJoin and wxSplit functions (modified patch 1638950)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44890 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-18 14:43:41 +00:00
Vadim Zeitlin
2d76b6d8c3 implemented wxMemoryInputStream::CanRead() and added tests for CanRead() to all stream tests
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44872 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-17 15:38:09 +00:00
Vadim Zeitlin
764471557e added wxMemoryInputStream(wxInputStream&, size_t) ctor (modified patch 1680108)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44871 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-17 15:28:28 +00:00
Vadim Zeitlin
67393addd8 corrected WX_DEFINE_VARARG_FUNC_NOP usage
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44869 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-17 15:00:51 +00:00
Václav Slavík
c9f7896861 first phase of transition to unified Unicode build:
1. changed c_str() to return wxCStrData (implicitly convertible to wxChar*)
2. added template type-safe wrappers for vararg functions
3. added wxUniChar class representing single Unicode character
4. changed wxString::operator[] and wxString::iterator to return wxUniChar


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44865 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-17 10:26:10 +00:00
Václav Slavík
f8087c0d2c changed wxPlatform implicit conversion to string to return const reference to wxString instead of const wxString object
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44860 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-16 20:10:17 +00:00
Vadim Zeitlin
72fa3e8a21 make wxFDIOHandler dtor virtual, it's meant to be used as a base class
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44856 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-16 16:17:04 +00:00