Couple of match preview changes.
. Commit the match preview on mouse up for instant results. This is
  needed as instant results may shift up during the commit. If we
  didn't do this it could mean the mouse up event appears over a
  different item then the mouse went down on.
. Makes match preview revert if focus goes to the page and wasn't
  initiated by a mouse event.
. Makes transition from about:crash to valid page not commit the match
  preview.
. Changes setOmniboxDimensions to setDropdownDimensions.

BUG=54833 56179
TEST=none

Review URL: http://codereview.chromium.org/3531001

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@60969 0039d316-1c4b-4281-b951-d872f2087c98
diff --git a/chrome/browser/tab_contents/tab_contents.cc b/chrome/browser/tab_contents/tab_contents.cc
index b33f3d8..a4592c1a 100644
--- a/chrome/browser/tab_contents/tab_contents.cc
+++ b/chrome/browser/tab_contents/tab_contents.cc
@@ -2370,8 +2370,10 @@
 
   // Restore the focus to the tab (otherwise the focus will be on the top
   // window).
-  if (was_crashed && !FocusLocationBarByDefault())
+  if (was_crashed && !FocusLocationBarByDefault() &&
+      (!delegate_ || delegate_->ShouldFocusPageAfterCrash())) {
     Focus();
+  }
 }
 
 void TabContents::RenderViewGone(RenderViewHost* rvh) {