src/sap.ui.dt/src/sap/ui/dt/ContextMenuControl.js
function (aButtons) {
			var iButtonsEnabled = 0;
			for (var i = 0; i < aButtons.length; i++) {
				if (aButtons[i].getEnabled()) {
					iButtonsEnabled++;
					if (!this._iFirstVisibleButtonIndex) {
						this._iFirstVisibleButtonIndex = i;
					}
				}
			}

			return iButtonsEnabled;
		}
function (aButtons) {
			var iButtonsEnabled = 0;
			for (var i = 0; i < aButtons.length; i++) {
				if (aButtons[i].getEnabled()) {
					iButtonsEnabled++;
					if (!this._iFirstVisibleButtonIndex) {
						this._iFirstVisibleButtonIndex = i;
					}
				}
			}

			return iButtonsEnabled;
		}
function ( aButtons ) { var iButtonsEnabled = 0 ; for ( var i = 0 ; i < aButtons . length ; i ++ ) { if ( aButtons [ i ] . getEnabled ( ) ) { iButtonsEnabled ++ ; if ( ! this . _iFirstVisibleButtonIndex ) { this . _iFirstVisibleButtonIndex = i ; } } } return iButtonsEnabled ; }
Returns the number of enabled button
Sets firstVisibleButtonIndex
@param {array} aButtons some buttons
@return {int} number of enabled buttons
Returns the number of enabled button Sets firstVisibleButtonIndex