@openui5/sap.ui.table 1.113.0 → 1.115.0
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.
- package/.reuse/dep5 +0 -5
- package/THIRDPARTY.txt +1 -7
- package/package.json +3 -3
- package/src/sap/ui/table/.library +1 -1
- package/src/sap/ui/table/AnalyticalColumn.js +1 -1
- package/src/sap/ui/table/AnalyticalColumnMenu.js +1 -1
- package/src/sap/ui/table/AnalyticalTable.js +3 -13
- package/src/sap/ui/table/Column.js +5 -1
- package/src/sap/ui/table/ColumnMenu.js +1 -1
- package/src/sap/ui/table/CreationRow.js +1 -1
- package/src/sap/ui/table/Row.js +2 -2
- package/src/sap/ui/table/RowAction.js +1 -1
- package/src/sap/ui/table/RowActionItem.js +1 -1
- package/src/sap/ui/table/RowSettings.js +1 -1
- package/src/sap/ui/table/Table.js +27 -45
- package/src/sap/ui/table/TablePersoController.js +4 -1
- package/src/sap/ui/table/TableRenderer.js +13 -8
- package/src/sap/ui/table/TreeTable.js +1 -1
- package/src/sap/ui/table/extensions/Accessibility.js +5 -5
- package/src/sap/ui/table/extensions/AccessibilityRender.js +3 -4
- package/src/sap/ui/table/extensions/DragAndDrop.js +1 -1
- package/src/sap/ui/table/extensions/ExtensionBase.js +1 -1
- package/src/sap/ui/table/extensions/Keyboard.js +1 -1
- package/src/sap/ui/table/extensions/KeyboardDelegate.js +83 -50
- package/src/sap/ui/table/extensions/Pointer.js +7 -33
- package/src/sap/ui/table/extensions/Scrolling.js +1 -1
- package/src/sap/ui/table/extensions/ScrollingIOS.js +1 -1
- package/src/sap/ui/table/extensions/Synchronization.js +2 -2
- package/src/sap/ui/table/library.js +56 -23
- package/src/sap/ui/table/menus/ColumnHeaderMenuAdapter.js +1 -1
- package/src/sap/ui/table/menus/MobileColumnHeaderMenuAdapter.js +2 -2
- package/src/sap/ui/table/plugins/BindingSelection.js +61 -19
- package/src/sap/ui/table/plugins/MultiSelectionPlugin.js +34 -21
- package/src/sap/ui/table/plugins/ODataV4Selection.js +506 -0
- package/src/sap/ui/table/plugins/PluginBase.js +1 -1
- package/src/sap/ui/table/plugins/SelectionModelSelection.js +71 -24
- package/src/sap/ui/table/plugins/SelectionPlugin.js +47 -160
- package/src/sap/ui/table/plugins/V4Aggregation.js +12 -10
- package/src/sap/ui/table/rowmodes/AutoRowMode.js +1 -1
- package/src/sap/ui/table/rowmodes/FixedRowMode.js +1 -1
- package/src/sap/ui/table/rowmodes/InteractiveRowMode.js +1 -1
- package/src/sap/ui/table/rowmodes/RowMode.js +1 -1
- package/src/sap/ui/table/rowmodes/VariableRowMode.js +1 -1
- package/src/sap/ui/table/rules/Plugins.support.js +4 -4
- package/src/sap/ui/table/utils/TableUtils.js +27 -72
- package/src/sap/ui/table/utils/_BindingUtils.js +1 -1
- package/src/sap/ui/table/utils/_ColumnUtils.js +1 -1
- package/src/sap/ui/table/utils/_GroupingUtils.js +1 -1
- package/src/sap/ui/table/utils/_HookUtils.js +1 -1
- package/src/sap/ui/table/utils/_MenuUtils.js +1 -1
package/.reuse/dep5
CHANGED
|
@@ -192,11 +192,6 @@ Copyright: 2012 Matteo Spinelli
|
|
|
192
192
|
License: MIT
|
|
193
193
|
Comment: these files belong to: cubiq.org - swipeview
|
|
194
194
|
|
|
195
|
-
Files: src/sap.ui.core/src/sap/ui/thirdparty/mobify-carousel.js
|
|
196
|
-
Copyright: Mobify R&D Inc.
|
|
197
|
-
License: MIT
|
|
198
|
-
Comment: these files belong to: Mobify.js
|
|
199
|
-
|
|
200
195
|
Files: src/sap.ui.core/src/sap/ui/thirdparty/zyngascroll.js
|
|
201
196
|
Copyright: 2011 Zynga Inc.
|
|
202
197
|
License: MIT
|
package/THIRDPARTY.txt
CHANGED
|
@@ -143,12 +143,6 @@ License: MIT
|
|
|
143
143
|
License Text: https://github.com/SAP/openui5/blob/master/LICENSES/MIT.txt
|
|
144
144
|
Contained in: src/sap.ui.core/src/sap/ui/thirdparty/swipe-view.js
|
|
145
145
|
|
|
146
|
-
Component: Mobify.js, version: 1.1
|
|
147
|
-
Copyright: Mobify R&D Inc.
|
|
148
|
-
License: MIT
|
|
149
|
-
License Text: https://github.com/SAP/openui5/blob/master/LICENSES/MIT.txt
|
|
150
|
-
Contained in: src/sap.ui.core/src/sap/ui/thirdparty/mobify-carousel.js
|
|
151
|
-
|
|
152
146
|
Component: Zynga Scroller, version: 1.2.1-0-g5d43806
|
|
153
147
|
Copyright: 2011 Zynga Inc.
|
|
154
148
|
License: MIT
|
|
@@ -478,7 +472,7 @@ License: Apache-2.0
|
|
|
478
472
|
License Text: https://github.com/SAP/openui5/blob/master/LICENSES/Apache-2.0.txt
|
|
479
473
|
Contained in: lib/jsdoc/ui5/plugin.js
|
|
480
474
|
|
|
481
|
-
Component: SAP Theming Base Content, version: 11.
|
|
475
|
+
Component: SAP Theming Base Content, version: 11.3.0
|
|
482
476
|
Copyright: SAP SE or an SAP affiliate company and Theming Base Content contributors
|
|
483
477
|
License: Apache-2.0
|
|
484
478
|
License Text: https://github.com/SAP/openui5/blob/master/LICENSES/Apache-2.0.txt
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@openui5/sap.ui.table",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.115.0",
|
|
4
4
|
"description": "OpenUI5 UI Library sap.ui.table",
|
|
5
5
|
"author": "SAP SE (https://www.sap.com)",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
"url": "https://github.com/SAP/openui5.git"
|
|
15
15
|
},
|
|
16
16
|
"dependencies": {
|
|
17
|
-
"@openui5/sap.ui.core": "1.
|
|
18
|
-
"@openui5/sap.ui.unified": "1.
|
|
17
|
+
"@openui5/sap.ui.core": "1.115.0",
|
|
18
|
+
"@openui5/sap.ui.unified": "1.115.0"
|
|
19
19
|
}
|
|
20
20
|
}
|
|
@@ -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.
|
|
9
|
+
<version>1.115.0</version>
|
|
10
10
|
|
|
11
11
|
<documentation>Table-like controls, mainly for desktop scenarios.</documentation>
|
|
12
12
|
|
|
@@ -42,7 +42,6 @@ sap.ui.define([
|
|
|
42
42
|
"use strict";
|
|
43
43
|
|
|
44
44
|
var GroupEventType = library.GroupEventType;
|
|
45
|
-
var SortOrder = library.SortOrder;
|
|
46
45
|
var TreeAutoExpandMode = library.TreeAutoExpandMode;
|
|
47
46
|
var _private = TableUtils.createWeakMapFacade();
|
|
48
47
|
|
|
@@ -58,7 +57,7 @@ sap.ui.define([
|
|
|
58
57
|
* @see https://github.com/SAP/odata-vocabularies/blob/main/docs/v2-annotations.md
|
|
59
58
|
*
|
|
60
59
|
* @extends sap.ui.table.Table
|
|
61
|
-
* @version 1.
|
|
60
|
+
* @version 1.115.0
|
|
62
61
|
*
|
|
63
62
|
* @constructor
|
|
64
63
|
* @public
|
|
@@ -346,15 +345,6 @@ sap.ui.define([
|
|
|
346
345
|
};
|
|
347
346
|
|
|
348
347
|
AnalyticalTable.prototype._applyAnalyticalBindingInfo = function(oBindingInfo) {
|
|
349
|
-
// extract the sorters from the columns (TODO: reconsider this!)
|
|
350
|
-
var aColumns = this.getColumns();
|
|
351
|
-
for (var i = 0, l = aColumns.length; i < l; i++) {
|
|
352
|
-
if (aColumns[i].getSorted()) {
|
|
353
|
-
oBindingInfo.sorter = oBindingInfo.sorter || [];
|
|
354
|
-
oBindingInfo.sorter.push(new Sorter(aColumns[i].getSortProperty() || aColumns[i].getLeadingProperty(), aColumns[i].getSortOrder() === SortOrder.Descending));
|
|
355
|
-
}
|
|
356
|
-
}
|
|
357
|
-
|
|
358
348
|
// Make sure all necessary parameters are given.
|
|
359
349
|
// The ODataModelAdapter (via bindList) needs these properties to determine if an AnalyticalBinding should be instantiated.
|
|
360
350
|
// This is the default for the AnalyticalTable.
|
|
@@ -642,7 +632,7 @@ sap.ui.define([
|
|
|
642
632
|
|
|
643
633
|
if (oGroupColumnInfo) {
|
|
644
634
|
var oColumn = oGroupColumnInfo.column;
|
|
645
|
-
oColumn.
|
|
635
|
+
oColumn._sort(false); //update Analytical Info triggered by aftersort in column
|
|
646
636
|
}
|
|
647
637
|
},
|
|
648
638
|
icon: "sap-icon://up"
|
|
@@ -658,7 +648,7 @@ sap.ui.define([
|
|
|
658
648
|
|
|
659
649
|
if (oGroupColumnInfo) {
|
|
660
650
|
var oColumn = oGroupColumnInfo.column;
|
|
661
|
-
oColumn.
|
|
651
|
+
oColumn._sort(true); //update Analytical Info triggered by aftersort in column
|
|
662
652
|
}
|
|
663
653
|
},
|
|
664
654
|
icon: "sap-icon://down"
|
|
@@ -72,7 +72,7 @@ sap.ui.define([
|
|
|
72
72
|
* @class
|
|
73
73
|
* The column allows you to define column specific properties that will be applied when rendering the table.
|
|
74
74
|
* @extends sap.ui.core.Element
|
|
75
|
-
* @version 1.
|
|
75
|
+
* @version 1.115.0
|
|
76
76
|
*
|
|
77
77
|
* @constructor
|
|
78
78
|
* @public
|
|
@@ -867,6 +867,10 @@ sap.ui.define([
|
|
|
867
867
|
* @deprecated Since version 1.5.1. Please use the function "sap.ui.Table.prototype.sort".
|
|
868
868
|
*/
|
|
869
869
|
Column.prototype.sort = function(bDescending, bAdd) {
|
|
870
|
+
return this._sort(bDescending, bAdd);
|
|
871
|
+
};
|
|
872
|
+
|
|
873
|
+
Column.prototype._sort = function(bDescending, bAdd) {
|
|
870
874
|
var oTable = this.getParent();
|
|
871
875
|
if (oTable) {
|
|
872
876
|
// add current column to list of sorted columns
|
package/src/sap/ui/table/Row.js
CHANGED
|
@@ -135,7 +135,7 @@ sap.ui.define([
|
|
|
135
135
|
* @class
|
|
136
136
|
* The row.
|
|
137
137
|
* @extends sap.ui.core.Element
|
|
138
|
-
* @version 1.
|
|
138
|
+
* @version 1.115.0
|
|
139
139
|
*
|
|
140
140
|
* @constructor
|
|
141
141
|
* @public
|
|
@@ -353,7 +353,7 @@ sap.ui.define([
|
|
|
353
353
|
*/
|
|
354
354
|
Row.prototype._updateSelection = function() {
|
|
355
355
|
var oTable = this.getTable();
|
|
356
|
-
var bIsSelected = oTable._getSelectionPlugin().
|
|
356
|
+
var bIsSelected = oTable._getSelectionPlugin().isSelected(this);
|
|
357
357
|
|
|
358
358
|
this._setSelected(bIsSelected);
|
|
359
359
|
oTable._getAccExtension().updateSelectionStateOfRow(this);
|
|
@@ -35,7 +35,7 @@ sap.ui.define([
|
|
|
35
35
|
* If more action items are available as the available space allows to display an overflow mechanism is provided.
|
|
36
36
|
* This control must only be used in the context of the <code>sap.ui.table.Table</code> control to define row actions.
|
|
37
37
|
* @extends sap.ui.core.Control
|
|
38
|
-
* @version 1.
|
|
38
|
+
* @version 1.115.0
|
|
39
39
|
*
|
|
40
40
|
* @constructor
|
|
41
41
|
* @public
|
|
@@ -24,7 +24,7 @@ sap.ui.define([
|
|
|
24
24
|
* The <code>RowSettings</code> control allows you to configure a row.
|
|
25
25
|
* You can only use this control in the context of the <code>sap.ui.table.Table</code> control to define row settings.
|
|
26
26
|
* @extends sap.ui.core.Element
|
|
27
|
-
* @version 1.
|
|
27
|
+
* @version 1.115.0
|
|
28
28
|
*
|
|
29
29
|
* @constructor
|
|
30
30
|
* @public
|
|
@@ -92,7 +92,7 @@ sap.ui.define([
|
|
|
92
92
|
* the data model and binding being used.
|
|
93
93
|
* </p>
|
|
94
94
|
* @extends sap.ui.core.Control
|
|
95
|
-
* @version 1.
|
|
95
|
+
* @version 1.115.0
|
|
96
96
|
*
|
|
97
97
|
* @constructor
|
|
98
98
|
* @public
|
|
@@ -189,8 +189,10 @@ sap.ui.define([
|
|
|
189
189
|
|
|
190
190
|
/**
|
|
191
191
|
* Flag whether the controls of the Table are editable or not (currently this only controls the background color in certain themes!)
|
|
192
|
+
*
|
|
193
|
+
* @deprecated As of version 1.115
|
|
192
194
|
*/
|
|
193
|
-
editable: {type: "boolean", group: "Behavior", defaultValue: true},
|
|
195
|
+
editable: {type: "boolean", group: "Behavior", defaultValue: true, deprecated: true},
|
|
194
196
|
|
|
195
197
|
/**
|
|
196
198
|
* This property has been deprecated and must not be used anymore, since <code>Scrollbar</code> is the only supported option.
|
|
@@ -374,7 +376,7 @@ sap.ui.define([
|
|
|
374
376
|
/**
|
|
375
377
|
* Control or text of title section of the Table (if not set it will be hidden)
|
|
376
378
|
*
|
|
377
|
-
* @deprecated As of 1.72. Use, for example, a <code>sap.m.Title</code> control in the <code>extension</code> aggregation instead.
|
|
379
|
+
* @deprecated As of version 1.72. Use, for example, a <code>sap.m.Title</code> control in the <code>extension</code> aggregation instead.
|
|
378
380
|
*/
|
|
379
381
|
title: {type: "sap.ui.core.Control", altTypes: ["string"], multiple: false, deprecated: true},
|
|
380
382
|
|
|
@@ -387,7 +389,7 @@ sap.ui.define([
|
|
|
387
389
|
* Toolbar of the Table
|
|
388
390
|
* If not set, no toolbar area will be rendered.
|
|
389
391
|
* Note: The CSS class sapMTBHeader-CTX is applied on the given toolbar.
|
|
390
|
-
* @deprecated
|
|
392
|
+
* @deprecated As of version 1.38. This aggregation is deprecated, use the <code>extension</code> aggregation instead.
|
|
391
393
|
*/
|
|
392
394
|
toolbar: {type: "sap.ui.core.Toolbar", multiple: false, deprecated: true},
|
|
393
395
|
|
|
@@ -754,7 +756,7 @@ sap.ui.define([
|
|
|
754
756
|
/**
|
|
755
757
|
* fired when the user clicks a cell of the table.
|
|
756
758
|
* @since 1.21.0
|
|
757
|
-
* @deprecated As of 1.54, replaced by <code>beforeOpenContextMenu</code>.
|
|
759
|
+
* @deprecated As of version 1.54, replaced by <code>beforeOpenContextMenu</code>.
|
|
758
760
|
*/
|
|
759
761
|
cellContextmenu: {
|
|
760
762
|
allowPreventDefault: true,
|
|
@@ -3110,7 +3112,7 @@ sap.ui.define([
|
|
|
3110
3112
|
}
|
|
3111
3113
|
|
|
3112
3114
|
if (this.getColumns().indexOf(oColumn) >= 0) {
|
|
3113
|
-
oColumn.
|
|
3115
|
+
oColumn._sort(oSortOrder === SortOrder.Descending, bAdd);
|
|
3114
3116
|
}
|
|
3115
3117
|
};
|
|
3116
3118
|
|
|
@@ -3168,7 +3170,7 @@ sap.ui.define([
|
|
|
3168
3170
|
}
|
|
3169
3171
|
|
|
3170
3172
|
if (mRenderConfig.headerSelector.type === "toggle") {
|
|
3171
|
-
var bAllRowsSelected =
|
|
3173
|
+
var bAllRowsSelected = mRenderConfig.headerSelector.selected;
|
|
3172
3174
|
|
|
3173
3175
|
$SelectAll.toggleClass("sapUiTableSelAll", !bAllRowsSelected);
|
|
3174
3176
|
this._getAccExtension().setSelectAllState(bAllRowsSelected);
|
|
@@ -3230,24 +3232,26 @@ sap.ui.define([
|
|
|
3230
3232
|
* @private
|
|
3231
3233
|
*/
|
|
3232
3234
|
Table.prototype._onSelectionChanged = function(oEvent) {
|
|
3235
|
+
this._updateSelection();
|
|
3236
|
+
|
|
3237
|
+
// If a selection plugin is applied to the table, the "rowSelectionChange" event should not be fired.
|
|
3238
|
+
if (this._hasSelectionPlugin()) {
|
|
3239
|
+
return;
|
|
3240
|
+
}
|
|
3241
|
+
|
|
3233
3242
|
var oSelectionPlugin = this._getSelectionPlugin();
|
|
3234
3243
|
var aRowIndices = oEvent.getParameter("rowIndices");
|
|
3235
3244
|
var bSelectAll = oEvent.getParameter("selectAll");
|
|
3236
3245
|
var iRowIndex = this._iSourceRowIndex !== undefined ? this._iSourceRowIndex : oSelectionPlugin.getSelectedIndex();
|
|
3237
3246
|
|
|
3238
|
-
this.
|
|
3239
|
-
|
|
3240
|
-
|
|
3241
|
-
|
|
3242
|
-
|
|
3243
|
-
|
|
3244
|
-
|
|
3245
|
-
|
|
3246
|
-
rowIndices: aRowIndices,
|
|
3247
|
-
selectAll: bSelectAll,
|
|
3248
|
-
userInteraction: this._iSourceRowIndex !== undefined
|
|
3249
|
-
});
|
|
3250
|
-
}
|
|
3247
|
+
this.setProperty("selectedIndex", oSelectionPlugin.getSelectedIndex(), true);
|
|
3248
|
+
this.fireRowSelectionChange({
|
|
3249
|
+
rowIndex: iRowIndex,
|
|
3250
|
+
rowContext: this.getContextByIndex(iRowIndex),
|
|
3251
|
+
rowIndices: aRowIndices,
|
|
3252
|
+
selectAll: bSelectAll,
|
|
3253
|
+
userInteraction: this._iSourceRowIndex !== undefined
|
|
3254
|
+
});
|
|
3251
3255
|
};
|
|
3252
3256
|
|
|
3253
3257
|
/**
|
|
@@ -3853,7 +3857,7 @@ sap.ui.define([
|
|
|
3853
3857
|
* @param {object} [mSettings] settings for the new Export, see {@link sap.ui.core.util.Export} <code>constructor</code>
|
|
3854
3858
|
* @returns {sap.ui.core.util.Export} Export object
|
|
3855
3859
|
* @experimental Experimental because the property for the column/cell definitions (sortProperty) could change in future.
|
|
3856
|
-
* @deprecated As of 1.56, replaced by the <code>sap.ui.export</code> library.
|
|
3860
|
+
* @deprecated As of version 1.56, replaced by the <code>sap.ui.export</code> library.
|
|
3857
3861
|
* @public
|
|
3858
3862
|
*/
|
|
3859
3863
|
Table.prototype.exportData = function(mSettings) {
|
|
@@ -3942,29 +3946,6 @@ sap.ui.define([
|
|
|
3942
3946
|
}
|
|
3943
3947
|
};
|
|
3944
3948
|
|
|
3945
|
-
/**
|
|
3946
|
-
* Toggles the selection state of all cells.
|
|
3947
|
-
* @private
|
|
3948
|
-
*/
|
|
3949
|
-
Table.prototype._toggleSelectAll = function() {
|
|
3950
|
-
if (!TableUtils.hasData(this) || this.getSelectionMode() !== SelectionMode.MultiToggle) {
|
|
3951
|
-
return;
|
|
3952
|
-
}
|
|
3953
|
-
|
|
3954
|
-
var oSelectionPlugin = this._getSelectionPlugin();
|
|
3955
|
-
|
|
3956
|
-
// in order to fire the rowSelectionChanged event, the SourceRowIndex mus be set to -1
|
|
3957
|
-
// to indicate that the selection was changed by user interaction
|
|
3958
|
-
if (TableUtils.areAllRowsSelected(this)) {
|
|
3959
|
-
this._iSourceRowIndex = -1;
|
|
3960
|
-
oSelectionPlugin.clearSelection();
|
|
3961
|
-
} else {
|
|
3962
|
-
this._iSourceRowIndex = 0;
|
|
3963
|
-
oSelectionPlugin.selectAll();
|
|
3964
|
-
}
|
|
3965
|
-
this._iSourceRowIndex = undefined;
|
|
3966
|
-
};
|
|
3967
|
-
|
|
3968
3949
|
Table.prototype.setBusy = function(bBusy) {
|
|
3969
3950
|
var bOldBusyState = this.getBusy();
|
|
3970
3951
|
var vReturn = Control.prototype.setBusy.call(this, bBusy, "sapUiTableGridCnt");
|
|
@@ -4454,6 +4435,7 @@ sap.ui.define([
|
|
|
4454
4435
|
* @throws {Error} If a selection plugin is applied
|
|
4455
4436
|
* @private
|
|
4456
4437
|
* @ui5-restricted sap.watt.hanaplugins.editor.plugin.hdbcalculationview
|
|
4438
|
+
* @deprecated As of version 1.115
|
|
4457
4439
|
*/
|
|
4458
4440
|
Table.prototype._enableLegacyMultiSelection = function() {
|
|
4459
4441
|
if (this._hasSelectionPlugin()) {
|
|
@@ -4474,7 +4456,7 @@ sap.ui.define([
|
|
|
4474
4456
|
} else {
|
|
4475
4457
|
this.setSelectedIndex(iIndex);
|
|
4476
4458
|
}
|
|
4477
|
-
} else if (bAdd || this.
|
|
4459
|
+
} else if (bAdd || this.getSelectedIndices().length === 1) {
|
|
4478
4460
|
this.removeSelectionInterval(iIndex, iIndex);
|
|
4479
4461
|
} else {
|
|
4480
4462
|
this.setSelectedIndex(iIndex);
|
|
@@ -23,6 +23,8 @@ sap.ui.define([
|
|
|
23
23
|
/**
|
|
24
24
|
* Constructor for a new TablePersoController.
|
|
25
25
|
*
|
|
26
|
+
* @deprecated since 1.115. Please use the {@link sap.m.p13n.Engine Engine} for personalization instead.
|
|
27
|
+
*
|
|
26
28
|
* @param {string} [sId] id for the new control, generated automatically if no id is given
|
|
27
29
|
* @param {object} [mSettings] initial settings for the new control
|
|
28
30
|
*
|
|
@@ -31,7 +33,7 @@ sap.ui.define([
|
|
|
31
33
|
* @extends sap.ui.base.ManagedObject
|
|
32
34
|
*
|
|
33
35
|
* @author SAP SE
|
|
34
|
-
* @version 1.
|
|
36
|
+
* @version 1.115.0
|
|
35
37
|
* @since 1.21.1
|
|
36
38
|
*
|
|
37
39
|
* @constructor
|
|
@@ -45,6 +47,7 @@ sap.ui.define([
|
|
|
45
47
|
},
|
|
46
48
|
|
|
47
49
|
metadata: {
|
|
50
|
+
deprecated: true,
|
|
48
51
|
properties: {
|
|
49
52
|
|
|
50
53
|
/**
|
|
@@ -83,7 +83,12 @@ sap.ui.define(['sap/ui/Device', './library', "./Column", './utils/TableUtils', "
|
|
|
83
83
|
if (oScrollExtension.isVerticalScrollbarRequired() && !oScrollExtension.isVerticalScrollbarExternal()) {
|
|
84
84
|
rm.class("sapUiTableVScr"); // show vertical scrollbar
|
|
85
85
|
}
|
|
86
|
-
|
|
86
|
+
/*
|
|
87
|
+
* @UI5_V2_DEPRECATION_CHECK
|
|
88
|
+
* editable is a deprecated property of sap.ui.table.Table.
|
|
89
|
+
* Once the deprecated code is removed the following 3 lines of code will become obsolete.
|
|
90
|
+
*/
|
|
91
|
+
if (oTable.getEditable && oTable.getEditable()) {
|
|
87
92
|
rm.class("sapUiTableEdt"); // editable (background color)
|
|
88
93
|
}
|
|
89
94
|
|
|
@@ -437,7 +442,7 @@ sap.ui.define(['sap/ui/Device', './library', "./Column", './utils/TableUtils', "
|
|
|
437
442
|
|
|
438
443
|
var sSelectAllResourceTextID;
|
|
439
444
|
if (mRenderConfig.headerSelector.visible) {
|
|
440
|
-
var bAllRowsSelected =
|
|
445
|
+
var bAllRowsSelected = mRenderConfig.headerSelector.selected;
|
|
441
446
|
|
|
442
447
|
if (mRenderConfig.headerSelector.type === "toggle") {
|
|
443
448
|
sSelectAllResourceTextID = bAllRowsSelected ? "TBL_DESELECT_ALL" : "TBL_SELECT_ALL";
|
|
@@ -678,7 +683,7 @@ sap.ui.define(['sap/ui/Device', './library', "./Column", './utils/TableUtils', "
|
|
|
678
683
|
};
|
|
679
684
|
|
|
680
685
|
TableRenderer.renderRowAddon = function(rm, oTable, oRow, iRowIndex, bHeader) {
|
|
681
|
-
var bRowSelected = oTable._getSelectionPlugin().
|
|
686
|
+
var bRowSelected = oTable._getSelectionPlugin().isSelected(oRow);
|
|
682
687
|
|
|
683
688
|
rm.openStart("div");
|
|
684
689
|
var oRowSettings = oRow.getAggregation("_settings");
|
|
@@ -726,7 +731,7 @@ sap.ui.define(['sap/ui/Device', './library', "./Column", './utils/TableUtils', "
|
|
|
726
731
|
rm.openEnd();
|
|
727
732
|
if (bHeader) {
|
|
728
733
|
this.writeRowHighlightContent(rm, oTable, oRow, iRowIndex);
|
|
729
|
-
this.writeRowSelectorContent(rm, oTable, oRow
|
|
734
|
+
this.writeRowSelectorContent(rm, oTable, oRow);
|
|
730
735
|
} else {
|
|
731
736
|
var oAction = oRow.getRowAction();
|
|
732
737
|
if (oAction) {
|
|
@@ -948,8 +953,8 @@ sap.ui.define(['sap/ui/Device', './library', "./Column", './utils/TableUtils', "
|
|
|
948
953
|
rm.close("table");
|
|
949
954
|
};
|
|
950
955
|
|
|
951
|
-
TableRenderer.writeRowSelectorContent = function(rm, oTable, oRow
|
|
952
|
-
oTable._getAccRenderExtension().writeAccRowSelectorText(rm, oTable, oRow
|
|
956
|
+
TableRenderer.writeRowSelectorContent = function(rm, oTable, oRow) {
|
|
957
|
+
oTable._getAccRenderExtension().writeAccRowSelectorText(rm, oTable, oRow);
|
|
953
958
|
|
|
954
959
|
if (TableUtils.Grouping.isInGroupMode(oTable)) {
|
|
955
960
|
rm.openStart("div");
|
|
@@ -1105,7 +1110,7 @@ sap.ui.define(['sap/ui/Device', './library', "./Column", './utils/TableUtils', "
|
|
|
1105
1110
|
if (bDraggable && bFixedTable) {
|
|
1106
1111
|
rm.attr("draggable", true);
|
|
1107
1112
|
}
|
|
1108
|
-
if (oSelectionPlugin.
|
|
1113
|
+
if (oSelectionPlugin.isSelected(oRow)) {
|
|
1109
1114
|
rm.class("sapUiTableRowSel");
|
|
1110
1115
|
}
|
|
1111
1116
|
}
|
|
@@ -1129,7 +1134,7 @@ sap.ui.define(['sap/ui/Device', './library', "./Column", './utils/TableUtils', "
|
|
|
1129
1134
|
|
|
1130
1135
|
rm.openEnd();
|
|
1131
1136
|
|
|
1132
|
-
var bSelected = !oRow.isEmpty() && oSelectionPlugin.
|
|
1137
|
+
var bSelected = !oRow.isEmpty() && oSelectionPlugin.isSelected(oRow); //see TableRenderer.renderRowAddon
|
|
1133
1138
|
var aCells = oRow.getCells();
|
|
1134
1139
|
|
|
1135
1140
|
for (var cell = 0, count = aCells.length; cell < count; cell++) {
|
|
@@ -679,7 +679,7 @@ sap.ui.define([
|
|
|
679
679
|
case AccExtension.ELEMENTTYPES.ROWHEADER:
|
|
680
680
|
mAttributes["role"] = "gridcell";
|
|
681
681
|
mAttributes["aria-colindex"] = 1;
|
|
682
|
-
if (TableUtils.hasRowHeader(oTable) && oTable.
|
|
682
|
+
if (TableUtils.hasRowHeader(oTable) && oTable.getSelectionMode() === SelectionMode.None) {
|
|
683
683
|
mAttributes["aria-labelledby"] = [sTableId + "-rowselecthdr"];
|
|
684
684
|
}
|
|
685
685
|
break;
|
|
@@ -932,7 +932,7 @@ sap.ui.define([
|
|
|
932
932
|
* @class Extension for sap.ui.table.Table which handles ACC related things.
|
|
933
933
|
* @extends sap.ui.table.extensions.ExtensionBase
|
|
934
934
|
* @author SAP SE
|
|
935
|
-
* @version 1.
|
|
935
|
+
* @version 1.115.0
|
|
936
936
|
* @constructor
|
|
937
937
|
* @private
|
|
938
938
|
* @alias sap.ui.table.extensions.Accessibility
|
|
@@ -1271,7 +1271,7 @@ sap.ui.define([
|
|
|
1271
1271
|
if (!oRow.isEmpty() && !oRow.isGroupHeader() && !oRow.isSummary()) {
|
|
1272
1272
|
var mTooltipTexts = this.getAriaTextsForSelectionMode(true);
|
|
1273
1273
|
var oTable = this.getTable();
|
|
1274
|
-
var bIsSelected = oTable._getSelectionPlugin().
|
|
1274
|
+
var bIsSelected = oTable._getSelectionPlugin().isSelected(oRow);
|
|
1275
1275
|
|
|
1276
1276
|
if ($Ref.row) {
|
|
1277
1277
|
$Ref.row.add($Ref.row.children(".sapUiTableCell")).attr("aria-selected", bIsSelected ? "true" : "false");
|
|
@@ -1409,7 +1409,7 @@ sap.ui.define([
|
|
|
1409
1409
|
}
|
|
1410
1410
|
};
|
|
1411
1411
|
|
|
1412
|
-
var
|
|
1412
|
+
var iSelectedCount = oTable._getSelectionPlugin().getSelectedCount();
|
|
1413
1413
|
|
|
1414
1414
|
if (sSelectionMode === SelectionMode.Single) {
|
|
1415
1415
|
mTooltipTexts.mouse.rowSelect = bShowTooltips ? TableUtils.getResourceText("TBL_ROW_SELECT") : "";
|
|
@@ -1424,7 +1424,7 @@ sap.ui.define([
|
|
|
1424
1424
|
// text for de-select is the same like for single selection
|
|
1425
1425
|
mTooltipTexts.keyboard.rowDeselect = TableUtils.getResourceText("TBL_ROW_DESELECT_KEY");
|
|
1426
1426
|
|
|
1427
|
-
if (bConsiderSelectionState === true &&
|
|
1427
|
+
if (bConsiderSelectionState === true && iSelectedCount === 0) {
|
|
1428
1428
|
// if there is no row selected yet, the selection is like in single selection case
|
|
1429
1429
|
mTooltipTexts.mouse.rowSelect = bShowTooltips ? TableUtils.getResourceText("TBL_ROW_SELECT") : "";
|
|
1430
1430
|
}
|
|
@@ -42,7 +42,7 @@ sap.ui.define([
|
|
|
42
42
|
* @class Extension for sap.ui.table.TableRenderer which handles ACC related things.
|
|
43
43
|
* @extends sap.ui.table.extensions.ExtensionBase
|
|
44
44
|
* @author SAP SE
|
|
45
|
-
* @version 1.
|
|
45
|
+
* @version 1.115.0
|
|
46
46
|
* @constructor
|
|
47
47
|
* @private
|
|
48
48
|
* @alias sap.ui.table.extensions.AccessibilityRender
|
|
@@ -173,16 +173,15 @@ sap.ui.define([
|
|
|
173
173
|
* @param {sap.ui.core.RenderManager} oRm The RenderManager that can be used for writing to the Render-Output-Buffer.
|
|
174
174
|
* @param {sap.ui.table.Table} oTable Instance of the table.
|
|
175
175
|
* @param {sap.ui.table.Row} oRow Instance of the row.
|
|
176
|
-
* @param {int} iRowIndex The index of the row.
|
|
177
176
|
* @see sap.ui.table.TableRenderer.writeRowSelectorContent
|
|
178
177
|
* @public
|
|
179
178
|
*/
|
|
180
|
-
writeAccRowSelectorText: function(oRm, oTable, oRow
|
|
179
|
+
writeAccRowSelectorText: function(oRm, oTable, oRow) {
|
|
181
180
|
if (!oTable._getAccExtension().getAccMode()) {
|
|
182
181
|
return;
|
|
183
182
|
}
|
|
184
183
|
|
|
185
|
-
var bIsSelected = oTable._getSelectionPlugin().
|
|
184
|
+
var bIsSelected = oTable._getSelectionPlugin().isSelected(oRow);
|
|
186
185
|
var mTooltipTexts = oTable._getAccExtension().getAriaTextsForSelectionMode(true);
|
|
187
186
|
var sText = mTooltipTexts.keyboard[bIsSelected ? "rowDeselect" : "rowSelect"];
|
|
188
187
|
|
|
@@ -267,7 +267,7 @@ sap.ui.define([
|
|
|
267
267
|
* @class Extension for sap.ui.table.Table which handles keyboard related things.
|
|
268
268
|
* @extends sap.ui.table.extensions.ExtensionBase
|
|
269
269
|
* @author SAP SE
|
|
270
|
-
* @version 1.
|
|
270
|
+
* @version 1.115.0
|
|
271
271
|
* @constructor
|
|
272
272
|
* @private
|
|
273
273
|
* @alias sap.ui.table.extensions.Keyboard
|