Trees | Indices | Help |
---|
|
1 # -*- Mode: Python -*- 2 # vi:si:et:sw=4:sts=4:ts=4 3 # 4 # Flumotion - a streaming media server 5 # Copyright (C) 2004,2005,2006,2007,2008 Fluendo, S.L. (www.fluendo.com). 6 # All rights reserved. 7 8 # This file may be distributed and/or modified under the terms of 9 # the GNU General Public License version 2 as published by 10 # the Free Software Foundation. 11 # This file is distributed without any warranty; without even the implied 12 # warranty of merchantability or fitness for a particular purpose. 13 # See "LICENSE.GPL" in the source distribution for more information. 14 15 # Licensees having purchased or holding a valid Flumotion Advanced 16 # Streaming Server license may use this file in accordance with th 17 # Flumotion Advanced Streaming Server Commercial License Agreement. 18 # See "LICENSE.Flumotion" in the source distribution for more information. 19 20 # Headers in this file shall remain intact. 21 22 """dialog to display debug markers""" 23 24 import gettext 25 26 import gobject 27 28 from flumotion.common.pygobject import gsignal 29 from flumotion.extern.log import log 30 from flumotion.ui.glade import GladeWindow 31 32 __version__ = "$Rev: 6581 $" 33 _ = gettext.gettext 34 3537 gladeFile = 'debug-marker.glade' 38 39 gsignal('set-marker', str, int) 4078 79 gobject.type_register(DebugMarkerDialog) 8042 debugLevels = log.getLevelNames() 43 GladeWindow.__init__(self) 44 pos = 0 45 self._debugLevelCode = {} 46 for level in debugLevels: 47 if level == 'ERROR': 48 continue 49 self.level_selection.get_model().insert(pos, [level]) 50 self._debugLevelCode[pos] = log.getLevelInt(level) 51 pos = pos+15254 if (self.marker_entry.get_text() and 55 self.level_selection.get_active()!=-1): 56 self.ok_button.set_sensitive(True) 57 else: 58 self.ok_button.set_sensitive(False)5961 level = self._debugLevelCode[self.level_selection.get_active()] 62 self.emit('set-marker', self.marker_entry.get_text(), level)63 64 # Callbacks 65 69 7274 self._updateOkButtonSensitiveness()7577 self._updateOkButtonSensitiveness()
Trees | Indices | Help |
---|
Generated by Epydoc 3.0.1 on Thu Dec 8 10:53:50 2011 | http://epydoc.sourceforge.net |