| OLD | NEW |
| 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 "build/build_config.h" | 5 #include "build/build_config.h" |
| 6 | 6 |
| 7 #include "app/keyboard_codes.h" | 7 #include "app/keyboard_codes.h" |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 #include "base/logging.h" | 9 #include "base/logging.h" |
| 10 #include "base/message_loop.h" | 10 #include "base/message_loop.h" |
| (...skipping 618 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 629 EXPECT_NO_FATAL_FAILURE(TestKeyEvent(tab_index, kTestAccess1)); | 629 EXPECT_NO_FATAL_FAILURE(TestKeyEvent(tab_index, kTestAccess1)); |
| 630 #if defined(TOOLKIT_GTK) | 630 #if defined(TOOLKIT_GTK) |
| 631 // On GTK, alt-0..9 are assigned as tab selection accelerators, so they can | 631 // On GTK, alt-0..9 are assigned as tab selection accelerators, so they can |
| 632 // not be used as accesskeys. | 632 // not be used as accesskeys. |
| 633 EXPECT_NO_FATAL_FAILURE(CheckFocusedElement(tab_index, L"")); | 633 EXPECT_NO_FATAL_FAILURE(CheckFocusedElement(tab_index, L"")); |
| 634 #else | 634 #else |
| 635 EXPECT_NO_FATAL_FAILURE(CheckFocusedElement(tab_index, L"1")); | 635 EXPECT_NO_FATAL_FAILURE(CheckFocusedElement(tab_index, L"1")); |
| 636 #endif | 636 #endif |
| 637 } | 637 } |
| 638 | 638 |
| 639 // Flaky, http://crbug.com/65847. | 639 // Disabled, http://crbug.com/69475. |
| 640 IN_PROC_BROWSER_TEST_F(BrowserKeyEventsTest, FLAKY_ReservedAccelerators) { | 640 IN_PROC_BROWSER_TEST_F(BrowserKeyEventsTest, DISABLED_ReservedAccelerators) { |
| 641 ASSERT_TRUE(test_server()->Start()); | 641 ASSERT_TRUE(test_server()->Start()); |
| 642 | 642 |
| 643 ASSERT_TRUE(ui_test_utils::BringBrowserWindowToFront(browser())); | 643 ASSERT_TRUE(ui_test_utils::BringBrowserWindowToFront(browser())); |
| 644 GURL url = test_server()->GetURL(kTestingPage); | 644 GURL url = test_server()->GetURL(kTestingPage); |
| 645 ui_test_utils::NavigateToURL(browser(), url); | 645 ui_test_utils::NavigateToURL(browser(), url); |
| 646 | 646 |
| 647 ASSERT_NO_FATAL_FAILURE(ClickOnView(VIEW_ID_TAB_CONTAINER)); | 647 ASSERT_NO_FATAL_FAILURE(ClickOnView(VIEW_ID_TAB_CONTAINER)); |
| 648 ASSERT_TRUE(IsViewFocused(VIEW_ID_TAB_CONTAINER_FOCUS_VIEW)); | 648 ASSERT_TRUE(IsViewFocused(VIEW_ID_TAB_CONTAINER_FOCUS_VIEW)); |
| 649 | 649 |
| 650 ASSERT_EQ(1, browser()->tab_count()); | 650 ASSERT_EQ(1, browser()->tab_count()); |
| (...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 837 EXPECT_NO_FATAL_FAILURE(TestKeyEvent(tab_index, kTestAltKeySuppress)); | 837 EXPECT_NO_FATAL_FAILURE(TestKeyEvent(tab_index, kTestAltKeySuppress)); |
| 838 ASSERT_TRUE(IsViewFocused(VIEW_ID_TAB_CONTAINER_FOCUS_VIEW)); | 838 ASSERT_TRUE(IsViewFocused(VIEW_ID_TAB_CONTAINER_FOCUS_VIEW)); |
| 839 | 839 |
| 840 // Ctrl+Alt should have no effect. | 840 // Ctrl+Alt should have no effect. |
| 841 EXPECT_NO_FATAL_FAILURE(TestKeyEvent(tab_index, kTestCtrlAltKey)); | 841 EXPECT_NO_FATAL_FAILURE(TestKeyEvent(tab_index, kTestCtrlAltKey)); |
| 842 ASSERT_TRUE(IsViewFocused(VIEW_ID_TAB_CONTAINER_FOCUS_VIEW)); | 842 ASSERT_TRUE(IsViewFocused(VIEW_ID_TAB_CONTAINER_FOCUS_VIEW)); |
| 843 } | 843 } |
| 844 #endif | 844 #endif |
| 845 | 845 |
| 846 } // namespace | 846 } // namespace |
| OLD | NEW |