summaryrefslogtreecommitdiff
path: root/chromium/components/web_cache/common
diff options
context:
space:
mode:
Diffstat (limited to 'chromium/components/web_cache/common')
-rw-r--r--chromium/components/web_cache/common/BUILD.gn16
-rw-r--r--chromium/components/web_cache/common/DEPS3
-rw-r--r--chromium/components/web_cache/common/OWNERS11
-rw-r--r--chromium/components/web_cache/common/web_cache_message_generator.cc33
-rw-r--r--chromium/components/web_cache/common/web_cache_message_generator.h7
-rw-r--r--chromium/components/web_cache/common/web_cache_messages.h23
6 files changed, 93 insertions, 0 deletions
diff --git a/chromium/components/web_cache/common/BUILD.gn b/chromium/components/web_cache/common/BUILD.gn
new file mode 100644
index 00000000000..5c7b2ef196c
--- /dev/null
+++ b/chromium/components/web_cache/common/BUILD.gn
@@ -0,0 +1,16 @@
+# Copyright 2014 The Chromium Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+static_library("common") {
+ output_name = "web_cache_common"
+ sources = [
+ "web_cache_message_generator.cc",
+ "web_cache_message_generator.h",
+ "web_cache_messages.h",
+ ]
+
+ deps = [
+ "//ipc",
+ ]
+}
diff --git a/chromium/components/web_cache/common/DEPS b/chromium/components/web_cache/common/DEPS
new file mode 100644
index 00000000000..1c40d981eb6
--- /dev/null
+++ b/chromium/components/web_cache/common/DEPS
@@ -0,0 +1,3 @@
+include_rules = [
+ "+ipc",
+]
diff --git a/chromium/components/web_cache/common/OWNERS b/chromium/components/web_cache/common/OWNERS
new file mode 100644
index 00000000000..5ecb4069fa5
--- /dev/null
+++ b/chromium/components/web_cache/common/OWNERS
@@ -0,0 +1,11 @@
+# Changes to IPC messages require a security review to avoid introducing
+# new sandbox escapes.
+per-file *_messages*.h=set noparent
+per-file *_messages*.h=dcheng@chromium.org
+per-file *_messages*.h=inferno@chromium.org
+per-file *_messages*.h=jln@chromium.org
+per-file *_messages*.h=jschuh@chromium.org
+per-file *_messages*.h=kenrb@chromium.org
+per-file *_messages*.h=nasko@chromium.org
+per-file *_messages*.h=tsepez@chromium.org
+per-file *_messages*.h=wfh@chromium.org
diff --git a/chromium/components/web_cache/common/web_cache_message_generator.cc b/chromium/components/web_cache/common/web_cache_message_generator.cc
new file mode 100644
index 00000000000..b4b2d265674
--- /dev/null
+++ b/chromium/components/web_cache/common/web_cache_message_generator.cc
@@ -0,0 +1,33 @@
+// Copyright 2014 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Get basic type definitions.
+#define IPC_MESSAGE_IMPL
+#include "components/web_cache/common/web_cache_message_generator.h"
+
+// Generate constructors.
+#include "ipc/struct_constructor_macros.h"
+#include "components/web_cache/common/web_cache_message_generator.h"
+
+// Generate destructors.
+#include "ipc/struct_destructor_macros.h"
+#include "components/web_cache/common/web_cache_message_generator.h"
+
+// Generate param traits write methods.
+#include "ipc/param_traits_write_macros.h"
+namespace IPC {
+#include "components/web_cache/common/web_cache_message_generator.h"
+} // namespace IPC
+
+// Generate param traits read methods.
+#include "ipc/param_traits_read_macros.h"
+namespace IPC {
+#include "components/web_cache/common/web_cache_message_generator.h"
+} // namespace IPC
+
+// Generate param traits log methods.
+#include "ipc/param_traits_log_macros.h"
+namespace IPC {
+#include "components/web_cache/common/web_cache_message_generator.h"
+} // namespace IPC
diff --git a/chromium/components/web_cache/common/web_cache_message_generator.h b/chromium/components/web_cache/common/web_cache_message_generator.h
new file mode 100644
index 00000000000..d88eb86447e
--- /dev/null
+++ b/chromium/components/web_cache/common/web_cache_message_generator.h
@@ -0,0 +1,7 @@
+// Copyright 2014 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Multiply-included file, no traditional include guard.
+
+#include "components/web_cache/common/web_cache_messages.h"
diff --git a/chromium/components/web_cache/common/web_cache_messages.h b/chromium/components/web_cache/common/web_cache_messages.h
new file mode 100644
index 00000000000..a521399101c
--- /dev/null
+++ b/chromium/components/web_cache/common/web_cache_messages.h
@@ -0,0 +1,23 @@
+// Copyright (c) 2014 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Multiply-included file, no traditional include guard.
+#include "ipc/ipc_message_macros.h"
+#include "ipc/ipc_message_utils.h"
+
+#define IPC_MESSAGE_START WebCacheMsgStart
+
+//-----------------------------------------------------------------------------
+// RenderView messages
+// These are messages sent from the browser to the renderer process.
+
+// Tells the renderer to set its maximum cache size to the supplied value.
+IPC_MESSAGE_CONTROL3(WebCacheMsg_SetCacheCapacities,
+ size_t /* min_dead_capacity */,
+ size_t /* max_dead_capacity */,
+ size_t /* capacity */)
+
+// Tells the renderer to clear the cache.
+IPC_MESSAGE_CONTROL1(WebCacheMsg_ClearCache,
+ bool /* on_navigation */)