Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(47)

Side by Side Diff: chrome/browser/ui/views/tabs/tab_drag_controller.h

Issue 149393009: Fixes possible crash in tab dragging (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/browser/ui/views/tabs/tab_drag_controller.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_UI_VIEWS_TABS_TAB_DRAG_CONTROLLER_H_ 5 #ifndef CHROME_BROWSER_UI_VIEWS_TABS_TAB_DRAG_CONTROLLER_H_
6 #define CHROME_BROWSER_UI_VIEWS_TABS_TAB_DRAG_CONTROLLER_H_ 6 #define CHROME_BROWSER_UI_VIEWS_TABS_TAB_DRAG_CONTROLLER_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 393 matching lines...) Expand 10 before | Expand all | Expand 10 after
404 void RevertDrag(); 404 void RevertDrag();
405 405
406 // Reverts the tab at |drag_index| in |drag_data_|. 406 // Reverts the tab at |drag_index| in |drag_data_|.
407 void RevertDragAt(size_t drag_index); 407 void RevertDragAt(size_t drag_index);
408 408
409 // Selects the dragged tabs in |model|. Does nothing if there are no longer 409 // Selects the dragged tabs in |model|. Does nothing if there are no longer
410 // any dragged contents (as happens when a WebContents is deleted out from 410 // any dragged contents (as happens when a WebContents is deleted out from
411 // under us). 411 // under us).
412 void ResetSelection(TabStripModel* model); 412 void ResetSelection(TabStripModel* model);
413 413
414 // Restores |initial_selection_model_| to the |source_tabstrip_|.
415 void RestoreInitialSelection();
416
414 // Finishes a succesful drag operation. 417 // Finishes a succesful drag operation.
415 void CompleteDrag(); 418 void CompleteDrag();
416 419
417 // Maximizes the attached window. 420 // Maximizes the attached window.
418 void MaximizeAttachedWindow(); 421 void MaximizeAttachedWindow();
419 422
420 // Resets the delegates of the WebContents. 423 // Resets the delegates of the WebContents.
421 void ResetDelegates(); 424 void ResetDelegates();
422 425
423 // Create the DraggedTabView. 426 // Create the DraggedTabView.
(...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after
658 // See comment around use for more details. 661 // See comment around use for more details.
659 int attach_x_; 662 int attach_x_;
660 int attach_index_; 663 int attach_index_;
661 664
662 base::WeakPtrFactory<TabDragController> weak_factory_; 665 base::WeakPtrFactory<TabDragController> weak_factory_;
663 666
664 DISALLOW_COPY_AND_ASSIGN(TabDragController); 667 DISALLOW_COPY_AND_ASSIGN(TabDragController);
665 }; 668 };
666 669
667 #endif // CHROME_BROWSER_UI_VIEWS_TABS_TAB_DRAG_CONTROLLER_H_ 670 #endif // CHROME_BROWSER_UI_VIEWS_TABS_TAB_DRAG_CONTROLLER_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/views/tabs/tab_drag_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698