@sapui5/sap.ushell_abap 1.94.1 → 1.97.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/package.json +1 -1
- package/src/main/js/sap/ui2/srvc/ODataWrapper.js +1 -1
- package/src/main/js/sap/ushell_abap/.library +4 -9
- package/src/main/js/sap/ushell_abap/adapters/abap/AdapterContainer.js +12 -5
- package/src/main/js/sap/ushell_abap/adapters/abap/AppStateAdapter.js +11 -7
- package/src/main/js/sap/ushell_abap/adapters/abap/ClientSideTargetResolutionAdapter.js +47 -32
- package/src/main/js/sap/ushell_abap/adapters/abap/ConfigurationDefaultsAdapter.js +1 -1
- package/src/main/js/sap/ushell_abap/adapters/abap/ContainerAdapter.js +46 -38
- package/src/main/js/sap/ushell_abap/adapters/abap/LaunchPageAdapter.js +574 -454
- package/src/main/js/sap/ushell_abap/adapters/abap/NavTargetResolutionAdapter.js +1 -1
- package/src/main/js/sap/ushell_abap/adapters/abap/PageBuildingAdapter.js +25 -15
- package/src/main/js/sap/ushell_abap/adapters/abap/PagePersistenceAdapter.js +3 -2
- package/src/main/js/sap/ushell_abap/adapters/abap/PersonalizationAdapter.js +16 -7
- package/src/main/js/sap/ushell_abap/adapters/abap/SearchAdapter.js +1 -1
- package/src/main/js/sap/ushell_abap/adapters/abap/SupportTicketAdapter.js +8 -8
- package/src/main/js/sap/ushell_abap/adapters/abap/Ui5ComponentLoaderAdapter.js +1 -1
- package/src/main/js/sap/ushell_abap/adapters/abap/UserInfoAdapter.js +11 -4
- package/src/main/js/sap/ushell_abap/adapters/hana/ContainerAdapter.js +9 -3
- package/src/main/js/sap/ushell_abap/bootstrap/evo/XhrLogonEventHandler.js +13 -11
- package/src/main/js/sap/ushell_abap/bootstrap/evo/abap-def-dev.js +1 -1
- package/src/main/js/sap/ushell_abap/bootstrap/evo/abap-def.js +1 -1
- package/src/main/js/sap/ushell_abap/bootstrap/evo/abap.bootstrap.utils.js +8 -4
- package/src/main/js/sap/ushell_abap/bootstrap/evo/abap.configure.ushell.js +1 -1
- package/src/main/js/sap/ushell_abap/bootstrap/evo/abap.constants.js +9 -0
- package/src/main/js/sap/ushell_abap/bootstrap/evo/abap.get.server.config.Urls.js +12 -5
- package/src/main/js/sap/ushell_abap/bootstrap/evo/abap.load.launchpad.js +21 -22
- package/src/main/js/sap/ushell_abap/bootstrap/evo/abap.request.pageset.js +8 -2
- package/src/main/js/sap/ushell_abap/bootstrap/evo/abap.request.server.config.js +6 -3
- package/src/main/js/sap/ushell_abap/bootstrap/evo/abap.request.startup.js +10 -5
- package/src/main/js/sap/ushell_abap/bootstrap/evo/abap.ui5.boot.handler.js +7 -4
- package/src/main/js/sap/ushell_abap/bootstrap/evo/abap.xhr.handler.js +10 -3
- package/src/main/js/sap/ushell_abap/bootstrap/evo/boottask.js +21 -16
- package/src/main/js/sap/ushell_abap/library.js +2 -2
- package/src/main/js/sap/ushell_abap/pbServices/ui2/AllCatalogs.js +186 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/Bag.js +718 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/Catalog.js +930 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/Chip.js +1027 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/ChipDefinition.js +216 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/ChipInstance.js +951 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/Error.js +45 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/Factory.js +647 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/ODataService.js +251 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/ODataWrapper.js +1262 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/Page.js +920 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/PageBuildingService.js +1498 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/PageSet.js +466 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/RemoteCatalogService.js +52 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/Utils.js +767 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/chipdefinition.xsd +139 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/contracts/actions.js +244 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/contracts/bag.js +150 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/contracts/configuration.js +165 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/contracts/configurationUi.js +330 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/contracts/fullscreen.js +70 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/contracts/navigation.js +50 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/contracts/preview.js +289 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/contracts/refresh.js +43 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/contracts/search.js +115 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/contracts/types.js +9 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/contracts/url.js +105 -0
- package/src/main/js/sap/ushell_abap/pbServices/ui2/contracts/visible.js +128 -0
- package/ui5.yaml +31 -0
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/Component.js +0 -426
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/css/style.css +0 -1
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n.properties +0 -56
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_ar.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_bg.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_ca.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_cs.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_cy.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_da.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_de.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_el.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_en.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_en_GB.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_en_US_sappsd.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_en_US_saprigi.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_en_US_saptrc.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_es.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_es_MX.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_et.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_fi.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_fr.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_fr_CA.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_hi.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_hr.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_hu.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_id.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_it.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_iw.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_ja.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_kk.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_ko.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_lt.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_lv.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_ms.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_nl.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_no.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_pl.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_pt.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_pt_PT.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_ro.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_ru.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_sh.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_sk.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_sl.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_sv.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_th.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_tr.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_uk.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_vi.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_zh_CN.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/i18n/i18n_zh_TW.properties +0 -36
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/manifest.json +0 -153
- package/src/main/js/sap/ushell_abap/plugins/fcc-transport-ui/model/models.js +0 -14
|
@@ -0,0 +1,289 @@
|
|
|
1
|
+
// Copyright (c) 2009-2021 SAP SE. All rights reserved.
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* @fileOverview The <code>preview</code> contract.
|
|
5
|
+
*/
|
|
6
|
+
sap.ui.require([
|
|
7
|
+
"sap/ushell_abap/pbServices/ui2/Chip"
|
|
8
|
+
], function (
|
|
9
|
+
Chip
|
|
10
|
+
) {
|
|
11
|
+
"use strict";
|
|
12
|
+
|
|
13
|
+
if (typeof jQuery === "function" && jQuery.sap) {
|
|
14
|
+
jQuery.sap.declare("sap.ui2.srvc.contracts.preview");
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
sap.ui2 = sap.ui2 || {};
|
|
18
|
+
sap.ui2.srvc = sap.ui2.srvc || {};
|
|
19
|
+
sap.ui2.srvc.contracts = sap.ui2.srvc.contracts || {};
|
|
20
|
+
sap.ui2.srvc.contracts.preview = sap.ui2.srvc.contracts.preview || {};
|
|
21
|
+
/**
|
|
22
|
+
* Allows the page builder to set the global type of environment for the preview contract to either runtime or design time.
|
|
23
|
+
* Based on this a CHIP can decide what preview to be shown. For example, in preview mode at design time, no HTTP request should be made,
|
|
24
|
+
* while in preview mode at runtime the CHIP may request a minimum of data to make the CHIP identifiable.
|
|
25
|
+
*
|
|
26
|
+
* By default the environment is unspecified (null).
|
|
27
|
+
*
|
|
28
|
+
* @param {string} sEnvironment
|
|
29
|
+
* Specified if the page builder is a design time or an runtime. Accepts only the values 'runtime' or 'designtime'.
|
|
30
|
+
*
|
|
31
|
+
* @since 1.71.0
|
|
32
|
+
* @public
|
|
33
|
+
* @see chip.preview.getEnvironmentType
|
|
34
|
+
*/
|
|
35
|
+
sap.ui2.srvc.contracts.preview.setEnvironmentType = function (sEnvironment) {
|
|
36
|
+
if (sEnvironment !== "runtime" && sEnvironment !== "designtime") {
|
|
37
|
+
throw new Error("setEnvironmentType only accepts the values 'runtime' or 'designtime'");
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
this.environment = sEnvironment;
|
|
41
|
+
};
|
|
42
|
+
|
|
43
|
+
/**
|
|
44
|
+
* Returns the global type of environment for the preview contract. Based on this a CHIP can decide what
|
|
45
|
+
* preview to be shown. For example, in preview mode at design time, no HTTP request should be made,
|
|
46
|
+
* while in preview mode at runtime the CHIP may request a minimum of data to make the CHIP identifiable.
|
|
47
|
+
*
|
|
48
|
+
* By default the environment is unspecified (null).
|
|
49
|
+
*
|
|
50
|
+
* @returns {string} Returns null, which means unspecified, 'runtime' or 'designtime'.
|
|
51
|
+
*
|
|
52
|
+
* @since 1.71.0
|
|
53
|
+
* @private
|
|
54
|
+
*
|
|
55
|
+
* @see #setEnvironmentType
|
|
56
|
+
*/
|
|
57
|
+
sap.ui2.srvc.contracts.preview.getEnvironmentType = function () {
|
|
58
|
+
return this.environment;
|
|
59
|
+
};
|
|
60
|
+
|
|
61
|
+
/**
|
|
62
|
+
* @namespace The namespace for the CHIP API's <code>preview</code> contract, which
|
|
63
|
+
* allows to display the CHIP in a preview mode.
|
|
64
|
+
* @name chip.preview
|
|
65
|
+
* @since 1.11.0
|
|
66
|
+
*/
|
|
67
|
+
Chip.addContract("preview", /* @returns {object} */ function (oChipInstance) {
|
|
68
|
+
var bEnabled = false,
|
|
69
|
+
sPreviewIconUrl,
|
|
70
|
+
sPreviewSubtitle,
|
|
71
|
+
sPreviewTitle,
|
|
72
|
+
sTargetUrl;
|
|
73
|
+
|
|
74
|
+
/**
|
|
75
|
+
* Returns this CHIP's description. May be used by the CHIP for the UI it shows in preview
|
|
76
|
+
* mode.
|
|
77
|
+
*
|
|
78
|
+
* @name chip.preview.getDescription
|
|
79
|
+
* @function
|
|
80
|
+
* @since 1.11.0
|
|
81
|
+
* @returns {string}
|
|
82
|
+
* the CHIP description
|
|
83
|
+
*/
|
|
84
|
+
this.getDescription = function () {
|
|
85
|
+
return oChipInstance.getChip().getDescription();
|
|
86
|
+
};
|
|
87
|
+
|
|
88
|
+
/**
|
|
89
|
+
* Returns this CHIP's title. May be used by the CHIP for the UI it shows in preview mode.
|
|
90
|
+
*
|
|
91
|
+
* @name chip.preview.getTitle
|
|
92
|
+
* @function
|
|
93
|
+
* @since 1.11.0
|
|
94
|
+
* @returns {string}
|
|
95
|
+
* the CHIP title
|
|
96
|
+
*/
|
|
97
|
+
this.getTitle = function () {
|
|
98
|
+
return oChipInstance.getTitle();
|
|
99
|
+
};
|
|
100
|
+
|
|
101
|
+
/**
|
|
102
|
+
* Tells whether preview mode is enabled. Note that this value is constant throughout
|
|
103
|
+
* a CHIP's lifetime. If preview mode is enabled, CHIPs should provide a target URL for the
|
|
104
|
+
* embedding application to trigger navigation, see {@link chip.preview.setTargetUrl}.
|
|
105
|
+
* They should not display live data for performance reasons.
|
|
106
|
+
*
|
|
107
|
+
* @name chip.preview.isEnabled
|
|
108
|
+
* @function
|
|
109
|
+
* @since 1.11.0
|
|
110
|
+
* @returns {boolean}
|
|
111
|
+
* whether preview mode is enabled
|
|
112
|
+
*/
|
|
113
|
+
this.isEnabled = function () {
|
|
114
|
+
return bEnabled;
|
|
115
|
+
};
|
|
116
|
+
|
|
117
|
+
/**
|
|
118
|
+
* Returns the type of environment in which the preview mode maybe displayed.
|
|
119
|
+
*
|
|
120
|
+
* Based on this a CHIP can decide what preview to be shown. For example, in preview
|
|
121
|
+
* mode at design time, no HTTP request should be made, while in preview mode at runtime
|
|
122
|
+
* the CHIP may request a minimum of data to make the CHIP identifiable.
|
|
123
|
+
*
|
|
124
|
+
* @returns {string} Returns null, which means unspecified, 'runtime' or 'designtime'.
|
|
125
|
+
*
|
|
126
|
+
* @since 1.71.0
|
|
127
|
+
* @public
|
|
128
|
+
*
|
|
129
|
+
* @see sap.ui2.srvc.contracts.preview#setEnvironmentType
|
|
130
|
+
* @since 1.71.0
|
|
131
|
+
*/
|
|
132
|
+
this.getEnvironmentType = function () {
|
|
133
|
+
return sap.ui2.srvc.contracts.preview.getEnvironmentType();
|
|
134
|
+
};
|
|
135
|
+
|
|
136
|
+
/**
|
|
137
|
+
* Determines the preview icon to be used by the embedding application for this CHIP.
|
|
138
|
+
*
|
|
139
|
+
* @name chip.preview.setPreviewIcon
|
|
140
|
+
* @function
|
|
141
|
+
* @since 1.11.0
|
|
142
|
+
* @param {string} sNewPreviewIconUrl
|
|
143
|
+
* the preview icon URL. It is recommended that this URL follows the rules defined for the
|
|
144
|
+
* <code>src</code> attribute of <code>sap.ui.core.Icon</code>.
|
|
145
|
+
*/
|
|
146
|
+
this.setPreviewIcon = function (sNewPreviewIconUrl) {
|
|
147
|
+
sPreviewIconUrl = sNewPreviewIconUrl;
|
|
148
|
+
};
|
|
149
|
+
|
|
150
|
+
/**
|
|
151
|
+
* Determines the preview subtitle to be used by the embedding application for this CHIP.
|
|
152
|
+
*
|
|
153
|
+
* @name chip.preview.setPreviewSubtitle
|
|
154
|
+
* @function
|
|
155
|
+
* @since 1.40.0
|
|
156
|
+
* @param {string} sNewPreviewSubtitle
|
|
157
|
+
* the preview subtitle.
|
|
158
|
+
*/
|
|
159
|
+
this.setPreviewSubtitle = function (sNewPreviewSubtitle) {
|
|
160
|
+
sPreviewSubtitle = sNewPreviewSubtitle;
|
|
161
|
+
};
|
|
162
|
+
|
|
163
|
+
/**
|
|
164
|
+
* Determines the preview title to be used by the embedding application for this CHIP. If the
|
|
165
|
+
* CHIP has no specific preview title e.g. based on its configuration it may return the title
|
|
166
|
+
* from the <code>getTitle</code> method of this contract.
|
|
167
|
+
*
|
|
168
|
+
* @name chip.preview.setPreviewTitle
|
|
169
|
+
* @function
|
|
170
|
+
* @since 1.11.0
|
|
171
|
+
* @param {string} sNewPreviewTitle
|
|
172
|
+
* the preview title.
|
|
173
|
+
*
|
|
174
|
+
* @see chip.preview.getTitle
|
|
175
|
+
*/
|
|
176
|
+
this.setPreviewTitle = function (sNewPreviewTitle) {
|
|
177
|
+
sPreviewTitle = sNewPreviewTitle;
|
|
178
|
+
};
|
|
179
|
+
|
|
180
|
+
/**
|
|
181
|
+
* Determines the target URL for navigation from this CHIP. May be used by the embedding
|
|
182
|
+
* application to trigger navigation to the CHIP's underlying application.
|
|
183
|
+
*
|
|
184
|
+
* @name chip.preview.setTargetUrl
|
|
185
|
+
* @function
|
|
186
|
+
* @since 1.11.0
|
|
187
|
+
* @param {string} sNewTargetUrl
|
|
188
|
+
* the target URL for navigation triggered in this CHIP
|
|
189
|
+
*/
|
|
190
|
+
this.setTargetUrl = function (sNewTargetUrl) {
|
|
191
|
+
sTargetUrl = sNewTargetUrl;
|
|
192
|
+
};
|
|
193
|
+
|
|
194
|
+
/**
|
|
195
|
+
* @namespace The namespace for the contract interface (to be used by a page builder) for
|
|
196
|
+
* the <code>preview</code> contract, which allows you to display a CHIP in preview
|
|
197
|
+
* mode and to retrieve the URL of the CHIP's underlying application.
|
|
198
|
+
* "Preview mode" means that a CHIP does not retrieve and display live data, but displays a
|
|
199
|
+
* static preview in order to improve performance.
|
|
200
|
+
* The embedding application has two alternatives to display a CHIP preview:
|
|
201
|
+
* Either it embeds the CHIP UI and relies on the CHIP not rendering live data or it
|
|
202
|
+
* retrieves preview attributes like title and icon from the CHIP to create the preview UI
|
|
203
|
+
* itself.
|
|
204
|
+
*
|
|
205
|
+
* @name contract.preview
|
|
206
|
+
* @since 1.11.0
|
|
207
|
+
*/
|
|
208
|
+
return {
|
|
209
|
+
/**
|
|
210
|
+
* Returns the URL of the preview icon for this CHIP.
|
|
211
|
+
*
|
|
212
|
+
* @name contract.preview.getPreviewIcon
|
|
213
|
+
* @function
|
|
214
|
+
* @returns {string}
|
|
215
|
+
* the preview icon's URL
|
|
216
|
+
* @since 1.11.0
|
|
217
|
+
*
|
|
218
|
+
* @see chip.preview.setPreviewIcon
|
|
219
|
+
*/
|
|
220
|
+
getPreviewIcon: function () {
|
|
221
|
+
return sPreviewIconUrl;
|
|
222
|
+
},
|
|
223
|
+
|
|
224
|
+
/**
|
|
225
|
+
* Returns the preview subtitle for this CHIP.
|
|
226
|
+
*
|
|
227
|
+
* @name contract.preview.getPreviewSubtitle
|
|
228
|
+
* @function
|
|
229
|
+
* @returns {string}
|
|
230
|
+
* the preview subtitle
|
|
231
|
+
* @since 1.40.0
|
|
232
|
+
*
|
|
233
|
+
* @see chip.preview.setPreviewSubtitle
|
|
234
|
+
*/
|
|
235
|
+
getPreviewSubtitle: function () {
|
|
236
|
+
return sPreviewSubtitle;
|
|
237
|
+
},
|
|
238
|
+
|
|
239
|
+
/**
|
|
240
|
+
* Returns the preview title for this CHIP.
|
|
241
|
+
*
|
|
242
|
+
* @name contract.preview.getPreviewTitle
|
|
243
|
+
* @function
|
|
244
|
+
* @returns {string}
|
|
245
|
+
* the preview title
|
|
246
|
+
* @since 1.11.0
|
|
247
|
+
*
|
|
248
|
+
* @see chip.preview.setPreviewTitle
|
|
249
|
+
*/
|
|
250
|
+
getPreviewTitle: function () {
|
|
251
|
+
return sPreviewTitle;
|
|
252
|
+
},
|
|
253
|
+
|
|
254
|
+
/**
|
|
255
|
+
* Returns the target URL for the CHIP's underlying application.
|
|
256
|
+
*
|
|
257
|
+
* @name contract.preview.getTargetUrl
|
|
258
|
+
* @function
|
|
259
|
+
* @returns {string}
|
|
260
|
+
* target URL
|
|
261
|
+
* @since 1.11.0
|
|
262
|
+
*
|
|
263
|
+
* @see chip.preview.setTargetUrl
|
|
264
|
+
*/
|
|
265
|
+
getTargetUrl: function () {
|
|
266
|
+
return sTargetUrl;
|
|
267
|
+
},
|
|
268
|
+
|
|
269
|
+
/**
|
|
270
|
+
* Determines whether preview mode for this CHIP instance is enabled by the page builder.
|
|
271
|
+
* <b>Note:</b> Changing this setting after <code>getImplementationAsSapui5()</code> has been
|
|
272
|
+
* called probably violates the contract of <code>chip.preview.isEnabled()</code>!
|
|
273
|
+
*
|
|
274
|
+
* @param {boolean} bNewEnabled
|
|
275
|
+
* whether preview mode for this CHIP instance is enabled by the page builder
|
|
276
|
+
*
|
|
277
|
+
* @name contract.preview.setEnabled
|
|
278
|
+
* @function
|
|
279
|
+
* @since 1.11.0
|
|
280
|
+
*
|
|
281
|
+
* @see sap.ushell_abap.pbServices.ui2.ChipInstance#getImplementationAsSapui5()
|
|
282
|
+
* @see chip.preview.isEnabled
|
|
283
|
+
*/
|
|
284
|
+
setEnabled: function (bNewEnabled) {
|
|
285
|
+
bEnabled = bNewEnabled;
|
|
286
|
+
}
|
|
287
|
+
};
|
|
288
|
+
});
|
|
289
|
+
});
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
// Copyright (c) 2009-2021 SAP SE. All rights reserved.
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* @fileOverview The <code>refresh</code> contract.
|
|
5
|
+
*/
|
|
6
|
+
sap.ui.require([
|
|
7
|
+
"sap/ushell_abap/pbServices/ui2/Chip"
|
|
8
|
+
], function (
|
|
9
|
+
Chip
|
|
10
|
+
) {
|
|
11
|
+
"use strict";
|
|
12
|
+
|
|
13
|
+
if (typeof jQuery === "function" && jQuery.sap) {
|
|
14
|
+
jQuery.sap.declare("sap.ui2.srvc.contracts.refresh");
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
/**
|
|
18
|
+
* @namespace The namespace for the CHIP API's <code>refresh</code> contract, which allows you to
|
|
19
|
+
* handle refresh events.
|
|
20
|
+
* @name chip.refresh
|
|
21
|
+
* @since 1.2.0
|
|
22
|
+
*/
|
|
23
|
+
Chip.addContract("refresh", function (oChipInstance) {
|
|
24
|
+
/**
|
|
25
|
+
* Attaches the given event handler to the "refresh" event which is fired
|
|
26
|
+
* whenever the user requests a refresh of this CHIP's content.
|
|
27
|
+
*
|
|
28
|
+
* Use <code>Function.prototype.bind()</code> to determine the event handler's
|
|
29
|
+
* <code>this</code> or some of its arguments.
|
|
30
|
+
*
|
|
31
|
+
* Note: Without such an event handler, the CHIP will be recreated to enforce a refresh!
|
|
32
|
+
*
|
|
33
|
+
* @name chip.refresh.attachRefresh
|
|
34
|
+
* @function
|
|
35
|
+
* @since 1.2.0
|
|
36
|
+
* @param {function} fnEventHandler
|
|
37
|
+
* the event handler for the "refresh" event
|
|
38
|
+
*/
|
|
39
|
+
this.attachRefresh = function (fnEventHandler) {
|
|
40
|
+
oChipInstance.attachRefresh(fnEventHandler);
|
|
41
|
+
};
|
|
42
|
+
});
|
|
43
|
+
});
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
// Copyright (c) 2009-2021 SAP SE. All rights reserved.
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* @fileOverview The <code>search</code> contract.
|
|
5
|
+
*/
|
|
6
|
+
sap.ui.define([
|
|
7
|
+
"sap/ushell_abap/pbServices/ui2/Chip",
|
|
8
|
+
"sap/ushell_abap/pbServices/ui2/Error",
|
|
9
|
+
"sap/ushell_abap/pbServices/ui2/Utils"
|
|
10
|
+
], function (
|
|
11
|
+
Chip,
|
|
12
|
+
SrvcError,
|
|
13
|
+
Utils
|
|
14
|
+
) {
|
|
15
|
+
"use strict";
|
|
16
|
+
|
|
17
|
+
if (typeof jQuery === "function" && jQuery.sap) {
|
|
18
|
+
jQuery.sap.declare("sap.ui2.srvc.contracts.search");
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
/**
|
|
23
|
+
* @namespace The namespace for the CHIP API's <code>search</code> contract with
|
|
24
|
+
* CHIP search-related functionality. With this contract, the CHIP can provide CHIP-specific
|
|
25
|
+
* search keywords. In addition, it can highlight words from the search in its UI.
|
|
26
|
+
* @name chip.search
|
|
27
|
+
* @since 1.11.0
|
|
28
|
+
*/
|
|
29
|
+
Chip.addContract("search", function (oChipInstance) {
|
|
30
|
+
var fnHighlight,
|
|
31
|
+
aKeywords;
|
|
32
|
+
|
|
33
|
+
/**
|
|
34
|
+
* Determines specific keywords with which the CHIP wants to be found in a search over all
|
|
35
|
+
* CHIPs from the page builder. If not set, the page builder executing a CHIP search can only
|
|
36
|
+
* search based on CHIP metadata like the CHIP title.
|
|
37
|
+
*
|
|
38
|
+
* @name chip.search.setKeywords
|
|
39
|
+
* @function
|
|
40
|
+
* @since 1.11.0
|
|
41
|
+
* @param {string[]} aNewKeywords
|
|
42
|
+
* the keywords of this CHIP
|
|
43
|
+
*/
|
|
44
|
+
this.setKeywords = function (aNewKeywords) {
|
|
45
|
+
if (!Utils.isArray(aNewKeywords)) {
|
|
46
|
+
throw new SrvcError("Not an array: " + aNewKeywords, "chip.search");
|
|
47
|
+
}
|
|
48
|
+
aKeywords = aNewKeywords.slice();
|
|
49
|
+
};
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
* Attaches the given event handler to the "highlight" event which is fired whenever the user
|
|
53
|
+
* executes a search over all CHIPs using specific search terms. The event handler takes a
|
|
54
|
+
* string array as parameter, containing the highlight words. These are derived from the
|
|
55
|
+
* search terms. The CHIP can then highlight these in its UI.
|
|
56
|
+
*
|
|
57
|
+
* @name chip.search.attachHighlight
|
|
58
|
+
* @function
|
|
59
|
+
* @since 1.11.0
|
|
60
|
+
* @param {function (string[])} fnEventHandler
|
|
61
|
+
* event handler for highlighting words in the CHIP UI which takes a string array with the
|
|
62
|
+
* highlight words as parameter
|
|
63
|
+
*/
|
|
64
|
+
this.attachHighlight = function (fnEventHandler) {
|
|
65
|
+
if (typeof fnEventHandler !== "function") {
|
|
66
|
+
throw new SrvcError("Not a function: " + fnEventHandler,
|
|
67
|
+
"chip.search");
|
|
68
|
+
}
|
|
69
|
+
fnHighlight = fnEventHandler;
|
|
70
|
+
};
|
|
71
|
+
|
|
72
|
+
/**
|
|
73
|
+
* @namespace The namespace for the contract interface (to be used by a page builder) for
|
|
74
|
+
* the <code>search</code> contract. This contract interface allows the pagebuilder to get
|
|
75
|
+
* the CHIP-specific search keywords. In addition, it can have the CHIP highlight words
|
|
76
|
+
* in its UI based on the search terms used.
|
|
77
|
+
* @name contract.search
|
|
78
|
+
* @since 1.11.0
|
|
79
|
+
*/
|
|
80
|
+
return {
|
|
81
|
+
/**
|
|
82
|
+
* Returns the CHIP-specific search keywords.
|
|
83
|
+
*
|
|
84
|
+
* @name contract.search.getKeywords
|
|
85
|
+
* @function
|
|
86
|
+
* @since 1.11.0
|
|
87
|
+
* @returns {string[]}
|
|
88
|
+
* CHIP-specific search keywords. Empty array if the CHIP has not set any keywords.
|
|
89
|
+
*
|
|
90
|
+
* @see chip.search.setKeywords
|
|
91
|
+
*/
|
|
92
|
+
getKeywords: function () {
|
|
93
|
+
return aKeywords ? aKeywords.slice() : [];
|
|
94
|
+
},
|
|
95
|
+
|
|
96
|
+
/**
|
|
97
|
+
* Fires the "highlight" event which takes a string array with the words to
|
|
98
|
+
* be highlighted as parameters.
|
|
99
|
+
*
|
|
100
|
+
* @name contract.search.fireHighlight
|
|
101
|
+
* @function
|
|
102
|
+
* @since 1.11.0
|
|
103
|
+
* @param {string[]} aHighlightWords
|
|
104
|
+
* words to be highlighted
|
|
105
|
+
*
|
|
106
|
+
* @see chip.search.attachHighlight
|
|
107
|
+
*/
|
|
108
|
+
fireHighlight: function (aHighlightWords) {
|
|
109
|
+
if (fnHighlight) {
|
|
110
|
+
fnHighlight(aHighlightWords);
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
};
|
|
114
|
+
});
|
|
115
|
+
});
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
// Copyright (c) 2009-2021 SAP SE. All rights reserved.
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* @fileOverview The <code>url</code> contract.
|
|
5
|
+
*/
|
|
6
|
+
sap.ui.define([
|
|
7
|
+
"sap/ushell_abap/pbServices/ui2/Chip"
|
|
8
|
+
], function (
|
|
9
|
+
Chip
|
|
10
|
+
) {
|
|
11
|
+
"use strict";
|
|
12
|
+
|
|
13
|
+
if (typeof jQuery === "function" && jQuery.sap) {
|
|
14
|
+
jQuery.sap.declare("sap.ui2.srvc.contracts.url");
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
/**
|
|
18
|
+
* @namespace The namespace for the CHIP API's <code>url</code> contract, which allows you
|
|
19
|
+
* convert relative URLs into absolute ones.
|
|
20
|
+
* @name chip.url
|
|
21
|
+
* @since 1.2.0
|
|
22
|
+
*/
|
|
23
|
+
Chip.addContract("url", function (oChipInstance) {
|
|
24
|
+
/**
|
|
25
|
+
* Makes the given server-relative service URL point to the system given as parameter
|
|
26
|
+
* <code>sSystem</code> or to the system of this CHIP's catalog if <code>sSystem</code>
|
|
27
|
+
* is empty.
|
|
28
|
+
* <em>Server-relative URL</em> means a URL starting with exactly one "/" (also known as
|
|
29
|
+
* absolute-path URL).
|
|
30
|
+
* <p>
|
|
31
|
+
* The function is typically used if the CHIP has been loaded from a remote catalog. In this
|
|
32
|
+
* case, a CHIP wants to perform service calls to the system providing the remote catalog:
|
|
33
|
+
* it must convert the corresponding URLs via this method. The function may also be used for
|
|
34
|
+
* CHIPs loaded from a local catalog to perform service calls to a different system.
|
|
35
|
+
* <p>
|
|
36
|
+
* The system is added via segment parameter <code>o</code> to the last URL segment of the
|
|
37
|
+
* service URL. It is also possible to make this function put the system to a different
|
|
38
|
+
* URL path segment of the service URL by specifying the empty segment parameter
|
|
39
|
+
* <code>o</code>. If both <code>sSystem</code> is empty and the CHIP is loaded from a local
|
|
40
|
+
* catalog, no system is added and the empty segment parameter <code>o</code> is removed.
|
|
41
|
+
* <br/>
|
|
42
|
+
* <b>Example 1:</b> <code>/sap/opu/odata/MyService/?p1=v1</code> is converted to
|
|
43
|
+
* <code>/sap/opu/odata/MyService;o=SYS/?p1=v1</code> if the corresponding CHIP has been loaded
|
|
44
|
+
* via a remote catalog with system ID "SYS".
|
|
45
|
+
* However it remains unchanged if the CHIP has been loaded from the logon system <em>and</em>
|
|
46
|
+
* the parameter <code>sSystem</code> is empty.<br/>
|
|
47
|
+
* <b>Example 2:</b> <code>/sap/opu/odata/MyService;o=/MyEntities/$count?p1=v1</code> is
|
|
48
|
+
* converted to <code>/sap/opu/odata/MyService;o=sid(SYS.123)/MyEntities/$count?p1=v1</code> if
|
|
49
|
+
* parameter <code>sSystem</code> is set to "sid(SYS.123)"</code>.
|
|
50
|
+
* <p>
|
|
51
|
+
* The URL is in no way normalized.
|
|
52
|
+
*
|
|
53
|
+
* @name chip.url.addSystemToServiceUrl
|
|
54
|
+
* @function
|
|
55
|
+
* @since 1.19.1
|
|
56
|
+
* @param {string} sServiceUrl
|
|
57
|
+
* a server-relative service URL (to be used when addressing the system directly)
|
|
58
|
+
* @param {string} [sSystem]
|
|
59
|
+
* a system specification like "SYS" or "sid(SYS.123)"; if empty the
|
|
60
|
+
* system of the CHIP's catalog is used
|
|
61
|
+
* @returns {string}
|
|
62
|
+
* the service URL pointing to the system specified in parameter <code>sSystem</code> or to
|
|
63
|
+
* the system from which the CHIP's catalog has been loaded
|
|
64
|
+
* @throws Error if the URL is not server-relative such as <code>./something</code>,
|
|
65
|
+
* <code>http://foo.bar/something</code>, ...)
|
|
66
|
+
*/
|
|
67
|
+
this.addSystemToServiceUrl = function (sServiceUrl, sSystem) {
|
|
68
|
+
return oChipInstance.getChip().getCatalog().addSystemToServiceUrl(sServiceUrl, sSystem);
|
|
69
|
+
};
|
|
70
|
+
|
|
71
|
+
/**
|
|
72
|
+
* Returns the system of this CHIP's catalog where application data for this CHIP is typically
|
|
73
|
+
* located. This API is needed in scenarios where a CHIP navigates to another application and
|
|
74
|
+
* needs to transfer system information so that the application can use the same application
|
|
75
|
+
* system.
|
|
76
|
+
*
|
|
77
|
+
* @name chip.url.getApplicationSystem
|
|
78
|
+
* @function
|
|
79
|
+
* @since 1.19.1
|
|
80
|
+
* @returns {string}
|
|
81
|
+
* the system of this CHIP's catalog or <code>undefined</code> if there is no such catalog
|
|
82
|
+
* @see chip.url.addSystemToServiceUrl
|
|
83
|
+
*/
|
|
84
|
+
this.getApplicationSystem = function () {
|
|
85
|
+
return oChipInstance.getChip().getCatalog().getSystemAlias();
|
|
86
|
+
};
|
|
87
|
+
|
|
88
|
+
/**
|
|
89
|
+
* Makes the given relative URL absolute. URLs containing host and/or protocol
|
|
90
|
+
* and URLs with an absolute path remain unchanged. The URL is in no way
|
|
91
|
+
* normalized; the function takes the URL of the CHIP definition XML as base.
|
|
92
|
+
*
|
|
93
|
+
* @name chip.url.toAbsoluteUrl
|
|
94
|
+
* @function
|
|
95
|
+
* @since 1.2.0
|
|
96
|
+
* @param {string} sUrl
|
|
97
|
+
* the (possibly server-relative) URL
|
|
98
|
+
* @returns {string}
|
|
99
|
+
* the absolute URL
|
|
100
|
+
*/
|
|
101
|
+
this.toAbsoluteUrl = function (sUrl) {
|
|
102
|
+
return oChipInstance.getChip().toAbsoluteUrl(sUrl);
|
|
103
|
+
};
|
|
104
|
+
});
|
|
105
|
+
});
|
|
@@ -0,0 +1,128 @@
|
|
|
1
|
+
// Copyright (c) 2009-2021 SAP SE. All rights reserved.
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* @fileOverview The <code>visible</code> contract.
|
|
5
|
+
*/
|
|
6
|
+
sap.ui.require([
|
|
7
|
+
"sap/ushell_abap/pbServices/ui2/Chip",
|
|
8
|
+
"sap/ushell_abap/pbServices/ui2/Error",
|
|
9
|
+
"sap/base/Log"
|
|
10
|
+
], function (
|
|
11
|
+
Chip,
|
|
12
|
+
SrvcError,
|
|
13
|
+
Log
|
|
14
|
+
) {
|
|
15
|
+
"use strict";
|
|
16
|
+
|
|
17
|
+
if (typeof jQuery === "function" && jQuery.sap) {
|
|
18
|
+
jQuery.sap.declare("sap.ui2.srvc.contracts.visible");
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
/**
|
|
23
|
+
* @namespace The namespace for the CHIP API's <code>visible</code> contract regarding the
|
|
24
|
+
* CHIP's current visibility within the page.
|
|
25
|
+
* @name chip.visible
|
|
26
|
+
* @since 1.17.1
|
|
27
|
+
*/
|
|
28
|
+
Chip.addContract("visible", function (oChipInstance) {
|
|
29
|
+
var bVisible = true,
|
|
30
|
+
fnOnVisible;
|
|
31
|
+
|
|
32
|
+
/**
|
|
33
|
+
* Calls fnOnVisible with bVisible as parameter. Adds some some error handling ensuring that exceptions will
|
|
34
|
+
* not affect the page builder.
|
|
35
|
+
*
|
|
36
|
+
* @private
|
|
37
|
+
*/
|
|
38
|
+
function callOnVisible () {
|
|
39
|
+
try {
|
|
40
|
+
fnOnVisible(bVisible);
|
|
41
|
+
} catch (e) {
|
|
42
|
+
Log.error(oChipInstance + ": call to visible handler failed: "
|
|
43
|
+
+ (e.message || e.toString()), null, "chip.visible");
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
/**
|
|
48
|
+
* Attaches the given event handler to the "visible" event which is fired whenever the CHIP's
|
|
49
|
+
* visibility has been changed. The event handler takes a boolean as parameter, representing
|
|
50
|
+
* the new visible state.
|
|
51
|
+
* (Since 1.42) fnEventHandler is called once initially with the current visibility making it
|
|
52
|
+
* unnecessary to check {#isVisible} when the CHIP is initialized. Attaching the same handler
|
|
53
|
+
* multiple times will only result in one call to it.
|
|
54
|
+
*
|
|
55
|
+
* @name chip.visible.attachVisible
|
|
56
|
+
* @function
|
|
57
|
+
* @since 1.17.0
|
|
58
|
+
* @param {function (boolean)} fnEventHandler
|
|
59
|
+
* event handler for visibility changes
|
|
60
|
+
*/
|
|
61
|
+
this.attachVisible = function (fnEventHandler) {
|
|
62
|
+
if (typeof fnEventHandler !== "function") {
|
|
63
|
+
throw new SrvcError("Not a function: " + fnEventHandler,
|
|
64
|
+
"chip.visible");
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
// attaching the same handler multiple time should not end in multiple calls (see below)
|
|
68
|
+
if (fnOnVisible === fnEventHandler) {
|
|
69
|
+
return;
|
|
70
|
+
}
|
|
71
|
+
fnOnVisible = fnEventHandler;
|
|
72
|
+
|
|
73
|
+
// call the handler directly to stay compatible with previous behavior in the FLP.
|
|
74
|
+
// There the tiles where notified directly after instantiation (multiple tiles) so they
|
|
75
|
+
// did not need to check via isVisible() if they are visible or not.
|
|
76
|
+
callOnVisible();
|
|
77
|
+
};
|
|
78
|
+
|
|
79
|
+
/**
|
|
80
|
+
* Returns the CHIP's visibility within the page builder's page. The visibility is
|
|
81
|
+
* <code>true</code> initially.
|
|
82
|
+
*
|
|
83
|
+
* @name chip.visible.isVisible
|
|
84
|
+
* @function
|
|
85
|
+
* @since 1.17.0
|
|
86
|
+
* @returns {boolean}
|
|
87
|
+
* the CHIP's visibility within the page builder's page.
|
|
88
|
+
* @see contract.visible.setVisible
|
|
89
|
+
*/
|
|
90
|
+
this.isVisible = function () {
|
|
91
|
+
return bVisible;
|
|
92
|
+
};
|
|
93
|
+
|
|
94
|
+
/**
|
|
95
|
+
* @namespace The namespace for the contract interface (to be used by a page builder) for
|
|
96
|
+
* the <code>visible</code> contract. This contract interface allows the pagebuilder to
|
|
97
|
+
* notify the CHIP when the CHIP's visibility has been changed.
|
|
98
|
+
*
|
|
99
|
+
* @name contract.visible
|
|
100
|
+
* @since 1.17.0
|
|
101
|
+
*/
|
|
102
|
+
return {
|
|
103
|
+
/**
|
|
104
|
+
* Notifies the CHIP about its new visibility. The CHIP is only informed, if the
|
|
105
|
+
* visibility is different then before.
|
|
106
|
+
*
|
|
107
|
+
* @param {boolean} bNewVisible
|
|
108
|
+
* the CHIP visibility
|
|
109
|
+
* @name contract.visible.setVisible
|
|
110
|
+
* @function
|
|
111
|
+
* @since 1.17.0
|
|
112
|
+
* @see chip.visible.isVisible
|
|
113
|
+
* @see chip.visible.attachVisible
|
|
114
|
+
*/
|
|
115
|
+
setVisible: function (bNewVisible) {
|
|
116
|
+
if (bVisible === bNewVisible) {
|
|
117
|
+
// nothing changed so do nothing
|
|
118
|
+
return;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
bVisible = bNewVisible;
|
|
122
|
+
if (fnOnVisible) {
|
|
123
|
+
callOnVisible();
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
};
|
|
127
|
+
});
|
|
128
|
+
});
|