Replaced PTR_SEG_TO_LIN macro by exported MapSL function.
Fixed a few ptr/segptr mismatches.
Moved CONV_RECT/POINT macros to wingdi16.h.

diff --git a/memory/selector.c b/memory/selector.c
index 35ac9a9..e27e35d 100644
--- a/memory/selector.c
+++ b/memory/selector.c
@@ -9,7 +9,6 @@
 #include "config.h"
 #include "winerror.h"
 #include "wine/winbase16.h"
-#include "ldt.h"
 #include "miscemu.h"
 #include "selectors.h"
 #include "stackframe.h"
@@ -410,7 +409,7 @@
     /* check for data or readable code segment */
     if (!(entry.HighWord.Bits.Type & 0x10)) return TRUE;  /* system descriptor */
     if ((entry.HighWord.Bits.Type & 0x0a) == 0x08) return TRUE;  /* non-readable code segment */
-    if (strlen(PTR_SEG_TO_LIN(ptr)) < size) size = strlen(PTR_SEG_TO_LIN(ptr)) + 1;
+    if (strlen(MapSL(ptr)) < size) size = strlen(MapSL(ptr)) + 1;
     if (size && (OFFSETOF(ptr) + size - 1 > wine_ldt_get_limit(&entry))) return TRUE;
     return FALSE;
 }
@@ -537,7 +536,7 @@
 
 LPVOID WINAPI MapSLFix( SEGPTR sptr )
 {
-    return (LPVOID)PTR_SEG_TO_LIN(sptr);
+    return MapSL(sptr);
 }
 
 /***********************************************************************