| 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 #import "ios/web/web_state/web_state_impl.h" | 5 #import "ios/web/web_state/web_state_impl.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 50 web_state->GetNavigationManagerImpl().InitializeSession(); | 50 web_state->GetNavigationManagerImpl().InitializeSession(); |
| 51 | 51 |
| 52 // TODO(crbug.com/703565): remove std::move() once Xcode 9.0+ is required. | 52 // TODO(crbug.com/703565): remove std::move() once Xcode 9.0+ is required. |
| 53 return std::move(web_state); | 53 return std::move(web_state); |
| 54 } | 54 } |
| 55 | 55 |
| 56 /* static */ | 56 /* static */ |
| 57 std::unique_ptr<WebState> WebState::CreateWithStorageSession( | 57 std::unique_ptr<WebState> WebState::CreateWithStorageSession( |
| 58 const CreateParams& params, | 58 const CreateParams& params, |
| 59 CRWSessionStorage* session_storage) { | 59 CRWSessionStorage* session_storage) { |
| 60 DCHECK(session_storage); |
| 60 std::unique_ptr<WebStateImpl> web_state( | 61 std::unique_ptr<WebStateImpl> web_state( |
| 61 new WebStateImpl(params, session_storage)); | 62 new WebStateImpl(params, session_storage)); |
| 62 | 63 |
| 63 // TODO(crbug.com/703565): remove std::move() once Xcode 9.0+ is required. | 64 // TODO(crbug.com/703565): remove std::move() once Xcode 9.0+ is required. |
| 64 return std::move(web_state); | 65 return std::move(web_state); |
| 65 } | 66 } |
| 66 | 67 |
| 67 WebStateImpl::WebStateImpl(const CreateParams& params) | 68 WebStateImpl::WebStateImpl(const CreateParams& params) |
| 68 : WebStateImpl(params, nullptr) {} | 69 : WebStateImpl(params, nullptr) {} |
| 69 | 70 |
| (...skipping 716 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 786 const LoadCommittedDetails& load_details) { | 787 const LoadCommittedDetails& load_details) { |
| 787 for (auto& observer : observers_) | 788 for (auto& observer : observers_) |
| 788 observer.NavigationItemCommitted(load_details); | 789 observer.NavigationItemCommitted(load_details); |
| 789 } | 790 } |
| 790 | 791 |
| 791 WebState* WebStateImpl::GetWebState() { | 792 WebState* WebStateImpl::GetWebState() { |
| 792 return this; | 793 return this; |
| 793 } | 794 } |
| 794 | 795 |
| 795 } // namespace web | 796 } // namespace web |
| OLD | NEW |