diff options
author | Caolán McNamara <caolan.mcnamara@collabora.com> | 2024-01-28 19:58:55 +0000 |
---|---|---|
committer | Caolán McNamara <caolan.mcnamara@collabora.com> | 2024-01-29 16:31:16 +0100 |
commit | 12d1c9a7000ac9bc816852d658562bb2c0de6bb1 (patch) | |
tree | 0fdd405c4395acffb1727a3af1b46801153c0cdc | |
parent | d4d44e38de2b4a592a03f1985e25483189cc7542 (diff) |
use existing timer to refresh notes later
Change-Id: Ic91b8930216b4099ed8af0265497120f9aad0917
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/162672
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
-rw-r--r-- | sc/qa/uitest/calc_tests8/navigator.py | 3 | ||||
-rw-r--r-- | sc/source/ui/navipi/navipi.cxx | 2 |
2 files changed, 4 insertions, 1 deletions
diff --git a/sc/qa/uitest/calc_tests8/navigator.py b/sc/qa/uitest/calc_tests8/navigator.py index 9c1769dcf49d..3c4eb1fe1dff 100644 --- a/sc/qa/uitest/calc_tests8/navigator.py +++ b/sc/qa/uitest/calc_tests8/navigator.py @@ -185,6 +185,7 @@ class navigator(UITestCase): def test_tdf158652(self): with self.ui_test.create_doc_in_start_center("calc"): + xToolkit = self.xContext.ServiceManager.createInstance('com.sun.star.awt.Toolkit') xCalcDoc = self.xUITest.getTopFocusWindow() xGridWin = xCalcDoc.getChild("grid_window") @@ -199,10 +200,12 @@ class navigator(UITestCase): commentText = mkPropertyValues({"Text":"CommentText"}) self.xUITest.executeCommandWithParameters(".uno:InsertAnnotation", commentText) + xToolkit.waitUntilAllIdlesDispatched() xComments = xContentBox.getChild("6") self.assertEqual(len(xComments.getChildren()), 1) self.xUITest.executeCommand(".uno:DeleteNote") + xToolkit.waitUntilAllIdlesDispatched() xComments = xContentBox.getChild("6") self.assertEqual(len(xComments.getChildren()), 0) diff --git a/sc/source/ui/navipi/navipi.cxx b/sc/source/ui/navipi/navipi.cxx index ae95220eeffb..a58491f58dd1 100644 --- a/sc/source/ui/navipi/navipi.cxx +++ b/sc/source/ui/navipi/navipi.cxx @@ -540,7 +540,7 @@ void ScNavigatorDlg::Notify( SfxBroadcaster&, const SfxHint& rHint ) m_xLbEntries->Refresh( ScContentId::GRAPHIC ); m_xLbEntries->Refresh( ScContentId::OLEOBJECT ); m_xLbEntries->Refresh( ScContentId::DRAWING ); - m_xLbEntries->Refresh( ScContentId::NOTE ); + aContentIdle.Start(); // Do not search notes immediately break; case SfxHintId::ScAreaLinksChanged: |