Update of /cvsroot/freevo/freevo/src/tv
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv4809/src/tv
Modified Files:
channels.py ivtv.py tvguide.py v4l2.py
Log Message:
delete old tv variables, rename some and fix detection
Index: v4l2.py
===================================================================
RCS file: /cvsroot/freevo/freevo/src/tv/v4l2.py,v
retrieving revision 1.25
retrieving revision 1.26
diff -C2 -d -r1.25 -r1.26
*** v4l2.py 28 Nov 2004 16:00:40 -0000 1.25
--- v4l2.py 5 Dec 2004 13:01:12 -0000 1.26
***************
*** 10,13 ****
--- 10,16 ----
# -----------------------------------------------------------------------
# $Log$
+ # Revision 1.26 2004/12/05 13:01:12 dischi
+ # delete old tv variables, rename some and fix detection
+ #
# Revision 1.25 2004/11/28 16:00:40 dischi
# delete some bad debug
***************
*** 33,37 ****
#
# Revision 1.18 2004/08/13 16:17:33 rshortt
! # More work on tv settings, configuration of v4l2 devices based on
TV_SETTINGS.
#
# Revision 1.17 2004/08/12 16:52:49 rshortt
--- 36,40 ----
#
# Revision 1.18 2004/08/13 16:17:33 rshortt
! # More work on tv settings, configuration of v4l2 devices based on TV_CARDS.
#
# Revision 1.17 2004/08/12 16:52:49 rshortt
***************
*** 141,145 ****
else:
! self.settings = config.TV_SETTINGS.get(which)
self.init_settings()
--- 144,148 ----
else:
! self.settings = config.TV_CARDS.get(which)
self.init_settings()
Index: tvguide.py
===================================================================
RCS file: /cvsroot/freevo/freevo/src/tv/tvguide.py,v
retrieving revision 1.62
retrieving revision 1.63
diff -C2 -d -r1.62 -r1.63
*** tvguide.py 4 Dec 2004 01:46:46 -0000 1.62
--- tvguide.py 5 Dec 2004 13:01:12 -0000 1.63
***************
*** 10,15 ****
# -----------------------------------------------------------------------
# $Log$
# Revision 1.62 2004/12/04 01:46:46 rshortt
! # Use TV_ALL_CHANNELS from config.
#
# Revision 1.61 2004/11/20 18:23:04 dischi
--- 10,18 ----
# -----------------------------------------------------------------------
# $Log$
+ # Revision 1.63 2004/12/05 13:01:12 dischi
+ # delete old tv variables, rename some and fix detection
+ #
# Revision 1.62 2004/12/04 01:46:46 rshortt
! # Use TV_CHANNELLIST from config.
#
# Revision 1.61 2004/11/20 18:23:04 dischi
***************
*** 162,166 ****
box.show()
! if not config.TV_ALL_CHANNELS:
box.destroy()
gui.AlertBox(text=_('TV Guide is corrupt!')).show()
--- 165,169 ----
box.show()
! if not config.TV_CHANNELLIST:
box.destroy()
gui.AlertBox(text=_('TV Guide is corrupt!')).show()
***************
*** 170,176 ****
start_time = self.current_time - 1800
stop_time = self.current_time + 3*3600
! config.TV_ALL_CHANNELS.import_programs(start_time, stop_time)
! self.channel = config.TV_ALL_CHANNELS.get()
self.selected = self.channel.get(self.current_time)[0]
--- 173,179 ----
start_time = self.current_time - 1800
stop_time = self.current_time + 3*3600
! config.TV_CHANNELLIST.import_programs(start_time, stop_time)
! self.channel = config.TV_CHANNELLIST.get()
self.selected = self.channel.get(self.current_time)[0]
***************
*** 217,222 ****
if event == MENU_UP:
! config.TV_ALL_CHANNELS.up()
! self.channel = config.TV_ALL_CHANNELS.get()
try:
self.selected = self.channel.get(self.current_time)[0]
--- 220,225 ----
if event == MENU_UP:
! config.TV_CHANNELLIST.up()
! self.channel = config.TV_CHANNELLIST.get()
try:
self.selected = self.channel.get(self.current_time)[0]
***************
*** 227,232 ****
elif event == MENU_DOWN:
! config.TV_ALL_CHANNELS.down()
! self.channel = config.TV_ALL_CHANNELS.get()
try:
self.selected = self.channel.get(self.current_time)[0]
--- 230,235 ----
elif event == MENU_DOWN:
! config.TV_CHANNELLIST.down()
! self.channel = config.TV_CHANNELLIST.get()
try:
self.selected = self.channel.get(self.current_time)[0]
***************
*** 260,264 ****
elif event == TV_SHOW_CHANNEL:
items = []
! # channel =
config.TV_ALL_CHANNELS.get_settings_by_id(self.chan_id)
# for prog in channel.get(time.time(), -1):
for prog in self.selected.get(time.time(), -1):
--- 263,267 ----
elif event == TV_SHOW_CHANNEL:
items = []
! # channel = config.TV_CHANNELLIST.get_settings_by_id(self.chan_id)
# for prog in channel.get(time.time(), -1):
for prog in self.selected.get(time.time(), -1):
Index: channels.py
===================================================================
RCS file: /cvsroot/freevo/freevo/src/tv/channels.py,v
retrieving revision 1.35
retrieving revision 1.36
diff -C2 -d -r1.35 -r1.36
*** channels.py 4 Dec 2004 01:45:09 -0000 1.35
--- channels.py 5 Dec 2004 13:01:12 -0000 1.36
***************
*** 45,49 ****
import sysconfig
import plugin
- import item
log = logging.getLogger('tv')
--- 45,48 ----
***************
*** 86,90 ****
dev_lock = False
! settings = config.TV_SETTINGS.get(which)
if not settings:
--- 85,89 ----
dev_lock = False
! settings = config.TV_CARDS.get(which)
if not settings:
***************
*** 230,234 ****
! class ChannelItem(item.Item):
"""
Information about one specific channel, also containing
--- 229,233 ----
! class Channel:
"""
Information about one specific channel, also containing
***************
*** 236,241 ****
"""
def __init__(self, id, display_name, access_id):
- item.Item.__init__(self)
-
self.chan_id = id
self.access_id = ''
--- 235,238 ----
***************
*** 265,274 ****
self.access_id = uri
defaults = []
! if isinstance(config.TV_DEFAULT_SETTINGS, list) or \
! isinstance(config.TV_DEFAULT_SETTINGS, tuple):
! for s in config.TV_DEFAULT_SETTINGS:
defaults.append(s)
else:
! defaults.append(config.TV_DEFAULT_SETTINGS)
for which in defaults:
--- 262,271 ----
self.access_id = uri
defaults = []
! if isinstance(config.TV_DEFAULT_DEVICE, list) or \
! isinstance(config.TV_DEFAULT_DEVICE, tuple):
! for s in config.TV_DEFAULT_DEVICE:
defaults.append(s)
else:
! defaults.append(config.TV_DEFAULT_DEVICE)
for which in defaults:
***************
*** 276,294 ****
int(which[-1:])
except ValueError:
! # This means that TV_DEFAULT_SETTINGS does NOT end with
# a number (it is dvb/tv/ivtv) so we add this channel
! # to all matching TV_SETTINGS.
! log.debug('TV_DEFAULT_SETTINGS does NOT end with a
number')
!
! for s in config.TV_SETTINGS.keys():
if s.find(which) == 0:
self.__add_uri__('%s:%s' % (s, uri))
! return
! uri = '%s:%s' % (which, uri)
else:
self.access_id = uri.split(':')[1]
!
! self.uri.append(uri)
--- 273,288 ----
int(which[-1:])
except ValueError:
! # This means that TV_DEFAULT_DEVICE does NOT end with
# a number (it is dvb/tv/ivtv) so we add this channel
! # to all matching TV_CARDS.
! for s in config.TV_CARDS:
if s.find(which) == 0:
self.__add_uri__('%s:%s' % (s, uri))
! return
! self.uri.append('%s:%s' % (which, uri))
else:
self.access_id = uri.split(':')[1]
! self.uri.append(uri)
***************
*** 317,321 ****
for u in self.uri:
type = u.split(':')[0]
! settings[type] = config.TV_SETTINGS.get(type)
return settings
--- 311,315 ----
for u in self.uri:
type = u.split(':')[0]
! settings[type] = config.TV_CARDS.get(type)
return settings
***************
*** 482,512 ****
return
! # Check the EPGDB for channels. If some of these exist in TV_CHHANELS
! # we use that information if not we use the info from the database.
for c in self.epg.get_channels():
if String(c['id']) in config.TV_CHANNELS_EXCLUDE:
# Skip channels that we explicitly do not want.
continue
!
! override = False
! for cc in config.TV_CHANNELS:
! if String(c['id']) == cc[0]:
! # Override with config data.
! self.add_channel(ChannelItem(cc[0], cc[1], cc[2:]))
! override = True
! break
!
! if not override:
! self.add_channel(ChannelItem(c['id'], c['display_name'],
c['access_id']))
!
! # Check TV_CHANNELS for any channels that aren't in EPGDB then
! # at them to the list.
! for c in config.TV_CHANNELS:
! if c[0] in config.TV_CHANNELS_EXCLUDE:
! # Skip channels that we explicitly do not want.
! continue
! if not c[0] in self.channel_dict.keys():
! self.add_channel(ChannelItem(c[0], c[1], c[2:]))
!
def sort_channels(self):
--- 476,491 ----
return
! # Check TV_CHANNELS and add them to the list
! for c in config.TV_CHANNELS:
! self.add_channel(Channel(c[0], c[1], c[2:]))
!
! # Check the EPGDB for channels. All channels not in the exclude list
! # will be added if not already in the list
for c in self.epg.get_channels():
if String(c['id']) in config.TV_CHANNELS_EXCLUDE:
# Skip channels that we explicitly do not want.
continue
! if not c['id'] in self.channel_dict.keys():
! self.add_channel(Channel(c['id'], c['display_name'],
c['access_id']))
def sort_channels(self):
Index: ivtv.py
===================================================================
RCS file: /cvsroot/freevo/freevo/src/tv/ivtv.py,v
retrieving revision 1.17
retrieving revision 1.18
diff -C2 -d -r1.17 -r1.18
*** ivtv.py 15 Nov 2004 22:57:32 -0000 1.17
--- ivtv.py 5 Dec 2004 13:01:12 -0000 1.18
***************
*** 10,13 ****
--- 10,16 ----
# -----------------------------------------------------------------------
# $Log$
+ # Revision 1.18 2004/12/05 13:01:12 dischi
+ # delete old tv variables, rename some and fix detection
+ #
# Revision 1.17 2004/11/15 22:57:32 rshortt
# -use util.ioctl for what we can
***************
*** 16,23 ****
#
# Revision 1.16 2004/08/13 16:17:33 rshortt
! # More work on tv settings, configuration of v4l2 devices based on
TV_SETTINGS.
#
# Revision 1.15 2004/08/13 15:25:28 rshortt
! # Remove TV_IVTV_OPTIONS in favour of new TV_SETTINGS.
#
# Revision 1.14 2004/08/12 16:52:49 rshortt
--- 19,26 ----
#
# Revision 1.16 2004/08/13 16:17:33 rshortt
! # More work on tv settings, configuration of v4l2 devices based on TV_CARDS.
#
# Revision 1.15 2004/08/13 15:25:28 rshortt
! # Remove TV_IVTV_OPTIONS in favour of new TV_CARDS.
#
# Revision 1.14 2004/08/12 16:52:49 rshortt
-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://productguide.itmanagersjournal.com/
_______________________________________________
Freevo-cvslog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog