1 #############################################################################
3 ## Purpose: XS for Wx::Cursor
4 ## Author: Mattia Barbon
7 ## RCS-ID: $Id: Cursor.xs 2635 2009-10-20 19:17:01Z mbarbon $
8 ## Copyright: (c) 2000-2004, 2006-2009 Mattia Barbon
9 ## Licence: This program is free software; you can redistribute it and/or
10 ## modify it under the same terms as Perl itself
11 #############################################################################
13 #include <wx/cursor.h>
15 MODULE=Wx PACKAGE=Wx::Cursor
21 MATCH_REDISP( wxPliOvl_n, newId )
22 MATCH_REDISP( wxPliOvl_wimg, newImage )
23 MATCH_REDISP_COUNT_ALLOWMORE( wxPliOvl_s_n_n_n, newFile, 2 )
24 END_OVERLOAD( Wx::Cursor::new )
26 #if defined( __WXMSW__ ) || defined( __WXPERL_FORCE__ )
29 newFile( CLASS, name, type, hsx = -1, hsy = -1 )
36 RETVAL = new wxCursor( name, type, hsx, hsy );
47 RETVAL = new wxCursor( id );
51 #if !defined(__WXMAC__)
54 newImage( CLASS, img )
58 RETVAL = new wxCursor( *img );
64 #if !defined( __WXGTK__ ) && !defined(__WXMAC__) \
65 && WXPERL_W_VERSION_LT( 2, 9, 0 )
68 newData( CLASS, bits, width, height, hotSpotX = -1, hotSpotY = -1, maskBits = 0 )
77 char* data = SvPV_nolen( bits );
78 char* mask = maskBits ? SvPV_nolen( maskBits ) : 0;
80 RETVAL = new wxCursor( data, width, height, hotSpotX, hotSpotY, mask );
89 wxPli_thread_sv_clone( aTHX_ CLASS, (wxPliCloneSV)wxPli_detach_object );
95 wxPli_thread_sv_unregister( aTHX_ "Wx::Cursor", THIS, ST(0) );
101 #if WXPERL_W_VERSION_GE( 2, 8, 0 )