summaryrefslogtreecommitdiff
path: root/atari/gui.c
diff options
context:
space:
mode:
authorVincent Sanders <vince@kyllikki.org>2014-07-06 10:45:31 +0100
committerVincent Sanders <vince@kyllikki.org>2014-07-06 10:45:31 +0100
commit0f151e37cba454fcb863b6b38e1780f2b04be903 (patch)
tree5b0f84879eb2896158c4f3c4f82c0391c8ec3380 /atari/gui.c
parentf5c62c2291add5e6e3b8fc604831283e4883a3c6 (diff)
parent18aefabd20a16dda9ed5363088f0da5ada0d4431 (diff)
downloadnetsurf-0f151e37cba454fcb863b6b38e1780f2b04be903.tar.gz
netsurf-0f151e37cba454fcb863b6b38e1780f2b04be903.tar.bz2
Merge branch 'vince/reformatpending'
Conflicts: amiga/gui.c
Diffstat (limited to 'atari/gui.c')
-rw-r--r--atari/gui.c21
1 files changed, 7 insertions, 14 deletions
diff --git a/atari/gui.c b/atari/gui.c
index 608d0d859..efa23efe4 100644
--- a/atari/gui.c
+++ b/atari/gui.c
@@ -201,7 +201,6 @@ gui_window_create(struct browser_window *bw,
option_window_x, option_window_y,
option_window_width, option_window_height
};
- gui_window_set_scale(gw, 1.0);
gui_window_set_url(gw, "");
gui_window_set_pointer(gw, BROWSER_POINTER_DEFAULT);
gui_set_input_gui_window(gw);
@@ -343,21 +342,14 @@ void gui_window_set_status(struct gui_window *w, const char *text)
window_set_stauts(w->root, (char*)text);
}
-float gui_window_get_scale(struct gui_window *gw)
+static void atari_window_reformat(struct gui_window *gw)
{
- return(gw->scale);
-}
-
-void gui_window_set_scale(struct gui_window *gw, float scale)
-{
- int width = 0, heigth = 0;
+ int width = 0, height = 0;
- LOG(("scale: %f", scale));
-
- gw->scale = MAX(scale, 0.25);
-
- gui_window_get_dimensions(gw, &width, &heigth, true);
- browser_window_reformat(gw->browser->bw, false, width, heigth);
+ if (gw != NULL) {
+ gui_window_get_dimensions(gw, &width, &height, true);
+ browser_window_reformat(gw->browser->bw, false, width, height);
+ }
}
static void gui_window_redraw_window(struct gui_window *gw)
@@ -1017,6 +1009,7 @@ static struct gui_window_table atari_window_table = {
.set_scroll = gui_window_set_scroll,
.get_dimensions = gui_window_get_dimensions,
.update_extent = gui_window_update_extent,
+ .reformat = atari_window_reformat,
.set_title = gui_window_set_title,
.set_url = gui_window_set_url,