🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #13242

Re: Screen->MonitorFromPoint(...)

#13242
From: Remy Lebeau (TeamB)
Date: Tue, 21 Oct 2003 22:31
34 lines
2239 bytes
"vERUs" <-verus-@telia.com> wrote in message
news:3f95ac40@newsgroups.borland.com...

> The 'x' is there alright... the declaration is in the "multimon.h"
> header file.

Yup, the following statement:

    #define MonitorFromPoint    xMonitorFromPoint

will be a problem.  The typical solutions probably apply - #undef
MonitorFromPoint in your own code prior to including Forms.hpp (which is
where TScreen is declared), or else alter the order of header includes so
that Forms.hpp is included before multimon.h so that the declaration does
not get messed up.

> It says something about a COMPILE_MULTIMON_STUBS
> declaration but I don't know if that has anything to do with it.

No, it does not, because the offending #define is declared outside of the
COMPILE_MULTIMON_STUBS block.

> I'm starting to think it might be easier to just get the
> ProcAddress and dynamically link the function myself.

TScreen::MonitorFromPoint() already uses the multimon.h MonitorFromPoint()
function.  But it also does a little more, since it then has to translate
the returned HMONITOR to a TMonitor for the VCL's use.  If you call
Multimon::MonitorFromPoint() directly, then you'll have to do that
conversion manually.


Gambit
Technical Details
Message-ID: <3f95b31f$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <3f958eed@newsgroups.borland.com> <3f9591d3$1@newsgroups.borland.com> <3f95ac40@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10cc67,ffe68e96065011c7
X-Google-Attributes: gid10cc67,public
X-Google-ArrivalTime: 2003-10-21 15:39:24 PST
From: "Remy Lebeau \(TeamB\)" <gambit47.no.spam@no.spam.yahoo.com>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <3f958eed@newsgroups.borland.com> <3f9591d3$1@newsgroups.borland.com> <3f95ac40@newsgroups.borland.com>
Subject: Re: Screen->MonitorFromPoint(...)
Date: Tue, 21 Oct 2003 15:31:17 -0700
Lines: 36
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
NNTP-Posting-Host: 67.22.137.75
Message-ID: <3f95b31f$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1066775327 67.22.137.75 (21 Oct 2003 15:28:47 -0700)
Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail