[Libreoffice-commits] core.git: sc/qa sd/qa sfx2/source sw/qa

Caolán McNamara (via logerrit) logerrit at kemper.freedesktop.org
Sun Sep 15 14:26:04 UTC 2019


 sc/qa/uitest/calc_tests/documentProperties.py    |    6 +++---
 sd/qa/uitest/impress_tests/documentProperties.py |    4 ++--
 sfx2/source/dialog/dinfdlg.cxx                   |    8 ++++----
 sw/qa/uitest/writer_tests2/documentProperties.py |    8 ++++----
 4 files changed, 13 insertions(+), 13 deletions(-)

New commits:
commit bcaeebd98a697d6bcf891990c3b13de5da1790e7
Author:     Caolán McNamara <caolanm at redhat.com>
AuthorDate: Fri Sep 13 11:19:56 2019 +0100
Commit:     Caolán McNamara <caolanm at redhat.com>
CommitDate: Sun Sep 15 16:24:49 2019 +0200

    Related: tdf#125531 use RemoveTabPage for removing a tab page
    
    which removes the tab cross-platform
    
    Change-Id: If2584cc75350fb0106f1a1f5190abb74b0ee0ccf
    Reviewed-on: https://gerrit.libreoffice.org/78871
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>
    Tested-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/sc/qa/uitest/calc_tests/documentProperties.py b/sc/qa/uitest/calc_tests/documentProperties.py
index 3f0f0cbf611b..71030b595959 100644
--- a/sc/qa/uitest/calc_tests/documentProperties.py
+++ b/sc/qa/uitest/calc_tests/documentProperties.py
@@ -48,12 +48,12 @@ class CalcDocumentProperties(UITestCase):
         xCommentsText.executeAction("TYPE", mkPropertyValues({"TEXT":"Comments text"}))
 
 #Font tab
-        select_pos(xTabs, "5")     #tab Fonts
+        select_pos(xTabs, "4")     #tab Fonts
         xFontEmbedCheckbox = xDialog.getChild("embedFonts")
         xFontEmbedCheckbox.executeAction("CLICK", tuple())
 
 #Security tab
-        select_pos(xTabs, "4")     #tab Security
+        select_pos(xTabs, "3")     #tab Security
         xReadOnlyCheckbox = xDialog.getChild("readonly")
         xReadOnlyCheckbox.executeAction("CLICK", tuple())
         xRecordChangesCheckbox = xDialog.getChild("recordchanges")
@@ -74,7 +74,7 @@ class CalcDocumentProperties(UITestCase):
         xAddBtn = xDialog.getChild("add")
         xAddBtn.executeAction("CLICK", tuple())
 
-        select_pos(xTabs, "6")     #tab Statistics
+        select_pos(xTabs, "5")     #tab Statistics
 
         xOkBtn = xDialog.getChild("ok")
         xOkBtn.executeAction("CLICK", tuple())
diff --git a/sd/qa/uitest/impress_tests/documentProperties.py b/sd/qa/uitest/impress_tests/documentProperties.py
index e74ba0fd26c6..54ad2947b6bf 100644
--- a/sd/qa/uitest/impress_tests/documentProperties.py
+++ b/sd/qa/uitest/impress_tests/documentProperties.py
@@ -52,12 +52,12 @@ class ImpressDocumentProperties(UITestCase):
         xCommentsText.executeAction("TYPE", mkPropertyValues({"TEXT":"Comments text"}))
 
         #Font tab
-        select_pos(xTabs, "5")     #tab Fonts
+        select_pos(xTabs, "4")     #tab Fonts
         xFontEmbedCheckbox = xDialog.getChild("embedFonts")
         xFontEmbedCheckbox.executeAction("CLICK", tuple())
 
         #Security tab
-        select_pos(xTabs, "4")     #tab Security
+        select_pos(xTabs, "3")     #tab Security
         xReadOnlyCheckbox = xDialog.getChild("readonly")
         xReadOnlyCheckbox.executeAction("CLICK", tuple())
 
diff --git a/sfx2/source/dialog/dinfdlg.cxx b/sfx2/source/dialog/dinfdlg.cxx
index 2b49b18bfc3b..782d4faa0b2e 100644
--- a/sfx2/source/dialog/dinfdlg.cxx
+++ b/sfx2/source/dialog/dinfdlg.cxx
@@ -1127,13 +1127,13 @@ SfxDocumentInfoDialog::SfxDocumentInfoDialog(weld::Window* pParent, const SfxIte
     AddTabPage("general", SfxDocumentPage::Create, nullptr);
     AddTabPage("description", SfxDocumentDescPage::Create, nullptr);
     AddTabPage("customprops", SfxCustomPropertiesPage::Create, nullptr);
-    AddTabPage("cmisprops", SfxCmisPropertiesPage::Create, nullptr);
-    if (!rInfoItem.isCmisDocument())
-        m_xTabCtrl->get_page("cmisprops")->hide();
+    if (rInfoItem.isCmisDocument())
+        AddTabPage("cmisprops", SfxCmisPropertiesPage::Create, nullptr);
+    else
+        RemoveTabPage("cmisprops");
     AddTabPage("security", SfxSecurityPage::Create, nullptr);
 }
 
-
 void SfxDocumentInfoDialog::PageCreated(const OString& rId, SfxTabPage &rPage)
 {
     if (rId == "general")
diff --git a/sw/qa/uitest/writer_tests2/documentProperties.py b/sw/qa/uitest/writer_tests2/documentProperties.py
index 0230decef350..40366d2303b5 100644
--- a/sw/qa/uitest/writer_tests2/documentProperties.py
+++ b/sw/qa/uitest/writer_tests2/documentProperties.py
@@ -53,12 +53,12 @@ class documentProperties(UITestCase):
 
 
 #Font tab
-        select_pos(xTabs, "5")     #tab Fonts
+        select_pos(xTabs, "4")     #tab Fonts
         xFontEmbedCheckbox = xDialog.getChild("embedFonts")
         xFontEmbedCheckbox.executeAction("CLICK", tuple())
 
 #Security tab
-        select_pos(xTabs, "4")     #tab Security
+        select_pos(xTabs, "3")     #tab Security
         xReadOnlyCheckbox = xDialog.getChild("readonly")
         xReadOnlyCheckbox.executeAction("CLICK", tuple())
         xRecordChangesCheckbox = xDialog.getChild("recordchanges")
@@ -80,7 +80,7 @@ class documentProperties(UITestCase):
         xAddBtn = xDialog.getChild("add")
         xAddBtn.executeAction("CLICK", tuple())
 
-        select_pos(xTabs, "6")     #tab Statistics
+        select_pos(xTabs, "5")     #tab Statistics
         xUpdateBtn = xDialog.getChild("update")
         xUpdateBtn.executeAction("CLICK", tuple())
 
@@ -115,4 +115,4 @@ class documentProperties(UITestCase):
 
         self.ui_test.close_doc()
 
-# vim: set shiftwidth=4 softtabstop=4 expandtab:
\ No newline at end of file
+# vim: set shiftwidth=4 softtabstop=4 expandtab:


More information about the Libreoffice-commits mailing list