OS/2 updates
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@3219 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -107,10 +107,15 @@ public:
|
|||||||
typedef void (wxEvtHandler::*wxSpinEventFunction)(wxSpinEvent&);
|
typedef void (wxEvtHandler::*wxSpinEventFunction)(wxSpinEvent&);
|
||||||
|
|
||||||
// macros for handling spin events
|
// macros for handling spin events
|
||||||
|
#ifndef EVT_SPIN_UP
|
||||||
#define EVT_SPIN_UP(id, func) { wxEVT_SCROLL_LINEUP, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxSpinEventFunction) & func },
|
#define EVT_SPIN_UP(id, func) { wxEVT_SCROLL_LINEUP, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxSpinEventFunction) & func },
|
||||||
|
#endif
|
||||||
|
#ifndef EVT_SPIN_DOWN
|
||||||
#define EVT_SPIN_DOWN(id, func) { wxEVT_SCROLL_LINEDOWN, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxSpinEventFunction) & func },
|
#define EVT_SPIN_DOWN(id, func) { wxEVT_SCROLL_LINEDOWN, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxSpinEventFunction) & func },
|
||||||
|
#endif
|
||||||
|
#ifndef EVT_SPIN
|
||||||
#define EVT_SPIN(id, func) { wxEVT_SCROLL_THUMBTRACK, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxSpinEventFunction) & func },
|
#define EVT_SPIN(id, func) { wxEVT_SCROLL_THUMBTRACK, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxSpinEventFunction) & func },
|
||||||
|
#endif
|
||||||
|
|
||||||
#endif // wxUSE_SPINBTN
|
#endif // wxUSE_SPINBTN
|
||||||
|
|
||||||
|
@@ -41,7 +41,8 @@ enum wxTextFileType
|
|||||||
wxTextFileType_None, // incomplete (the last line of the file only)
|
wxTextFileType_None, // incomplete (the last line of the file only)
|
||||||
wxTextFileType_Unix, // line is terminated with 'LF' = 0xA = 10 = '\n'
|
wxTextFileType_Unix, // line is terminated with 'LF' = 0xA = 10 = '\n'
|
||||||
wxTextFileType_Dos, // 'CR' 'LF'
|
wxTextFileType_Dos, // 'CR' 'LF'
|
||||||
wxTextFileType_Mac // 'CR' = 0xD = 13 = '\r'
|
wxTextFileType_Mac, // 'CR' = 0xD = 13 = '\r'
|
||||||
|
wxTextFileType_Os2 // 'CR' 'LF'
|
||||||
};
|
};
|
||||||
|
|
||||||
WX_DEFINE_ARRAY(wxTextFileType, ArrayFileType);
|
WX_DEFINE_ARRAY(wxTextFileType, ArrayFileType);
|
||||||
|
@@ -41,7 +41,7 @@ class WXDLLEXPORT wxProcess;
|
|||||||
class WXDLLEXPORT wxFrame;
|
class WXDLLEXPORT wxFrame;
|
||||||
|
|
||||||
// FIXME should use wxStricmp() instead
|
// FIXME should use wxStricmp() instead
|
||||||
#ifdef __GNUWIN32__
|
#if defined(__GNUWIN32__)
|
||||||
#define stricmp strcasecmp
|
#define stricmp strcasecmp
|
||||||
#define strnicmp strncasecmp
|
#define strnicmp strncasecmp
|
||||||
#endif
|
#endif
|
||||||
|
@@ -59,12 +59,18 @@ IMPLEMENT_DYNAMIC_CLASS(wxPNGHandler,wxImageHandler)
|
|||||||
|
|
||||||
#if wxUSE_STREAMS
|
#if wxUSE_STREAMS
|
||||||
|
|
||||||
static void _PNG_stream_reader( png_structp png_ptr, png_bytep data, png_size_t length )
|
#if defined(__VISAGECPP__)
|
||||||
|
#define LINKAGEMODE _Optlink
|
||||||
|
#else
|
||||||
|
#define LINKAGEMODE
|
||||||
|
#endif
|
||||||
|
|
||||||
|
static void LINKAGEMODE _PNG_stream_reader( png_structp png_ptr, png_bytep data, png_size_t length )
|
||||||
{
|
{
|
||||||
((wxInputStream*) png_get_io_ptr( png_ptr )) -> Read(data, length);
|
((wxInputStream*) png_get_io_ptr( png_ptr )) -> Read(data, length);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void _PNG_stream_writer( png_structp png_ptr, png_bytep data, png_size_t length )
|
static void LINKAGEMODE _PNG_stream_writer( png_structp png_ptr, png_bytep data, png_size_t length )
|
||||||
{
|
{
|
||||||
((wxOutputStream*) png_get_io_ptr( png_ptr )) -> Write(data, length);
|
((wxOutputStream*) png_get_io_ptr( png_ptr )) -> Write(data, length);
|
||||||
}
|
}
|
||||||
|
@@ -53,6 +53,8 @@ const wxTextFileType wxTextFile::typeDefault =
|
|||||||
wxTextFileType_Unix;
|
wxTextFileType_Unix;
|
||||||
#elif defined(__WXMAC__)
|
#elif defined(__WXMAC__)
|
||||||
wxTextFileType_Mac;
|
wxTextFileType_Mac;
|
||||||
|
#elif defined(__WXPM__)
|
||||||
|
wxTextFileType_Os2;
|
||||||
#else
|
#else
|
||||||
wxTextFileType_None;
|
wxTextFileType_None;
|
||||||
#error "wxTextFile: unsupported platform."
|
#error "wxTextFile: unsupported platform."
|
||||||
|
@@ -157,7 +157,7 @@ bool wxGetLocalTime(long *timeZone, int *dstObserved)
|
|||||||
*dstObserved = tp->tm_isdst;
|
*dstObserved = tp->tm_isdst;
|
||||||
#else
|
#else
|
||||||
|
|
||||||
#if (((defined(__SYSV__) && !defined(__HPUX__)) || defined(__MSDOS__) || defined(__WXMSW__)) \
|
#if (((defined(__SYSV__) && !defined(__HPUX__)) || defined(__MSDOS__) || defined(__WXMSW__) || defined(__WXPM__)) \
|
||||||
&& !defined(__GNUWIN32__) && !defined(__MWERKS__) )
|
&& !defined(__GNUWIN32__) && !defined(__MWERKS__) )
|
||||||
# if defined(__BORLANDC__)
|
# if defined(__BORLANDC__)
|
||||||
/* Borland uses underscores */
|
/* Borland uses underscores */
|
||||||
@@ -166,6 +166,9 @@ bool wxGetLocalTime(long *timeZone, int *dstObserved)
|
|||||||
# elif defined(__SALFORDC__)
|
# elif defined(__SALFORDC__)
|
||||||
*timeZone = _timezone;
|
*timeZone = _timezone;
|
||||||
*dstObserved = daylight;
|
*dstObserved = daylight;
|
||||||
|
# elif defined(__VISAGECPP__)
|
||||||
|
*timeZone = _timezone;
|
||||||
|
*dstObserved = daylight;
|
||||||
# else
|
# else
|
||||||
*timeZone = timezone;
|
*timeZone = timezone;
|
||||||
*dstObserved = daylight;
|
*dstObserved = daylight;
|
||||||
|
@@ -407,6 +407,11 @@ void wxTextOutputStream::WriteString(const wxString& string)
|
|||||||
#elif defined(__WXMAC__)
|
#elif defined(__WXMAC__)
|
||||||
c = _T('\r');
|
c = _T('\r');
|
||||||
m_output->Write( (const void*)(&c), sizeof(wxChar) );
|
m_output->Write( (const void*)(&c), sizeof(wxChar) );
|
||||||
|
#elif defined(__OS2__)
|
||||||
|
c = _T('\r');
|
||||||
|
m_output->Write( (const void*)(&c), sizeof(wxChar) );
|
||||||
|
c = _T('\n');
|
||||||
|
m_output->Write( (const void*)(&c), sizeof(wxChar) );
|
||||||
#else
|
#else
|
||||||
#error "wxTextOutputStream: unsupported platform."
|
#error "wxTextOutputStream: unsupported platform."
|
||||||
#endif
|
#endif
|
||||||
|
@@ -177,6 +177,10 @@ extern "C"
|
|||||||
#endif
|
#endif
|
||||||
#endif /* __WXMSW__ */
|
#endif /* __WXMSW__ */
|
||||||
|
|
||||||
|
#ifdef __WXPM__
|
||||||
|
#define strcasecmp stricmp
|
||||||
|
#define strncasecmp strnicmp
|
||||||
|
#endif
|
||||||
|
|
||||||
wxChar *
|
wxChar *
|
||||||
copystring (const wxChar *s)
|
copystring (const wxChar *s)
|
||||||
|
Reference in New Issue
Block a user