[Libreoffice-commits] core.git: starmath/source

Julien Nabet serval2412 at yahoo.fr
Sun Mar 8 05:31:48 PDT 2015


 starmath/source/edit.cxx |   12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

New commits:
commit 79b3e12526c42bd9acc78e7541f49756fc297200
Author: Julien Nabet <serval2412 at yahoo.fr>
Date:   Sun Mar 8 13:30:15 2015 +0100

    cppcheck: cstyleCast
    
    Change-Id: If5ab5dbf638d1ff81693fafc1895e68314929f90

diff --git a/starmath/source/edit.cxx b/starmath/source/edit.cxx
index f05a04e..2d4d87f 100644
--- a/starmath/source/edit.cxx
+++ b/starmath/source/edit.cxx
@@ -107,12 +107,12 @@ SmEditWindow::SmEditWindow( SmCmdBoxWindow &rMyCmdBoxWin ) :
     SetBackground( GetSettings().GetStyleSettings().GetWindowColor() );
 
     aModifyIdle.SetIdleHdl(LINK(this, SmEditWindow, ModifyTimerHdl));
-    aModifyIdle.SetPriority(SchedulerPriority::LOWEST);
+    aModifyIdle.SetPriority(VCL_IDLE_PRIORITY_LOWEST);
 
     if (!IsInlineEditEnabled())
     {
         aCursorMoveIdle.SetIdleHdl(LINK(this, SmEditWindow, CursorMoveTimerHdl));
-        aCursorMoveIdle.SetPriority(SchedulerPriority::LOWEST);
+        aCursorMoveIdle.SetPriority(VCL_IDLE_PRIORITY_LOWEST);
     }
 
     // if not called explicitly the this edit window within the
@@ -244,14 +244,14 @@ void SmEditWindow::DataChanged( const DataChangedEvent& )
     Resize();
 }
 
-IMPL_LINK( SmEditWindow, ModifyTimerHdl, Idle *, EMPTYARG /*pTimer*/ )
+IMPL_LINK( SmEditWindow, ModifyTimerHdl, Timer *, EMPTYARG /*pTimer*/ )
 {
     UpdateStatus();
     aModifyIdle.Stop();
     return 0;
 }
 
-IMPL_LINK(SmEditWindow, CursorMoveTimerHdl, Idle *, EMPTYARG /*pTimer*/)
+IMPL_LINK(SmEditWindow, CursorMoveTimerHdl, Timer *, EMPTYARG /*pTimer*/)
     // every once in a while check cursor position (selection) of edit
     // window and if it has changed (try to) set the formula-cursor
     // according to that.
@@ -731,7 +731,7 @@ void SmEditWindow::LoseFocus()
 bool SmEditWindow::IsAllSelected() const
 {
     bool bRes = false;
-    EditEngine *pEditEngine = ((SmEditWindow *) this)->GetEditEngine();
+    EditEngine *pEditEngine = (const_cast<SmEditWindow *>(this))->GetEditEngine();
     OSL_ENSURE( pEditView, "NULL pointer" );
     OSL_ENSURE( pEditEngine, "NULL pointer" );
     if (pEditEngine  &&  pEditView)
@@ -945,7 +945,7 @@ void SmEditWindow::SetSelection(const ESelection &rSel)
 
 bool SmEditWindow::IsEmpty() const
 {
-    EditEngine *pEditEngine = ((SmEditWindow *) this)->GetEditEngine();
+    EditEngine *pEditEngine = (const_cast<SmEditWindow *>(this))->GetEditEngine();
     bool bEmpty = ( pEditEngine && pEditEngine->GetTextLen() == 0 );
     return bEmpty;
 }


More information about the Libreoffice-commits mailing list