diff options
| -rw-r--r-- | doc/html/ntqeventloop.html | 3 | ||||
| -rw-r--r-- | doc/html/qeventloop-h.html | 9 | ||||
| -rw-r--r-- | src/kernel/ntqeventloop.h | 9 | ||||
| -rw-r--r-- | src/kernel/qclipboard_x11.cpp | 6 | ||||
| -rw-r--r-- | src/kernel/qeventloop.cpp | 1 | ||||
| -rw-r--r-- | src/kernel/qeventloop_x11.cpp | 10 | ||||
| -rw-r--r-- | src/kernel/qeventloop_x11_glib.cpp | 8 | 
7 files changed, 23 insertions, 23 deletions
| diff --git a/doc/html/ntqeventloop.html b/doc/html/ntqeventloop.html index 2fe9c05ac..8b139b8a5 100644 --- a/doc/html/ntqeventloop.html +++ b/doc/html/ntqeventloop.html @@ -41,7 +41,7 @@ body { background: #ffffff; color: black; }  <ul>  <li class=fn><a href="#TQEventLoop"><b>TQEventLoop</b></a> ( TQObject * parent = 0, const char * name = 0 )</li>  <li class=fn><a href="#~TQEventLoop"><b>~TQEventLoop</b></a> ()</li> -<li class=fn>enum <a href="#ProcessEvents-enum"><b>ProcessEvents</b></a> { AllEvents = 0x00, ExcludeUserInput = 0x01, ExcludeSocketNotifiers = 0x02, WaitForMore = 0x04 }</li> +<li class=fn>enum <a href="#ProcessEvents-enum"><b>ProcessEvents</b></a> { AllEvents = 0x00, ExcludeUserInput = 0x01, ExcludeSocketNotifiers = 0x02, WaitForMore = 0x04, ExcludeTimers = 0x08 }</li>  <li class=fn>typedef uint <a href="#ProcessEventsFlags"><b>ProcessEventsFlags</b></a></li>  <li class=fn>void <a href="#processEvents"><b>processEvents</b></a> ( ProcessEventsFlags flags, int maxTime )</li>  <li class=fn>virtual bool <a href="#processEvents-2"><b>processEvents</b></a> ( ProcessEventsFlags flags )</li> @@ -97,6 +97,7 @@ it before you create the TQApplication object.  events.  <li><tt>TQEventLoop::WaitForMore</tt> - Wait for events if no pending events  are available. +<li><tt>TQEventLoop::ExcludeTimers</tt> - Do not process timer events.  </ul><p> <p>See also <a href="#processEvents">processEvents</a>().  <h3 class=fn><a name="ProcessEventsFlags"></a>TQEventLoop::ProcessEventsFlags</h3>  diff --git a/doc/html/qeventloop-h.html b/doc/html/qeventloop-h.html index 7ddf52e36..a74e35b58 100644 --- a/doc/html/qeventloop-h.html +++ b/doc/html/qeventloop-h.html @@ -102,10 +102,11 @@ public:      ~TQEventLoop();      enum ProcessEvents { -	AllEvents		= 0x00, -	ExcludeUserInput	= 0x01, -	ExcludeSocketNotifiers	= 0x02, -	WaitForMore		= 0x04 +	AllEvents              = 0x00, +	ExcludeUserInput       = 0x01, +	ExcludeSocketNotifiers = 0x02, +	WaitForMore            = 0x04, +	ExcludeTimers          = 0x08      };      typedef uint ProcessEventsFlags; diff --git a/src/kernel/ntqeventloop.h b/src/kernel/ntqeventloop.h index deca8d061..99c4ed499 100644 --- a/src/kernel/ntqeventloop.h +++ b/src/kernel/ntqeventloop.h @@ -73,10 +73,11 @@ public:      ~TQEventLoop();      enum ProcessEvents { -	AllEvents		= 0x00, -	ExcludeUserInput	= 0x01, -	ExcludeSocketNotifiers	= 0x02, -	WaitForMore		= 0x04 +	AllEvents              = 0x00, +	ExcludeUserInput       = 0x01, +	ExcludeSocketNotifiers = 0x02, +	WaitForMore            = 0x04, +	ExcludeTimers          = 0x08      };      typedef uint ProcessEventsFlags; diff --git a/src/kernel/qclipboard_x11.cpp b/src/kernel/qclipboard_x11.cpp index d0571fc5a..ae5e093a8 100644 --- a/src/kernel/qclipboard_x11.cpp +++ b/src/kernel/qclipboard_x11.cpp @@ -502,10 +502,10 @@ bool qt_xclb_wait_for_event( Display *dpy, Window win, int type, XEvent *event,              if ( started > now )			// crossed midnight                  started = now; -            // 0x08 == ExcludeTimers for X11 only -            tqApp->eventLoop()->processEvents( TQEventLoop::ExcludeUserInput | +            tqApp->eventLoop()->processEvents(TQEventLoop::ExcludeUserInput |                                                TQEventLoop::ExcludeSocketNotifiers | -                                              TQEventLoop::WaitForMore | 0x08 ); +                                              TQEventLoop::WaitForMore | +                                              TQEventLoop::ExcludeTimers);              if ( has_captured_event ) {                  waiting_for_data = FALSE; diff --git a/src/kernel/qeventloop.cpp b/src/kernel/qeventloop.cpp index 402894f2a..b52f5a605 100644 --- a/src/kernel/qeventloop.cpp +++ b/src/kernel/qeventloop.cpp @@ -83,6 +83,7 @@             events.      \value WaitForMore - Wait for events if no pending events             are available. +    \value ExcludeTimers - Do not process X11 timer events.      \sa processEvents()  */ diff --git a/src/kernel/qeventloop_x11.cpp b/src/kernel/qeventloop_x11.cpp index 1ba3b21df..163f8d771 100644 --- a/src/kernel/qeventloop_x11.cpp +++ b/src/kernel/qeventloop_x11.cpp @@ -206,8 +206,7 @@ bool TQEventLoop::processEvents( ProcessEventsFlags flags )      TQApplication::sendPostedEvents(); -    const uint exclude_all = ExcludeSocketNotifiers | 0x08; -    // 0x08 == ExcludeTimers for X11 only +    const uint exclude_all = ExcludeSocketNotifiers | ExcludeTimers;      if ( nevents > 0 && ( flags & exclude_all ) == exclude_all &&  	 ( flags & WaitForMore ) ) {  	return TRUE; @@ -221,8 +220,8 @@ bool TQEventLoop::processEvents( ProcessEventsFlags flags )      // return the maximum time we can wait for an event.      static timeval zerotm;      timeval *tm = 0; -    if ( ! ( flags & 0x08 ) ) {			// 0x08 == ExcludeTimers for X11 only -	tm = qt_wait_timer();			// wait for timer or X event +    if ( ! ( flags & ExcludeTimers ) ) { +	tm = qt_wait_timer();			// wait for TQt timers  	if ( !canWait ) {  	    if ( !tm )  		tm = &zerotm; @@ -391,8 +390,7 @@ bool TQEventLoop::processEvents( ProcessEventsFlags flags )      }      // activate timers -    if ( ! ( flags & 0x08 ) ) { -	// 0x08 == ExcludeTimers for X11 only +    if ( ! ( flags & ExcludeTimers ) ) {  	nevents += activateTimers();      } diff --git a/src/kernel/qeventloop_x11_glib.cpp b/src/kernel/qeventloop_x11_glib.cpp index 695232c2e..529ea08b2 100644 --- a/src/kernel/qeventloop_x11_glib.cpp +++ b/src/kernel/qeventloop_x11_glib.cpp @@ -376,8 +376,7 @@ bool TQEventLoop::processX11Events()  	TQApplication::sendPostedEvents(); -	const uint exclude_all = ExcludeSocketNotifiers | 0x08; -	// 0x08 == ExcludeTimers for X11 only +	const uint exclude_all = ExcludeSocketNotifiers | ExcludeTimers;  	if ( nevents > 0 && ( flags & exclude_all ) == exclude_all && ( flags & WaitForMore ) ) {  		return TRUE;  	} @@ -407,7 +406,7 @@ bool TQEventLoop::gsourcePrepare(GSource *gs, int * timeout)  	// return the maximum time we can wait for an event.  	static timeval zerotm;  	timeval *tm = 0; -	if ( ! ( flags & 0x08 ) ) {				// 0x08 == ExcludeTimers for X11 only +	if ( ! ( flags & ExcludeTimers ) ) {  		if (TQApplication::isGuiThread()) {  			tm = qt_wait_timer();				// wait for TQt timers  			if ( !canWait ) { @@ -605,8 +604,7 @@ bool TQEventLoop::gsourceDispatch(GSource *gs) {  	}  	// activate timers -	if ( ! ( flags & 0x08 ) ) { -		// 0x08 == ExcludeTimers for X11 only +	if ( ! ( flags & ExcludeTimers ) ) {  		if (TQApplication::isGuiThread()) {  			nevents += activateTimers();  		} | 
