1 #############################################################################
2 ## Name: ext/media/XS/MediaCtrl.xsp
3 ## Purpose: XS++ for Wx::MediaCtrl
4 ## Author: Mattia Barbon
7 ## RCS-ID: $Id: MediaCtrl.xsp 2079 2007-07-08 21:18:04Z mbarbon $
8 ## Copyright: (c) 2006 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 #############################################################################
19 #include <wx/mediactrl.h>
20 #include "cpp/overload.h"
22 #define wxDefaultValidatorPtr (wxValidator*)&wxDefaultValidator
24 %typemap{wxMediaCtrl*}{simple};
25 %typemap{wxMediaCtrlPlayerControls}{simple};
26 %typemap{wxMediaState}{simple};
27 %typemap{off_t}{simple};
28 %typemap{wxSeekMode}{simple};
30 %name{Wx::MediaCtrl} class wxMediaCtrl
32 %name{newDefault} wxMediaCtrl();
33 %name{newFull} wxMediaCtrl( wxWindow* parent,
34 wxWindowID id = wxID_ANY,
35 const wxString& filename = wxEmptyString,
36 const wxPoint& pos = wxDefaultPosition,
37 const wxSize& size = wxDefaultSize,
39 const wxString& szBackend = wxEmptyString,
40 const wxValidator& validator = wxDefaultValidatorPtr,
41 const wxString& name = wxPanelNameStr );
43 bool Create( wxWindow* parent,
44 wxWindowID id = wxID_ANY,
45 const wxString& filename = wxEmptyString,
46 const wxPoint& pos = wxDefaultPosition,
47 const wxSize& size = wxDefaultSize, long style = 0,
48 const wxString& szBackend = wxEmptyString,
49 const wxValidator& validator = wxDefaultValidatorPtr,
50 const wxString& name = wxPanelNameStr );
54 off_t Seek( off_t where, wxSeekMode whence );
56 wxMediaState GetState();
63 bool SetVolume( double volume );
65 double GetPlaybackRate();
66 bool SetPlaybackRate( double volume );
68 bool ShowPlayerControls( wxMediaCtrlPlayerControls flags =
69 wxMEDIACTRLPLAYERCONTROLS_DEFAULT );
78 MATCH_VOIDM_REDISP( newDefault )
79 MATCH_ANY_REDISP( newFull )
80 END_OVERLOAD( "Wx::Button::new" )
83 wxMediaCtrl::LoadFile( file )
86 RETVAL = THIS->Load( file );
90 wxMediaCtrl::LoadURI( uri )
93 RETVAL = THIS->Load( wxURI( uri ) );