Opened 9 years ago

Closed 9 years ago

#29 closed enhancement (fixed)

Mouse pointer shape changing for Qt and SDL frontends

Reported by: Valery V. Sedletski Owned by: Valery V. Sedletski
Priority: minor Milestone: preview
Component: Frontends Keywords: mouse pointer integration shape
Cc:

Description (last modified by Valery V. Sedletski)

For mouse pointer integration, it's needed to implement changing of mouse pointer shape when crossing the VM window boundaries, between OS/2 and guest OS.

Attachments (1)

mouse-integration.diff (15.7 KB ) - added by Valery V. Sedletski 9 years ago.
Mouse integration patch

Download all attachments as: .zip

Change History (9)

comment:1 by Valery V. Sedletski, 9 years ago

Description: modified (diff)

comment:2 by Valery V. Sedletski, 9 years ago

The code is implemented (it is almost the same for Qt4 and SDL). It is working, tested successfully with WinXP guest, but did not yet committed. Also, implemented the pointer shrinking (the WinXP pointers with transparency are 48x48, but OS/2 mouse pointers should be not more than 32x32). For scaling/shrinking, linear interpolation is used (thanks to Yagiza for suggestion). For mouse pointers with alpha channel, I used alpha channel to AND mask conversion. The resulted pointers look nice. Also, animated Win7/Vista pointers are tested successfully. Animation just changes the mouse pointer many times per second. For that, a WinXP with some Win7/Vista enhancements ported, was used. The code is to be committed soon.

Last edited 9 years ago by Valery V. Sedletski (previous) (diff)

comment:3 by diver, 9 years ago

Milestone: Enhancedpreview

by Valery V. Sedletski, 9 years ago

Attachment: mouse-integration.diff added

Mouse integration patch

comment:4 by Valery V. Sedletski, 9 years ago

Here I attached a mouse integration patch. It will be committed soon.

comment:5 by dmik, 9 years ago

Ok, looks nice, but here are my comments:

  • For <os2.h>, please use generic statements:
    #define INCL_DOS
    #define INCL_PM
    #define INCL_GPI
    
    this will save us from most troubles when <os2.h> is multiply included. This is a general rule, not only for this particular source.
  • Please remove commented pieces of code (unless they are absolutely necessary to keep them — in which case please add a verbose comment on why it is necessary). As I see these are debug statements. If you really think it makes sense to leave them, please consider using LogFlow and friends. In rare cases (if some debugging needs months etc.) you may leave pure debug stuff surrounded by defines like #ifdef DEBUG_myname (search for DEBUG_andy, for instance). But this is should not normally be necessary.

When the above is fixed, you may commit this patch.

comment:6 by Valery V. Sedletski, 9 years ago

So far, the code is committed, so I close this ticket.

Last edited 9 years ago by Valery V. Sedletski (previous) (diff)

comment:7 by Valery V. Sedletski, 9 years ago

Owner: set to Valery V. Sedletski
Status: newaccepted

comment:8 by Valery V. Sedletski, 9 years ago

Resolution: fixed
Status: acceptedclosed
Note: See TracTickets for help on using tickets.