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 7339 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7350 .load( | 7350 .load( |
7351 FrameLoadRequest( | 7351 FrameLoadRequest( |
7352 nullptr, FrameLoader::resourceRequestFromHistoryItem( | 7352 nullptr, FrameLoader::resourceRequestFromHistoryItem( |
7353 item.get(), WebCachePolicy::UseProtocolCachePolicy)), | 7353 item.get(), WebCachePolicy::UseProtocolCachePolicy)), |
7354 FrameLoadTypeBackForward, item.get(), HistorySameDocumentLoad); | 7354 FrameLoadTypeBackForward, item.get(), HistorySameDocumentLoad); |
7355 EXPECT_EQ(WebBackForwardCommit, client.lastCommitType()); | 7355 EXPECT_EQ(WebBackForwardCommit, client.lastCommitType()); |
7356 } | 7356 } |
7357 | 7357 |
7358 class TestHistoryWebFrameClient : public FrameTestHelpers::TestWebFrameClient { | 7358 class TestHistoryWebFrameClient : public FrameTestHelpers::TestWebFrameClient { |
7359 public: | 7359 public: |
7360 TestHistoryWebFrameClient() { | 7360 TestHistoryWebFrameClient() { m_replacesCurrentHistoryItem = false; } |
7361 m_replacesCurrentHistoryItem = false; | |
7362 } | |
7363 | 7361 |
7364 void didStartProvisionalLoad(WebDataSource* dataSource) { | 7362 void didStartProvisionalLoad(WebDataSource* dataSource) { |
7365 m_replacesCurrentHistoryItem = dataSource->replacesCurrentHistoryItem(); | 7363 m_replacesCurrentHistoryItem = dataSource->replacesCurrentHistoryItem(); |
7366 } | 7364 } |
7367 | 7365 |
7368 bool replacesCurrentHistoryItem() { return m_replacesCurrentHistoryItem; } | 7366 bool replacesCurrentHistoryItem() { return m_replacesCurrentHistoryItem; } |
7369 | 7367 |
7370 private: | 7368 private: |
7371 bool m_replacesCurrentHistoryItem; | 7369 bool m_replacesCurrentHistoryItem; |
7372 }; | 7370 }; |
(...skipping 4015 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
11388 | 11386 |
11389 EXPECT_TRUE(mainFrameClient.childClient().didCallFrameDetached()); | 11387 EXPECT_TRUE(mainFrameClient.childClient().didCallFrameDetached()); |
11390 EXPECT_TRUE(mainFrameClient.childClient().didCallDidStopLoading()); | 11388 EXPECT_TRUE(mainFrameClient.childClient().didCallDidStopLoading()); |
11391 EXPECT_TRUE(mainFrameClient.childClient().didCallDidFinishDocumentLoad()); | 11389 EXPECT_TRUE(mainFrameClient.childClient().didCallDidFinishDocumentLoad()); |
11392 EXPECT_TRUE(mainFrameClient.childClient().didCallDidHandleOnloadEvents()); | 11390 EXPECT_TRUE(mainFrameClient.childClient().didCallDidHandleOnloadEvents()); |
11393 | 11391 |
11394 webViewHelper.reset(); | 11392 webViewHelper.reset(); |
11395 } | 11393 } |
11396 | 11394 |
11397 } // namespace blink | 11395 } // namespace blink |
OLD | NEW |