]>
Commit | Line | Data |
---|---|---|
8ac8dba0 RD |
1 | # This file was created automatically by SWIG. |
2 | # Don't modify this file, modify the SWIG interface instead. | |
3 | ||
4 | """ | |
5 | Classes for a medai player control | |
6 | """ | |
7 | ||
8 | import _media | |
9 | ||
10 | import _core | |
11 | wx = _core | |
12 | __docfilter__ = wx.__DocFilter(globals()) | |
13 | MEDIASTATE_STOPPED = _media.MEDIASTATE_STOPPED | |
14 | MEDIASTATE_PAUSED = _media.MEDIASTATE_PAUSED | |
15 | MEDIASTATE_PLAYING = _media.MEDIASTATE_PLAYING | |
16 | MEDIATIMEFORMAT_TIME = _media.MEDIATIMEFORMAT_TIME | |
17 | class MediaEvent(_core.NotifyEvent): | |
18 | def __repr__(self): | |
19 | return "<%s.%s; proxy of C++ wxMediaEvent instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,) | |
20 | def __init__(self, *args, **kwargs): | |
21 | """__init__(self, wxEventType commandType=wxEVT_NULL, int id=0) -> MediaEvent""" | |
22 | newobj = _media.new_MediaEvent(*args, **kwargs) | |
23 | self.this = newobj.this | |
24 | self.thisown = 1 | |
25 | del newobj.thisown | |
26 | ||
27 | class MediaEventPtr(MediaEvent): | |
28 | def __init__(self, this): | |
29 | self.this = this | |
30 | if not hasattr(self,"thisown"): self.thisown = 0 | |
31 | self.__class__ = MediaEvent | |
32 | _media.MediaEvent_swigregister(MediaEventPtr) | |
33 | cvar = _media.cvar | |
34 | MEDIABACKEND_DIRECTSHOW = cvar.MEDIABACKEND_DIRECTSHOW | |
35 | MEDIABACKEND_MCI = cvar.MEDIABACKEND_MCI | |
36 | MEDIABACKEND_QUICKTIME = cvar.MEDIABACKEND_QUICKTIME | |
37 | ||
38 | class MediaCtrl(_core.Control): | |
39 | def __repr__(self): | |
40 | return "<%s.%s; proxy of C++ wxMediaCtrl instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,) | |
41 | def __init__(self, *args, **kwargs): | |
42 | """ | |
43 | __init__(self, Window parent, int id=-1, String fileName=EmptyString, | |
44 | Point pos=DefaultPosition, Size size=DefaultSize, | |
45 | long style=0, String szBackend=EmptyString, | |
46 | Validator validator=DefaultValidator, | |
47 | String name=MediaCtrlNameStr) -> MediaCtrl | |
48 | """ | |
49 | newobj = _media.new_MediaCtrl(*args, **kwargs) | |
50 | self.this = newobj.this | |
51 | self.thisown = 1 | |
52 | del newobj.thisown | |
53 | self._setOORInfo(self) | |
54 | ||
55 | def CreateFromURI(*args, **kwargs): | |
56 | """ | |
57 | CreateFromURI(self, Window parent, int id=-1, String location=EmptyString, | |
58 | Point pos=DefaultPosition, Size size=DefaultSize, | |
59 | long style=0, String szBackend=EmptyString, | |
60 | Validator validator=DefaultValidator, | |
61 | String name=MediaCtrlNameStr) -> bool | |
62 | """ | |
63 | return _media.MediaCtrl_CreateFromURI(*args, **kwargs) | |
64 | ||
65 | def Create(*args, **kwargs): | |
66 | """ | |
67 | Create(self, Window parent, int id=-1, String fileName=EmptyString, | |
68 | Point pos=DefaultPosition, Size size=DefaultSize, | |
69 | long style=0, String szBackend=EmptyString, | |
70 | Validator validator=DefaultValidator, | |
71 | String name=MediaCtrlNameStr) -> bool | |
72 | """ | |
73 | return _media.MediaCtrl_Create(*args, **kwargs) | |
74 | ||
75 | def Play(*args, **kwargs): | |
76 | """Play(self) -> bool""" | |
77 | return _media.MediaCtrl_Play(*args, **kwargs) | |
78 | ||
79 | def Pause(*args, **kwargs): | |
80 | """Pause(self) -> bool""" | |
81 | return _media.MediaCtrl_Pause(*args, **kwargs) | |
82 | ||
83 | def Stop(*args, **kwargs): | |
84 | """Stop(self) -> bool""" | |
85 | return _media.MediaCtrl_Stop(*args, **kwargs) | |
86 | ||
87 | def Load(*args, **kwargs): | |
88 | """Load(self, String fileName) -> bool""" | |
89 | return _media.MediaCtrl_Load(*args, **kwargs) | |
90 | ||
91 | def LoadFromURI(*args, **kwargs): | |
92 | """LoadFromURI(self, String location) -> bool""" | |
93 | return _media.MediaCtrl_LoadFromURI(*args, **kwargs) | |
94 | ||
95 | def Loop(*args, **kwargs): | |
96 | """Loop(self, bool bLoop=True)""" | |
97 | return _media.MediaCtrl_Loop(*args, **kwargs) | |
98 | ||
99 | def IsLooped(*args, **kwargs): | |
100 | """IsLooped(self) -> bool""" | |
101 | return _media.MediaCtrl_IsLooped(*args, **kwargs) | |
102 | ||
103 | def GetState(*args, **kwargs): | |
104 | """GetState(self) -> int""" | |
105 | return _media.MediaCtrl_GetState(*args, **kwargs) | |
106 | ||
107 | def GetPlaybackRate(*args, **kwargs): | |
108 | """GetPlaybackRate(self) -> double""" | |
109 | return _media.MediaCtrl_GetPlaybackRate(*args, **kwargs) | |
110 | ||
111 | def SetPlaybackRate(*args, **kwargs): | |
112 | """SetPlaybackRate(self, double dRate) -> bool""" | |
113 | return _media.MediaCtrl_SetPlaybackRate(*args, **kwargs) | |
114 | ||
115 | def SetPosition(*args, **kwargs): | |
116 | """SetPosition(self, wxLongLong where) -> bool""" | |
117 | return _media.MediaCtrl_SetPosition(*args, **kwargs) | |
118 | ||
119 | def GetPosition(*args, **kwargs): | |
120 | """ | |
121 | GetPosition(self) -> wxLongLong | |
122 | ||
123 | Get the window's position. | |
124 | """ | |
125 | return _media.MediaCtrl_GetPosition(*args, **kwargs) | |
126 | ||
127 | def GetDuration(*args, **kwargs): | |
128 | """GetDuration(self) -> wxLongLong""" | |
129 | return _media.MediaCtrl_GetDuration(*args, **kwargs) | |
130 | ||
131 | ||
132 | class MediaCtrlPtr(MediaCtrl): | |
133 | def __init__(self, this): | |
134 | self.this = this | |
135 | if not hasattr(self,"thisown"): self.thisown = 0 | |
136 | self.__class__ = MediaCtrl | |
137 | _media.MediaCtrl_swigregister(MediaCtrlPtr) | |
138 | MediaCtrlNameStr = cvar.MediaCtrlNameStr | |
139 | ||
140 | def PreMediaCtrl(*args, **kwargs): | |
141 | """PreMediaCtrl() -> MediaCtrl""" | |
142 | val = _media.new_PreMediaCtrl(*args, **kwargs) | |
143 | val.thisown = 1 | |
144 | return val | |
145 | ||
146 | def MediaCtrlFromURI(*args, **kwargs): | |
147 | """ | |
148 | MediaCtrlFromURI(Window parent, int id=-1, String location=EmptyString, | |
149 | Point pos=DefaultPosition, Size size=DefaultSize, | |
150 | long style=0, String szBackend=EmptyString, | |
151 | Validator validator=DefaultValidator, | |
152 | String name=MediaCtrlNameStr) -> MediaCtrl | |
153 | """ | |
154 | val = _media.new_MediaCtrlFromURI(*args, **kwargs) | |
155 | val.thisown = 1 | |
156 | self._setOORInfo(self) | |
157 | return val | |
158 | ||
159 | wxEVT_MEDIA_FINISHED = _media.wxEVT_MEDIA_FINISHED | |
160 | wxEVT_MEDIA_STOP = _media.wxEVT_MEDIA_STOP | |
161 | EVT_MEDIA_FINISHED = wx.PyEventBinder( wxEVT_MEDIA_FINISHED, 1) | |
162 | EVT_MEDIA_STOP = wx.PyEventBinder( wxEVT_MEDIA_STOP, 1) | |
163 | ||
164 |