public void runViewUpdate(final Runnable runnable, final boolean preserveExpansion) {
   if (Utils.canUpdateViewer(getViewer()) || isPerformingBackgroundUpdate()) {
     internalRunViewUpdate(runnable, preserveExpansion);
   } else {
     if (Thread.currentThread() != getEventHandlerJob().getThread()) {
       // Run view update should only be called from the UI thread or
       // the update handler thread.
       // We will log the problem for now and make it an assert later
       TeamUIPlugin.log(
           IStatus.WARNING,
           "View update invoked from invalid thread",
           new TeamException(
               "View update invoked from invalid thread")); //$NON-NLS-1$ //$NON-NLS-2$
     }
     final Control ctrl = getViewer().getControl();
     if (ctrl != null && !ctrl.isDisposed()) {
       ctrl.getDisplay()
           .syncExec(
               new Runnable() {
                 public void run() {
                   if (!ctrl.isDisposed()) {
                     BusyIndicator.showWhile(
                         ctrl.getDisplay(),
                         new Runnable() {
                           public void run() {
                             internalRunViewUpdate(runnable, preserveExpansion);
                           }
                         });
                   }
                 }
               });
     }
   }
 }
  protected void calculateDescription() {
    SyncInfoTree syncInfoTree = getVisibleSyncInfoSet();
    if (syncInfoTree.getErrors().length > 0) {
      if (!showingError) {
        TeamUIPlugin.getStandardDisplay()
            .asyncExec(
                new Runnable() {
                  public void run() {
                    updatePage(getErrorComposite(getContainer()));
                    showingError = true;
                  }
                });
      }
      return;
    }

    showingError = false;
    super.calculateDescription();
  }