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

Side by Side Diff: chrome/browser/ui/cocoa/tabs/tab_controller.mm

Issue 2743993003: cocoa: add experimental tabstrip keyboard focus support (Closed)
Patch Set: fix histogram Created 3 years, 9 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/about_flags.cc ('k') | chrome/browser/ui/cocoa/tabs/tab_view.mm » ('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 #import "chrome/browser/ui/cocoa/tabs/tab_controller.h" 5 #import "chrome/browser/ui/cocoa/tabs/tab_controller.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <cmath> 8 #include <cmath>
9 9
10 #include "base/i18n/rtl.h" 10 #include "base/i18n/rtl.h"
(...skipping 472 matching lines...) Expand 10 before | Expand all | Expand 10 after
483 return [[self target] performSelector:@selector(inRapidClosureMode)] ? 483 return [[self target] performSelector:@selector(inRapidClosureMode)] ?
484 YES : NO; 484 YES : NO;
485 } 485 }
486 return NO; 486 return NO;
487 } 487 }
488 488
489 - (void)maybeStartDrag:(NSEvent*)event forTab:(TabController*)tab { 489 - (void)maybeStartDrag:(NSEvent*)event forTab:(TabController*)tab {
490 [[target_ dragController] maybeStartDrag:event forTab:tab]; 490 [[target_ dragController] maybeStartDrag:event forTab:tab];
491 } 491 }
492 492
493 - (void)keyUp:(NSEvent*)event {
494 unichar keyChar = [[event characters] characterAtIndex:0];
495 if (keyChar == '\r' || keyChar == '\n')
496 [self selectTab:self];
497 }
498
493 @end 499 @end
OLDNEW
« no previous file with comments | « chrome/browser/about_flags.cc ('k') | chrome/browser/ui/cocoa/tabs/tab_view.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698