Summary:
By default the E_NEW() will create our output objects with a 0.0 scale,
which doesn't make any sense and if anything will lead to crashes.
Instead use a scale factor of 1.0.
When updating output details, if the scale setting is invalid then set
it to 1.0 as a sensible value.
Note this doesn't actually enable scaling, just helps make sure we're
not injecting invalid scale parameters from the start.
Reviewers: zmike, devilhorns, cedric
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2078
output->global = wl_global_create(cdata->wl.disp, &wl_output_interface,
2, output, _e_comp_wl_cb_output_bind);
output->resources = NULL;
+ output->scale = 1.0;
}
/* update the output details */
output->subpixel = subpixel;
output->transform = transform;
+ if (output->scale <= 0)
+ output->scale = 1.0;
+
/* if we have bound resources, send updates */
EINA_LIST_FOREACH(output->resources, l2, resource)
{