Respond with QuotaExceededError when IndexedDB has no disk space on open.
[chromium-blink-merge.git] / content / common / clipboard_messages.cc
blobcae2f469262de399d93483bcc160f4144bbb6beb
1 // Copyright (c) 2012 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.
5 #include "content/common/clipboard_messages.h"
7 #include "ui/base/clipboard/clipboard.h"
9 namespace IPC {
11 void ParamTraits<ui::Clipboard::FormatType>::Write(
12 Message* m, const param_type& p) {
13 m->WriteString(p.Serialize());
16 bool ParamTraits<ui::Clipboard::FormatType>::Read(
17 const Message* m, PickleIterator* iter, param_type* r) {
18 std::string serialization;
19 if (!ReadParam(m, iter, &serialization))
20 return false;
21 *r = ui::Clipboard::FormatType::Deserialize(serialization);
22 return true;
25 void ParamTraits<ui::Clipboard::FormatType>::Log(
26 const param_type& p, std::string* l) {
27 *l = p.Serialize();
30 } // namespace IPC