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

Side by Side Diff: chrome/browser/views/tabs/dragged_tab_controller.cc

Issue 18540: Don't expose the go and star button views directly through the BrowserWindow ... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 11 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 | « chrome/browser/views/info_bubble.cc ('k') | chrome/test/test_browser_window.h » ('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) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 #include <math.h> 5 #include <math.h>
6 #include <set> 6 #include <set>
7 7
8 #include "chrome/browser/views/tabs/dragged_tab_controller.h" 8 #include "chrome/browser/views/tabs/dragged_tab_controller.h"
9 9
10 #include "chrome/browser/browser_window.h" 10 #include "chrome/browser/browser_window.h"
(...skipping 672 matching lines...) Expand 10 before | Expand all | Expand 10 after
683 683
684 TabStrip* DraggedTabController::GetTabStripForPoint( 684 TabStrip* DraggedTabController::GetTabStripForPoint(
685 const gfx::Point& screen_point) { 685 const gfx::Point& screen_point) {
686 HWND dragged_hwnd = view_->GetWidget()->GetHWND(); 686 HWND dragged_hwnd = view_->GetWidget()->GetHWND();
687 dock_windows_.insert(dragged_hwnd); 687 dock_windows_.insert(dragged_hwnd);
688 HWND local_window = 688 HWND local_window =
689 DockInfo::GetLocalProcessWindowAtPoint(screen_point, dock_windows_); 689 DockInfo::GetLocalProcessWindowAtPoint(screen_point, dock_windows_);
690 dock_windows_.erase(dragged_hwnd); 690 dock_windows_.erase(dragged_hwnd);
691 if (!local_window) 691 if (!local_window)
692 return NULL; 692 return NULL;
693 BrowserWindow* browser = BrowserView::GetBrowserWindowForHWND(local_window); 693 BrowserView* browser = BrowserView::GetBrowserViewForHWND(local_window);
694 if (!browser) 694 if (!browser)
695 return NULL; 695 return NULL;
696 696
697 TabStrip* other_tabstrip = browser->GetTabStrip(); 697 TabStrip* other_tabstrip = browser->tabstrip();
698 if (!other_tabstrip->IsCompatibleWith(source_tabstrip_)) 698 if (!other_tabstrip->IsCompatibleWith(source_tabstrip_))
699 return NULL; 699 return NULL;
700 return GetTabStripIfItContains(other_tabstrip, screen_point); 700 return GetTabStripIfItContains(other_tabstrip, screen_point);
701 } 701 }
702 702
703 TabStrip* DraggedTabController::GetTabStripIfItContains( 703 TabStrip* DraggedTabController::GetTabStripIfItContains(
704 TabStrip* tabstrip, const gfx::Point& screen_point) const { 704 TabStrip* tabstrip, const gfx::Point& screen_point) const {
705 static const int kVerticalDetachMagnetism = 15; 705 static const int kVerticalDetachMagnetism = 15;
706 // Make sure the specified screen point is actually within the bounds of the 706 // Make sure the specified screen point is actually within the bounds of the
707 // specified tabstrip... 707 // specified tabstrip...
(...skipping 485 matching lines...) Expand 10 before | Expand all | Expand 10 after
1193 // Move the window to the front. 1193 // Move the window to the front.
1194 SetWindowPos(hwnd, HWND_TOP, 0, 0, 0, 0, 1194 SetWindowPos(hwnd, HWND_TOP, 0, 0, 0, 0,
1195 SWP_NOACTIVATE | SWP_NOMOVE | SWP_NOSIZE); 1195 SWP_NOACTIVATE | SWP_NOMOVE | SWP_NOSIZE);
1196 1196
1197 // The previous call made the window appear on top of the dragged window, 1197 // The previous call made the window appear on top of the dragged window,
1198 // move the dragged window to the front. 1198 // move the dragged window to the front.
1199 SetWindowPos(view_->GetWidget()->GetHWND(), HWND_TOP, 0, 0, 0, 0, 1199 SetWindowPos(view_->GetWidget()->GetHWND(), HWND_TOP, 0, 0, 0, 0,
1200 SWP_NOACTIVATE | SWP_NOMOVE | SWP_NOSIZE); 1200 SWP_NOACTIVATE | SWP_NOMOVE | SWP_NOSIZE);
1201 } 1201 }
1202 } 1202 }
OLDNEW
« no previous file with comments | « chrome/browser/views/info_bubble.cc ('k') | chrome/test/test_browser_window.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698