| 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 1369 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1380 | 1380 |
| 1381 WebDragData::Item item; | 1381 WebDragData::Item item; |
| 1382 item.storageType = WebDragData::Item::StorageTypeString; | 1382 item.storageType = WebDragData::Item::StorageTypeString; |
| 1383 item.stringType = "text/uri-list"; | 1383 item.stringType = "text/uri-list"; |
| 1384 item.stringData = WebString::fromUTF8(url); | 1384 item.stringData = WebString::fromUTF8(url); |
| 1385 dragData.addItem(item); | 1385 dragData.addItem(item); |
| 1386 | 1386 |
| 1387 const WebPoint clientPoint(0, 0); | 1387 const WebPoint clientPoint(0, 0); |
| 1388 const WebPoint screenPoint(0, 0); | 1388 const WebPoint screenPoint(0, 0); |
| 1389 webView->dragTargetDragEnter(dragData, clientPoint, screenPoint, WebDragOper
ationCopy, 0); | 1389 webView->dragTargetDragEnter(dragData, clientPoint, screenPoint, WebDragOper
ationCopy, 0); |
| 1390 webView->dragTargetDrop(clientPoint, screenPoint, 0); | 1390 webView->dragTargetDrop(dragData, clientPoint, screenPoint, 0); |
| 1391 FrameTestHelpers::pumpPendingRequestsForFrameToLoad(webView->mainFrame()); | 1391 FrameTestHelpers::pumpPendingRequestsForFrameToLoad(webView->mainFrame()); |
| 1392 } | 1392 } |
| 1393 | 1393 |
| 1394 TEST_F(WebViewTest, DragDropURL) | 1394 TEST_F(WebViewTest, DragDropURL) |
| 1395 { | 1395 { |
| 1396 URLTestHelpers::registerMockedURLFromBaseURL(WebString::fromUTF8(m_baseURL.c
_str()), "foo.html"); | 1396 URLTestHelpers::registerMockedURLFromBaseURL(WebString::fromUTF8(m_baseURL.c
_str()), "foo.html"); |
| 1397 URLTestHelpers::registerMockedURLFromBaseURL(WebString::fromUTF8(m_baseURL.c
_str()), "bar.html"); | 1397 URLTestHelpers::registerMockedURLFromBaseURL(WebString::fromUTF8(m_baseURL.c
_str()), "bar.html"); |
| 1398 | 1398 |
| 1399 const std::string fooUrl = m_baseURL + "foo.html"; | 1399 const std::string fooUrl = m_baseURL + "foo.html"; |
| 1400 const std::string barUrl = m_baseURL + "bar.html"; | 1400 const std::string barUrl = m_baseURL + "bar.html"; |
| (...skipping 1776 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3177 frame->setAutofillClient(&client); | 3177 frame->setAutofillClient(&client); |
| 3178 webView->setInitialFocus(false); | 3178 webView->setInitialFocus(false); |
| 3179 | 3179 |
| 3180 EXPECT_TRUE(webView->confirmComposition(WebString::fromUTF8(std::string("hel
lo").c_str()))); | 3180 EXPECT_TRUE(webView->confirmComposition(WebString::fromUTF8(std::string("hel
lo").c_str()))); |
| 3181 EXPECT_EQ(1, client.textChangesFromUserGesture()); | 3181 EXPECT_EQ(1, client.textChangesFromUserGesture()); |
| 3182 EXPECT_FALSE(UserGestureIndicator::processingUserGesture()); | 3182 EXPECT_FALSE(UserGestureIndicator::processingUserGesture()); |
| 3183 frame->setAutofillClient(0); | 3183 frame->setAutofillClient(0); |
| 3184 } | 3184 } |
| 3185 | 3185 |
| 3186 } // namespace blink | 3186 } // namespace blink |
| OLD | NEW |