1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-01-10 01:48:00 +00:00

Remove extra braces in drawing_area_setup. (NFC)

I'm about to rearrange this function, and the patch that actually does
work will be easier to read if mass reindentation isn't combined with
it.

The braces I've just removed were necessary when we hadn't yet
committed to requiring (most of) C99 from all our build platforms. Now
they aren't.
This commit is contained in:
Simon Tatham 2019-10-20 18:47:33 +01:00
parent 444e7c70e7
commit c24313c0b3

View File

@ -758,34 +758,32 @@ static void drawing_area_setup(GtkFrontend *inst, int width, int height)
inst->drawing_area_setup_needed = false;
inst->scale = new_scale;
{
int backing_w = w * inst->font_width + 2*inst->window_border;
int backing_h = h * inst->font_height + 2*inst->window_border;
int backing_w = w * inst->font_width + 2*inst->window_border;
int backing_h = h * inst->font_height + 2*inst->window_border;
backing_w *= inst->scale;
backing_h *= inst->scale;
backing_w *= inst->scale;
backing_h *= inst->scale;
#ifndef NO_BACKING_PIXMAPS
if (inst->pixmap) {
gdk_pixmap_unref(inst->pixmap);
inst->pixmap = NULL;
}
if (inst->pixmap) {
gdk_pixmap_unref(inst->pixmap);
inst->pixmap = NULL;
}
inst->pixmap = gdk_pixmap_new(gtk_widget_get_window(inst->area),
backing_w, backing_h, -1);
inst->pixmap = gdk_pixmap_new(gtk_widget_get_window(inst->area),
backing_w, backing_h, -1);
#endif
#ifdef DRAW_TEXT_CAIRO
if (inst->surface) {
cairo_surface_destroy(inst->surface);
inst->surface = NULL;
}
inst->surface = cairo_image_surface_create(CAIRO_FORMAT_ARGB32,
backing_w, backing_h);
#endif
if (inst->surface) {
cairo_surface_destroy(inst->surface);
inst->surface = NULL;
}
inst->surface = cairo_image_surface_create(CAIRO_FORMAT_ARGB32,
backing_w, backing_h);
#endif
draw_backing_rect(inst);
if (need_size && inst->term) {