Adapts the visibility of the button bar.
548650
private void adaptButtonBarVisibility() {
        if (buttonBarParent != null) {
            buttonBarParent.setVisibility(showRestoreDefaultsButton ? View.VISIBLE : View.GONE);
        }
    }
1299551
private void overButtonBar(Widget buttonBar) {

        if ((m_buttonBar == null) || (buttonBar.getElement() != m_buttonBar.getElement())) {
            closeAll();
            m_buttonBar = buttonBar;
            setButtonBarVisibility(m_buttonBar, true);
        }
    }
1348773
private void adaptHeaderVisibility() {
        if (header != null) {
            if (showHeader) {
                header.setVisibility(View.VISIBLE);
                notifyOnAreaShown(Area.HEADER);
            } else {
                header.setVisibility(View.GONE);
                notifyOnAreaHidden(Area.HEADER);
            }
        }
    }
67328
private void adaptPositiveButton() {
        if (positiveButton != null) {
            positiveButton.setText(positiveButtonText != null ?
                    positiveButtonText.toString().toUpperCase(Locale.getDefault()) : null);
            OnClickListenerWrapper onClickListener =
                    new OnClickListenerWrapper(positiveButtonListener, true, getDialog(),
                            DialogInterface.BUTTON_POSITIVE);
            positiveButton.setOnClickListener(onClickListener);
            positiveButton.setVisibility(
                    !TextUtils.isEmpty(positiveButtonText) ? View.VISIBLE : View.GONE);
            adaptButtonBarContainerVisibility();
        }
    }
1354376
private void adaptButtonTypeface() {
        if (buttonTypeface != null) {
            if (positiveButton != null) {
                positiveButton.setTypeface(buttonTypeface);
            }

            if (neutralButton != null) {
                neutralButton.setTypeface(buttonTypeface);
            }

            if (negativeButton != null) {
                negativeButton.setTypeface(buttonTypeface);
            }
        }
    }
664818
private void adaptButtonVisibility() {
        if (viewPager != null && viewPagerAdapter != null && backButton != null &&
                nextButton != null && finishButton != null) {
            int selectedIndex = viewPager.getCurrentItem();
            backButton.setVisibility(selectedIndex > 0 ? View.VISIBLE : View.GONE);
            nextButton.setVisibility(
                    selectedIndex < viewPagerAdapter.getCount() - 1 ? View.VISIBLE : View.GONE);
            finishButton.setVisibility(
                    selectedIndex == viewPagerAdapter.getCount() - 1 ? View.VISIBLE : View.GONE);
        }
    }
736617
def set_visible(self, visible):
        
        v = View.VISIBILITY_VISIBLE if visible else View.VISIBILITY_GONE
        self.widget.setVisibility(v)
453540
private void adaptButtonBar() {
        if (buttonBarContainer != null) {
            inflateButtonBar();
            adaptPositiveButton();
            adaptNegativeButton();
            adaptNeutralButton();
            adaptButtonTextColor();
            adaptButtonTypeface();
            adaptButtonBarContainerVisibility();
            adaptButtonBarDividerVisibility();
        }
    }
645452
protected void setDirectEditButtonsVisible(boolean visible) {

        m_editButtonsVisibility.setValue(
            visible
            ? I_CmsLayoutBundle.INSTANCE.directEditCss().showButtons()
            : I_CmsLayoutBundle.INSTANCE.directEditCss().hideButtons());
        getHandler().showToolbar(visible);
    }
1110699
private void adaptButtonBarDividerVisibility() {
        if (buttonBarDivider != null) {
            buttonBarDivider.setVisibility(showButtonBarDivider ? View.VISIBLE : View.GONE);
            buttonBarDivider.setVisibleByDefault(showButtonBarDivider);
        }
    }
352207
private void adaptPadding() {
        ViewGroup dialogRootView = getRootView();

        if (dialogRootView != null) {
            dialogRootView.setPadding(getPaddingLeft(), getPaddingTop(), getPaddingRight(),
                    getPaddingBottom());
        }
    }
789601
function updateScrollButtonVisibility(hideAll) {
		if (hideAll && this._topScrollButton && this._bottomScrollButton) {
			this._topScrollButton.style.display = "none";
			this._bottomScrollButton.style.display = "none";	
		}
		else if (!hideAll) {
			if (this._dropdownNode.scrollTop > 0) {
				this._topScrollButton.style.display = "block";
			} 
			else {
				this._topScrollButton.style.display = "none";
			}	
			if (this._dropdownNode.scrollHeight > this._dropdownNode.scrollTop + this._dropdownNode.offsetHeight) {
				this._bottomScrollButton.style.display = "block";
			}	 
			else {
				this._bottomScrollButton.style.display = "none";
			}
		}
	}
1345047
private void setButtonBarVisible(boolean visible) {

        if (m_hasButtonBar != visible) {
            m_hasButtonBar = visible;
            if (m_hasButtonBar) {

                m_buttonBar.getStyle().clearDisplay();
                int width = CmsClientStringUtil.parseInt(m_borderTopStyle.getWidth()) + BUTTON_BAR_WIDTH;
                m_borderTopStyle.setWidth(width, Unit.PX);
                m_borderBottomStyle.setWidth(width, Unit.PX);
                m_borderRightStyle.setLeft(
                    CmsClientStringUtil.parseInt(m_borderRightStyle.getLeft()) + BUTTON_BAR_WIDTH,
                    Unit.PX);
            } else {
                m_buttonBar.getStyle().setDisplay(Display.NONE);
                int width = CmsClientStringUtil.parseInt(m_borderTopStyle.getWidth()) - BUTTON_BAR_WIDTH;
                m_borderTopStyle.setWidth(width, Unit.PX);
                m_borderBottomStyle.setWidth(width, Unit.PX);
                m_borderRightStyle.setLeft(
                    CmsClientStringUtil.parseInt(m_borderRightStyle.getLeft()) - BUTTON_BAR_WIDTH,
                    Unit.PX);
            }
        }
    }
723198
private void adjustVisibleColumns() {

        if (m_table.isColumnCollapsingAllowed()) {
            if ((m_model.hasDefaultValues()) || m_model.getBundleType().equals(BundleType.DESCRIPTOR)) {
                m_table.setColumnCollapsed(TableProperty.DEFAULT, false);
            } else {
                m_table.setColumnCollapsed(TableProperty.DEFAULT, true);
            }

            if (((m_model.getEditMode().equals(EditMode.MASTER) || m_model.hasDescriptionValues()))
                || m_model.getBundleType().equals(BundleType.DESCRIPTOR)) {
                m_table.setColumnCollapsed(TableProperty.DESCRIPTION, false);
            } else {
                m_table.setColumnCollapsed(TableProperty.DESCRIPTION, true);
            }
        }
    }
1251716
def adjustButtons( self ):
        
        y = 1
        
        for btn in self.buttons():
            btn.setIconSize(self.iconSize())
            btn.setFixedSize(QSize(self.height() - 2, self.height() - 2))
        
        # adjust the location for the left buttons
        left_buttons = self._buttons.get(Qt.AlignLeft, [])
        x = (self.cornerRadius() / 2.0) + 2
        
        for btn in left_buttons:
            btn.move(x, y)
            x += btn.width()
        
        # adjust the location for the right buttons
        right_buttons = self._buttons.get(Qt.AlignRight, [])
        
        w       = self.width()
        bwidth  = sum([btn.width() for btn in right_buttons])
        bwidth  += (self.cornerRadius() / 2.0) + 1
        
        for btn in right_buttons:
            btn.move(w - bwidth, y)
            bwidth -= btn.width()
        
        self._buttonWidth = sum([btn.width() for btn in self.buttons()])
        self.adjustTextMargins()
584201
private void adaptProgressBar() {
        LayoutInflater inflater = LayoutInflater.from(getContext());
        View view = inflater.inflate(getCustomMessageId(), getRootView(), false);
        getDialog().setCustomMessage(view);
        View progressView = view.findViewById(R.id.progress_bar);
        progressBar =
                progressView instanceof CircularProgressBar ? (CircularProgressBar) progressView :
                        null;
        adaptProgressBarColor();
        adaptProgressBarSize();
        adaptProgressBarThickness();
        adaptMessageTextSize();
    }
1244886
private void setDetailsVisible(boolean detailsVisible) {
		detailsLayout.setVisible(detailsVisible);
		if (detailsVisible) {
			setAutoSize(false);
			expandButton.setTitle(MESSAGES.exceptionDetailsHide());
			setHeight(WidgetLayout.exceptionWindowHeightDetails);
		} else {
			expandButton.setTitle(MESSAGES.exceptionDetailsView());
			setHeight(WidgetLayout.exceptionWindowHeightNormal);
		}
	}