Re: [AD] mouse pointer colors

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


In reply to Peter Wang <tjaden@xxxxxxxxxx>:
>`set_mouse_sprite' does not generate the default arrow bitmap.  That
>happens in the (misnamed) `_set_mouse_range' function, called by
>`set_gfx_mode'.  So the mouse code gets linked in anyway if you set
>a graphics mode.

We should change this call - either by somehow removing the dependency
on calling _set_mouse_range() (for instance, we could call this function
whenever the user calls show_mouse() ), or by using the trick with a
constructor function in mouse.c setting a function pointer in
graphics.c; the constructor is only executed if mouse.o is linked in, so
the function pointer is zero if mouse.o is not linked or non-zero if it
is. I believe the MIDI functions work this way.

>  I think we should change `set_mouse_sprite(NULL)'
>so it _does_ generate the arrow bitmap.  Like in the attached patch.

Yes, exactly.

Bye for now,
-- 
Laurence Withers, lwithers@xxxxxxxxxx
                http://www.lwithers.demon.co.uk/

Attachment: signature.asc
Description: PGP signature



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/