summaryrefslogtreecommitdiff
path: root/frontends/windows
diff options
context:
space:
mode:
authorVincent Sanders <vince@kyllikki.org>2019-08-04 11:23:35 +0100
committerVincent Sanders <vince@kyllikki.org>2019-08-04 11:25:35 +0100
commitf21c41a2e549e22e523118e8d8f2c881c0f088a7 (patch)
tree06c382262a3dca39bb545ab94660ca91c3660c9c /frontends/windows
parentb2f5c80ef82c2e76bd33f58b6454031500c98504 (diff)
downloadnetsurf-f21c41a2e549e22e523118e8d8f2c881c0f088a7.tar.gz
netsurf-f21c41a2e549e22e523118e8d8f2c881c0f088a7.tar.bz2
change browser_window_redraw to use unscaled coordinates
Diffstat (limited to 'frontends/windows')
-rw-r--r--frontends/windows/drawable.c4
-rw-r--r--frontends/windows/window.c10
-rw-r--r--frontends/windows/window.h2
3 files changed, 6 insertions, 10 deletions
diff --git a/frontends/windows/drawable.c b/frontends/windows/drawable.c
index 9383f7069..84b11ed78 100644
--- a/frontends/windows/drawable.c
+++ b/frontends/windows/drawable.c
@@ -383,8 +383,8 @@ nsws_drawable_paint(struct gui_window *gw, HWND hwnd)
*/
browser_window_redraw(gw->bw,
- -gw->scrollx / gw->scale,
- -gw->scrolly / gw->scale,
+ -gw->scrollx,
+ -gw->scrolly,
&clip,
&ctx);
}
diff --git a/frontends/windows/window.c b/frontends/windows/window.c
index b9a0dfc5e..e1254d8f2 100644
--- a/frontends/windows/window.c
+++ b/frontends/windows/window.c
@@ -882,8 +882,8 @@ win32_window_invalidate_area(struct gui_window *gw, const struct rect *rect)
if (rect != NULL) {
redrawrectp = &redrawrect;
- redrawrect.left = (long)rect->x0 - (gw->scrollx / gw->scale);
- redrawrect.top = (long)rect->y0 - (gw->scrolly / gw->scale);
+ redrawrect.left = (long)rect->x0 - gw->scrollx;
+ redrawrect.top = (long)rect->y0 - gw->scrolly;
redrawrect.right =(long)rect->x1;
redrawrect.bottom = (long)rect->y1;
@@ -1417,7 +1417,6 @@ win32_window_create(struct browser_window *bw,
gw->width = 800;
gw->height = 600;
- gw->scale = 1.0;
gw->toolbuttonsize = 24;
gw->requestscrollx = 0;
gw->requestscrolly = 0;
@@ -1609,9 +1608,8 @@ win32_window_place_caret(struct gui_window *w, int x, int y,
return;
}
- CreateCaret(w->drawingarea, (HBITMAP)NULL, 1, height * w->scale);
- SetCaretPos(x * w->scale - w->scrollx,
- y * w->scale - w->scrolly);
+ CreateCaret(w->drawingarea, (HBITMAP)NULL, 1, height );
+ SetCaretPos(x - w->scrollx, y - w->scrolly);
ShowCaret(w->drawingarea);
}
diff --git a/frontends/windows/window.h b/frontends/windows/window.h
index c887ed5d4..80f5f2774 100644
--- a/frontends/windows/window.h
+++ b/frontends/windows/window.h
@@ -62,8 +62,6 @@ struct gui_window {
HACCEL acceltable; /**< accelerators */
- float scale; /**< scale of content */
-
int scrollx; /**< current scroll location */
int scrolly; /**< current scroll location */