nsCOMPtr<nsIDocShellTreeItem> docShell(do_QueryReferent(mContainer));
nsCOMPtr<nsIDocShellTreeItem> docShell(do_QueryInterface(mContainer));
nsPresContext::PreferenceChanged(const char* aPrefName){  nsCOMPtr<nsIDocShellTreeItem> docShell(do_QueryReferent(mContainer));  if (docShell) {    PRInt32 docShellType;    docShell->GetItemType(&docShellType);    if (nsIDocShellTreeItem::typeChrome == docShellType)      return;  }  // Initialize our state from the user preferences  GetUserPreferences();  // update the presShell: tell it to set the preference style rules up  if (mShell) {    mShell->SetPreferenceStyleRules(PR_TRUE);  }  mDeviceContext->FlushFontCache();  ClearStyleDataAndReflow();}