Package elisa :: Package plugins :: Package base :: Package models :: Module player_model
[hide private]
[frames] | no frames]

Source Code for Module elisa.plugins.base.models.player_model

 1  # Elisa - Home multimedia server 
 2  # Copyright (C) 2006-2008 Fluendo Embedded S.L. (www.fluendo.com). 
 3  # All rights reserved. 
 4  # 
 5  # This file is available under one of two license agreements. 
 6  # 
 7  # This file is licensed under the GPL version 3. 
 8  # See "LICENSE.GPL" in the root of this distribution including a special 
 9  # exception to use Elisa with Fluendo's plugins. 
10  # 
11  # The GPL part of Elisa is also available under a commercial licensing 
12  # agreement from Fluendo. 
13  # See "LICENSE.Elisa" in the root directory of this distribution package 
14  # for details on that license. 
15   
16   
17  __maintainer__ = 'Florian Boucault <florian@fluendo.com>' 
18  __maintainer2__ = 'Philippe Normand <philippe@fluendo.com>' 
19   
20   
21  from elisa.base_components.model import Model 
22   
23   
24 -class PlayerModel(Model):
25 """ 26 DOCME 27 28 @ivar uri: URI of the media currently played 29 @type uri: L{elisa.core.media_uri.MediaUri} 30 @ivar state: current state of the player 31 @type state: L{elisa.core.player.STATES} 32 @ivar playlist: list of media that are to be played 33 @type playlist: L{elisa.plugins.base.models.list_model.ListModel} 34 @ivar preview_mode: whether or not the player is previewing the media 35 @type preview_mode: boolean 36 @ivar volume: volume level; between 0 and 10 37 @type volume: float 38 @ivar muted: whether or not the player is muted 39 @type muted: boolean 40 @ivar position: current position in the media (in nanoseconds); 41 READ ONLY; -1 if unknown 42 @type position: int 43 @ivar duration: duration of the current media (in nanoseconds); 44 READ ONLY; -1 if unknown 45 @type duration: int 46 @ivar seek_to: position where to seek in the file (in nanoseconds) 47 @type seek_to: int 48 @ivar pause_requested: DOCME 49 @type pause_requested: boolean 50 @ivar media_type: type of the media current played amongst; can be 51 'audio' or 'video' 52 @type media_type: string 53 """ 54 55 uri = None 56 state = None 57 playlist = None 58 preview_mode = False 59 volume = 1.0 60 muted = False 61 position = -1 62 duration = -1 63 seek_to = 0 64 # FIXME: pause_requested is not understandable 65 # should the player pause() next time OK key is pressed 66 pause_requested = False 67 media_type = None
68