🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

Re: Clear win.messages buffer

#14046
From: Darren Stone
Date: Sun, 07 Sep 2003 02:51
18 lines
1571 bytes
Majo Petrik wrote:
> Is there any way to clear (something like) windows messages buffer? I'd like
> just to put some routine into the mousewheelmove event next to zoom
> procedure...

You can use PeekMessage() to read and remove pending messages in a 
window's message queue.

i.e.  Use PeekMessage() to eat the mouse wheel messages accumulated 
after a long operation:

     MSG msg;
     while (::PeekMessage(&msg, this->Handle,
                          WM_MOUSEWHEEL, WM_MOUSEWHEEL, PM_REMOVE))
       ;


-- darren
Technical Details
Message-ID: <3f5a9d4a$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-06!sn-xit-08!supernews.com!newsfeed.wirehub.nl!news.kweb.on.ca!KWeb!newsgroups.borland.com!not-for-mail
References: <3f5a63df@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10cc67,e1ab6c7003eccd3a
X-Google-Attributes: gid10cc67,public
X-Google-ArrivalTime: 2003-09-06 20:01:12 PST
Date: Sat, 06 Sep 2003 19:51:58 -0700
From: Darren Stone <dastone_spam_@engr.uvic.ca>
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.5b) Gecko/20030901 Thunderbird/0.2
X-Accept-Language: en-ca, en, en-us
MIME-Version: 1.0
Newsgroups: borland.public.cppbuilder.nativeapi
Subject: Re: Clear win.messages buffer
References: <3f5a63df@newsgroups.borland.com>
In-Reply-To: <3f5a63df@newsgroups.borland.com>
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: 24.69.46.34
Message-ID: <3f5a9d4a$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1062903114 24.69.46.34 (6 Sep 2003 19:51:54 -0700)
Lines: 20
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-06!sn-xit-08!supernews.com!newsfeed.wirehub.nl!news.kweb.on.ca!KWeb!newsgroups.borland.com!not-for-mail