src/sap.ui.dt/src/sap/ui/dt/ContextMenuControl.js
function (aButtons) {
			var iVisibleButtons = 0;
			aButtons.forEach(function (oButton) {
				oButton.setVisible(oButton.getEnabled());
				if (oButton.getEnabled()) {
					iVisibleButtons++;
				}
			});

			return iVisibleButtons;
		}
function (aButtons) {
			var iVisibleButtons = 0;
			aButtons.forEach(function (oButton) {
				oButton.setVisible(oButton.getEnabled());
				if (oButton.getEnabled()) {
					iVisibleButtons++;
				}
			});

			return iVisibleButtons;
		}
function ( aButtons ) { var iVisibleButtons = 0 ; aButtons . forEach ( function ( oButton ) { oButton . setVisible ( oButton . getEnabled ( ) ) ; if ( oButton . getEnabled ( ) ) { iVisibleButtons ++ ; } } ) ; return iVisibleButtons ; }
Hiddes all disabled buttons and returns the number if visible buttons
@param {array} aButtons some Buttons
@return {int} the number of visible buttons
Hiddes all disabled buttons and returns the number if visible buttons