@openui5/sap.ui.rta 1.111.2 → 1.112.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (151) hide show
  1. package/package.json +6 -6
  2. package/src/sap/ui/rta/.library +1 -1
  3. package/src/sap/ui/rta/Client.js +1 -1
  4. package/src/sap/ui/rta/RuntimeAuthoring.js +41 -14
  5. package/src/sap/ui/rta/Utils.js +1 -1
  6. package/src/sap/ui/rta/appVariant/AppVariantManager.js +1 -1
  7. package/src/sap/ui/rta/command/AddIFrame.js +5 -1
  8. package/src/sap/ui/rta/command/AddProperty.js +1 -1
  9. package/src/sap/ui/rta/command/AddXML.js +1 -1
  10. package/src/sap/ui/rta/command/AddXMLAtExtensionPoint.js +1 -1
  11. package/src/sap/ui/rta/command/AppDescriptorCommand.js +1 -1
  12. package/src/sap/ui/rta/command/BaseCommand.js +9 -1
  13. package/src/sap/ui/rta/command/BindProperty.js +1 -1
  14. package/src/sap/ui/rta/command/Combine.js +1 -1
  15. package/src/sap/ui/rta/command/CommandFactory.js +1 -1
  16. package/src/sap/ui/rta/command/CompositeCommand.js +1 -1
  17. package/src/sap/ui/rta/command/ControlVariantConfigure.js +1 -1
  18. package/src/sap/ui/rta/command/ControlVariantSave.js +1 -1
  19. package/src/sap/ui/rta/command/ControlVariantSaveAs.js +1 -1
  20. package/src/sap/ui/rta/command/ControlVariantSetTitle.js +1 -1
  21. package/src/sap/ui/rta/command/ControlVariantSwitch.js +5 -2
  22. package/src/sap/ui/rta/command/CreateContainer.js +1 -1
  23. package/src/sap/ui/rta/command/CustomAdd.js +1 -1
  24. package/src/sap/ui/rta/command/FlexCommand.js +1 -1
  25. package/src/sap/ui/rta/command/LREPSerializer.js +1 -1
  26. package/src/sap/ui/rta/command/LocalReset.js +1 -1
  27. package/src/sap/ui/rta/command/Move.js +1 -1
  28. package/src/sap/ui/rta/command/Property.js +1 -1
  29. package/src/sap/ui/rta/command/Remove.js +1 -1
  30. package/src/sap/ui/rta/command/Rename.js +1 -1
  31. package/src/sap/ui/rta/command/Resize.js +1 -1
  32. package/src/sap/ui/rta/command/Reveal.js +1 -1
  33. package/src/sap/ui/rta/command/Settings.js +1 -1
  34. package/src/sap/ui/rta/command/Split.js +1 -1
  35. package/src/sap/ui/rta/command/Stack.js +22 -1
  36. package/src/sap/ui/rta/command/appDescriptor/AddLibrary.js +1 -1
  37. package/src/sap/ui/rta/command/compVariant/CompVariantContent.js +1 -1
  38. package/src/sap/ui/rta/command/compVariant/CompVariantSaveAs.js +1 -1
  39. package/src/sap/ui/rta/command/compVariant/CompVariantSwitch.js +5 -1
  40. package/src/sap/ui/rta/command/compVariant/CompVariantUpdate.js +1 -1
  41. package/src/sap/ui/rta/enablement/elementActionTest.js +1 -1
  42. package/src/sap/ui/rta/library.js +2 -2
  43. package/src/sap/ui/rta/messagebundle.properties +18 -0
  44. package/src/sap/ui/rta/messagebundle_ar.properties +13 -1
  45. package/src/sap/ui/rta/messagebundle_bg.properties +13 -1
  46. package/src/sap/ui/rta/messagebundle_ca.properties +13 -1
  47. package/src/sap/ui/rta/messagebundle_cs.properties +13 -1
  48. package/src/sap/ui/rta/messagebundle_cy.properties +13 -1
  49. package/src/sap/ui/rta/messagebundle_da.properties +13 -1
  50. package/src/sap/ui/rta/messagebundle_de.properties +13 -1
  51. package/src/sap/ui/rta/messagebundle_el.properties +13 -1
  52. package/src/sap/ui/rta/messagebundle_en.properties +13 -1
  53. package/src/sap/ui/rta/messagebundle_en_GB.properties +13 -1
  54. package/src/sap/ui/rta/messagebundle_en_US_sappsd.properties +13 -1
  55. package/src/sap/ui/rta/messagebundle_en_US_saprigi.properties +10 -2
  56. package/src/sap/ui/rta/messagebundle_en_US_saptrc.properties +13 -1
  57. package/src/sap/ui/rta/messagebundle_es.properties +13 -1
  58. package/src/sap/ui/rta/messagebundle_es_MX.properties +13 -1
  59. package/src/sap/ui/rta/messagebundle_et.properties +13 -1
  60. package/src/sap/ui/rta/messagebundle_fi.properties +13 -1
  61. package/src/sap/ui/rta/messagebundle_fr.properties +13 -1
  62. package/src/sap/ui/rta/messagebundle_fr_CA.properties +14 -2
  63. package/src/sap/ui/rta/messagebundle_hi.properties +13 -1
  64. package/src/sap/ui/rta/messagebundle_hr.properties +13 -1
  65. package/src/sap/ui/rta/messagebundle_hu.properties +13 -1
  66. package/src/sap/ui/rta/messagebundle_id.properties +13 -1
  67. package/src/sap/ui/rta/messagebundle_it.properties +13 -1
  68. package/src/sap/ui/rta/messagebundle_iw.properties +13 -1
  69. package/src/sap/ui/rta/messagebundle_ja.properties +13 -1
  70. package/src/sap/ui/rta/messagebundle_kk.properties +13 -1
  71. package/src/sap/ui/rta/messagebundle_ko.properties +13 -1
  72. package/src/sap/ui/rta/messagebundle_lt.properties +13 -1
  73. package/src/sap/ui/rta/messagebundle_lv.properties +13 -1
  74. package/src/sap/ui/rta/messagebundle_ms.properties +13 -1
  75. package/src/sap/ui/rta/messagebundle_nl.properties +13 -1
  76. package/src/sap/ui/rta/messagebundle_no.properties +13 -1
  77. package/src/sap/ui/rta/messagebundle_pl.properties +13 -1
  78. package/src/sap/ui/rta/messagebundle_pt.properties +14 -2
  79. package/src/sap/ui/rta/messagebundle_pt_PT.properties +13 -1
  80. package/src/sap/ui/rta/messagebundle_ro.properties +13 -1
  81. package/src/sap/ui/rta/messagebundle_ru.properties +13 -1
  82. package/src/sap/ui/rta/messagebundle_sh.properties +13 -1
  83. package/src/sap/ui/rta/messagebundle_sk.properties +13 -1
  84. package/src/sap/ui/rta/messagebundle_sl.properties +13 -1
  85. package/src/sap/ui/rta/messagebundle_sv.properties +13 -1
  86. package/src/sap/ui/rta/messagebundle_th.properties +13 -1
  87. package/src/sap/ui/rta/messagebundle_tr.properties +13 -1
  88. package/src/sap/ui/rta/messagebundle_uk.properties +13 -1
  89. package/src/sap/ui/rta/messagebundle_vi.properties +13 -1
  90. package/src/sap/ui/rta/messagebundle_zh_CN.properties +13 -1
  91. package/src/sap/ui/rta/messagebundle_zh_TW.properties +13 -1
  92. package/src/sap/ui/rta/plugin/AddXMLAtExtensionPoint.js +1 -1
  93. package/src/sap/ui/rta/plugin/BaseCreate.js +1 -1
  94. package/src/sap/ui/rta/plugin/Combine.js +1 -1
  95. package/src/sap/ui/rta/plugin/ControlVariant.js +1 -1
  96. package/src/sap/ui/rta/plugin/CreateContainer.js +1 -1
  97. package/src/sap/ui/rta/plugin/CutPaste.js +1 -1
  98. package/src/sap/ui/rta/plugin/DragDrop.js +1 -1
  99. package/src/sap/ui/rta/plugin/EasyAdd.js +1 -1
  100. package/src/sap/ui/rta/plugin/EasyRemove.js +1 -1
  101. package/src/sap/ui/rta/plugin/LocalReset.js +1 -1
  102. package/src/sap/ui/rta/plugin/Plugin.js +1 -1
  103. package/src/sap/ui/rta/plugin/RTAElementMover.js +1 -1
  104. package/src/sap/ui/rta/plugin/Remove.js +1 -1
  105. package/src/sap/ui/rta/plugin/Rename.js +15 -11
  106. package/src/sap/ui/rta/plugin/RenameHandler.js +6 -56
  107. package/src/sap/ui/rta/plugin/Resize.js +1 -1
  108. package/src/sap/ui/rta/plugin/Selection.js +1 -1
  109. package/src/sap/ui/rta/plugin/Settings.js +1 -1
  110. package/src/sap/ui/rta/plugin/Split.js +1 -1
  111. package/src/sap/ui/rta/plugin/Stretch.js +1 -1
  112. package/src/sap/ui/rta/plugin/additionalElements/ActionExtractor.js +1 -1
  113. package/src/sap/ui/rta/plugin/additionalElements/AddElementsDialog.js +1 -1
  114. package/src/sap/ui/rta/plugin/additionalElements/AdditionalElementsPlugin.js +1 -1
  115. package/src/sap/ui/rta/plugin/additionalElements/AdditionalElementsUtils.js +1 -1
  116. package/src/sap/ui/rta/plugin/additionalElements/CommandBuilder.js +1 -1
  117. package/src/sap/ui/rta/plugin/iframe/AddIFrame.js +13 -6
  118. package/src/sap/ui/rta/plugin/iframe/AddIFrameDialog.fragment.xml +73 -48
  119. package/src/sap/ui/rta/plugin/iframe/AddIFrameDialog.js +16 -14
  120. package/src/sap/ui/rta/plugin/iframe/AddIFrameDialogController.js +34 -3
  121. package/src/sap/ui/rta/service/Action.js +1 -1
  122. package/src/sap/ui/rta/service/ControllerExtension.js +1 -1
  123. package/src/sap/ui/rta/service/Outline.js +1 -1
  124. package/src/sap/ui/rta/service/Property.js +1 -1
  125. package/src/sap/ui/rta/service/Selection.js +1 -1
  126. package/src/sap/ui/rta/service/SupportTools.js +1 -1
  127. package/src/sap/ui/rta/themes/base/AddIFrame.less +9 -0
  128. package/src/sap/ui/rta/themes/base/Toolbar.adaptation.less +19 -21
  129. package/src/sap/ui/rta/themes/base/Toolbar.base.less +1 -1
  130. package/src/sap/ui/rta/toolbar/Adaptation.fragment.xml +30 -22
  131. package/src/sap/ui/rta/toolbar/Adaptation.js +118 -66
  132. package/src/sap/ui/rta/toolbar/Base.js +6 -2
  133. package/src/sap/ui/rta/toolbar/Fiori.js +49 -10
  134. package/src/sap/ui/rta/toolbar/FioriLike.js +1 -1
  135. package/src/sap/ui/rta/toolbar/OverflowToolbarButton.js +1 -1
  136. package/src/sap/ui/rta/toolbar/Personalization.js +1 -1
  137. package/src/sap/ui/rta/toolbar/Standalone.js +1 -1
  138. package/src/sap/ui/rta/toolbar/contextBased/ManageAdaptations.js +16 -6
  139. package/src/sap/ui/rta/toolbar/contextBased/ManageAdaptationsDialog.fragment.xml +17 -0
  140. package/src/sap/ui/rta/toolbar/contextBased/SaveAsAdaptation.js +1 -1
  141. package/src/sap/ui/rta/toolbar/translation/Translation.js +1 -1
  142. package/src/sap/ui/rta/toolbar/versioning/Versioning.js +1 -1
  143. package/src/sap/ui/rta/util/PluginManager.js +1 -1
  144. package/src/sap/ui/rta/util/PopupManager.js +1 -1
  145. package/src/sap/ui/rta/util/ReloadManager.js +1 -1
  146. package/src/sap/ui/rta/util/ServiceEventBus.js +1 -1
  147. package/src/sap/ui/rta/util/UrlParser.js +14 -7
  148. package/src/sap/ui/rta/util/changeVisualization/ChangeIndicator.js +1 -1
  149. package/src/sap/ui/rta/util/changeVisualization/ChangeIndicatorRegistry.js +8 -5
  150. package/src/sap/ui/rta/util/changeVisualization/ChangeVisualization.js +15 -10
  151. package/src/sap/ui/rta/util/validateText.js +71 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openui5/sap.ui.rta",
3
- "version": "1.111.2",
3
+ "version": "1.112.2",
4
4
  "description": "OpenUI5 UI Library sap.ui.rta",
5
5
  "author": "SAP SE (https://www.sap.com)",
6
6
  "license": "Apache-2.0",
@@ -14,10 +14,10 @@
14
14
  "url": "https://github.com/SAP/openui5.git"
15
15
  },
16
16
  "dependencies": {
17
- "@openui5/sap.m": "1.111.2",
18
- "@openui5/sap.ui.core": "1.111.2",
19
- "@openui5/sap.ui.dt": "1.111.2",
20
- "@openui5/sap.ui.fl": "1.111.2",
21
- "@openui5/sap.ui.layout": "1.111.2"
17
+ "@openui5/sap.m": "1.112.2",
18
+ "@openui5/sap.ui.core": "1.112.2",
19
+ "@openui5/sap.ui.dt": "1.112.2",
20
+ "@openui5/sap.ui.fl": "1.112.2",
21
+ "@openui5/sap.ui.layout": "1.112.2"
22
22
  }
23
23
  }
@@ -6,7 +6,7 @@
6
6
  <copyright>OpenUI5
7
7
  * (c) Copyright 2009-2023 SAP SE or an SAP affiliate company.
8
8
  * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.</copyright>
9
- <version>1.111.2</version>
9
+ <version>1.112.2</version>
10
10
 
11
11
  <documentation>SAPUI5 library with RTA controls.</documentation>
12
12
 
@@ -57,7 +57,7 @@ sap.ui.define([
57
57
  * @alias sap.ui.rta.Client
58
58
  * @author SAP SE
59
59
  * @since 1.56.0
60
- * @version 1.111.2
60
+ * @version 1.112.2
61
61
  * @private
62
62
  * @ui5-restricted
63
63
  */
@@ -116,7 +116,7 @@ sap.ui.define([
116
116
  * @class The runtime authoring allows to adapt the fields of a running application.
117
117
  * @extends sap.ui.base.ManagedObject
118
118
  * @author SAP SE
119
- * @version 1.111.2
119
+ * @version 1.112.2
120
120
  * @constructor
121
121
  * @private
122
122
  * @since 1.30
@@ -589,10 +589,13 @@ sap.ui.define([
589
589
  };
590
590
 
591
591
  function showSaveConfirmation() {
592
- return Utils.showMessageBox("warning", "MSG_UNSAVED_CHANGES_ON_CLOSE", {
592
+ var bVersionEnabled = this._oVersionsModel.getProperty("/versioningEnabled");
593
+ var sWarningMessageKey = bVersionEnabled ? "MSG_UNSAVED_DRAFT_CHANGES_ON_CLOSE" : "MSG_UNSAVED_CHANGES_ON_CLOSE";
594
+ var sSaveButtonTextKey = bVersionEnabled ? "BTN_UNSAVED_DRAFT_CHANGES_ON_CLOSE_SAVE" : "BTN_UNSAVED_CHANGES_ON_CLOSE_SAVE";
595
+ return Utils.showMessageBox("warning", sWarningMessageKey, {
593
596
  titleKey: "TIT_UNSAVED_CHANGES_ON_CLOSE",
594
597
  actionKeys: [
595
- "BTN_UNSAVED_CHANGES_ON_CLOSE_SAVE",
598
+ sSaveButtonTextKey,
596
599
  "BTN_UNSAVED_CHANGES_ON_CLOSE_DONT_SAVE"
597
600
  ],
598
601
  emphasizedActionKey: "BTN_UNSAVED_CHANGES_ON_CLOSE_SAVE",
@@ -614,10 +617,9 @@ sap.ui.define([
614
617
  checkToolbarAndExecuteFunction.call(this, "setBusy", true);
615
618
  return waitForPendingActions.call(this)
616
619
  .then(function() {
617
- var oCommandStack = this.getCommandStack();
618
620
  var sLayer = this.getLayer();
619
- if (sLayer !== Layer.USER && !bSkipSave && oCommandStack.canUndo()) {
620
- return showSaveConfirmation()
621
+ if (sLayer !== Layer.USER && !bSkipSave && this.canSave()) {
622
+ return showSaveConfirmation.call(this)
621
623
  .then(function (sAction) {
622
624
  if (sAction === MessageBox.Action.CANCEL) {
623
625
  bUserCancelled = true;
@@ -886,6 +888,10 @@ sap.ui.define([
886
888
  return this.getCommandStack().canUndo();
887
889
  };
888
890
 
891
+ RuntimeAuthoring.prototype.canSave = function() {
892
+ return this.getCommandStack().canSave();
893
+ };
894
+
889
895
  RuntimeAuthoring.prototype.canRedo = function() {
890
896
  return this.getCommandStack().canRedo();
891
897
  };
@@ -932,8 +938,7 @@ sap.ui.define([
932
938
  */
933
939
  RuntimeAuthoring.prototype._onUnload = function() {
934
940
  // this function is still in the prototype scope for easier testing
935
- var oCommandStack = this.getCommandStack();
936
- if (oCommandStack.canUndo() && this.getShowWindowUnloadDialog()) {
941
+ if (this.canSave() && this.getShowWindowUnloadDialog()) {
937
942
  return this._getTextResources().getText("MSG_UNSAVED_CHANGES");
938
943
  }
939
944
  window.onbeforeunload = this._oldUnloadHandler;
@@ -1083,6 +1088,7 @@ sap.ui.define([
1083
1088
  var oCommandStack = this.getCommandStack();
1084
1089
  var bCanUndo = oCommandStack.canUndo();
1085
1090
  var bCanRedo = oCommandStack.canRedo();
1091
+ var bCanSave = oCommandStack.canSave();
1086
1092
  var bWasSaved = oCommandStack.getSaved();
1087
1093
  var bTranslationRelevantDirtyChange = this._oToolbarControlsModel.getProperty("/translation/visible") &&
1088
1094
  TranslationAPI.hasTranslationRelevantDirtyChanges({layer: Layer.CUSTOMER, selector: this.getRootControlInstance()});
@@ -1091,8 +1097,8 @@ sap.ui.define([
1091
1097
  this._oVersionsModel.setDirtyChanges(PersistenceWriteAPI.hasDirtyChanges({selector: this.getRootControlInstance()}));
1092
1098
  this._oToolbarControlsModel.setProperty("/undo/enabled", bCanUndo);
1093
1099
  this._oToolbarControlsModel.setProperty("/redo/enabled", bCanRedo);
1094
- this._oToolbarControlsModel.setProperty("/save/enabled", bCanUndo);
1095
- this._oToolbarControlsModel.setProperty("/restore/enabled", this.bInitialResetEnabled || bCanUndo || bWasSaved);
1100
+ this._oToolbarControlsModel.setProperty("/save/enabled", bCanSave);
1101
+ this._oToolbarControlsModel.setProperty("/restore/enabled", this.bInitialResetEnabled || bCanSave || bWasSaved);
1096
1102
  this._oToolbarControlsModel.setProperty("/translation/enabled", this.bPersistedDataTranslatable || bTranslationRelevantDirtyChange);
1097
1103
  }
1098
1104
  this.fireUndoRedoStackModified();
@@ -1157,7 +1163,18 @@ sap.ui.define([
1157
1163
 
1158
1164
  function saveOnly(oEvent) {
1159
1165
  var fnCallback = oEvent.getParameter("callback") || function() {};
1166
+ var bVersionsEnabled = this._oVersionsModel.getProperty("/versioningEnabled");
1160
1167
  return this.save()
1168
+ .then(function() {
1169
+ showMessageToast.call(
1170
+ this,
1171
+ bVersionsEnabled ? "MSG_SAVE_DRAFT_SUCCESS" : "MSG_SAVE_SUCCESS",
1172
+ { duration: 5000 }
1173
+ );
1174
+ }.bind(this))
1175
+ .catch(function(vError) {
1176
+ return showTechnicalError(vError);
1177
+ })
1161
1178
  .then(fnCallback);
1162
1179
  }
1163
1180
 
@@ -1276,7 +1293,7 @@ sap.ui.define([
1276
1293
  return;
1277
1294
  }
1278
1295
 
1279
- if (this.canUndo()) {
1296
+ if (this.canSave()) {
1280
1297
  this._sSwitchToVersion = sVersion;
1281
1298
  Utils.showMessageBox("warning", "MSG_SWITCH_VERSION_DIALOG", {
1282
1299
  titleKey: "TIT_SWITCH_VERSION_DIALOG",
@@ -1584,8 +1601,9 @@ sap.ui.define([
1584
1601
  *
1585
1602
  * @param {object} vAction - The create action from designtime metadata
1586
1603
  * @param {string} sNewControlID - The id of the newly created container
1604
+ * @param {string} sNewContainerName - The name of the newly created container
1587
1605
  */
1588
- function scheduleRenameOnCreatedContainer(vAction, sNewControlID) {
1606
+ function scheduleRenameOnCreatedContainer(vAction, sNewControlID, sNewContainerName) {
1589
1607
  var fnStartEdit = function(oElementOverlay) {
1590
1608
  oElementOverlay.setSelected(true);
1591
1609
  this.getPluginManager().getPlugin("rename").startEdit(oElementOverlay);
@@ -1596,7 +1614,15 @@ sap.ui.define([
1596
1614
  var sNewContainerID = this.getPluginManager().getPlugin("createContainer").getCreatedContainerId(vAction, oElementOverlay.getElement().getId());
1597
1615
  var oContainerElementOverlay = OverlayRegistry.getOverlay(sNewContainerID);
1598
1616
  if (oContainerElementOverlay) {
1599
- fnStartEdit(oContainerElementOverlay);
1617
+ if (sNewContainerName) {
1618
+ this.getPluginManager().getPlugin("rename").createRenameCommand(oContainerElementOverlay, sNewContainerName)
1619
+ .then(function() {
1620
+ // The create container and rename must be a single command in the stack
1621
+ this.getCommandStack().compositeLastTwoCommands();
1622
+ }.bind(this));
1623
+ } else {
1624
+ fnStartEdit(oContainerElementOverlay);
1625
+ }
1600
1626
  } else {
1601
1627
  scheduleOnCreatedAndVisible.call(this, sNewContainerID, fnStartEdit);
1602
1628
  }
@@ -1614,6 +1640,7 @@ sap.ui.define([
1614
1640
  var oCommand = oEvent.getParameter("command");
1615
1641
  var sNewControlID = oEvent.getParameter("newControlId");
1616
1642
  var vAction = oEvent.getParameter("action");
1643
+ var sContainerTitle = oEvent.getParameter("title");
1617
1644
 
1618
1645
  this._pElementModified = this._pElementModified.then(function() {
1619
1646
  this.getPluginManager().handleStopCutPaste();
@@ -1628,7 +1655,7 @@ sap.ui.define([
1628
1655
  }
1629
1656
  });
1630
1657
  if (vAction) {
1631
- scheduleRenameOnCreatedContainer.call(this, vAction, sNewControlID);
1658
+ scheduleRenameOnCreatedContainer.call(this, vAction, sNewControlID, sContainerTitle);
1632
1659
  }
1633
1660
  }
1634
1661
  return this.getCommandStack().pushAndExecute(oCommand)
@@ -45,7 +45,7 @@ function(
45
45
  *
46
46
  * @namespace
47
47
  * @author SAP SE
48
- * @version 1.111.2
48
+ * @version 1.112.2
49
49
  *
50
50
  * @private
51
51
  * @since 1.30
@@ -24,7 +24,7 @@ sap.ui.define([
24
24
  * @class
25
25
  * @extends sap.ui.base.ManagedObject
26
26
  * @author SAP SE
27
- * @version 1.111.2
27
+ * @version 1.112.2
28
28
  * @constructor
29
29
  * @private
30
30
  * @since 1.53
@@ -16,7 +16,7 @@ sap.ui.define([
16
16
  * @class
17
17
  * @extends sap.ui.rta.command.FlexCommand
18
18
  * @author SAP SE
19
- * @version 1.111.2
19
+ * @version 1.112.2
20
20
  * @constructor
21
21
  * @private
22
22
  * @since 1.75
@@ -52,6 +52,10 @@ sap.ui.define([
52
52
  type: "string",
53
53
  group: "content"
54
54
  },
55
+ title: {
56
+ type: "string",
57
+ group: "content"
58
+ },
55
59
  changeType: {
56
60
  type: "string",
57
61
  defaultValue: "addIFrame"
@@ -14,7 +14,7 @@ sap.ui.define([
14
14
  * @class
15
15
  * @extends sap.ui.rta.command.FlexCommand
16
16
  * @author SAP SE
17
- * @version 1.111.2
17
+ * @version 1.112.2
18
18
  * @constructor
19
19
  * @private
20
20
  * @since 1.78
@@ -16,7 +16,7 @@ sap.ui.define([
16
16
  * @class
17
17
  * @extends sap.ui.rta.command.FlexCommand
18
18
  * @author SAP SE
19
- * @version 1.111.2
19
+ * @version 1.112.2
20
20
  * @constructor
21
21
  * @private
22
22
  * @since 1.54
@@ -24,7 +24,7 @@ sap.ui.define([
24
24
  * @class
25
25
  * @extends sap.ui.rta.command.FlexCommand
26
26
  * @author SAP SE
27
- * @version 1.111.2
27
+ * @version 1.112.2
28
28
  * @constructor
29
29
  * @private
30
30
  * @since 1.76
@@ -21,7 +21,7 @@ sap.ui.define([
21
21
  * @extends sap.ui.rta.command.BaseCommand
22
22
  *
23
23
  * @author SAP SE
24
- * @version 1.111.2
24
+ * @version 1.112.2
25
25
  *
26
26
  * @constructor
27
27
  * @private
@@ -13,7 +13,7 @@ sap.ui.define(["sap/ui/base/ManagedObject"], function(ManagedObject) {
13
13
  * @extends sap.ui.base.ManagedObject
14
14
  *
15
15
  * @author SAP SE
16
- * @version 1.111.2
16
+ * @version 1.112.2
17
17
  *
18
18
  * @constructor
19
19
  * @private
@@ -31,6 +31,14 @@ sap.ui.define(["sap/ui/base/ManagedObject"], function(ManagedObject) {
31
31
  },
32
32
  runtimeOnly: {
33
33
  type: "boolean"
34
+ },
35
+ /**
36
+ * decides if the command execution is relevant for persistency which
37
+ * enables or disables the save option
38
+ */
39
+ relevantForSave: {
40
+ type: "boolean",
41
+ defaultValue: true
34
42
  }
35
43
  },
36
44
  associations: {
@@ -26,7 +26,7 @@ sap.ui.define([
26
26
  * @class
27
27
  * @extends sap.ui.rta.command.FlexCommand
28
28
  * @author SAP SE
29
- * @version 1.111.2
29
+ * @version 1.112.2
30
30
  * @constructor
31
31
  * @private
32
32
  * @since 1.38
@@ -16,7 +16,7 @@ sap.ui.define([
16
16
  * @class
17
17
  * @extends sap.ui.rta.command.FlexCommand
18
18
  * @author SAP SE
19
- * @version 1.111.2
19
+ * @version 1.112.2
20
20
  * @constructor
21
21
  * @private
22
22
  * @since 1.46
@@ -485,7 +485,7 @@ sap.ui.define([
485
485
  * @extends sap.ui.base.ManagedObject
486
486
  *
487
487
  * @author SAP SE
488
- * @version 1.111.2
488
+ * @version 1.112.2
489
489
  *
490
490
  * @constructor
491
491
  * @private
@@ -21,7 +21,7 @@ sap.ui.define([
21
21
  * @extends sap.ui.rta.command.BaseCommand
22
22
  *
23
23
  * @author SAP SE
24
- * @version 1.111.2
24
+ * @version 1.112.2
25
25
  *
26
26
  * @constructor
27
27
  * @private
@@ -24,7 +24,7 @@ sap.ui.define([
24
24
  * @class
25
25
  * @extends sap.ui.rta.command.BaseCommand
26
26
  * @author SAP SE
27
- * @version 1.111.2
27
+ * @version 1.112.2
28
28
  * @constructor
29
29
  * @private
30
30
  * @since 1.52
@@ -20,7 +20,7 @@ sap.ui.define([
20
20
  * @class
21
21
  * @extends sap.ui.rta.command.BaseCommand
22
22
  * @author SAP SE
23
- * @version 1.111.2
23
+ * @version 1.112.2
24
24
  * @constructor
25
25
  * @private
26
26
  * @since 1.86
@@ -28,7 +28,7 @@ sap.ui.define([
28
28
  * @class
29
29
  * @extends sap.ui.rta.command.BaseCommand
30
30
  * @author SAP SE
31
- * @version 1.111.2
31
+ * @version 1.112.2
32
32
  * @constructor
33
33
  * @private
34
34
  * @since 1.86
@@ -24,7 +24,7 @@ sap.ui.define([
24
24
  * @class
25
25
  * @extends sap.ui.rta.command.BaseCommand
26
26
  * @author SAP SE
27
- * @version 1.111.2
27
+ * @version 1.112.2
28
28
  * @constructor
29
29
  * @private
30
30
  * @since 1.50
@@ -22,7 +22,7 @@ sap.ui.define([
22
22
  * @class
23
23
  * @extends sap.ui.rta.command.BaseCommand
24
24
  * @author SAP SE
25
- * @version 1.111.2
25
+ * @version 1.112.2
26
26
  * @constructor
27
27
  * @private
28
28
  * @since 1.50
@@ -44,6 +44,10 @@ sap.ui.define([
44
44
  },
45
45
  associations: {},
46
46
  events: {}
47
+ },
48
+ constructor: function() {
49
+ BaseCommand.apply(this, arguments);
50
+ this.setRelevantForSave(false);
47
51
  }
48
52
  });
49
53
 
@@ -60,7 +64,6 @@ sap.ui.define([
60
64
  return oElement ? flUtils.getAppComponentForControl(oElement) : this.getSelector().appComponent;
61
65
  };
62
66
 
63
-
64
67
  /**
65
68
  * Template Method to implement execute logic, with ensure precondition Element is available.
66
69
  *
@@ -12,7 +12,7 @@ sap.ui.define(["sap/ui/rta/command/FlexCommand"], function(FlexCommand) {
12
12
  * @class
13
13
  * @extends sap.ui.rta.command.FlexCommand
14
14
  * @author SAP SE
15
- * @version 1.111.2
15
+ * @version 1.112.2
16
16
  * @constructor
17
17
  * @private
18
18
  * @since 1.34
@@ -12,7 +12,7 @@ sap.ui.define(["sap/ui/rta/command/FlexCommand"], function(FlexCommand) {
12
12
  * @class
13
13
  * @extends sap.ui.rta.command.FlexCommand
14
14
  * @author SAP SE
15
- * @version 1.111.2
15
+ * @version 1.112.2
16
16
  * @constructor
17
17
  * @private
18
18
  * @since 1.62
@@ -33,7 +33,7 @@ sap.ui.define([
33
33
  * @extends sap.ui.rta.command.BaseCommand
34
34
  *
35
35
  * @author SAP SE
36
- * @version 1.111.2
36
+ * @version 1.112.2
37
37
  *
38
38
  * @constructor
39
39
  * @private
@@ -27,7 +27,7 @@ sap.ui.define([
27
27
  * @class
28
28
  * @extends sap.ui.base.ManagedObject
29
29
  * @author SAP SE
30
- * @version 1.111.2
30
+ * @version 1.112.2
31
31
  * @constructor
32
32
  * @private
33
33
  * @since 1.42
@@ -20,7 +20,7 @@ sap.ui.define([
20
20
  * @class
21
21
  * @extends sap.ui.rta.command.BaseCommand
22
22
  * @author SAP SE
23
- * @version 1.111.2
23
+ * @version 1.112.2
24
24
  * @constructor
25
25
  * @private
26
26
  * @since 1.90
@@ -17,7 +17,7 @@ function(
17
17
  * @class
18
18
  * @extends sap.ui.rta.command.FlexCommand
19
19
  * @author SAP SE
20
- * @version 1.111.2
20
+ * @version 1.112.2
21
21
  * @constructor
22
22
  * @private
23
23
  * @since 1.34
@@ -16,7 +16,7 @@ sap.ui.define([
16
16
  * @class
17
17
  * @extends sap.ui.rta.command.FlexCommand
18
18
  * @author SAP SE
19
- * @version 1.111.2
19
+ * @version 1.112.2
20
20
  * @constructor
21
21
  * @private
22
22
  * @since 1.34
@@ -12,7 +12,7 @@ sap.ui.define(["sap/ui/rta/command/FlexCommand"], function(FlexCommand) {
12
12
  * @class
13
13
  * @extends sap.ui.rta.command.FlexCommand
14
14
  * @author SAP SE
15
- * @version 1.111.2
15
+ * @version 1.112.2
16
16
  * @constructor
17
17
  * @private
18
18
  * @since 1.42
@@ -12,7 +12,7 @@ sap.ui.define(["sap/ui/rta/command/FlexCommand"], function(FlexCommand) {
12
12
  * @class
13
13
  * @extends sap.ui.rta.command.FlexCommand
14
14
  * @author SAP SE
15
- * @version 1.111.2
15
+ * @version 1.112.2
16
16
  * @constructor
17
17
  * @private
18
18
  * @since 1.34
@@ -16,7 +16,7 @@ sap.ui.define([
16
16
  * @class
17
17
  * @extends sap.ui.rta.command.FlexCommand
18
18
  * @author SAP SE
19
- * @version 1.111.2
19
+ * @version 1.112.2
20
20
  * @constructor
21
21
  * @private
22
22
  * @since 1.101
@@ -12,7 +12,7 @@ sap.ui.define(["sap/ui/rta/command/FlexCommand"], function(FlexCommand) {
12
12
  * @class
13
13
  * @extends sap.ui.rta.command.FlexCommand
14
14
  * @author SAP SE
15
- * @version 1.111.2
15
+ * @version 1.112.2
16
16
  * @constructor
17
17
  * @private
18
18
  * @since 1.44
@@ -12,7 +12,7 @@ sap.ui.define(["sap/ui/rta/command/FlexCommand"], function(FlexCommand) {
12
12
  * @class
13
13
  * @extends sap.ui.rta.command.FlexCommand
14
14
  * @author SAP SE
15
- * @version 1.111.2
15
+ * @version 1.112.2
16
16
  * @constructor
17
17
  * @private
18
18
  * @since 1.44
@@ -14,7 +14,7 @@ sap.ui.define([
14
14
  * @class
15
15
  * @extends sap.ui.rta.command.FlexCommand
16
16
  * @author SAP SE
17
- * @version 1.111.2
17
+ * @version 1.112.2
18
18
  * @constructor
19
19
  * @private
20
20
  * @since 1.46
@@ -59,7 +59,7 @@ sap.ui.define([
59
59
  * @class
60
60
  * @extends sap.ui.base.ManagedObject
61
61
  * @author SAP SE
62
- * @version 1.111.2
62
+ * @version 1.112.2
63
63
  * @constructor
64
64
  * @private
65
65
  * @since 1.34
@@ -289,6 +289,12 @@ sap.ui.define([
289
289
  return (this._toBeExecuted + 1) < this.getCommands().length;
290
290
  };
291
291
 
292
+ Stack.prototype.canSave = function() {
293
+ return this.canUndo() && this.getAllExecutedCommands().some(function(oCommand) {
294
+ return oCommand.getRelevantForSave();
295
+ });
296
+ };
297
+
292
298
  Stack.prototype.undo = function() {
293
299
  return this._unExecute();
294
300
  };
@@ -343,5 +349,20 @@ sap.ui.define([
343
349
  return aCommands;
344
350
  };
345
351
 
352
+ /**
353
+ * Combines the last two commands into a composite command
354
+ *
355
+ * @private
356
+ */
357
+ Stack.prototype.compositeLastTwoCommands = function() {
358
+ var oLastCommand = this.pop();
359
+ var oSecondLastCommand = this.pop();
360
+
361
+ var oCompositeCommand = new CompositeCommand();
362
+ oCompositeCommand.addCommand(oSecondLastCommand);
363
+ oCompositeCommand.addCommand(oLastCommand);
364
+ this.push(oCompositeCommand);
365
+ };
366
+
346
367
  return Stack;
347
368
  });
@@ -17,7 +17,7 @@ sap.ui.define([
17
17
  * @extends sap.ui.rta.command.AppDescriptorCommand
18
18
  *
19
19
  * @author SAP SE
20
- * @version 1.111.2
20
+ * @version 1.112.2
21
21
  *
22
22
  * @constructor
23
23
  * @private
@@ -20,7 +20,7 @@ sap.ui.define([
20
20
  * @class
21
21
  * @extends sap.ui.rta.command.BaseCommand
22
22
  * @author SAP SE
23
- * @version 1.111.2
23
+ * @version 1.112.2
24
24
  * @constructor
25
25
  * @private
26
26
  * @since 1.102
@@ -20,7 +20,7 @@ sap.ui.define([
20
20
  * @class
21
21
  * @extends sap.ui.rta.command.BaseCommand
22
22
  * @author SAP SE
23
- * @version 1.111.2
23
+ * @version 1.112.2
24
24
  * @constructor
25
25
  * @private
26
26
  * @since 1.87
@@ -18,7 +18,7 @@ sap.ui.define([
18
18
  * @class
19
19
  * @extends sap.ui.rta.command.BaseCommand
20
20
  * @author SAP SE
21
- * @version 1.111.2
21
+ * @version 1.112.2
22
22
  * @constructor
23
23
  * @private
24
24
  * @since 1.87
@@ -38,6 +38,10 @@ sap.ui.define([
38
38
  type: "boolean"
39
39
  }
40
40
  }
41
+ },
42
+ constructor: function() {
43
+ BaseCommand.apply(this, arguments);
44
+ this.setRelevantForSave(false);
41
45
  }
42
46
  });
43
47
 
@@ -22,7 +22,7 @@ sap.ui.define([
22
22
  * @class
23
23
  * @extends sap.ui.rta.command.BaseCommand
24
24
  * @author SAP SE
25
- * @version 1.111.2
25
+ * @version 1.112.2
26
26
  * @constructor
27
27
  * @private
28
28
  * @since 1.87
@@ -53,7 +53,7 @@ sap.ui.define([
53
53
  * E.g. <code>elementActionTest.only("Remove");</code>
54
54
  *
55
55
  * @author SAP SE
56
- * @version 1.111.2
56
+ * @version 1.112.2
57
57
  *
58
58
  * @static
59
59
  * @since 1.42