OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "content/renderer/render_frame_impl.h" | 5 #include "content/renderer/render_frame_impl.h" |
6 | 6 |
7 #include <map> | 7 #include <map> |
8 #include <string> | 8 #include <string> |
9 #include <utility> | 9 #include <utility> |
10 #include <vector> | 10 #include <vector> |
(...skipping 5520 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5531 ? blink::WebFrameLoadType::InitialHistoryLoad | 5531 ? blink::WebFrameLoadType::InitialHistoryLoad |
5532 : blink::WebFrameLoadType::BackForward; | 5532 : blink::WebFrameLoadType::BackForward; |
5533 should_load_request = true; | 5533 should_load_request = true; |
5534 | 5534 |
5535 if (history_load_type == blink::WebHistorySameDocumentLoad) { | 5535 if (history_load_type == blink::WebHistorySameDocumentLoad) { |
5536 // If this is marked as a same document load but we haven't committed | 5536 // If this is marked as a same document load but we haven't committed |
5537 // anything, treat it as a new load. The browser shouldn't let this | 5537 // anything, treat it as a new load. The browser shouldn't let this |
5538 // happen. | 5538 // happen. |
5539 if (current_history_item_.isNull()) { | 5539 if (current_history_item_.isNull()) { |
5540 history_load_type = blink::WebHistoryDifferentDocumentLoad; | 5540 history_load_type = blink::WebHistoryDifferentDocumentLoad; |
| 5541 NOTREACHED(); |
5541 } else { | 5542 } else { |
5542 // Additionally, if the |current_history_item_|'s document | 5543 // Additionally, if the |current_history_item_|'s document |
5543 // sequence number doesn't match the one sent from the browser, it | 5544 // sequence number doesn't match the one sent from the browser, it |
5544 // is possible that this renderer has committed a different | 5545 // is possible that this renderer has committed a different |
5545 // document. In such case, don't use WebHistorySameDocumentLoad. | 5546 // document. In such case, don't use WebHistorySameDocumentLoad. |
5546 if (current_history_item_.documentSequenceNumber() != | 5547 if (current_history_item_.documentSequenceNumber() != |
5547 item_for_history_navigation.documentSequenceNumber()) { | 5548 item_for_history_navigation.documentSequenceNumber()) { |
5548 history_load_type = blink::WebHistoryDifferentDocumentLoad; | 5549 history_load_type = blink::WebHistoryDifferentDocumentLoad; |
5549 } | 5550 } |
5550 } | 5551 } |
(...skipping 800 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6351 // event target. Potentially a Pepper plugin will receive the event. | 6352 // event target. Potentially a Pepper plugin will receive the event. |
6352 // In order to tell whether a plugin gets the last mouse event and which it | 6353 // In order to tell whether a plugin gets the last mouse event and which it |
6353 // is, we set |pepper_last_mouse_event_target_| to null here. If a plugin gets | 6354 // is, we set |pepper_last_mouse_event_target_| to null here. If a plugin gets |
6354 // the event, it will notify us via DidReceiveMouseEvent() and set itself as | 6355 // the event, it will notify us via DidReceiveMouseEvent() and set itself as |
6355 // |pepper_last_mouse_event_target_|. | 6356 // |pepper_last_mouse_event_target_|. |
6356 pepper_last_mouse_event_target_ = nullptr; | 6357 pepper_last_mouse_event_target_ = nullptr; |
6357 #endif | 6358 #endif |
6358 } | 6359 } |
6359 | 6360 |
6360 } // namespace content | 6361 } // namespace content |
OLD | NEW |