| Index: chrome/browser/ui/views/tabs/base_tab.cc
|
| diff --git a/chrome/browser/ui/views/tabs/base_tab.cc b/chrome/browser/ui/views/tabs/base_tab.cc
|
| index cef7d9c4a2b5838cb4b3a038e2f76fae7ab8e974..87290ed25bb518ad108131a3a7877d3e602a2178 100644
|
| --- a/chrome/browser/ui/views/tabs/base_tab.cc
|
| +++ b/chrome/browser/ui/views/tabs/base_tab.cc
|
| @@ -315,7 +315,7 @@ bool BaseTab::OnMouseDragged(const views::MouseEvent& event) {
|
| return true;
|
| }
|
|
|
| -void BaseTab::OnMouseReleased(const views::MouseEvent& event, bool canceled) {
|
| +void BaseTab::OnMouseReleased(const views::MouseEvent& event) {
|
| if (!controller())
|
| return;
|
|
|
| @@ -324,7 +324,7 @@ void BaseTab::OnMouseReleased(const views::MouseEvent& event, bool canceled) {
|
| // In some cases, ending the drag will schedule the tab for destruction; if
|
| // so, bail immediately, since our members are already dead and we shouldn't
|
| // do anything else except drop the tab where it is.
|
| - if (controller()->EndDrag(canceled))
|
| + if (controller()->EndDrag(false))
|
| return;
|
|
|
| // Close tab on middle click, but only if the button is released over the tab
|
| @@ -352,6 +352,11 @@ void BaseTab::OnMouseReleased(const views::MouseEvent& event, bool canceled) {
|
| }
|
| }
|
|
|
| +void BaseTab::OnMouseCaptureLost() {
|
| + if (controller())
|
| + controller()->EndDrag(true);
|
| +}
|
| +
|
| void BaseTab::OnMouseEntered(const views::MouseEvent& event) {
|
| if (!hover_animation_.get()) {
|
| hover_animation_.reset(new ui::SlideAnimation(this));
|
|
|