summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJennifer Liebel <jliebel94@gmail.com>2014-11-10 14:57:14 +0000
committerTobias Madl <tobias.madl.dev@gmail.com>2014-12-09 12:34:54 +0000
commit9824b78dd4ac44fe61d194854a4bc0e98015b4b2 (patch)
tree1f6ef6221f76c492a386e2bedb7b59fbe1978557
parent484129d08cc48595fe735f77bc3a30b5b8c3475a (diff)
changed timers to idle
Change-Id: I5846940cc45781f4a0264047107dbb568604d543
-rw-r--r--dbaccess/source/ui/inc/JoinTableView.hxx2
-rw-r--r--dbaccess/source/ui/querydesign/JoinTableView.cxx18
-rw-r--r--editeng/source/editeng/impedit.hxx6
-rw-r--r--editeng/source/editeng/impedit2.cxx6
-rw-r--r--editeng/source/editeng/impedit3.cxx2
-rw-r--r--editeng/source/editeng/impedit4.cxx4
-rw-r--r--include/svtools/wizdlg.hxx2
-rw-r--r--include/svx/sidebar/PanelLayout.hxx2
-rw-r--r--include/vcl/syswin.hxx4
-rw-r--r--reportdesign/source/ui/inc/DesignView.hxx2
-rw-r--r--reportdesign/source/ui/report/DesignView.cxx12
-rw-r--r--sc/inc/document.hxx2
-rw-r--r--sc/source/core/data/documen2.cxx10
-rw-r--r--sc/source/ui/inc/conflictsdlg.hxx2
-rw-r--r--sc/source/ui/miscdlgs/conflictsdlg.cxx6
-rw-r--r--sd/source/ui/dlg/dlgass.cxx33
-rw-r--r--svtools/source/dialogs/wizdlg.cxx14
-rw-r--r--svx/source/dialog/_contdlg.cxx18
-rw-r--r--svx/source/dialog/contimp.hxx4
-rw-r--r--svx/source/sidebar/PanelLayout.cxx10
-rw-r--r--sw/source/uibase/inc/swruler.hxx2
-rw-r--r--sw/source/uibase/misc/swruler.cxx10
-rw-r--r--vcl/source/window/syswin.cxx10
23 files changed, 90 insertions, 91 deletions
diff --git a/dbaccess/source/ui/inc/JoinTableView.hxx b/dbaccess/source/ui/inc/JoinTableView.hxx
index c9c500263402..a14be0d739de 100644
--- a/dbaccess/source/ui/inc/JoinTableView.hxx
+++ b/dbaccess/source/ui/inc/JoinTableView.hxx
@@ -85,7 +85,7 @@ namespace dbaui
OTableWindowMap m_aTableMap;
::std::vector<OTableConnection*> m_vTableConnection;
- Timer m_aDragScrollTimer;
+ Idle m_aDragScrollIdle;
Rectangle m_aDragRect;
Rectangle m_aSizingRect;
Point m_aDragOffset;
diff --git a/dbaccess/source/ui/querydesign/JoinTableView.cxx b/dbaccess/source/ui/querydesign/JoinTableView.cxx
index f622e3eac0b8..020e990e4db7 100644
--- a/dbaccess/source/ui/querydesign/JoinTableView.cxx
+++ b/dbaccess/source/ui/querydesign/JoinTableView.cxx
@@ -169,7 +169,7 @@ OJoinTableView::OJoinTableView( vcl::Window* pParent, OJoinDesignView* pView )
InitColors();
- m_aDragScrollTimer.SetTimeoutHdl(LINK(this, OJoinTableView, OnDragScrollTimer));
+ m_aDragScrollIdle.SetIdleHdl(LINK(this, OJoinTableView, OnDragScrollTimer));
}
OJoinTableView::~OJoinTableView()
@@ -716,8 +716,8 @@ void OJoinTableView::Tracking( const TrackingEvent& rTEvt )
{
if( m_pDragWin )
{
- if (m_aDragScrollTimer.IsActive())
- m_aDragScrollTimer.Stop();
+ if (m_aDragScrollIdle.IsActive())
+ m_aDragScrollIdle.Stop();
// adjust position of child after moving
// windows are not allowed to leave display range
@@ -776,8 +776,8 @@ void OJoinTableView::Tracking( const TrackingEvent& rTEvt )
}
else if (rTEvt.IsTrackingCanceled())
{
- if (m_aDragScrollTimer.IsActive())
- m_aDragScrollTimer.Stop();
+ if (m_aDragScrollIdle.IsActive())
+ m_aDragScrollIdle.Stop();
EndTracking();
}
else
@@ -989,8 +989,8 @@ bool OJoinTableView::ScrollWhileDragging()
OSL_ENSURE(m_pDragWin != NULL, "OJoinTableView::ScrollWhileDragging must not be called when a window is being dragged !");
// kill the timer
- if (m_aDragScrollTimer.IsActive())
- m_aDragScrollTimer.Stop();
+ if (m_aDragScrollIdle.IsActive())
+ m_aDragScrollIdle.Stop();
Point aDragWinPos = m_ptPrevDraggingPos - m_aDragOffset;
Size aDragWinSize = m_pDragWin->GetSizePixel();
@@ -1048,8 +1048,8 @@ bool OJoinTableView::ScrollWhileDragging()
// resetting timer, if still necessary
if (bNeedScrollTimer)
{
- m_aDragScrollTimer.SetTimeout(100);
- m_aDragScrollTimer.Start();
+ m_aDragScrollIdle.SetPriority(VCL_IDLE_PRIORITY_LOW);
+ m_aDragScrollIdle.Start();
}
// redraw DraggingRect
diff --git a/editeng/source/editeng/impedit.hxx b/editeng/source/editeng/impedit.hxx
index c6e41d48ee28..f98f9433ac85 100644
--- a/editeng/source/editeng/impedit.hxx
+++ b/editeng/source/editeng/impedit.hxx
@@ -465,7 +465,7 @@ private:
IdleFormattter aIdleFormatter;
- Timer aOnlineSpellTimer;
+ Idle aOnlineSpellIdle;
// If it is detected at one point that the StatusHdl has to be called, but
// this should not happen immediately (critical section):
@@ -979,8 +979,8 @@ public:
inline EditEngine* GetEditEnginePtr() const { return pEditEngine; }
- void StartOnlineSpellTimer() { aOnlineSpellTimer.Start(); }
- void StopOnlineSpellTimer() { aOnlineSpellTimer.Stop(); }
+ void StartOnlineSpellTimer() { aOnlineSpellIdle.Start(); }
+ void StopOnlineSpellTimer() { aOnlineSpellIdle.Stop(); }
const OUString& GetAutoCompleteText() const { return aAutoCompleteText; }
void SetAutoCompleteText(const OUString& rStr, bool bUpdateTipWindow);
diff --git a/editeng/source/editeng/impedit2.cxx b/editeng/source/editeng/impedit2.cxx
index fcc9c24cfcf8..f4b48b8d90ad 100644
--- a/editeng/source/editeng/impedit2.cxx
+++ b/editeng/source/editeng/impedit2.cxx
@@ -148,8 +148,8 @@ ImpEditEngine::ImpEditEngine( EditEngine* pEE, SfxItemPool* pItemPool ) :
aIdleFormatter.SetPriority( VCL_IDLE_PRIORITY_REPAINT );
aIdleFormatter.SetIdleHdl( LINK( this, ImpEditEngine, IdleFormatHdl ) );
- aOnlineSpellTimer.SetTimeout( 100 );
- aOnlineSpellTimer.SetTimeoutHdl( LINK( this, ImpEditEngine, OnlineSpellHdl ) );
+ aOnlineSpellIdle.SetPriority( VCL_IDLE_PRIORITY_LOW );
+ aOnlineSpellIdle.SetIdleHdl( LINK( this, ImpEditEngine, OnlineSpellHdl ) );
// Access data already from here on!
SetRefDevice( NULL );
@@ -163,7 +163,7 @@ ImpEditEngine::ImpEditEngine( EditEngine* pEE, SfxItemPool* pItemPool ) :
ImpEditEngine::~ImpEditEngine()
{
aStatusTimer.Stop();
- aOnlineSpellTimer.Stop();
+ aOnlineSpellIdle.Stop();
aIdleFormatter.Stop();
// Destroying templates may otherwise cause unnecessary formatting,
diff --git a/editeng/source/editeng/impedit3.cxx b/editeng/source/editeng/impedit3.cxx
index e4af13171947..39db002f1e85 100644
--- a/editeng/source/editeng/impedit3.cxx
+++ b/editeng/source/editeng/impedit3.cxx
@@ -312,7 +312,7 @@ IMPL_LINK_NOARG(ImpEditEngine, OnlineSpellHdl)
if ( !Application::AnyInput( VCL_INPUT_KEYBOARD ) && GetUpdateMode() && IsFormatted() )
DoOnlineSpelling();
else
- aOnlineSpellTimer.Start();
+ aOnlineSpellIdle.Start();
return 0;
}
diff --git a/editeng/source/editeng/impedit4.cxx b/editeng/source/editeng/impedit4.cxx
index 5d1719486b8d..dd5c2f035efc 100644
--- a/editeng/source/editeng/impedit4.cxx
+++ b/editeng/source/editeng/impedit4.cxx
@@ -1478,7 +1478,7 @@ EESpellState ImpEditEngine::Spell( EditView* pEditView, bool bMultipleDoc )
if ( !xSpeller.is() )
return EE_SPELL_NOSPELLER;
- aOnlineSpellTimer.Stop();
+ aOnlineSpellIdle.Stop();
// In MultipleDoc always from the front / rear ...
if ( bMultipleDoc )
@@ -2447,7 +2447,7 @@ void ImpEditEngine::DoOnlineSpelling( ContentNode* pThisNodeOnly, bool bSpellAtC
break;
}
if ( bRestartTimer )
- aOnlineSpellTimer.Start();
+ aOnlineSpellIdle.Start();
}
diff --git a/include/svtools/wizdlg.hxx b/include/svtools/wizdlg.hxx
index 8ff5f3c224a5..382403aa4d5b 100644
--- a/include/svtools/wizdlg.hxx
+++ b/include/svtools/wizdlg.hxx
@@ -197,7 +197,7 @@ IMPL_LINK( MyWizardDlg, ImplNextHdl, PushButton*, pBtn )
class SVT_DLLPUBLIC WizardDialog : public ModalDialog
{
private:
- Timer maWizardLayoutTimer;
+ Idle maWizardLayoutIdle;
Size maPageSize;
ImplWizPageData* mpFirstPage;
ImplWizButtonData* mpFirstBtn;
diff --git a/include/svx/sidebar/PanelLayout.hxx b/include/svx/sidebar/PanelLayout.hxx
index 93b0030127da..c696a6208414 100644
--- a/include/svx/sidebar/PanelLayout.hxx
+++ b/include/svx/sidebar/PanelLayout.hxx
@@ -23,7 +23,7 @@
class SVX_DLLPUBLIC PanelLayout : public Control, public VclBuilderContainer
{
private:
- Timer m_aPanelLayoutTimer;
+ Idle m_aPanelLayoutIdle;
bool m_bInClose;
bool hasPanelPendingLayout() const;
diff --git a/include/vcl/syswin.hxx b/include/vcl/syswin.hxx
index 1f98a6b1d713..1ec6054ca747 100644
--- a/include/vcl/syswin.hxx
+++ b/include/vcl/syswin.hxx
@@ -152,7 +152,7 @@ private:
sal_uInt16 mnMenuBarMode;
sal_uInt16 mnIcon;
ImplData* mpImplData;
- Timer maLayoutTimer;
+ Idle maLayoutIdle;
protected:
bool mbIsDefferedInit;
vcl::Window* mpDialogParent;
@@ -274,7 +274,7 @@ public:
void SetCloseHdl(const Link& rLink);
const Link& GetCloseHdl() const;
- SAL_DLLPRIVATE bool hasPendingLayout() const { return maLayoutTimer.IsActive(); }
+ SAL_DLLPRIVATE bool hasPendingLayout() const { return maLayoutIdle.IsActive(); }
virtual void doDeferredInit(WinBits nBits);
};
diff --git a/reportdesign/source/ui/inc/DesignView.hxx b/reportdesign/source/ui/inc/DesignView.hxx
index 2b219ea3ee63..047b72759b81 100644
--- a/reportdesign/source/ui/inc/DesignView.hxx
+++ b/reportdesign/source/ui/inc/DesignView.hxx
@@ -68,7 +68,7 @@ namespace rptui
OAddFieldWindow* m_pAddField;
OSectionView* m_pCurrentView;
ONavigator* m_pReportExplorer;
- Timer m_aMarkTimer;
+ Idle m_aMarkIdle;
Point m_aScrollOffset;
DlgEdMode m_eMode;
sal_uInt16 m_nCurrentPosition;
diff --git a/reportdesign/source/ui/report/DesignView.cxx b/reportdesign/source/ui/report/DesignView.cxx
index 7aecedeae1ba..bca85bcea186 100644
--- a/reportdesign/source/ui/report/DesignView.cxx
+++ b/reportdesign/source/ui/report/DesignView.cxx
@@ -118,8 +118,8 @@ ODesignView::ODesignView( vcl::Window* pParent,
m_aSplitWin.SetAlign(WINDOWALIGN_LEFT);
m_aSplitWin.Show();
- m_aMarkTimer.SetTimeout( 100 );
- m_aMarkTimer.SetTimeoutHdl( LINK( this, ODesignView, MarkTimeout ) );
+ m_aMarkIdle.SetPriority( VCL_IDLE_PRIORITY_LOW );
+ m_aMarkIdle.SetIdleHdl( LINK( this, ODesignView, MarkTimeout ) );
}
@@ -128,7 +128,7 @@ ODesignView::~ODesignView()
m_bDeleted = true;
Hide();
m_aScrollWindow.Hide();
- m_aMarkTimer.Stop();
+ m_aMarkIdle.Stop();
if ( m_pPropWin )
{
notifySystemWindow(this,m_pPropWin,::comphelper::mem_fun(&TaskPaneList::RemoveWindow));
@@ -360,7 +360,7 @@ void ODesignView::UpdatePropertyBrowserDelayed(OSectionView& _rView)
DlgEdHint aHint( RPTUI_HINT_SELECTIONCHANGED );
Broadcast( aHint );
}
- m_aMarkTimer.Start();
+ m_aMarkIdle.Start();
}
@@ -461,7 +461,7 @@ void ODesignView::togglePropertyBrowser(bool _bToogleOn)
m_aSplitWin.RemoveItem(TASKPANE_ID);
if ( bWillBeVisible )
- m_aMarkTimer.Start();
+ m_aMarkIdle.Start();
}
}
@@ -473,7 +473,7 @@ void ODesignView::showProperties(const uno::Reference< uno::XInterface>& _xRepor
if ( m_pCurrentView )
m_aScrollWindow.setMarked(m_pCurrentView,false);
m_pCurrentView = NULL;
- m_aMarkTimer.Start();
+ m_aMarkIdle.Start();
}
}
diff --git a/sc/inc/document.hxx b/sc/inc/document.hxx
index 52a252e75519..003bf22889a6 100644
--- a/sc/inc/document.hxx
+++ b/sc/inc/document.hxx
@@ -348,7 +348,7 @@ private:
ScRange aEmbedRange;
ScAddress aCurTextWidthCalcPos;
- Timer aTrackTimer;
+ Idle aTrackIdle;
com::sun::star::uno::Reference< com::sun::star::script::vba::XVBAEventProcessor >
mxVbaEvents;
diff --git a/sc/source/core/data/documen2.cxx b/sc/source/core/data/documen2.cxx
index 02e19929871a..93e8b9f1acf1 100644
--- a/sc/source/core/data/documen2.cxx
+++ b/sc/source/core/data/documen2.cxx
@@ -249,8 +249,8 @@ ScDocument::ScDocument( ScDocumentMode eMode, SfxObjectShell* pDocShell ) :
// languages for a visible document are set by docshell later (from options)
SetLanguage( ScGlobal::eLnge, ScGlobal::eLnge, ScGlobal::eLnge );
- aTrackTimer.SetTimeoutHdl( LINK( this, ScDocument, TrackTimeHdl ) );
- aTrackTimer.SetTimeout( 100 );
+ aTrackIdle.SetIdleHdl( LINK( this, ScDocument, TrackTimeHdl ) );
+ aTrackIdle.SetPriority( VCL_IDLE_PRIORITY_LOW );
}
sfx2::LinkManager* ScDocument::GetLinkManager()
@@ -333,7 +333,7 @@ IMPL_LINK_NOARG(ScDocument, TrackTimeHdl)
{
if ( ScDdeLink::IsInUpdate() ) // do not nest
{
- aTrackTimer.Start(); // try again later
+ aTrackIdle.Start(); // try again later
}
else if (pShell) // execute
{
@@ -364,8 +364,8 @@ void ScDocument::SetExpandRefs( bool bVal )
void ScDocument::StartTrackTimer()
{
- if (!aTrackTimer.IsActive()) // do not postpone for forever
- aTrackTimer.Start();
+ if (!aTrackIdle.IsActive()) // don't postpone forever
+ aTrackIdle.Start();
}
ScDocument::~ScDocument()
diff --git a/sc/source/ui/inc/conflictsdlg.hxx b/sc/source/ui/inc/conflictsdlg.hxx
index 461a7c7d20a9..57cc7242cb90 100644
--- a/sc/source/ui/inc/conflictsdlg.hxx
+++ b/sc/source/ui/inc/conflictsdlg.hxx
@@ -136,7 +136,7 @@ private:
ScConflictsList& mrConflictsList;
Size maDialogSize;
- Timer maSelectionTimer;
+ Idle maSelectionIdle;
bool mbInSelectHdl;
bool mbInDeselectHdl;
diff --git a/sc/source/ui/miscdlgs/conflictsdlg.cxx b/sc/source/ui/miscdlgs/conflictsdlg.cxx
index 61df8e219500..b9c6a0c79ebe 100644
--- a/sc/source/ui/miscdlgs/conflictsdlg.cxx
+++ b/sc/source/ui/miscdlgs/conflictsdlg.cxx
@@ -420,8 +420,8 @@ ScConflictsDlg::ScConflictsDlg( vcl::Window* pParent, ScViewData* pViewData, ScD
m_pLbConflicts->SetSelectionMode( MULTIPLE_SELECTION );
m_pLbConflicts->SetHighlightRange();
- maSelectionTimer.SetTimeout( 100 );
- maSelectionTimer.SetTimeoutHdl( LINK( this, ScConflictsDlg, UpdateSelectionHdl ) );
+ maSelectionIdle.SetPriority( VCL_IDLE_PRIORITY_LOW );
+ maSelectionIdle.SetIdleHdl( LINK( this, ScConflictsDlg, UpdateSelectionHdl ) );
m_pLbConflicts->SetSelectHdl( LINK( this, ScConflictsDlg, SelectHandle ) );
m_pLbConflicts->SetDeselectHdl( LINK( this, ScConflictsDlg, DeselectHandle ) );
@@ -534,7 +534,7 @@ IMPL_LINK_NOARG(ScConflictsDlg, SelectHandle)
mbInSelectHdl = true;
HandleListBoxSelection( true );
- maSelectionTimer.Start();
+ maSelectionIdle.Start();
mbInSelectHdl = false;
return 0;
diff --git a/sd/source/ui/dlg/dlgass.cxx b/sd/source/ui/dlg/dlgass.cxx
index 9338dc40d6b4..60f63631f02e 100644
--- a/sd/source/ui/dlg/dlgass.cxx
+++ b/sd/source/ui/dlg/dlgass.cxx
@@ -188,10 +188,9 @@ public:
// preview
bool mbUserDataDirty;
- Timer maPrevTimer;
- Timer maEffectPrevTimer;
- Timer maUpdatePageListTimer;
- Timer maStartScanTimer;
+ Idle maPrevIdle;
+ Idle maEffectPrevIdle;
+ Idle maUpdatePageListIdle;
SfxObjectShellLock xDocShell;
@@ -585,14 +584,14 @@ AssistentDlgImpl::AssistentDlgImpl( vcl::Window* pWindow, const Link& rFinishLin
maAssistentFunc.GotoPage(1);
mpLastPageButton->Disable();
- maPrevTimer.SetTimeout( 200 );
- maPrevTimer.SetTimeoutHdl( LINK( this, AssistentDlgImpl, UpdatePreviewHdl));
+ maPrevIdle.SetPriority( VCL_IDLE_PRIORITY_LOWER );
+ maPrevIdle.SetIdleHdl( LINK( this, AssistentDlgImpl, UpdatePreviewHdl));
- maEffectPrevTimer.SetTimeout( 50 );
- maEffectPrevTimer.SetTimeoutHdl( LINK( this, AssistentDlgImpl, EffectPreviewHdl ));
+ maEffectPrevIdle.SetPriority( VCL_IDLE_PRIORITY_MEDIUM );
+ maEffectPrevIdle.SetIdleHdl( LINK( this, AssistentDlgImpl, EffectPreviewHdl ));
- maUpdatePageListTimer.SetTimeout( 50 );
- maUpdatePageListTimer.SetTimeoutHdl( LINK( this, AssistentDlgImpl, UpdatePageListHdl));
+ maUpdatePageListIdle.SetPriority( VCL_IDLE_PRIORITY_MEDIUM );
+ maUpdatePageListIdle.SetIdleHdl( LINK( this, AssistentDlgImpl, UpdatePageListHdl));
SetStartType( ST_EMPTY );
@@ -999,7 +998,7 @@ void AssistentDlgImpl::LeavePage()
int nPage = maAssistentFunc.GetCurrentPage();
if( nPage == 4 && mbUserDataDirty )
- maPrevTimer.Start();
+ maPrevIdle.Start();
}
void AssistentDlgImpl::ChangePage()
@@ -1054,7 +1053,7 @@ void AssistentDlgImpl::UpdatePage()
if(mbDocPreview || maPageListFile != maDocFile)
mpPage5PageListCT->Clear();
- maUpdatePageListTimer.Start();
+ maUpdatePageListIdle.Start();
break;
}
@@ -1096,7 +1095,7 @@ IMPL_LINK( AssistentDlgImpl, SelectRegionHdl, ListBox *, pLB )
IMPL_LINK_NOARG(AssistentDlgImpl, SelectEffectHdl)
{
- maEffectPrevTimer.Start();
+ maEffectPrevIdle.Start();
return 0;
}
@@ -1144,20 +1143,20 @@ IMPL_LINK_NOARG(AssistentDlgImpl, SelectTemplateHdl)
SetStartType( ST_TEMPLATE );
mpPage2Medium5RB->Check();
mpPage2LayoutLB->SelectEntryPos(0);
- maPrevTimer.Start();
+ maPrevIdle.Start();
return 0;
}
IMPL_LINK_NOARG(AssistentDlgImpl, SelectLayoutHdl)
{
- maPrevTimer.Start();
+ maPrevIdle.Start();
return 0;
}
IMPL_LINK_NOARG(AssistentDlgImpl, SelectFileHdl)
{
SetStartType( ST_OPEN );
- maPrevTimer.Start();
+ maPrevIdle.Start();
return 0;
}
@@ -1204,7 +1203,7 @@ IMPL_LINK( AssistentDlgImpl, StartTypeHdl, RadioButton *, pButton )
else if(eType == ST_OPEN)
mpPage1OpenLB->SelectEntryPos(0);
- maPrevTimer.Start();
+ maPrevIdle.Start();
return 0;
}
diff --git a/svtools/source/dialogs/wizdlg.cxx b/svtools/source/dialogs/wizdlg.cxx
index ed8e29051e8e..eb2e62d0cd0e 100644
--- a/svtools/source/dialogs/wizdlg.cxx
+++ b/svtools/source/dialogs/wizdlg.cxx
@@ -61,8 +61,8 @@ void WizardDialog::ImplInitData()
mbEmptyViewMargin = false;
mnLeftAlignCount = 0;
- maWizardLayoutTimer.SetTimeout(50);
- maWizardLayoutTimer.SetTimeoutHdl( LINK( this, WizardDialog, ImplHandleWizardLayoutTimerHdl ) );
+ maWizardLayoutIdle.SetPriority(VCL_IDLE_PRIORITY_RESIZE);
+ maWizardLayoutIdle.SetIdleHdl( LINK( this, WizardDialog, ImplHandleWizardLayoutTimerHdl ) );
}
@@ -113,7 +113,7 @@ void WizardDialog::ImplCalcSize( Size& rSize )
bool WizardDialog::hasWizardPendingLayout() const
{
- return maWizardLayoutTimer.IsActive();
+ return maWizardLayoutIdle.IsActive();
}
void WizardDialog::queue_resize(StateChangedType /*eReason*/)
@@ -122,7 +122,7 @@ void WizardDialog::queue_resize(StateChangedType /*eReason*/)
return;
if (IsInClose())
return;
- maWizardLayoutTimer.Start();
+ maWizardLayoutIdle.Start();
}
IMPL_LINK( WizardDialog, ImplHandleWizardLayoutTimerHdl, void*, EMPTYARG )
@@ -263,7 +263,7 @@ void WizardDialog::ImplPosTabPage()
return;
}
- // ButtonBar-Hoehe berechnen
+ // calculate height of ButtonBar
long nMaxHeight = 0;
ImplWizButtonData* pBtnData = mpFirstBtn;
while ( pBtnData )
@@ -276,7 +276,7 @@ void WizardDialog::ImplPosTabPage()
if ( nMaxHeight )
nMaxHeight += WIZARDDIALOG_BUTTON_OFFSET_Y*2;
- // TabPage positionieren
+ // position TabPage
Size aDlgSize = GetOutputSizePixel();
aDlgSize.Height() -= nMaxHeight;
long nOffX = 0;
@@ -363,7 +363,7 @@ WizardDialog::WizardDialog( vcl::Window* pParent, const OUString& rID, const OUS
WizardDialog::~WizardDialog()
{
- maWizardLayoutTimer.Stop();
+ maWizardLayoutIdle.Stop();
// Remove all buttons
while ( mpFirstBtn )
diff --git a/svx/source/dialog/_contdlg.cxx b/svx/source/dialog/_contdlg.cxx
index 9b471b4b5aba..6362690901ae 100644
--- a/svx/source/dialog/_contdlg.cxx
+++ b/svx/source/dialog/_contdlg.cxx
@@ -264,11 +264,11 @@ SvxSuperContourDlg::SvxSuperContourDlg(SfxBindings *_pBindings, SfxChildWindow *
Resize();
- aUpdateTimer.SetTimeout( 100 );
- aUpdateTimer.SetTimeoutHdl( LINK( this, SvxSuperContourDlg, UpdateHdl ) );
+ aUpdateIdle.SetPriority( VCL_IDLE_PRIORITY_LOW );
+ aUpdateIdle.SetIdleHdl( LINK( this, SvxSuperContourDlg, UpdateHdl ) );
- aCreateTimer.SetTimeout( 50 );
- aCreateTimer.SetTimeoutHdl( LINK( this, SvxSuperContourDlg, CreateHdl ) );
+ aCreateIdle.SetPriority( VCL_IDLE_PRIORITY_RESIZE );
+ aCreateIdle.SetIdleHdl( LINK( this, SvxSuperContourDlg, CreateHdl ) );
}
SvxSuperContourDlg::~SvxSuperContourDlg()
@@ -386,7 +386,7 @@ void SvxSuperContourDlg::UpdateGraphic( const Graphic& rGraphic, bool _bGraphicL
else
aUpdatePolyPoly = tools::PolyPolygon();
- aUpdateTimer.Start();
+ aUpdateIdle.Start();
}
bool SvxSuperContourDlg::IsUndoPossible() const
@@ -480,7 +480,7 @@ IMPL_LINK( SvxSuperContourDlg, Tbx1ClickHdl, ToolBox*, pTbx )
}
else if (nId == mnAutoContourId)
{
- aCreateTimer.Start();
+ aCreateIdle.Start();
}
else if (nId == mnPipetteId)
{
@@ -543,7 +543,7 @@ IMPL_LINK( SvxSuperContourDlg, GraphSizeHdl, ContourWindow*, pWnd )
IMPL_LINK_NOARG(SvxSuperContourDlg, UpdateHdl)
{
- aUpdateTimer.Stop();
+ aUpdateIdle.Stop();
if ( pUpdateEditingObject != pCheckObj )
{
@@ -569,7 +569,7 @@ IMPL_LINK_NOARG(SvxSuperContourDlg, UpdateHdl)
IMPL_LINK_NOARG(SvxSuperContourDlg, CreateHdl)
{
- aCreateTimer.Stop();
+ aCreateIdle.Stop();
const Rectangle aWorkRect = m_pContourWnd->LogicToPixel( m_pContourWnd->GetWorkRect(), MapMode( MAP_100TH_MM ) );
const Graphic& rGraphic = m_pContourWnd->GetGraphic();
@@ -696,7 +696,7 @@ IMPL_LINK( SvxSuperContourDlg, PipetteClickHdl, ContourWindow*, pWnd )
pWnd->SetGraphic( aGraphic, bNewContour );
if( bNewContour )
- aCreateTimer.Start();
+ aCreateIdle.Start();
}
}
diff --git a/svx/source/dialog/contimp.hxx b/svx/source/dialog/contimp.hxx
index 407dd2fd4df1..2e999e855e8f 100644
--- a/svx/source/dialog/contimp.hxx
+++ b/svx/source/dialog/contimp.hxx
@@ -35,8 +35,8 @@ class SvxSuperContourDlg : public SvxContourDlg
Graphic aRedoGraphic;
Graphic aUpdateGraphic;
tools::PolyPolygon aUpdatePolyPoly;
- Timer aUpdateTimer;
- Timer aCreateTimer;
+ Idle aUpdateIdle;
+ Idle aCreateIdle;
Size aLastSize;
void* pUpdateEditingObject;
void* pCheckObj;
diff --git a/svx/source/sidebar/PanelLayout.cxx b/svx/source/sidebar/PanelLayout.cxx
index 08256d180236..6630d7ae55ba 100644
--- a/svx/source/sidebar/PanelLayout.cxx
+++ b/svx/source/sidebar/PanelLayout.cxx
@@ -20,14 +20,14 @@ PanelLayout::PanelLayout(vcl::Window* pParent, const OString& rID, const OUStrin
{
SetStyle(GetStyle() | WB_DIALOGCONTROL);
m_pUIBuilder = new VclBuilder(this, getUIRootDir(), rUIXMLDescription, rID, rFrame);
- m_aPanelLayoutTimer.SetTimeout(50);
- m_aPanelLayoutTimer.SetTimeoutHdl( LINK( this, PanelLayout, ImplHandlePanelLayoutTimerHdl ) );
+ m_aPanelLayoutIdle.SetPriority(VCL_IDLE_PRIORITY_RESIZE);
+ m_aPanelLayoutIdle.SetIdleHdl( LINK( this, PanelLayout, ImplHandlePanelLayoutTimerHdl ) );
}
PanelLayout::~PanelLayout()
{
m_bInClose = true;
- m_aPanelLayoutTimer.Stop();
+ m_aPanelLayoutIdle.Stop();
}
Size PanelLayout::GetOptimalSize() const
@@ -40,7 +40,7 @@ Size PanelLayout::GetOptimalSize() const
bool PanelLayout::hasPanelPendingLayout() const
{
- return m_aPanelLayoutTimer.IsActive();
+ return m_aPanelLayoutIdle.IsActive();
}
void PanelLayout::queue_resize(StateChangedType /*eReason*/)
@@ -51,7 +51,7 @@ void PanelLayout::queue_resize(StateChangedType /*eReason*/)
return;
if (!isLayoutEnabled(this))
return;
- m_aPanelLayoutTimer.Start();
+ m_aPanelLayoutIdle.Start();
}
IMPL_LINK( PanelLayout, ImplHandlePanelLayoutTimerHdl, void*, EMPTYARG )
diff --git a/sw/source/uibase/inc/swruler.hxx b/sw/source/uibase/inc/swruler.hxx
index 015815c1c52f..19b877f8253f 100644
--- a/sw/source/uibase/inc/swruler.hxx
+++ b/sw/source/uibase/inc/swruler.hxx
@@ -45,7 +45,7 @@ protected:
SwViewShell * mpViewShell; //< Shell to check if there is any comments on doc and their visibility
SwEditWin * mpSwWin; //< Used to get SwView to change the SideBar visibility
bool mbIsHighlighted; //< If comment control is highlighted (mouse is over it)
- Idle maFadeIdle; //< Timer for high/'low'light fading
+ Timer maFadeTimer; //< Timer for high/'low'light fading
int mnFadeRate; //< From 0 to 100. 0 means not highlighted.
VirtualDevice maVirDev; //< VirtualDevice of this window. Just for convenience.
diff --git a/sw/source/uibase/misc/swruler.cxx b/sw/source/uibase/misc/swruler.cxx
index 8b374b904457..172a0b39c483 100644
--- a/sw/source/uibase/misc/swruler.cxx
+++ b/sw/source/uibase/misc/swruler.cxx
@@ -44,8 +44,8 @@ SwCommentRuler::SwCommentRuler( SwViewShell* pViewSh, vcl::Window* pParent, SwEd
, maVirDev( *this )
{
// Set fading timeout: 5 x 40ms = 200ms
- maFadeIdle.SetPriority(VCL_IDLE_PRIORITY_RESIZE);
- maFadeIdle.SetIdleHdl( LINK( this, SwCommentRuler, FadeHandler ) );
+ maFadeTimer.SetTimeout(40);
+ maFadeTimer.SetTimeoutHdl( LINK( this, SwCommentRuler, FadeHandler ) );
}
// Destructor
@@ -203,7 +203,7 @@ void SwCommentRuler::MouseMove(const MouseEvent& rMEvt)
SetQuickHelpText( OUString() );
}
// Do start fading
- maFadeIdle.Start();
+ maFadeTimer.Start();
}
}
@@ -274,7 +274,7 @@ Rectangle SwCommentRuler::GetCommentControlRegion()
Color SwCommentRuler::GetFadedColor(const Color &rHighColor, const Color &rLowColor)
{
- if ( ! maFadeIdle.IsActive() )
+ if ( ! maFadeTimer.IsActive() )
return mbIsHighlighted ? rHighColor : rLowColor;
Color aColor = rHighColor;
@@ -295,7 +295,7 @@ IMPL_LINK_NOARG(SwCommentRuler, FadeHandler)
Invalidate();
if ( mnFadeRate != 0 && mnFadeRate != 100)
- maFadeIdle.Start();
+ maFadeTimer.Start();
return 0;
}
diff --git a/vcl/source/window/syswin.cxx b/vcl/source/window/syswin.cxx
index 678b7c3a59d2..1c258cb81832 100644
--- a/vcl/source/window/syswin.cxx
+++ b/vcl/source/window/syswin.cxx
@@ -85,8 +85,8 @@ void SystemWindow::Init()
mpDialogParent = NULL;
//To-Do, reuse maResizeTimer
- maLayoutTimer.SetTimeout(50);
- maLayoutTimer.SetTimeoutHdl( LINK( this, SystemWindow, ImplHandleLayoutTimerHdl ) );
+ maLayoutIdle.SetPriority(VCL_IDLE_PRIORITY_RESIZE);
+ maLayoutIdle.SetIdleHdl( LINK( this, SystemWindow, ImplHandleLayoutTimerHdl ) );
}
SystemWindow::SystemWindow(WindowType nType)
@@ -106,7 +106,7 @@ void SystemWindow::loadUI(vcl::Window* pParent, const OString& rID, const OUStri
SystemWindow::~SystemWindow()
{
- maLayoutTimer.Stop();
+ maLayoutIdle.Stop();
delete mpImplData;
mpImplData = NULL;
}
@@ -997,7 +997,7 @@ void SystemWindow::queue_resize(StateChangedType /*eReason*/)
WindowImpl *pWindowImpl = mpWindowImpl->mpBorderWindow ? mpWindowImpl->mpBorderWindow->mpWindowImpl : mpWindowImpl;
pWindowImpl->mnOptimalWidthCache = -1;
pWindowImpl->mnOptimalHeightCache = -1;
- maLayoutTimer.Start();
+ maLayoutIdle.Start();
}
void SystemWindow::Resize()
@@ -1071,7 +1071,7 @@ void SystemWindow::settingOptimalLayoutSize(VclBox* /*pBox*/)
void SystemWindow::setOptimalLayoutSize()
{
- maLayoutTimer.Stop();
+ maLayoutIdle.Stop();
//resize SystemWindow to fit requisition on initial show
VclBox *pBox = static_cast<VclBox*>(GetWindow(WINDOW_FIRSTCHILD));