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

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

Issue 3174030: Making window.focus()/blur() work only when there is a user gesture. (Closed) Base URL: git://codf21.jail/chromium.git
Patch Set: Created 10 years, 4 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
« no previous file with comments | « chrome/browser/views/tabs/dragged_tab_controller.h ('k') | chrome/renderer/render_view.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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 "chrome/browser/views/tabs/dragged_tab_controller.h" 5 #include "chrome/browser/views/tabs/dragged_tab_controller.h"
6 6
7 #include <math.h> 7 #include <math.h>
8 #include <set> 8 #include <set>
9 9
10 #include "app/animation.h" 10 #include "app/animation.h"
(...skipping 411 matching lines...) Expand 10 before | Expand all | Expand 10 after
422 if (original_delegate_) { 422 if (original_delegate_) {
423 original_delegate_->AddNewContents(source, new_contents, disposition, 423 original_delegate_->AddNewContents(source, new_contents, disposition,
424 initial_pos, user_gesture); 424 initial_pos, user_gesture);
425 } 425 }
426 } 426 }
427 427
428 void DraggedTabController::ActivateContents(TabContents* contents) { 428 void DraggedTabController::ActivateContents(TabContents* contents) {
429 // Ignored. 429 // Ignored.
430 } 430 }
431 431
432 void DraggedTabController::DeactivateContents(TabContents* contents) {
433 // Ignored.
434 }
435
432 void DraggedTabController::LoadingStateChanged(TabContents* source) { 436 void DraggedTabController::LoadingStateChanged(TabContents* source) {
433 // It would be nice to respond to this message by changing the 437 // It would be nice to respond to this message by changing the
434 // screen shot in the dragged tab. 438 // screen shot in the dragged tab.
435 if (view_.get()) 439 if (view_.get())
436 view_->Update(); 440 view_->Update();
437 } 441 }
438 442
439 void DraggedTabController::CloseContents(TabContents* source) { 443 void DraggedTabController::CloseContents(TabContents* source) {
440 // Theoretically could be called by a window. Should be ignored 444 // Theoretically could be called by a window. Should be ignored
441 // because window.close() is ignored (usually, even though this 445 // because window.close() is ignored (usually, even though this
(...skipping 886 matching lines...) Expand 10 before | Expand all | Expand 10 after
1328 #else 1332 #else
1329 NOTIMPLEMENTED(); 1333 NOTIMPLEMENTED();
1330 #endif 1334 #endif
1331 } 1335 }
1332 } 1336 }
1333 1337
1334 TabStripModel* DraggedTabController::GetModel(BaseTabStrip* tabstrip) const { 1338 TabStripModel* DraggedTabController::GetModel(BaseTabStrip* tabstrip) const {
1335 return static_cast<BrowserTabStripController*>(tabstrip->controller())-> 1339 return static_cast<BrowserTabStripController*>(tabstrip->controller())->
1336 model(); 1340 model();
1337 } 1341 }
OLDNEW
« no previous file with comments | « chrome/browser/views/tabs/dragged_tab_controller.h ('k') | chrome/renderer/render_view.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698