1. wxTimer::Start() returns bool in wxGTK too (other minor corrections
to this class, such as "const" addition, Notify() is = 0 now...) 2. wxGTK::wxTextCtrl::Delete renamed to Clear for consistency 3. wx/wx_prec.h now includes wx/setup.h even if !wxUSE_PRECOMP because otherwise (recently added) tests "#if wxUSE_IOSTREAMH" donb't work. 4. Other compilation fixes for wxGTK (now it compiles again) git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@819 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -86,7 +86,7 @@ class wxTextCtrl: public wxControl, public streambuf
|
||||
void Cut();
|
||||
void Copy();
|
||||
void Paste();
|
||||
void Delete();
|
||||
void Clear();
|
||||
|
||||
void OnChar( wxKeyEvent &event );
|
||||
|
||||
|
@@ -31,23 +31,26 @@ class wxTimer;
|
||||
|
||||
class wxTimer: public wxObject
|
||||
{
|
||||
DECLARE_DYNAMIC_CLASS(wxTimer)
|
||||
public:
|
||||
wxTimer();
|
||||
~wxTimer();
|
||||
|
||||
public:
|
||||
int Interval() const { return m_time; }
|
||||
|
||||
wxTimer(void);
|
||||
~wxTimer(void);
|
||||
int Interval(void);
|
||||
bool OneShot(void);
|
||||
virtual void Notify(void);
|
||||
void Start( int millisecs = -1, bool oneShot = FALSE );
|
||||
void Stop(void);
|
||||
|
||||
private:
|
||||
|
||||
bool OneShot() const { return m_oneShot; }
|
||||
|
||||
virtual bool Start( int millisecs = -1, bool oneShot = FALSE );
|
||||
virtual void Stop();
|
||||
|
||||
virtual void Notify() = 0; // override this
|
||||
|
||||
protected:
|
||||
int m_tag;
|
||||
int m_time;
|
||||
bool m_oneShot;
|
||||
|
||||
private:
|
||||
DECLARE_ABSTRACT_CLASS(wxTimer)
|
||||
};
|
||||
|
||||
#endif // __GTKTIMERH__
|
||||
|
@@ -86,7 +86,7 @@ class wxTextCtrl: public wxControl, public streambuf
|
||||
void Cut();
|
||||
void Copy();
|
||||
void Paste();
|
||||
void Delete();
|
||||
void Clear();
|
||||
|
||||
void OnChar( wxKeyEvent &event );
|
||||
|
||||
|
@@ -31,23 +31,26 @@ class wxTimer;
|
||||
|
||||
class wxTimer: public wxObject
|
||||
{
|
||||
DECLARE_DYNAMIC_CLASS(wxTimer)
|
||||
public:
|
||||
wxTimer();
|
||||
~wxTimer();
|
||||
|
||||
public:
|
||||
int Interval() const { return m_time; }
|
||||
|
||||
wxTimer(void);
|
||||
~wxTimer(void);
|
||||
int Interval(void);
|
||||
bool OneShot(void);
|
||||
virtual void Notify(void);
|
||||
void Start( int millisecs = -1, bool oneShot = FALSE );
|
||||
void Stop(void);
|
||||
|
||||
private:
|
||||
|
||||
bool OneShot() const { return m_oneShot; }
|
||||
|
||||
virtual bool Start( int millisecs = -1, bool oneShot = FALSE );
|
||||
virtual void Stop();
|
||||
|
||||
virtual void Notify() = 0; // override this
|
||||
|
||||
protected:
|
||||
int m_tag;
|
||||
int m_time;
|
||||
bool m_oneShot;
|
||||
|
||||
private:
|
||||
DECLARE_ABSTRACT_CLASS(wxTimer)
|
||||
};
|
||||
|
||||
#endif // __GTKTIMERH__
|
||||
|
@@ -1,18 +1,26 @@
|
||||
#ifndef _WX_ICON_H_BASE_
|
||||
#define _WX_ICON_H_BASE_
|
||||
|
||||
// this is for Unix (i.e. now for anything other than MSW)
|
||||
#undef wxICON
|
||||
#define wxICON(icon_name) wxIcon(icon_name##_xpm)
|
||||
|
||||
#if defined(__WXMSW__)
|
||||
#include "wx/msw/icon.h"
|
||||
// under Windows, icon name is the ressource id (string)
|
||||
#undef wxICON
|
||||
#define wxICON(icon_name) wxIcon(#icon_name)
|
||||
|
||||
#include "wx/msw/icon.h"
|
||||
#elif defined(__WXMOTIF__)
|
||||
#include "wx/motif/icon.h"
|
||||
#include "wx/motif/icon.h"
|
||||
#elif defined(__WXGTK__)
|
||||
#include "wx/gtk/icon.h"
|
||||
#include "wx/gtk/icon.h"
|
||||
#elif defined(__WXQT__)
|
||||
#include "wx/qt/icon.h"
|
||||
#include "wx/qt/icon.h"
|
||||
#elif defined(__WXMAC__)
|
||||
#include "wx/mac/icon.h"
|
||||
#include "wx/mac/icon.h"
|
||||
#elif defined(__WXSTUBS__)
|
||||
#include "wx/stubs/icon.h"
|
||||
#include "wx/stubs/icon.h"
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
@@ -188,6 +188,8 @@ protected:
|
||||
ostream *m_ostr;
|
||||
};
|
||||
|
||||
#ifndef wxUSE_NOGUI
|
||||
|
||||
// log everything to a text window (GUI only of course)
|
||||
class WXDLLEXPORT wxLogTextCtrl : public wxLogStream
|
||||
{
|
||||
@@ -269,6 +271,8 @@ private:
|
||||
wxLogFrame *m_pLogFrame; // the log frame
|
||||
};
|
||||
|
||||
#endif // wxUSE_NOGUI
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// /dev/null log target: suppress logging until this object goes out of scope
|
||||
// ----------------------------------------------------------------------------
|
||||
|
@@ -18,27 +18,35 @@
|
||||
|
||||
#include "wx/object.h"
|
||||
|
||||
class WXDLLEXPORT wxTimer: public wxObject
|
||||
class WXDLLEXPORT wxTimer : public wxObject
|
||||
{
|
||||
DECLARE_DYNAMIC_CLASS(wxTimer)
|
||||
public:
|
||||
wxTimer();
|
||||
~wxTimer();
|
||||
|
||||
public:
|
||||
bool oneShot ;
|
||||
int milli ;
|
||||
int lastMilli ;
|
||||
virtual bool Start(int milliseconds = -1,
|
||||
bool one_shot = FALSE); // Start timer
|
||||
virtual void Stop(); // Stop timer
|
||||
|
||||
long id;
|
||||
public:
|
||||
wxTimer(void);
|
||||
~wxTimer(void);
|
||||
virtual bool Start(int milliseconds = -1,bool one_shot = FALSE); // Start timer
|
||||
virtual void Stop(void); // Stop timer
|
||||
virtual void Notify(void) = 0; // Override this member
|
||||
inline int Interval(void) { return milli ; }; // Returns the current interval time (0 if stop)
|
||||
virtual void Notify() = 0; // Override this member
|
||||
|
||||
// Returns the current interval time (0 if stop)
|
||||
int Interval() const { return milli; };
|
||||
bool OneShot() const { return oneShot; }
|
||||
|
||||
protected:
|
||||
bool oneShot ;
|
||||
int milli ;
|
||||
int lastMilli ;
|
||||
|
||||
long id;
|
||||
|
||||
private:
|
||||
DECLARE_ABSTRACT_CLASS(wxTimer)
|
||||
};
|
||||
|
||||
// Timer functions (milliseconds)
|
||||
void WXDLLEXPORT wxStartTimer(void);
|
||||
void WXDLLEXPORT wxStartTimer();
|
||||
// Gets time since last wxStartTimer or wxGetElapsedTime
|
||||
long WXDLLEXPORT wxGetElapsedTime(bool resetTimer = TRUE);
|
||||
|
||||
@@ -46,7 +54,7 @@ long WXDLLEXPORT wxGetElapsedTime(bool resetTimer = TRUE);
|
||||
bool WXDLLEXPORT wxGetLocalTime(long *timeZone, int *dstObserved);
|
||||
|
||||
// Get number of seconds since 00:00:00 GMT, Jan 1st 1970.
|
||||
long WXDLLEXPORT wxGetCurrentTime(void);
|
||||
long WXDLLEXPORT wxGetCurrentTime();
|
||||
|
||||
#endif
|
||||
// _WX_TIMERH_
|
||||
|
@@ -6,7 +6,7 @@
|
||||
// Created: ??/??/98
|
||||
// RCS-ID: $Id$
|
||||
// Copyright: (c) AUTHOR
|
||||
// Licence: wxWindows licence
|
||||
// Licence: wxWindows licence
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef _WX_TIMER_H_
|
||||
@@ -20,22 +20,29 @@
|
||||
|
||||
class WXDLLEXPORT wxTimer: public wxObject
|
||||
{
|
||||
DECLARE_DYNAMIC_CLASS(wxTimer)
|
||||
public:
|
||||
wxTimer();
|
||||
~wxTimer();
|
||||
|
||||
public:
|
||||
wxTimer();
|
||||
~wxTimer();
|
||||
virtual bool Start(int milliseconds = -1,bool one_shot = FALSE); // Start timer
|
||||
virtual void Stop(); // Stop timer
|
||||
virtual void Notify() = 0; // Override this member
|
||||
inline int Interval() { return m_milli ; }; // Returns the current interval time (0 if stop)
|
||||
virtual bool Start(int milliseconds = -1,
|
||||
bool one_shot = FALSE); // Start timer
|
||||
virtual void Stop(); // Stop timer
|
||||
|
||||
virtual void Notify() = 0; // Override this member
|
||||
|
||||
// Returns the current interval time (0 if stop)
|
||||
int Interval() const { return milli; };
|
||||
bool OneShot() const { return oneShot; }
|
||||
|
||||
protected:
|
||||
bool m_oneShot ;
|
||||
int m_milli ;
|
||||
int m_lastMilli ;
|
||||
long m_id;
|
||||
bool oneShot ;
|
||||
int milli ;
|
||||
int lastMilli ;
|
||||
|
||||
long id;
|
||||
|
||||
private:
|
||||
DECLARE_ABSTRACT_CLASS(wxTimer)
|
||||
};
|
||||
|
||||
/* Note: these are implemented in common/timercmn.cpp, so need to implement them separately.
|
||||
|
@@ -20,22 +20,29 @@
|
||||
|
||||
class WXDLLEXPORT wxTimer: public wxObject
|
||||
{
|
||||
DECLARE_DYNAMIC_CLASS(wxTimer)
|
||||
public:
|
||||
wxTimer();
|
||||
~wxTimer();
|
||||
|
||||
public:
|
||||
wxTimer();
|
||||
~wxTimer();
|
||||
virtual bool Start(int milliseconds = -1,bool one_shot = FALSE); // Start timer
|
||||
virtual void Stop(); // Stop timer
|
||||
virtual void Notify() = 0; // Override this member
|
||||
inline int Interval() { return m_milli ; }; // Returns the current interval time (0 if stop)
|
||||
virtual bool Start(int milliseconds = -1,
|
||||
bool one_shot = FALSE); // Start timer
|
||||
virtual void Stop(); // Stop timer
|
||||
|
||||
virtual void Notify() = 0; // Override this member
|
||||
|
||||
// Returns the current interval time (0 if stop)
|
||||
int Interval() const { return milli; };
|
||||
bool OneShot() const { return oneShot; }
|
||||
|
||||
protected:
|
||||
bool m_oneShot ;
|
||||
int m_milli ;
|
||||
int m_lastMilli ;
|
||||
long m_id;
|
||||
bool oneShot ;
|
||||
int milli ;
|
||||
int lastMilli ;
|
||||
|
||||
long id;
|
||||
|
||||
private:
|
||||
DECLARE_ABSTRACT_CLASS(wxTimer)
|
||||
};
|
||||
|
||||
/* Note: these are implemented in common/timercmn.cpp, so need to implement them separately.
|
||||
|
@@ -6,7 +6,7 @@
|
||||
#elif defined(__WXMOTIF__)
|
||||
#include "wx/generic/treectrl.h"
|
||||
#elif defined(__WXGTK__)
|
||||
#include "wx/gtk/treectrl.h"
|
||||
#include "wx/generic/treectrl.h"
|
||||
#elif defined(__WXQT__)
|
||||
#include "wx/qt/treectrl.h"
|
||||
#elif defined(__WXMAC__)
|
||||
|
@@ -57,5 +57,8 @@
|
||||
#undef FindResource
|
||||
#endif
|
||||
|
||||
#else
|
||||
// always include this file (under Unix it's generated by configure)
|
||||
#include "wx/setup.h"
|
||||
#endif
|
||||
|
||||
|
Reference in New Issue
Block a user