| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2010 Google Inc. All rights reserved. | 2 * Copyright (C) 2010 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 1893 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1904 | 1904 |
| 1905 IntPoint hitPoint = IntPoint(30, 30); // button size is 100x100 | 1905 IntPoint hitPoint = IntPoint(30, 30); // button size is 100x100 |
| 1906 | 1906 |
| 1907 WebLocalFrameImpl* frame = webViewHelper.webView()->mainFrameImpl(); | 1907 WebLocalFrameImpl* frame = webViewHelper.webView()->mainFrameImpl(); |
| 1908 Document* document = frame->frame()->document(); | 1908 Document* document = frame->frame()->document(); |
| 1909 Element* element = document->getElementById("tap_button"); | 1909 Element* element = document->getElementById("tap_button"); |
| 1910 | 1910 |
| 1911 ASSERT_NE(nullptr, element); | 1911 ASSERT_NE(nullptr, element); |
| 1912 EXPECT_EQ(String("oldValue"), element->innerText()); | 1912 EXPECT_EQ(String("oldValue"), element->innerText()); |
| 1913 | 1913 |
| 1914 PlatformGestureEvent gestureEvent(PlatformEvent::EventType::GestureTap, | 1914 WebGestureEvent gestureEvent; |
| 1915 hitPoint, hitPoint, IntSize(0, 0), | 1915 gestureEvent.type = WebInputEvent::GestureTap; |
| 1916 TimeTicks(), PlatformEvent::NoModifiers, | 1916 gestureEvent.x = gestureEvent.globalX = hitPoint.x(); |
| 1917 PlatformGestureSourceTouchscreen); | 1917 gestureEvent.y = gestureEvent.globalY = hitPoint.y(); |
| 1918 gestureEvent.sourceDevice = WebGestureDeviceTouchscreen; |
| 1918 webViewHelper.webView() | 1919 webViewHelper.webView() |
| 1919 ->mainFrameImpl() | 1920 ->mainFrameImpl() |
| 1920 ->frame() | 1921 ->frame() |
| 1921 ->eventHandler() | 1922 ->eventHandler() |
| 1922 .handleGestureEvent(gestureEvent); | 1923 .handleGestureEvent(gestureEvent); |
| 1923 // when pressed, the button changes its own text to "updatedValue" | 1924 // when pressed, the button changes its own text to "updatedValue" |
| 1924 EXPECT_EQ(String("updatedValue"), element->innerText()); | 1925 EXPECT_EQ(String("updatedValue"), element->innerText()); |
| 1925 } | 1926 } |
| 1926 | 1927 |
| 1927 TEST_F(WebFrameTest, FrameOwnerPropertiesMargin) { | 1928 TEST_F(WebFrameTest, FrameOwnerPropertiesMargin) { |
| (...skipping 9167 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 11095 | 11096 |
| 11096 EXPECT_TRUE(mainFrameClient.childClient().didCallFrameDetached()); | 11097 EXPECT_TRUE(mainFrameClient.childClient().didCallFrameDetached()); |
| 11097 EXPECT_TRUE(mainFrameClient.childClient().didCallDidStopLoading()); | 11098 EXPECT_TRUE(mainFrameClient.childClient().didCallDidStopLoading()); |
| 11098 EXPECT_TRUE(mainFrameClient.childClient().didCallDidFinishDocumentLoad()); | 11099 EXPECT_TRUE(mainFrameClient.childClient().didCallDidFinishDocumentLoad()); |
| 11099 EXPECT_TRUE(mainFrameClient.childClient().didCallDidHandleOnloadEvents()); | 11100 EXPECT_TRUE(mainFrameClient.childClient().didCallDidHandleOnloadEvents()); |
| 11100 | 11101 |
| 11101 webViewHelper.reset(); | 11102 webViewHelper.reset(); |
| 11102 } | 11103 } |
| 11103 | 11104 |
| 11104 } // namespace blink | 11105 } // namespace blink |
| OLD | NEW |