code: private void adaptHeaderVisibility() {
          if (header != null) {
              if (showHeader) {
                  header.setVisibility(View.VISIBLE);
                  notifyOnAreaShown(Area.HEADER);
              } else {
                  header.setVisibility(View.GONE);
                  notifyOnAreaHidden(Area.HEADER);
              }
          }
      }
docs: Adapts the visibility of the dialog's header.