| OLD | NEW | 
|---|
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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/public/common/page_state.h" | 5 #include "content/public/common/page_state.h" | 
| 6 | 6 | 
| 7 #include "base/files/file_path.h" | 7 #include "base/files/file_path.h" | 
| 8 #include "base/strings/utf_string_conversions.h" | 8 #include "base/strings/utf_string_conversions.h" | 
| 9 #include "content/common/page_state_serialization.h" | 9 #include "content/common/page_state_serialization.h" | 
| 10 | 10 | 
| (...skipping 28 matching lines...) Expand all  Loading... | 
| 39   if (state->http_body.contains_passwords) | 39   if (state->http_body.contains_passwords) | 
| 40     state->http_body = ExplodedHttpBody(); | 40     state->http_body = ExplodedHttpBody(); | 
| 41 } | 41 } | 
| 42 | 42 | 
| 43 void RecursivelyRemoveScrollOffset(ExplodedFrameState* state) { | 43 void RecursivelyRemoveScrollOffset(ExplodedFrameState* state) { | 
| 44   state->scroll_offset = gfx::Point(); | 44   state->scroll_offset = gfx::Point(); | 
| 45 } | 45 } | 
| 46 | 46 | 
| 47 void RecursivelyRemoveReferrer(ExplodedFrameState* state) { | 47 void RecursivelyRemoveReferrer(ExplodedFrameState* state) { | 
| 48   state->referrer = base::NullableString16(); | 48   state->referrer = base::NullableString16(); | 
|  | 49   state->referrer_policy = blink::WebReferrerPolicyDefault; | 
| 49   for (std::vector<ExplodedFrameState>::iterator it = state->children.begin(); | 50   for (std::vector<ExplodedFrameState>::iterator it = state->children.begin(); | 
| 50        it != state->children.end(); | 51        it != state->children.end(); | 
| 51        ++it) { | 52        ++it) { | 
| 52     RecursivelyRemoveReferrer(&*it); | 53     RecursivelyRemoveReferrer(&*it); | 
| 53   } | 54   } | 
| 54 } | 55 } | 
| 55 | 56 | 
| 56 }  // namespace | 57 }  // namespace | 
| 57 | 58 | 
| 58 // static | 59 // static | 
| (...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 160 } | 161 } | 
| 161 | 162 | 
| 162 PageState::PageState(const std::string& data) | 163 PageState::PageState(const std::string& data) | 
| 163     : data_(data) { | 164     : data_(data) { | 
| 164   // TODO(darin): Enable this DCHECK once tests have been fixed up to not pass | 165   // TODO(darin): Enable this DCHECK once tests have been fixed up to not pass | 
| 165   // bogus encoded data to CreateFromEncodedData. | 166   // bogus encoded data to CreateFromEncodedData. | 
| 166   //DCHECK(IsValid()); | 167   //DCHECK(IsValid()); | 
| 167 } | 168 } | 
| 168 | 169 | 
| 169 }  // namespace content | 170 }  // namespace content | 
| OLD | NEW | 
|---|