🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

Re: BHO question

#13080
From: Martin C
Date: Sat, 25 Oct 2003 23:16
64 lines
4043 bytes
Hi Remy,

"Remy Lebeau (TeamB)" <gambit47.no.spam@no.spam.yahoo.com> wrote in message
news:3f99e7a4$1@newsgroups.borland.com...
>
> That doesn't tell me anything about the windows.  Offhand, without seeing
> the actual HTML that is triggering them, I would suspect that they are
> actually popup messagebox messages via scripting, not actual browser
windows
> loading new pages, is that correct?

All I am sure off that those popup windows are regular browser windows, not
messagebox, anyway here is the url where I was testing you can see it your
self  http://www.popup-blocker.info/testpage/test2.html   please go down to
the (Element Event Test) this test generate popup windows (regular IE
windows) once you pass by your mouse pointer over the image (on Enter and On
Leave).

Also after you check the url, I though of an Idea to overcome this problem,
please find below the code I wrote to solve the mouse over problem (I really
need your opinion on it)..

case DISPID_HTMLDOCUMENTEVENTS2_ONMOUSEMOVE: //On Mouse Move
 {
   CComPtr<IDispatch> spDisp;
   spDisp = pDispParams->rgvarg[0].pdispVal;
   if (spDisp)
   {
    CComQIPtr<IHTMLEventObj, &IID_IHTMLEventObj> spEventObj(spDisp);
    if (spEventObj)
    {
     long nMouseBtn = 0;
     HRESULT hr = spEventObj->get_button(&nMouseBtn);
     if (SUCCEEDED(hr) && nMouseBtn == 0)
     {
      *m_pbUserClickedLink = FALSE; // Kill the popup
      break;
     }
     *m_pbUserClickedLink = TRUE; // Allow the popup as it was generated
based on user command/click
    }
   }
}


Another question remy, when you check the url I submited up here, you can
see that there is a test on IE window page refresh popup, so I need to block
any popup window generated based on pressing the refresh button (or pressing
F5), so how I can detect that Refresh Button / F5 is pressed on the current
IE page...?

Looking forward for your reply

BR

> If so, then there is nothing your BHO
> can do about that, it only knows about browser-based events, not
> scripting-based events.  I do not know of anyway to hook the scripting
> engne's events from a BHO, or if it is even possible at all.
>
>
> Gambit
>
>
Technical Details
Message-ID: <3f9b0463@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: <3f84957c@newsgroups.borland.com> <3f84a0b8@newsgroups.borland.com> <3f88b9db@newsgroups.borland.com> <3f88be72$1@newsgroups.borland.com> <3f897b9a@newsgroups.borland.com> <3f89c56f$1@newsgroups.borland.com> <3f8af683@newsgroups.borland.com> <3f8af95a$3@newsgroups.borland.com> <3f8affad@newsgroups.borland.com> <3f8b009f$3@newsgroups.borland.com> <3f8ed9f0$1@newsgroups.borland.com> <3f8edeb3$1@newsgroups.borland.com> <3f93f0e3@newsgroups.borland.com> <3f941ba4$1@newsgroups.borland.com> <3f9472ab@newsgroups.borland.com> <3f94782e$1@newsgroups.borland.com> <3f9487b0@newsgroups.borland.com> <3f94933e$1@newsgroups.borland.com> <3f949421$1@newsgroups.borland.com> <3f9496e6$1@newsgroups.borland.com> <3f9565e3@newsgroups.borland.com> <3f9570dd@newsgroups.borland.com> <3f95da49@newsgroups.borland.com> <3f95e02e$1@newsgroups.borland.com> <3f967065@newsgroups.borland.com> <3f96c2d7@newsgroups.borland.com> <3f99d769@newsgroups.borland.com> <3f99e7a4$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10cc67,15b7dd6889830f4f
X-Google-Attributes: gid10cc67,public
X-Google-ArrivalTime: 2003-10-25 16:39:04 PST
From: "Martin C" <martinc@aol.com>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <3f84957c@newsgroups.borland.com> <3f84a0b8@newsgroups.borland.com> <3f88b9db@newsgroups.borland.com> <3f88be72$1@newsgroups.borland.com> <3f897b9a@newsgroups.borland.com> <3f89c56f$1@newsgroups.borland.com> <3f8af683@newsgroups.borland.com> <3f8af95a$3@newsgroups.borland.com> <3f8affad@newsgroups.borland.com> <3f8b009f$3@newsgroups.borland.com> <3f8ed9f0$1@newsgroups.borland.com> <3f8edeb3$1@newsgroups.borland.com> <3f93f0e3@newsgroups.borland.com> <3f941ba4$1@newsgroups.borland.com> <3f9472ab@newsgroups.borland.com> <3f94782e$1@newsgroups.borland.com> <3f9487b0@newsgroups.borland.com> <3f94933e$1@newsgroups.borland.com> <3f949421$1@newsgroups.borland.com> <3f9496e6$1@newsgroups.borland.com> <3f9565e3@newsgroups.borland.com> <3f9570dd@newsgroups.borland.com> <3f95da49@newsgroups.borland.com> <3f95e02e$1@newsgroups.borland.com> <3f967065@newsgroups.borland.com> <3f96c2d7@newsgroups.borland.com> <3f99d769@newsgroups.borland.com> <3f99e7a4$1@newsgroups.borland.com>
Subject: Re: BHO question
Date: Sat, 25 Oct 2003 15:16:52 -0800
Lines: 66
Organization: V Safe
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: 81.10.4.238
Message-ID: <3f9b0463@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1067123811 81.10.4.238 (25 Oct 2003 16:16:51 -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