PC Review


Reply
Thread Tools Rate Thread

how to catch mouse click anywhere on the screen...

 
 
=?Utf-8?B?TGlvbmVsIFJleWVybw==?=
Guest
Posts: n/a
 
      21st May 2005
Hi,

I am using the Game API to play a video. There is too mode, fullscreen, and
...... not fullscreen.

When the video is not in fullscreen, it is surrounded by a few buttons. When
the video is switched to fullscreen, frames are displayed with the game API
over the visual controls. If the user click on the video, he can still click
buttons "behind" the video, which is not good... Also I would like that
when the user clicks anywhere on the screen, the video is switched back to
"not fullscreen" mode.

So my question is : How can I catch all the mouse click event (regardless
to the coordinates of the mouse click) ?

I would use it to prevent the user from clicking on buttons behind the
video, and to exit fullscreen mode. I need to catch all mouse click , event
those on the start menu icon... any idea ?

Thanks a lot!

Lionel Reyero
 
Reply With Quote
 
 
 
 
Alex Feinman [MVP]
Guest
Posts: n/a
 
      21st May 2005
When you go fullscreen, make sure that you either expand your window to full
screen, or create a new window size of the screen and make it topmost
(SetWindowPos(HWND_TOPMOST...))

--
Alex Feinman
---
Visit http://www.opennetcf.org
"Lionel Reyero" <(E-Mail Removed)> wrote in message
news:0845AD38-041A-4611-B4D7-(E-Mail Removed)...
> Hi,
>
> I am using the Game API to play a video. There is too mode, fullscreen,
> and
> ..... not fullscreen.
>
> When the video is not in fullscreen, it is surrounded by a few buttons.
> When
> the video is switched to fullscreen, frames are displayed with the game
> API
> over the visual controls. If the user click on the video, he can still
> click
> buttons "behind" the video, which is not good... Also I would like that
> when the user clicks anywhere on the screen, the video is switched back to
> "not fullscreen" mode.
>
> So my question is : How can I catch all the mouse click event (regardless
> to the coordinates of the mouse click) ?
>
> I would use it to prevent the user from clicking on buttons behind the
> video, and to exit fullscreen mode. I need to catch all mouse click ,
> event
> those on the start menu icon... any idea ?
>
> Thanks a lot!
>
> Lionel Reyero


 
Reply With Quote
 
=?Utf-8?B?TGlvbmVsIFJleWVybw==?=
Guest
Posts: n/a
 
      21st May 2005
Hi Alex,

I'm sorry, I don't really understand what you are proposing. I don't see how
I can do this in the compact framework.

You propose that when I switch to fullscreen I put a frame with TopMost
value (does not seem to exist in CF) and that I catch all mouse click on that
one ?

Thanks,

 
Reply With Quote
 
Peter Foot [MVP]
Guest
Posts: n/a
 
      21st May 2005
You can set a window as TopMost in .NETCF v1.0 with a little P/Invoke:-
http://www.peterfoot.net/CreateATopMostForm.aspx

Peter

--
Peter Foot
Windows Embedded MVP
http://www.inthehand.com | http://www.peterfoot.net |
http://www.opennetcf.org

"Lionel Reyero" <(E-Mail Removed)> wrote in message
news:319B7741-1CA6-46BF-9856-(E-Mail Removed)...
> Hi Alex,
>
> I'm sorry, I don't really understand what you are proposing. I don't see
> how
> I can do this in the compact framework.
>
> You propose that when I switch to fullscreen I put a frame with TopMost
> value (does not seem to exist in CF) and that I catch all mouse click on
> that
> one ?
>
> Thanks,
>



 
Reply With Quote
 
Alex Feinman [MVP]
Guest
Posts: n/a
 
      21st May 2005
Using MessageWindow might help too

--
Alex Feinman
---
Visit http://www.opennetcf.org
"Peter Foot [MVP]" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> You can set a window as TopMost in .NETCF v1.0 with a little P/Invoke:-
> http://www.peterfoot.net/CreateATopMostForm.aspx
>
> Peter
>
> --
> Peter Foot
> Windows Embedded MVP
> http://www.inthehand.com | http://www.peterfoot.net |
> http://www.opennetcf.org
>
> "Lionel Reyero" <(E-Mail Removed)> wrote in message
> news:319B7741-1CA6-46BF-9856-(E-Mail Removed)...
>> Hi Alex,
>>
>> I'm sorry, I don't really understand what you are proposing. I don't see
>> how
>> I can do this in the compact framework.
>>
>> You propose that when I switch to fullscreen I put a frame with TopMost
>> value (does not seem to exist in CF) and that I catch all mouse click on
>> that
>> one ?
>>
>> Thanks,
>>

>
>


 
Reply With Quote
 
=?Utf-8?B?TGlvbmVsIFJleWVybw==?=
Guest
Posts: n/a
 
      22nd May 2005
Thanks, I got it working with the topmost form.

"Peter Foot [MVP]" wrote:

> You can set a window as TopMost in .NETCF v1.0 with a little P/Invoke:-
> http://www.peterfoot.net/CreateATopMostForm.aspx
>
> Peter
>
> --
> Peter Foot
> Windows Embedded MVP
> http://www.inthehand.com | http://www.peterfoot.net |
> http://www.opennetcf.org
>
> "Lionel Reyero" <(E-Mail Removed)> wrote in message
> news:319B7741-1CA6-46BF-9856-(E-Mail Removed)...
> > Hi Alex,
> >
> > I'm sorry, I don't really understand what you are proposing. I don't see
> > how
> > I can do this in the compact framework.
> >
> > You propose that when I switch to fullscreen I put a frame with TopMost
> > value (does not seem to exist in CF) and that I catch all mouse click on
> > that
> > one ?
> >
> > Thanks,
> >

>
>
>

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Catch a mouse click on any app in the taskbar jay.maiurano@gmail.com Microsoft C# .NET 2 21st Aug 2006 03:11 PM
How do I catch a mouse click on the TaskBar? Udi Microsoft C# .NET 1 6th Jul 2006 06:13 PM
How do I catch a right click of the mouse in a Button Moises Durovni Microsoft VB .NET 2 2nd Oct 2005 03:02 PM
How to insert the image into the richtextbox control and catch the mouse click event of that image. Sakharam Phapale Microsoft VB .NET 1 1st Mar 2005 12:21 PM
How to insert the image into the richtextbox control and catch the mouse click event of that image. Sakharam Phapale Microsoft C# .NET 0 1st Mar 2005 10:05 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 07:01 PM.