Fix bug 130606:	Panels [WIN]: Alt-Tabbing to a minimized panel no longer restores it

BUG=130606
TEST=Manual test by minimizing panel and alt-tabbing to it


Review URL: https://chromiumcodereview.appspot.com/10509011

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@140498 0039d316-1c4b-4281-b951-d872f2087c98
bool PanelBrowserView::OnTitlebarMouseReleased(panel::ClickModifier modifier) {
  if (mouse_dragging_state_ != NO_DRAGGING) {
    if (panel_->IsMinimized() && panel_->IsActive())
      panel_->Deactivate();

    if (mouse_dragging_state_ == DRAGGING_STARTED) {
      if (old_focused_view_) {
        GetFocusManager()->SetFocusedView(old_focused_view_);
        old_focused_view_ = NULL;
      }
      return EndDragging(false);
    }

    if (mouse_dragging_state_ != NO_DRAGGING)
      return true;
  }

  panel_->OnTitlebarClicked(modifier);
  return true;
}

bool PanelBrowserView::OnTitlebarMouseReleased(panel::ClickModifier modifier) {
  if (mouse_dragging_state_ != NO_DRAGGING) {
    if (panel_->IsMinimized() && panel_->IsActive())
      panel_->Deactivate();

    if (mouse_dragging_state_ == DRAGGING_STARTED) {
      if (old_focused_view_) {
        GetFocusManager()->SetFocusedView(old_focused_view_);
        old_focused_view_ = NULL;
      }
      return EndDragging(false);
    }

    if (mouse_dragging_state_ != NO_DRAGGING)
      return true;
  }

  panel_->OnTitlebarClicked(modifier);
  return true;
}
