Add gfx:PointF support to mate::Converter
It's needed by atom_api_screen, BuildPrototype function on Windows.
This commit is contained in:
parent
622544a902
commit
c786abf1e9
3 changed files with 36 additions and 10 deletions
|
@ -6,6 +6,7 @@
|
|||
#define ATOM_COMMON_NATIVE_MATE_CONVERTERS_GFX_CONVERTER_H_
|
||||
|
||||
#include "native_mate/converter.h"
|
||||
#include "ui/gfx/geometry/point_f.h"
|
||||
|
||||
namespace display {
|
||||
class Display;
|
||||
|
@ -27,6 +28,15 @@ struct Converter<gfx::Point> {
|
|||
gfx::Point* out);
|
||||
};
|
||||
|
||||
template <>
|
||||
struct Converter<gfx::PointF> {
|
||||
static v8::Local<v8::Value> ToV8(v8::Isolate* isolate,
|
||||
const gfx::PointF& val);
|
||||
static bool FromV8(v8::Isolate* isolate,
|
||||
v8::Local<v8::Value> val,
|
||||
gfx::PointF* out);
|
||||
};
|
||||
|
||||
template <>
|
||||
struct Converter<gfx::Size> {
|
||||
static v8::Local<v8::Value> ToV8(v8::Isolate* isolate, const gfx::Size& val);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue