Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4387)

Unified Diff: chrome/common/render_messages.h

Issue 174232: Chromium side patch for DB support on Linux. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Final version, including changes to the DEPS file. Created 11 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/common/db_message_filter.cc ('k') | chrome/common/render_messages_internal.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/render_messages.h
===================================================================
--- chrome/common/render_messages.h (revision 24791)
+++ chrome/common/render_messages.h (working copy)
@@ -46,7 +46,12 @@
#include "webkit/glue/webpreferences.h"
#include "webkit/glue/webview_delegate.h"
+#if defined(OS_WIN)
+#include "base/platform_file.h"
+#endif
+
#if defined(OS_POSIX)
+#include "base/file_descriptor_posix.h"
#include "third_party/skia/include/core/SkBitmap.h"
#endif
@@ -387,6 +392,15 @@
std::vector<int> pages;
};
+struct ViewMsg_DatabaseOpenFileResponse_Params {
+#if defined(OS_WIN)
+ base::PlatformFile file_handle; // DB file handle
+#elif defined(OS_POSIX)
+ base::FileDescriptor file_handle; // DB file handle
+ base::FileDescriptor dir_handle; // DB directory handle
+#endif
+};
+
// Parameters to describe a rendered page.
struct ViewHostMsg_DidPrintPage_Params {
// A shared memory handle to the EMF data. This data can be quite large so a
@@ -1853,6 +1867,33 @@
};
template <>
+struct ParamTraits<ViewMsg_DatabaseOpenFileResponse_Params> {
+ typedef ViewMsg_DatabaseOpenFileResponse_Params param_type;
+ static void Write(Message* m, const param_type& p) {
+ WriteParam(m, p.file_handle);
+#if defined(OS_POSIX)
+ WriteParam(m, p.dir_handle);
+#endif
+ }
+ static bool Read(const Message* m, void** iter, param_type* p) {
+ return ReadParam(m, iter, &p->file_handle)
+#if defined(OS_POSIX)
+ && ReadParam(m, iter, &p->dir_handle)
+#endif
+ ;
+ }
+ static void Log(const param_type& p, std::wstring* l) {
+ l->append(L"(");
+ LogParam(p.file_handle, l);
+#if defined(OS_POSIX)
+ l->append(L", ");
+ LogParam(p.dir_handle, l);
+#endif
+ l->append(L")");
+ }
+};
+
+template <>
struct ParamTraits<appcache::Status> {
typedef appcache::Status param_type;
static void Write(Message* m, const param_type& p) {
« no previous file with comments | « chrome/common/db_message_filter.cc ('k') | chrome/common/render_messages_internal.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698