aboutsummaryrefslogtreecommitdiffhomepage
path: root/win32/PlatWin.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'win32/PlatWin.cxx')
-rw-r--r--win32/PlatWin.cxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/win32/PlatWin.cxx b/win32/PlatWin.cxx
index 348cbb255..2c537d766 100644
--- a/win32/PlatWin.cxx
+++ b/win32/PlatWin.cxx
@@ -622,7 +622,7 @@ void SurfaceGDI::Polygon(Point *pts, size_t npts, ColourDesired fore, ColourDesi
BrushColour(back);
std::vector<POINT> outline;
for (size_t i=0; i<npts; i++) {
- POINT pt = {static_cast<LONG>(pts[i].x), static_cast<LONG>(pts[i].y)};
+ POINT pt = POINTFromPoint(pts[i]);
outline.push_back(pt);
}
::Polygon(hdc, &outline[0], static_cast<int>(npts));
@@ -2474,9 +2474,9 @@ void ListBoxX::Create(Window &parent_, int ctrlID_, Point location_, int lineHei
hinstanceParent,
this);
- POINT locationw = {static_cast<LONG>(location.x), static_cast<LONG>(location.y)};
+ POINT locationw = POINTFromPoint(location);
::MapWindowPoints(hwndParent, NULL, &locationw, 1);
- location = Point::FromInts(locationw.x, locationw.y);
+ location = PointFromPOINT(locationw);
}
void ListBoxX::SetFont(Font &font) {
@@ -2799,7 +2799,7 @@ void ListBoxX::ResizeToCursor() {
PRectangle rc = GetPosition();
POINT ptw;
::GetCursorPos(&ptw);
- const Point pt = Point::FromInts(ptw.x, ptw.y) + dragOffset;
+ const Point pt = PointFromPOINT(ptw) + dragOffset;
switch (resizeHit) {
case HTLEFT: