| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011, 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2011, 2012 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 2438 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2449 mouse_event.button = WebMouseEvent::Button::kRight; | 2449 mouse_event.button = WebMouseEvent::Button::kRight; |
| 2450 mouse_event.SetPositionInWidget(1, 1); | 2450 mouse_event.SetPositionInWidget(1, 1); |
| 2451 mouse_event.click_count = 1; | 2451 mouse_event.click_count = 1; |
| 2452 web_view->HandleInputEvent(WebCoalescedInputEvent(mouse_event)); | 2452 web_view->HandleInputEvent(WebCoalescedInputEvent(mouse_event)); |
| 2453 RunPendingTasks(); | 2453 RunPendingTasks(); |
| 2454 | 2454 |
| 2455 WebLocalFrameImpl* main_frame = web_view->MainFrameImpl(); | 2455 WebLocalFrameImpl* main_frame = web_view->MainFrameImpl(); |
| 2456 EXPECT_TRUE(main_frame->GetFrame()->Selection().IsCaretBlinkingSuspended()); | 2456 EXPECT_TRUE(main_frame->GetFrame()->Selection().IsCaretBlinkingSuspended()); |
| 2457 | 2457 |
| 2458 // Caret blinking is still suspended after showing context menu. | 2458 // Caret blinking is still suspended after showing context menu. |
| 2459 web_view->ShowContextMenu(); | 2459 web_view->ShowContextMenu(kMenuSourceMouse); |
| 2460 EXPECT_TRUE(main_frame->GetFrame()->Selection().IsCaretBlinkingSuspended()); | 2460 EXPECT_TRUE(main_frame->GetFrame()->Selection().IsCaretBlinkingSuspended()); |
| 2461 | 2461 |
| 2462 // Caret blinking will be resumed only after context menu is closed. | 2462 // Caret blinking will be resumed only after context menu is closed. |
| 2463 web_view->DidCloseContextMenu(); | 2463 web_view->DidCloseContextMenu(); |
| 2464 | 2464 |
| 2465 EXPECT_FALSE(main_frame->GetFrame()->Selection().IsCaretBlinkingSuspended()); | 2465 EXPECT_FALSE(main_frame->GetFrame()->Selection().IsCaretBlinkingSuspended()); |
| 2466 } | 2466 } |
| 2467 | 2467 |
| 2468 TEST_P(WebViewTest, SelectionOnReadOnlyInput) { | 2468 TEST_P(WebViewTest, SelectionOnReadOnlyInput) { |
| 2469 RegisterMockedHttpURLLoad("selection_readonly.html"); | 2469 RegisterMockedHttpURLLoad("selection_readonly.html"); |
| (...skipping 1878 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4348 EXPECT_FALSE(frame_view->VisualViewportSuppliesScrollbars()); | 4348 EXPECT_FALSE(frame_view->VisualViewportSuppliesScrollbars()); |
| 4349 if (RuntimeEnabledFeatures::rootLayerScrollingEnabled()) { | 4349 if (RuntimeEnabledFeatures::rootLayerScrollingEnabled()) { |
| 4350 EXPECT_NE(nullptr, | 4350 EXPECT_NE(nullptr, |
| 4351 frame_view->LayoutViewportScrollableArea()->VerticalScrollbar()); | 4351 frame_view->LayoutViewportScrollableArea()->VerticalScrollbar()); |
| 4352 } else { | 4352 } else { |
| 4353 EXPECT_NE(nullptr, frame_view->VerticalScrollbar()); | 4353 EXPECT_NE(nullptr, frame_view->VerticalScrollbar()); |
| 4354 } | 4354 } |
| 4355 } | 4355 } |
| 4356 | 4356 |
| 4357 } // namespace blink | 4357 } // namespace blink |
| OLD | NEW |