summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsky@chromium.org <sky@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-01-12 19:49:56 +0000
committersky@chromium.org <sky@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-01-12 19:49:56 +0000
commit3f3775345a4fab5c7b88739141897a164fdf6c2e (patch)
treed471a037099747b69fa870cf8235e4e6f39fb5a9
parentcdc5f1e82f5f11856c906ee5403748e623131a06 (diff)
downloadchromium_src-3f3775345a4fab5c7b88739141897a164fdf6c2e.zip
chromium_src-3f3775345a4fab5c7b88739141897a164fdf6c2e.tar.gz
chromium_src-3f3775345a4fab5c7b88739141897a164fdf6c2e.tar.bz2
Fixes crash in dragging a tab out in overview mode. This regression
was introduced when adding the views/gtk support. As we don't need non-views/gtk support anymore, I'm nuking the defines in this file. BUG=32057 TEST=see bug Review URL: http://codereview.chromium.org/546019 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@36032 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--chrome/browser/views/tabs/tab_overview_controller.cc19
1 files changed, 3 insertions, 16 deletions
diff --git a/chrome/browser/views/tabs/tab_overview_controller.cc b/chrome/browser/views/tabs/tab_overview_controller.cc
index ac5a251..3e791d6 100644
--- a/chrome/browser/views/tabs/tab_overview_controller.cc
+++ b/chrome/browser/views/tabs/tab_overview_controller.cc
@@ -6,13 +6,8 @@
#include "chrome/browser/browser.h"
#include "chrome/browser/browser_process.h"
-#if defined(TOOLKIT_VIEWS)
-#include "chrome/common/x11_util.h"
#include "chrome/browser/views/frame/browser_extender.h"
#include "chrome/browser/views/frame/browser_view.h"
-#else
-#include "chrome/browser/gtk/browser_window_gtk.h"
-#endif
#include "chrome/browser/tab_contents/tab_contents.h"
#include "chrome/browser/tab_contents/thumbnail_generator.h"
#include "chrome/browser/views/tabs/tab_overview_cell.h"
@@ -21,6 +16,7 @@
#include "chrome/browser/views/tabs/tab_overview_grid.h"
#include "chrome/browser/views/tabs/tab_overview_types.h"
#include "chrome/browser/window_sizer.h"
+#include "chrome/common/x11_util.h"
#include "views/widget/root_view.h"
#include "views/widget/widget_gtk.h"
@@ -163,22 +159,13 @@ void TabOverviewController::ConfigureCell(TabOverviewCell* cell,
void TabOverviewController::DragStarted() {
DCHECK(!drag_browser_);
drag_browser_ = browser_;
-#if defined(TOOLKIT_VIEWS)
- static_cast<BrowserView*>(browser_->window())->
+ static_cast<BrowserView*>(drag_browser_->window())->
browser_extender()->set_can_close(false);
-#else
- static_cast<BrowserWindowGtk*>(browser_->window())->set_drag_active(true);
-#endif
}
void TabOverviewController::DragEnded() {
-#if defined(TOOLKIT_VIEWS)
- static_cast<BrowserView*>(browser_->window())->
+ static_cast<BrowserView*>(drag_browser_->window())->
browser_extender()->set_can_close(true);
-#else
- static_cast<BrowserWindowGtk*>(drag_browser_->window())->
- set_drag_active(false);
-#endif
if (drag_browser_->tabstrip_model()->count() == 0)
drag_browser_->tabstrip_model()->delegate()->CloseFrameAfterDragSession();
drag_browser_ = NULL;