[Libreoffice-commits] .: Branch 'feature/gtk3' - basic/source desktop/source sc/source sd/source sw/source vcl/aqua vcl/headless vcl/inc vcl/ios vcl/unx vcl/win

Michael Meeks michael at kemper.freedesktop.org
Mon Oct 24 08:03:53 PDT 2011


 basic/source/app/textedit.cxx        |    2 +-
 desktop/source/app/app.cxx           |    4 ++--
 sc/source/core/data/documen8.cxx     |    2 +-
 sc/source/ui/app/scmod.cxx           |    2 +-
 sd/source/ui/tools/IdleDetection.cxx |    2 +-
 sw/source/core/layout/layact.cxx     |   10 +++++-----
 sw/source/core/txtnode/txtedt.cxx    |    2 +-
 vcl/aqua/source/app/salinst.cxx      |   10 +++++-----
 vcl/headless/svpinst.cxx             |    2 +-
 vcl/inc/vcl/apptypes.hxx             |   12 ++++++------
 vcl/inc/vcl/svapp.hxx                |    2 +-
 vcl/ios/source/app/salinst.cxx       |    6 +++---
 vcl/unx/generic/app/salinst.cxx      |    9 ++++-----
 vcl/unx/gtk/app/gtkinst.cxx          |   10 +++++-----
 vcl/win/source/app/salinst.cxx       |   10 +++++-----
 15 files changed, 42 insertions(+), 43 deletions(-)

New commits:
commit e065338d305044204d350c1e8cfb553b2e432ff2
Author: Olivier Hallot <olivier.hallot at alta.org.br>
Date:   Mon Oct 24 16:04:07 2011 +0100

    Fix for fdo41997 continuation of VCL cleanup

diff --git a/basic/source/app/textedit.cxx b/basic/source/app/textedit.cxx
index 8c8ea68..a2226bd 100644
--- a/basic/source/app/textedit.cxx
+++ b/basic/source/app/textedit.cxx
@@ -370,7 +370,7 @@ IMPL_LINK( TextEditImp, SyntaxTimerHdl, Timer *, EMPTYARG )
 
     bHighlightning = sal_True;
     sal_uInt16 nLine;
-    while ( aSyntaxLineTable.First() && !Application::AnyInput( INPUT_MOUSEANDKEYBOARD ) )
+    while ( aSyntaxLineTable.First() && !Application::AnyInput( VCL_INPUT_MOUSEANDKEYBOARD ) )
     {
         nLine = (sal_uInt16)aSyntaxLineTable.GetCurKey();
         DoSyntaxHighlight( nLine );
diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index fb1da91..b63ee06 100644
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@ -1784,7 +1784,7 @@ int Desktop::Main()
                 (SvtModuleOptions().IsModuleInstalled(SvtModuleOptions::E_SSTARTMODULE)) &&
                 (!bExistsRecoveryData                                                  ) &&
                 (!bExistsSessionData                                                   ) &&
-                (!Application::AnyInput( INPUT_APPEVENT )                              ))
+                (!Application::AnyInput( VCL_INPUT_APPEVENT )                          ))
             {
                  RTL_LOGFILE_CONTEXT_TRACE( aLog, "{ create BackingComponent" );
                  Reference< XFrame > xDesktopFrame( xDesktop, UNO_QUERY );
@@ -2875,7 +2875,7 @@ void Desktop::OpenClients()
     if ( xList->hasElements() || rArgs.IsServer() )
         return;
 
-    if ( rArgs.IsQuickstart() || rArgs.IsInvisible() || rArgs.IsBean() || Application::AnyInput( INPUT_APPEVENT ) )
+    if ( rArgs.IsQuickstart() || rArgs.IsInvisible() || rArgs.IsBean() || Application::AnyInput( VCL_INPUT_APPEVENT ) )
         // soffice was started as tray icon ...
         return;
     {
diff --git a/sc/source/core/data/documen8.cxx b/sc/source/core/data/documen8.cxx
index 5f0ca06..61dc837 100644
--- a/sc/source/core/data/documen8.cxx
+++ b/sc/source/core/data/documen8.cxx
@@ -450,7 +450,7 @@ void ScDocument::InvalidateTextWidth( const ScAddress* pAdrFrom, const ScAddress
 //------------------------------------------------------------------------
 
 #define CALCMAX                 1000    // Berechnungen
-#define ABORT_EVENTS            (INPUT_ANY & ~INPUT_TIMER & ~INPUT_OTHER)
+#define ABORT_EVENTS            (VCL_INPUT_ANY & ~VCL_INPUT_TIMER & ~VCL_INPUT_OTHER)
 
 sal_Bool ScDocument::IdleCalcTextWidth()            // sal_True = demnaechst wieder versuchen
 {
diff --git a/sc/source/ui/app/scmod.cxx b/sc/source/ui/app/scmod.cxx
index b4284e7..fe71636 100644
--- a/sc/source/ui/app/scmod.cxx
+++ b/sc/source/ui/app/scmod.cxx
@@ -1822,7 +1822,7 @@ void lcl_CheckNeedsRepaint( ScDocShell* pDocShell )
 
 IMPL_LINK( ScModule, IdleHandler, Timer*, EMPTYARG )
 {
-    if ( Application::AnyInput( INPUT_MOUSEANDKEYBOARD ) )
+    if ( Application::AnyInput( VCL_INPUT_MOUSEANDKEYBOARD ) )
     {
         aIdleTimer.Start();         // Timeout unveraendert
         return 0;
diff --git a/sd/source/ui/tools/IdleDetection.cxx b/sd/source/ui/tools/IdleDetection.cxx
index e0fba1a..f7d3857 100644
--- a/sd/source/ui/tools/IdleDetection.cxx
+++ b/sd/source/ui/tools/IdleDetection.cxx
@@ -59,7 +59,7 @@ sal_Int32 IdleDetection::GetIdleState (const ::Window* pWindow)
 
 sal_Int32 IdleDetection::CheckInputPending (void)
 {
-    if (GetpApp()->AnyInput(VCL_INPUT_MOUSE | VCL_INPUT_KEYBOARD | INPUT_PAINT))
+    if (GetpApp()->AnyInput(VCL_INPUT_MOUSE | VCL_INPUT_KEYBOARD | VCL_INPUT_PAINT))
         return IDET_SYSTEM_EVENT_PENDING;
     else
         return IDET_IDLE;
diff --git a/sw/source/core/layout/layact.cxx b/sw/source/core/layout/layact.cxx
index 70bfd1a..f48061b 100644
--- a/sw/source/core/layout/layact.cxx
+++ b/sw/source/core/layout/layact.cxx
@@ -2127,13 +2127,13 @@ sal_Bool SwLayIdle::_DoIdleJob( const SwCntntFrm *pCnt, IdleJobType eJob )
                     bAllValid = sal_False;
                 if ( aRepaint.HasArea() )
                     pImp->GetShell()->InvalidateWindows( aRepaint );
-                if ( Application::AnyInput( INPUT_MOUSEANDKEYBOARD|INPUT_OTHER|INPUT_PAINT ) )
+                if ( Application::AnyInput( VCL_INPUT_MOUSEANDKEYBOARD|VCL_INPUT_OTHER|VCL_INPUT_PAINT ) )
                     return sal_True;
                 break;
             }
             case AUTOCOMPLETE_WORDS :
                 ((SwTxtFrm*)pCnt)->CollectAutoCmplWrds( pCntntNode, nTxtPos );
-                if ( Application::AnyInput( INPUT_ANY ) )
+                if ( Application::AnyInput( VCL_INPUT_ANY ) )
                     return sal_True;
                 break;
             case WORD_COUNT :
@@ -2141,7 +2141,7 @@ sal_Bool SwLayIdle::_DoIdleJob( const SwCntntFrm *pCnt, IdleJobType eJob )
                 const xub_StrLen nEnd = pTxtNode->GetTxt().Len();
                 SwDocStat aStat;
                 pTxtNode->CountWords( aStat, 0, nEnd );
-                if ( Application::AnyInput( INPUT_ANY ) )
+                if ( Application::AnyInput( VCL_INPUT_ANY ) )
                     return sal_True;
                 break;
             }
@@ -2153,7 +2153,7 @@ sal_Bool SwLayIdle::_DoIdleJob( const SwCntntFrm *pCnt, IdleJobType eJob )
                     bAllValid = sal_False;
                 if ( aRepaint.HasArea() )
                     pImp->GetShell()->InvalidateWindows( aRepaint );
-                if ( Application::AnyInput( INPUT_MOUSEANDKEYBOARD|INPUT_OTHER|INPUT_PAINT ) )
+                if ( Application::AnyInput( VCL_INPUT_MOUSEANDKEYBOARD|VCL_INPUT_OTHER|VCL_INPUT_PAINT ) )
                     return sal_True;
                 break;
             }
@@ -2360,7 +2360,7 @@ SwLayIdle::SwLayIdle( SwRootFrm *pRt, SwViewImp *pI ) :
         } while ( pSh != pImp->GetShell() );
 
         SwLayAction aAction( pRoot, pImp );
-        aAction.SetInputType( INPUT_ANY );
+        aAction.SetInputType( VCL_INPUT_ANY );
         aAction.SetIdle( sal_True );
         aAction.SetWaitAllowed( sal_False );
         aAction.Action();
diff --git a/sw/source/core/txtnode/txtedt.cxx b/sw/source/core/txtnode/txtedt.cxx
index f63826c..0c70225 100644
--- a/sw/source/core/txtnode/txtedt.cxx
+++ b/sw/source/core/txtnode/txtedt.cxx
@@ -1436,7 +1436,7 @@ void SwTxtFrm::CollectAutoCmplWrds( SwCntntNode* pActNode, xub_StrLen nActPos )
             }
             if( !--nCnt )
             {
-                if ( Application::AnyInput( INPUT_ANY ) )
+                if ( Application::AnyInput( VCL_INPUT_ANY ) )
                     return;
                 nCnt = 100;
             }
diff --git a/vcl/aqua/source/app/salinst.cxx b/vcl/aqua/source/app/salinst.cxx
index 63d657c..4ef19f9 100644
--- a/vcl/aqua/source/app/salinst.cxx
+++ b/vcl/aqua/source/app/salinst.cxx
@@ -854,15 +854,15 @@ void AquaSalInstance::Yield( bool bWait, bool bHandleAllCurrentEvents )
 
 bool AquaSalInstance::AnyInput( sal_uInt16 nType )
 {
-    if( nType & INPUT_APPEVENT )
+    if( nType & VCL_INPUT_APPEVENT )
     {
         if( ! aAppEventList.empty() )
             return true;
-        if( nType == INPUT_APPEVENT )
+        if( nType == VCL_INPUT_APPEVENT )
             return false;
     }
 
-    if( nType & INPUT_TIMER )
+    if( nType & VCL_INPUT_TIMER )
     {
         if( AquaSalTimer::pRunningTimer )
         {
@@ -885,9 +885,9 @@ bool AquaSalInstance::AnyInput( sal_uInt16 nType )
             NSMouseEnteredMask | NSMouseExitedMask;
     if( nType & VCL_INPUT_KEYBOARD)
         nEventMask |= NSKeyDownMask | NSKeyUpMask | NSFlagsChangedMask;
-    if( nType & INPUT_OTHER)
+    if( nType & VCL_INPUT_OTHER)
         nEventMask |= NSTabletPoint;
-    // TODO: INPUT_PAINT / more INPUT_OTHER
+    // TODO: VCL_INPUT_PAINT / more VCL_INPUT_OTHER
     if( !nType)
         return false;
 
diff --git a/vcl/headless/svpinst.cxx b/vcl/headless/svpinst.cxx
index 9c0eb6e..ad58bc5 100644
--- a/vcl/headless/svpinst.cxx
+++ b/vcl/headless/svpinst.cxx
@@ -397,7 +397,7 @@ void SvpSalInstance::Yield( bool bWait, bool bHandleAllCurrentEvents )
 
 bool SvpSalInstance::AnyInput( sal_uInt16 nType )
 {
-    if( (nType & INPUT_TIMER) != 0 )
+    if( (nType & VCL_INPUT_TIMER) != 0 )
         return CheckTimeout( false );
     return false;
 }
diff --git a/vcl/inc/vcl/apptypes.hxx b/vcl/inc/vcl/apptypes.hxx
index a52b2e9..e9f3dd7 100644
--- a/vcl/inc/vcl/apptypes.hxx
+++ b/vcl/inc/vcl/apptypes.hxx
@@ -57,12 +57,12 @@ public:
 
 #define VCL_INPUT_MOUSE                 0x0001
 #define VCL_INPUT_KEYBOARD              0x0002
-#define INPUT_PAINT                 0x0004
-#define INPUT_TIMER                 0x0008
-#define INPUT_OTHER                 0x0010
-#define INPUT_APPEVENT              0x0020
-#define INPUT_MOUSEANDKEYBOARD      (VCL_INPUT_MOUSE | VCL_INPUT_KEYBOARD)
-#define INPUT_ANY                   (INPUT_MOUSEANDKEYBOARD | INPUT_PAINT | INPUT_TIMER | INPUT_OTHER | INPUT_APPEVENT)
+#define VCL_INPUT_PAINT                 0x0004
+#define VCL_INPUT_TIMER                 0x0008
+#define VCL_INPUT_OTHER                 0x0010
+#define VCL_INPUT_APPEVENT              0x0020
+#define VCL_INPUT_MOUSEANDKEYBOARD      (VCL_INPUT_MOUSE | VCL_INPUT_KEYBOARD)
+#define VCL_INPUT_ANY                   (VCL_INPUT_MOUSEANDKEYBOARD | VCL_INPUT_PAINT | VCL_INPUT_TIMER | VCL_INPUT_OTHER | VCL_INPUT_APPEVENT)
 
 #define DISPATCH_OPEN               0x0001
 #define DISPATCH_PRINT              0x0002
diff --git a/vcl/inc/vcl/svapp.hxx b/vcl/inc/vcl/svapp.hxx
index 07f75f5..1cc0a40 100644
--- a/vcl/inc/vcl/svapp.hxx
+++ b/vcl/inc/vcl/svapp.hxx
@@ -258,7 +258,7 @@ public:
     static sal_uInt16               GetModalModeCount();
 
     static sal_uInt16               GetDispatchLevel();
-    static sal_Bool                 AnyInput( sal_uInt16 nType = INPUT_ANY );
+    static sal_Bool                 AnyInput( sal_uInt16 nType = VCL_INPUT_ANY );
     static sal_uLong                GetLastInputInterval();
     static sal_Bool                 IsUICaptured();
 
diff --git a/vcl/ios/source/app/salinst.cxx b/vcl/ios/source/app/salinst.cxx
index f7c9685..e91e34f 100644
--- a/vcl/ios/source/app/salinst.cxx
+++ b/vcl/ios/source/app/salinst.cxx
@@ -521,15 +521,15 @@ void IosSalInstance::Yield( bool bWait, bool bHandleAllCurrentEvents )
 
 bool IosSalInstance::AnyInput( sal_uInt16 nType )
 {
-    if( nType & INPUT_APPEVENT )
+    if( nType & VCL_INPUT_APPEVENT )
     {
         if( ! aAppEventList.empty() )
             return true;
-        if( nType == INPUT_APPEVENT )
+        if( nType == VCL_INPUT_APPEVENT )
             return false;
     }
 
-    if( nType & INPUT_TIMER )
+    if( nType & VCL_INPUT_TIMER )
     {
         if( IosSalTimer::pRunningTimer )
         {
diff --git a/vcl/unx/generic/app/salinst.cxx b/vcl/unx/generic/app/salinst.cxx
index c98ed9d..73659f5 100644
--- a/vcl/unx/generic/app/salinst.cxx
+++ b/vcl/unx/generic/app/salinst.cxx
@@ -131,13 +131,13 @@ Bool ImplPredicateEvent( Display *, XEvent *pEvent, char *pData )
         case Expose:
         case GraphicsExpose:
         case NoExpose:
-            nType = INPUT_PAINT;
+            nType = VCL_INPUT_PAINT;
             break;
         default:
             nType = 0;
     }
 
-    if ( (nType & pPre->nType) || ( ! nType && (pPre->nType & INPUT_OTHER) ) )
+    if ( (nType & pPre->nType) || ( ! nType && (pPre->nType & VCL_INPUT_OTHER) ) )
         pPre->bRet = sal_True;
 
     return False;
@@ -150,10 +150,9 @@ bool X11SalInstance::AnyInput(sal_uInt16 nType)
     Display *pDisplay  = pData->GetSalDisplay()->GetDisplay();
     sal_Bool bRet = sal_False;
 
-    if( (nType & INPUT_TIMER) && mpXLib->CheckTimeout( false ) )
-    {
+    if( (nType & VCL_INPUT_TIMER) && mpXLib->CheckTimeout( false ) )
         bRet = sal_True;
-    }
+
     else if (XPending(pDisplay) )
     {
         PredicateReturn aInput;
diff --git a/vcl/unx/gtk/app/gtkinst.cxx b/vcl/unx/gtk/app/gtkinst.cxx
index 16e702f..9049419 100644
--- a/vcl/unx/gtk/app/gtkinst.cxx
+++ b/vcl/unx/gtk/app/gtkinst.cxx
@@ -252,10 +252,10 @@ extern "C" {
         case Expose:
         case GraphicsExpose:
         case NoExpose:
-            nType = INPUT_PAINT;
+            nType = VCL_INPUT_PAINT;
             break;
         default:
-            nType = INPUT_OTHER;
+            nType = VCL_INPUT_OTHER;
             break;
         }
         ((GtkInstance *)data)->addEvent( nType );
@@ -284,10 +284,10 @@ extern "C" {
             nType = VCL_INPUT_KEYBOARD;
             break;
         case GDK_EXPOSE:
-            nType = INPUT_PAINT;
+            nType = VCL_INPUT_PAINT;
             break;
         default:
-            nType = INPUT_OTHER;
+            nType = VCL_INPUT_OTHER;
             break;
         }
         ((GtkInstance *)data)->subtractEvent( nType );
@@ -614,7 +614,7 @@ bool GtkInstance::IsTimerExpired()
 
 bool GtkInstance::AnyInput( sal_uInt16 nType )
 {
-    if( (nType & INPUT_TIMER) && IsTimerExpired() )
+    if( (nType & VCL_INPUT_TIMER) && IsTimerExpired() )
         return true;
     else
     {
diff --git a/vcl/win/source/app/salinst.cxx b/vcl/win/source/app/salinst.cxx
index 10655ef..caf0d27 100644
--- a/vcl/win/source/app/salinst.cxx
+++ b/vcl/win/source/app/salinst.cxx
@@ -904,7 +904,7 @@ bool WinSalInstance::AnyInput( sal_uInt16 nType )
 {
     MSG aMsg;
 
-    if ( (nType & (INPUT_ANY)) == (INPUT_ANY) )
+    if ( (nType & (VCL_INPUT_ANY)) == (VCL_INPUT_ANY) )
     {
         // revert bugfix for #108919# which never reported timeouts when called from the timer handler
         // which made the application completely unresponsive during background formatting
@@ -913,7 +913,7 @@ bool WinSalInstance::AnyInput( sal_uInt16 nType )
     }
     else
     {
-        if ( nType & INPUT_MOUSE )
+        if ( nType & VCL_INPUT_MOUSE )
         {
             // Test for mouse input
             if ( ImplPeekMessage( &aMsg, 0, WM_MOUSEFIRST, WM_MOUSELAST,
@@ -936,7 +936,7 @@ bool WinSalInstance::AnyInput( sal_uInt16 nType )
             }
         }
 
-        if ( nType & INPUT_PAINT )
+        if ( nType & VCL_INPUT_PAINT )
         {
             // Test for paint input
             if ( ImplPeekMessage( &aMsg, 0, WM_PAINT, WM_PAINT,
@@ -960,7 +960,7 @@ bool WinSalInstance::AnyInput( sal_uInt16 nType )
                 return true;
         }
 
-        if ( nType & INPUT_TIMER )
+        if ( nType & VCL_INPUT_TIMER )
         {
             // Test for timer input
             if ( ImplPeekMessage( &aMsg, 0, WM_TIMER, WM_TIMER,
@@ -969,7 +969,7 @@ bool WinSalInstance::AnyInput( sal_uInt16 nType )
 
         }
 
-        if ( nType & INPUT_OTHER )
+        if ( nType & VCL_INPUT_OTHER )
         {
             // Test for any input
             if ( ImplPeekMessage( &aMsg, 0, 0, 0, PM_NOREMOVE | PM_NOYIELD ) )


More information about the Libreoffice-commits mailing list