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

Unified Diff: content/public/common/common_param_traits.h

Issue 10818011: Allow floating point rectangles to be sent via IPC. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: using ParamTraits<float> instead of Pickle. Created 8 years, 5 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 | « no previous file | content/public/common/common_param_traits.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/public/common/common_param_traits.h
diff --git a/content/public/common/common_param_traits.h b/content/public/common/common_param_traits.h
index 8d79891a3088fb7fb3882f00a264b367826b6ead..df0ddc3a6521e3e32e82cebe9c68ba75d50535e0 100644
--- a/content/public/common/common_param_traits.h
+++ b/content/public/common/common_param_traits.h
@@ -33,6 +33,7 @@ struct Referrer;
namespace gfx {
class Point;
class Rect;
+class RectF;
class Size;
} // namespace gfx
@@ -129,6 +130,14 @@ struct CONTENT_EXPORT ParamTraits<gfx::Rect> {
};
template <>
+struct CONTENT_EXPORT ParamTraits<gfx::RectF> {
+ typedef gfx::RectF param_type;
+ static void Write(Message* m, const param_type& p);
+ static bool Read(const Message* m, PickleIterator* iter, param_type* r);
+ static void Log(const param_type& p, std::string* l);
+};
+
+template <>
struct ParamTraits<gfx::NativeWindow> {
typedef gfx::NativeWindow param_type;
static void Write(Message* m, const param_type& p) {
« no previous file with comments | « no previous file | content/public/common/common_param_traits.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698