ImageHandle image = _states[_state].image;
Rect self = item_to_window (Rect (0, 0, image->get_width(), image->get_height()));
- boost::optional<Rect> draw = self.intersection (area);
+ Rect draw = self.intersection (area);
if (!draw) {
return;
("window" coordinates) and render it.
*/
context->set_source (image, self.x0, self.y0);
- context->rectangle (draw->x0, draw->y0, draw->width(), draw->height());
+ context->rectangle (draw.x0, draw.y0, draw.width(), draw.height());
context->fill ();
if (!_text.empty()) {
continue;
}
- if ((s.image = find_image (prop->value())) == 0) {
+ if (!(s.image = find_image (prop->value()))) {
error << string_compose (_("image %1 not found for state"), prop->value()) << endmsg;
continue;
}