forked from enlightenment/efl
ector: implement surface size property.
This commit is contained in:
parent
0d95e53932
commit
39f7ce192c
|
@ -10,20 +10,25 @@
|
|||
typedef struct _Ector_Generic_Surface_Data Ector_Generic_Surface_Data;
|
||||
struct _Ector_Generic_Surface_Data
|
||||
{
|
||||
int w, h;
|
||||
};
|
||||
|
||||
void
|
||||
_ector_generic_surface_size_set(Eo *obj,
|
||||
_ector_generic_surface_size_set(Eo *obj EINA_UNUSED,
|
||||
Ector_Generic_Surface_Data *pd,
|
||||
int w, int h)
|
||||
{
|
||||
pd->w = w;
|
||||
pd->h = h;
|
||||
}
|
||||
|
||||
void
|
||||
_ector_generic_surface_size_get(Eo *obj,
|
||||
_ector_generic_surface_size_get(Eo *obj EINA_UNUSED,
|
||||
Ector_Generic_Surface_Data *pd,
|
||||
int *w, int *h)
|
||||
{
|
||||
if (w) *w = pd->w;
|
||||
if (h) *h = pd->h;
|
||||
}
|
||||
|
||||
#include "ector_generic_surface.eo.c"
|
||||
|
|
|
@ -2524,7 +2524,9 @@ _ector_cairo_software_surface_surface_set(Eo *obj, Ector_Cairo_Software_Surface_
|
|||
pd->height = height;
|
||||
|
||||
end:
|
||||
eo_do(obj, ector_cairo_surface_context_set(pd->ctx));
|
||||
eo_do(obj,
|
||||
ector_cairo_surface_context_set(pd->ctx),
|
||||
ector_surface_size_set(pd->width, pd->height));
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
|
@ -5073,7 +5073,9 @@ _ector_cairo_software_surface_surface_set(Eo *obj, Ector_Cairo_Software_Surface_
|
|||
end:
|
||||
evas_common_cpu_end_opt();
|
||||
|
||||
eo_do(obj, ector_cairo_surface_context_set(pd->ctx));
|
||||
eo_do(obj,
|
||||
ector_cairo_surface_context_set(pd->ctx),
|
||||
ector_surface_size_set(pd->width, pd->height));
|
||||
}
|
||||
|
||||
void
|
||||
|
|
Loading…
Reference in New Issue