blob: d8fcdc9eff80b0d7d736922fe3f2195808024414 [file] [log] [blame]
[email protected]691aa2f2013-05-28 22:52:041// 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
3// found in the LICENSE file.
4
5#include "content/public/renderer/history_item_serialization.h"
6
7#include "content/public/common/page_state.h"
8#include "webkit/glue/glue_serialize_deprecated.h"
9
10namespace content {
11
12PageState HistoryItemToPageState(const WebKit::WebHistoryItem& item) {
13 return PageState::CreateFromEncodedData(
14 webkit_glue::HistoryItemToString(item));
15}
16
17WebKit::WebHistoryItem PageStateToHistoryItem(const PageState& state) {
18 return webkit_glue::HistoryItemFromString(state.ToEncodedData());
19}
20
21} // namespace content