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 1081 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1092 | 1092 |
1093 size_t location; | 1093 size_t location; |
1094 size_t length; | 1094 size_t length; |
1095 EXPECT_TRUE(toWebViewImpl(webView)->caretOrSelectionRange(&location, &length
)); | 1095 EXPECT_TRUE(toWebViewImpl(webView)->caretOrSelectionRange(&location, &length
)); |
1096 EXPECT_EQ(location, 0UL); | 1096 EXPECT_EQ(location, 0UL); |
1097 EXPECT_EQ(length, testWord.length()); | 1097 EXPECT_EQ(length, testWord.length()); |
1098 } | 1098 } |
1099 | 1099 |
1100 static void configueCompositingWebView(WebSettings* settings) | 1100 static void configueCompositingWebView(WebSettings* settings) |
1101 { | 1101 { |
1102 settings->setForceCompositingMode(true); | |
1103 settings->setAcceleratedCompositingEnabled(true); | 1102 settings->setAcceleratedCompositingEnabled(true); |
1104 settings->setAcceleratedCompositingForFixedPositionEnabled(true); | 1103 settings->setAcceleratedCompositingForFixedPositionEnabled(true); |
1105 settings->setAcceleratedCompositingForOverflowScrollEnabled(true); | 1104 settings->setAcceleratedCompositingForOverflowScrollEnabled(true); |
1106 settings->setCompositedScrollingForFramesEnabled(true); | 1105 settings->setCompositedScrollingForFramesEnabled(true); |
1107 } | 1106 } |
1108 | 1107 |
1109 TEST_F(WebViewTest, ShowPressOnTransformedLink) | 1108 TEST_F(WebViewTest, ShowPressOnTransformedLink) |
1110 { | 1109 { |
1111 OwnPtr<FrameTestHelpers::TestWebViewClient> fakeCompositingWebViewClient = a
doptPtr(new FrameTestHelpers::TestWebViewClient()); | 1110 OwnPtr<FrameTestHelpers::TestWebViewClient> fakeCompositingWebViewClient = a
doptPtr(new FrameTestHelpers::TestWebViewClient()); |
1112 FrameTestHelpers::WebViewHelper webViewHelper; | 1111 FrameTestHelpers::WebViewHelper webViewHelper; |
(...skipping 832 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1945 | 1944 |
1946 EXPECT_EQ(0, client.getUserGestureNotificationsCount()); | 1945 EXPECT_EQ(0, client.getUserGestureNotificationsCount()); |
1947 | 1946 |
1948 EXPECT_TRUE(tapElementById(webView, WebInputEvent::GestureTap, WebString::fr
omUTF8("target"))); | 1947 EXPECT_TRUE(tapElementById(webView, WebInputEvent::GestureTap, WebString::fr
omUTF8("target"))); |
1949 | 1948 |
1950 EXPECT_EQ(1, client.getUserGestureNotificationsCount()); | 1949 EXPECT_EQ(1, client.getUserGestureNotificationsCount()); |
1951 webView->setAutofillClient(0); | 1950 webView->setAutofillClient(0); |
1952 } | 1951 } |
1953 | 1952 |
1954 } // namespace | 1953 } // namespace |
OLD | NEW |