Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. Hide/Show Mouse in like in Fullscreen Video play [modified]

Hide/Show Mouse in like in Fullscreen Video play [modified]

Scheduled Pinned Locked Moved C#
question
4 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    Sukhjinder_K
    wrote on last edited by
    #1

    Hi, I'm writing a Media Player. In Fullscreen mode, as you know, the Mouse is hidden and becomes visible whenever you move it a little and hides after sometime. Now I understand that I need to use multithreading to set up a timeout to hide the mouse. My Question is which event should I handle for mouse movements. Should it be MouseMove, MouseHover or any other method? Please advice Here is how I think I will do it if the mouse moves then Show the mouse Start a Timeout When the Timeout expires, Hide the mouse and do the above whenever the mouse moves Thanks...

    modified on Wednesday, January 09, 2008 5:07:28 AM

    C 1 Reply Last reply
    0
    • S Sukhjinder_K

      Hi, I'm writing a Media Player. In Fullscreen mode, as you know, the Mouse is hidden and becomes visible whenever you move it a little and hides after sometime. Now I understand that I need to use multithreading to set up a timeout to hide the mouse. My Question is which event should I handle for mouse movements. Should it be MouseMove, MouseHover or any other method? Please advice Here is how I think I will do it if the mouse moves then Show the mouse Start a Timeout When the Timeout expires, Hide the mouse and do the above whenever the mouse moves Thanks...

      modified on Wednesday, January 09, 2008 5:07:28 AM

      C Offline
      C Offline
      Christian Graus
      wrote on last edited by
      #2

      Yeah, that sounds right.

      Christian Graus - Microsoft MVP - C++ "also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )

      S 1 Reply Last reply
      0
      • C Christian Graus

        Yeah, that sounds right.

        Christian Graus - Microsoft MVP - C++ "also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )

        S Offline
        S Offline
        Sukhjinder_K
        wrote on last edited by
        #3

        Do I need to use MouseMove or MouseHover or both?

        M 1 Reply Last reply
        0
        • S Sukhjinder_K

          Do I need to use MouseMove or MouseHover or both?

          M Offline
          M Offline
          M Aamir Malik
          wrote on last edited by
          #4

          use MouseMove event for this and run a counter in mousemove event when the counter confirms your condition show the cursor. int move = 0; private void Form1_MouseMove(object sender, MouseEventArgs e) { if (move++ >= 20) { this.Cursor = new Cursor(System.Windows.Forms.Cursors.Arrow.CopyHandle()); this.label1.Cursor = this.Cursor; move = 0; } } Hope it helps.

          modified on Wednesday, January 09, 2008 6:45:53 AM

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups