tdf#138976 change "Cancel" button to "Close" in Template Manager dialog
Change-Id: I3e8cbdb70f70002f1fe2b873e899f25a72463358
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107704
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
diff --git a/cui/qa/uitest/dialogs/chardlg.py b/cui/qa/uitest/dialogs/chardlg.py
index 2545d26..fb1c128 100644
--- a/cui/qa/uitest/dialogs/chardlg.py
+++ b/cui/qa/uitest/dialogs/chardlg.py
@@ -16,7 +16,7 @@ class Test(UITestCase):
# Start Impress.
self.ui_test.create_doc_in_start_center("impress")
template = self.xUITest.getTopFocusWindow()
self.ui_test.close_dialog_through_button(template.getChild("cancel"))
self.ui_test.close_dialog_through_button(template.getChild("close"))
doc = self.xUITest.getTopFocusWindow()
editWin = doc.getChild("impress_win")
# Select the title shape.
diff --git a/cui/qa/uitest/dialogs/pastedlg.py b/cui/qa/uitest/dialogs/pastedlg.py
index ccd33e0..9ac40c5 100644
--- a/cui/qa/uitest/dialogs/pastedlg.py
+++ b/cui/qa/uitest/dialogs/pastedlg.py
@@ -16,7 +16,7 @@ class Test(UITestCase):
# Copy a string in Impress.
self.ui_test.create_doc_in_start_center("impress")
template = self.xUITest.getTopFocusWindow()
self.ui_test.close_dialog_through_button(template.getChild("cancel"))
self.ui_test.close_dialog_through_button(template.getChild("close"))
doc = self.xUITest.getTopFocusWindow()
editWin = doc.getChild("impress_win")
# Select the title shape.
diff --git a/sd/qa/uitest/impress_tests/autocorrectOptions.py b/sd/qa/uitest/impress_tests/autocorrectOptions.py
index feeabe5..d386aa8 100644
--- a/sd/qa/uitest/impress_tests/autocorrectOptions.py
+++ b/sd/qa/uitest/impress_tests/autocorrectOptions.py
@@ -16,7 +16,7 @@ class autocorrectOptions(UITestCase):
def test_autocorrect_options_impress(self):
self.ui_test.create_doc_in_start_center("impress")
xTemplateDlg = self.xUITest.getTopFocusWindow()
xCancelBtn = xTemplateDlg.getChild("cancel")
xCancelBtn = xTemplateDlg.getChild("close")
self.ui_test.close_dialog_through_button(xCancelBtn)
document = self.ui_test.get_component()
diff --git a/sd/qa/uitest/impress_tests/customSlideShow.py b/sd/qa/uitest/impress_tests/customSlideShow.py
index 61b15cd..9feef4a1 100644
--- a/sd/qa/uitest/impress_tests/customSlideShow.py
+++ b/sd/qa/uitest/impress_tests/customSlideShow.py
@@ -12,7 +12,7 @@ class customSlideShow(UITestCase):
MainDoc = self.ui_test.create_doc_in_start_center("impress")
MainWindow = self.xUITest.getTopFocusWindow()
TemplateDialog = self.xUITest.getTopFocusWindow()
cancel = TemplateDialog.getChild("cancel")
cancel = TemplateDialog.getChild("close")
self.ui_test.close_dialog_through_button(cancel)
self.ui_test.execute_dialog_through_command(".uno:CustomShowDialog")
CustomSlideShows = self.xUITest.getTopFocusWindow()
diff --git a/sd/qa/uitest/impress_tests/documentProperties.py b/sd/qa/uitest/impress_tests/documentProperties.py
index 54ad294..811feb1 100644
--- a/sd/qa/uitest/impress_tests/documentProperties.py
+++ b/sd/qa/uitest/impress_tests/documentProperties.py
@@ -17,7 +17,7 @@ class ImpressDocumentProperties(UITestCase):
def test_open_document_properties_impress(self):
self.ui_test.create_doc_in_start_center("impress")
xTemplateDlg = self.xUITest.getTopFocusWindow()
xCancelBtn = xTemplateDlg.getChild("cancel")
xCancelBtn = xTemplateDlg.getChild("close")
self.ui_test.close_dialog_through_button(xCancelBtn)
self.ui_test.execute_dialog_through_command(".uno:SetDocumentProperties")
diff --git a/sd/qa/uitest/impress_tests/insertSlide.py b/sd/qa/uitest/impress_tests/insertSlide.py
index 396079d..d33f3212 100644
--- a/sd/qa/uitest/impress_tests/insertSlide.py
+++ b/sd/qa/uitest/impress_tests/insertSlide.py
@@ -17,7 +17,7 @@ class insertSlide(UITestCase):
def test_insert_slide(self):
self.ui_test.create_doc_in_start_center("impress")
xTemplateDlg = self.xUITest.getTopFocusWindow()
xCancelBtn = xTemplateDlg.getChild("cancel")
xCancelBtn = xTemplateDlg.getChild("close")
self.ui_test.close_dialog_through_button(xCancelBtn)
document = self.ui_test.get_component()
self.assertEqual(document.DrawPages.getCount(), 1) #nr. of pages
@@ -34,7 +34,7 @@ class insertSlide(UITestCase):
def test_tdf85360_insert_4th_slide(self):
self.ui_test.create_doc_in_start_center("impress")
xTemplateDlg = self.xUITest.getTopFocusWindow()
xCancelBtn = xTemplateDlg.getChild("cancel")
xCancelBtn = xTemplateDlg.getChild("close")
self.ui_test.close_dialog_through_button(xCancelBtn)
document = self.ui_test.get_component()
self.assertEqual(document.DrawPages.getCount(), 1) #nr. of pages
diff --git a/sd/qa/uitest/impress_tests/masterElements.py b/sd/qa/uitest/impress_tests/masterElements.py
index 73c9440..00e865d 100644
--- a/sd/qa/uitest/impress_tests/masterElements.py
+++ b/sd/qa/uitest/impress_tests/masterElements.py
@@ -16,7 +16,7 @@ class masterElements(UITestCase):
def test_master_elements(self):
self.ui_test.create_doc_in_start_center("impress")
xTemplateDlg = self.xUITest.getTopFocusWindow()
xCancelBtn = xTemplateDlg.getChild("cancel")
xCancelBtn = xTemplateDlg.getChild("close")
self.ui_test.close_dialog_through_button(xCancelBtn)
document = self.ui_test.get_component()
diff --git a/sd/qa/uitest/impress_tests/renameSlide.py b/sd/qa/uitest/impress_tests/renameSlide.py
index da203fd..964f6a7 100644
--- a/sd/qa/uitest/impress_tests/renameSlide.py
+++ b/sd/qa/uitest/impress_tests/renameSlide.py
@@ -16,7 +16,7 @@ class renameSlide(UITestCase):
def test_rename_slide(self):
self.ui_test.create_doc_in_start_center("impress")
xTemplateDlg = self.xUITest.getTopFocusWindow()
xCancelBtn = xTemplateDlg.getChild("cancel")
xCancelBtn = xTemplateDlg.getChild("close")
self.ui_test.close_dialog_through_button(xCancelBtn)
self.ui_test.execute_dialog_through_command(".uno:RenamePage")
diff --git a/sd/qa/uitest/impress_tests/slideShowSettings.py b/sd/qa/uitest/impress_tests/slideShowSettings.py
index 2d2a592..5b9e44f 100644
--- a/sd/qa/uitest/impress_tests/slideShowSettings.py
+++ b/sd/qa/uitest/impress_tests/slideShowSettings.py
@@ -11,7 +11,7 @@ class slideShowSettings(UITestCase):
MainDoc = self.ui_test.create_doc_in_start_center("impress")
MainWindow = self.xUITest.getTopFocusWindow()
TemplateDialog = self.xUITest.getTopFocusWindow()
cancel = TemplateDialog.getChild("cancel")
cancel = TemplateDialog.getChild("close")
self.ui_test.close_dialog_through_button(cancel)
self.xUITest.executeCommand(".uno:InsertPage")
self.ui_test.execute_dialog_through_command(".uno:PresentationDialog")
diff --git a/sd/qa/uitest/impress_tests/tdf126605.py b/sd/qa/uitest/impress_tests/tdf126605.py
index 7443247..b4a2668a 100644
--- a/sd/qa/uitest/impress_tests/tdf126605.py
+++ b/sd/qa/uitest/impress_tests/tdf126605.py
@@ -12,7 +12,7 @@ class tdf126605(UITestCase):
def test_run(self):
self.ui_test.create_doc_in_start_center("impress")
xTemplateDlg = self.xUITest.getTopFocusWindow()
xCancelBtn = xTemplateDlg.getChild("cancel")
xCancelBtn = xTemplateDlg.getChild("close")
self.ui_test.close_dialog_through_button(xCancelBtn)
xDoc = self.xUITest.getTopFocusWindow()
diff --git a/sd/qa/uitest/impress_tests/tdf130440.py b/sd/qa/uitest/impress_tests/tdf130440.py
index 348feb3..60ea610 100644
--- a/sd/qa/uitest/impress_tests/tdf130440.py
+++ b/sd/qa/uitest/impress_tests/tdf130440.py
@@ -12,7 +12,7 @@ class tdf129346(UITestCase):
def test_run(self):
self.ui_test.create_doc_in_start_center("impress")
xTemplateDlg = self.xUITest.getTopFocusWindow()
xCancelBtn = xTemplateDlg.getChild("cancel")
xCancelBtn = xTemplateDlg.getChild("close")
self.ui_test.close_dialog_through_button(xCancelBtn)
xToolkit = self.xContext.ServiceManager.createInstance('com.sun.star.awt.Toolkit')
diff --git a/sd/qa/uitest/impress_tests/tdf91762.py b/sd/qa/uitest/impress_tests/tdf91762.py
index 2487bc2..92a23de 100644
--- a/sd/qa/uitest/impress_tests/tdf91762.py
+++ b/sd/qa/uitest/impress_tests/tdf91762.py
@@ -13,7 +13,7 @@ class tdf91762(UITestCase):
def test_tdf91762(self):
self.ui_test.create_doc_in_start_center("impress")
xTemplateDlg = self.xUITest.getTopFocusWindow()
xCancelBtn = xTemplateDlg.getChild("cancel")
xCancelBtn = xTemplateDlg.getChild("close")
self.ui_test.close_dialog_through_button(xCancelBtn)
self.xUITest.executeCommand(".uno:AssignLayout?WhatLayout:long=1")
diff --git a/sfx2/uiconfig/ui/templatedlg.ui b/sfx2/uiconfig/ui/templatedlg.ui
index 5939f851f..b6fccf2 100644
--- a/sfx2/uiconfig/ui/templatedlg.ui
+++ b/sfx2/uiconfig/ui/templatedlg.ui
@@ -148,10 +148,11 @@
</packing>
</child>
<child>
<object class="GtkButton" id="cancel">
<property name="label">gtk-cancel</property>
<object class="GtkButton" id="close">
<property name="label">gtk-close</property>
<property name="visible">True</property>
<property name="can-focus">True</property>
<property name="can_default">True</property>
<property name="receives-default">True</property>
<property name="use-stock">True</property>
</object>
@@ -770,7 +771,7 @@
<action-widgets>
<action-widget response="-11">help</action-widget>
<action-widget response="-5">ok</action-widget>
<action-widget response="-6">cancel</action-widget>
<action-widget response="-7">close</action-widget>
</action-widgets>
</object>
</interface>
diff --git a/svx/qa/uitest/table/tablecontroller.py b/svx/qa/uitest/table/tablecontroller.py
index 27ed4a1..afc5de8 100644
--- a/svx/qa/uitest/table/tablecontroller.py
+++ b/svx/qa/uitest/table/tablecontroller.py
@@ -15,7 +15,7 @@ class SvxTableControllerTest(UITestCase):
# Create an Impress document with a single table in it.
self.ui_test.create_doc_in_start_center("impress")
template = self.xUITest.getTopFocusWindow()
self.ui_test.close_dialog_through_button(template.getChild("cancel"))
self.ui_test.close_dialog_through_button(template.getChild("close"))
self.xUITest.executeCommand(".uno:SelectAll")
self.xUITest.executeCommand(".uno:Delete")
self.xUITest.executeCommand(".uno:InsertTable?Columns:short=2&Rows:short=2")
diff --git a/sw/qa/uitest/writer_dialogs/openDialogs.py b/sw/qa/uitest/writer_dialogs/openDialogs.py
index 4dbacaa..343c2ae 100644
--- a/sw/qa/uitest/writer_dialogs/openDialogs.py
+++ b/sw/qa/uitest/writer_dialogs/openDialogs.py
@@ -11,7 +11,7 @@ from uitest.uihelper.testDialog import testDialog
dialogs = [
{"command": ".uno:OpenRemote", "closeButton": "cancel"},
{"command": ".uno:NewDoc", "closeButton": "cancel"},
{"command": ".uno:NewDoc", "closeButton": "close"},
{"command": ".uno:SaveAsTemplate", "closeButton": "cancel"},
{"command": ".uno:ExportToPDF", "closeButton": "cancel", "skipTestOK": True},
# export needs filesystem
diff --git a/uitest/impress_tests/backgrounds.py b/uitest/impress_tests/backgrounds.py
index 6e2493b..de4a349 100644
--- a/uitest/impress_tests/backgrounds.py
+++ b/uitest/impress_tests/backgrounds.py
@@ -108,7 +108,7 @@ class ImpressBackgrounds(UITestCase):
self.ui_test.create_doc_in_start_center("impress")
xTemplateDlg = self.xUITest.getTopFocusWindow()
xCancelBtn = xTemplateDlg.getChild("cancel")
xCancelBtn = xTemplateDlg.getChild("close")
self.ui_test.close_dialog_through_button(xCancelBtn)
buttons = ['btnbitmap', 'btncolor', 'btngradient', 'btnhatch', 'btnpattern']
diff --git a/uitest/impress_tests/drawinglayer.py b/uitest/impress_tests/drawinglayer.py
index d4de9f3..2a0bcf4 100644
--- a/uitest/impress_tests/drawinglayer.py
+++ b/uitest/impress_tests/drawinglayer.py
@@ -16,7 +16,7 @@ class ImpressDrawinglayerTest(UITestCase):
self.ui_test.create_doc_in_start_center("impress")
xTemplateDlg = self.xUITest.getTopFocusWindow()
xCancelBtn = xTemplateDlg.getChild("cancel")
xCancelBtn = xTemplateDlg.getChild("close")
self.ui_test.close_dialog_through_button(xCancelBtn)
change_measurement_unit(self, 'Centimeter')
@@ -67,7 +67,7 @@ class ImpressDrawinglayerTest(UITestCase):
self.ui_test.create_doc_in_start_center("impress")
xTemplateDlg = self.xUITest.getTopFocusWindow()
xCancelBtn = xTemplateDlg.getChild("cancel")
xCancelBtn = xTemplateDlg.getChild("close")
self.ui_test.close_dialog_through_button(xCancelBtn)
change_measurement_unit(self, 'Centimeter')
diff --git a/uitest/impress_tests/layouts.py b/uitest/impress_tests/layouts.py
index 8e10891..ebbe8e2 100644
--- a/uitest/impress_tests/layouts.py
+++ b/uitest/impress_tests/layouts.py
@@ -14,7 +14,7 @@ class ImpressLayouts(UITestCase):
self.ui_test.create_doc_in_start_center("impress")
xTemplateDlg = self.xUITest.getTopFocusWindow()
xCancelBtn = xTemplateDlg.getChild("cancel")
xCancelBtn = xTemplateDlg.getChild("close")
self.ui_test.close_dialog_through_button(xCancelBtn)
layouts= (".uno:AssignLayout?WhatLayout:long=20", ".uno:AssignLayout?WhatLayout:long=19",
diff --git a/uitest/impress_tests/start.py b/uitest/impress_tests/start.py
index 6406ceb..b6f5cbc 100644
--- a/uitest/impress_tests/start.py
+++ b/uitest/impress_tests/start.py
@@ -15,7 +15,7 @@ class SimpleImpressTest(UITestCase):
self.ui_test.create_doc_in_start_center("impress")
xTemplateDlg = self.xUITest.getTopFocusWindow()
xCancelBtn = xTemplateDlg.getChild("cancel")
xCancelBtn = xTemplateDlg.getChild("close")
self.ui_test.close_dialog_through_button(xCancelBtn)
xImpressDoc = self.xUITest.getTopFocusWindow()
@@ -32,7 +32,7 @@ class SimpleImpressTest(UITestCase):
self.ui_test.create_doc_in_start_center("impress")
xTemplateDlg = self.xUITest.getTopFocusWindow()
xCancelBtn = xTemplateDlg.getChild("cancel")
xCancelBtn = xTemplateDlg.getChild("close")
self.ui_test.close_dialog_through_button(xCancelBtn)
xImpressDoc = self.xUITest.getTopFocusWindow()