Thread: Detecting Cursor-Icon Change

  1. #1
    Registered User
    Join Date
    Jul 2008
    Posts
    1

    Wink Detecting Cursor-Icon Change

    Hey there,

    I hate simply asking for code but this one has me stumped. Im after either an event that runs when the cursor changes icons, or an 'if' statement that can compare the current cursor to a stored cursor (in C++).

    Ive tried using (inapropriately?) the CursorChanged() event, comparing System::Windows::Forms::Cursor to a stored variable of the same type and messed around with handles and im out of ideas.

    Also, if possible, the cursor being referenced should be the cursor the entire system is using at that point in time, even in other programs (not just when interacting with my own program's forms).

    If anybody could point me in the right direction I would be so grateful.

  2. #2
    Kernel hacker
    Join Date
    Jul 2007
    Location
    Farncombe, Surrey, England
    Posts
    15,677
    What do you actually want to do? The cursor, in your application, is under your control [although dialog boxes with text-input may of course set the cursor to the I-shape cursor for example].

    If you want to know what happens to the cursor outside of your application, I'm not sure you can actually do that - unless you can hook in to GDI or the graphics driver somehow.

    --
    Mats
    Compilers can produce warnings - make the compiler programmers happy: Use them!
    Please don't PM me for help - and no, I don't do help over instant messengers.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. c++builder6 change form names problem
    By Leite33 in forum C++ Programming
    Replies: 2
    Last Post: 06-09-2008, 08:20 AM
  2. how to change static char* and not lose mem ?
    By jabka in forum C Programming
    Replies: 15
    Last Post: 09-07-2007, 05:33 PM
  3. Change Value in an array
    By beginner999 in forum C Programming
    Replies: 3
    Last Post: 01-18-2003, 07:16 AM
  4. Replies: 2
    Last Post: 11-08-2002, 03:22 AM
  5. Replies: 2
    Last Post: 09-04-2001, 02:12 PM