else mPresShell = 0;
  void HandleEvent() {        nsCOMPtr<nsIPresShell> presShell = do_QueryReferent(mPresShell);    if (presShell) {#ifdef DEBUG      if (VERIFY_REFLOW_NOISY_RC & gVerifyReflowFlags) {         printf("\n*** Handling reflow event: PresShell=%p, event=%p\n", presShell.get(), this);      }#endif      // XXX Statically cast the pres shell pointer so that we can call      // protected methods on the pres shell. (the ReflowEvent struct      // is a friend of the PresShell class)      PresShell* ps = NS_REINTERPRET_CAST(PresShell*, presShell.get());      PRBool isBatching;      ps->SetReflowEventStatus(PR_FALSE);      ps->GetReflowBatchingStatus(&isBatching);      if (!isBatching) {        nsCOMPtr<nsIViewManager> viewManager;        // Set a kung fu death grip on the view manager associated with the pres shell        // before processing that pres shell's reflow commands.  Fixes bug 54868.        presShell->GetViewManager(getter_AddRefs(viewManager));        ps->ProcessReflowCommands(PR_TRUE);        // Now, explicitly release the pres shell before the view manager        presShell = nsnull;        viewManager = nsnull;      }    }    else      mPresShell = 0;  }