[Freevo-devel] Making ConfirmBox modal

2003-12-10 Thread Matthieu Weber
Is it possible to make the ConfirmBox (and AlertBox, and so on) modal?
Meaning that the ConfirmBox.show() function doesn't return unless the
user has chosen between OK or Cancel?

My problem is the following:
When playing some movies from FXD files (I have one directory containing
FXD files for all my DivX movies), freevo creates a VideoItem that has 2
sub-VideoItems (one movie split into 2 files, each file stored on one
CD). When pressing SELECT, the first sub-item is played (as a VideoItem
containing just one file). If there is no media present that contains
the file, a ConfirmBox appears. But the way it is coded now, if I want
to actually play the second file and not the first (because I have only
1 CD drive), it still sticks to asking me the first disc. If I tweak the
code so that it jumps to the second sub-item, the ConfirmBox appears,
and is immediately hidden by the second half of the movie playing (which
is what I want). But when I quit playing this file, I have a black
screen and a ConfirmBox which ignores my keypresses.

So it seems that the eventhandlers are messed up at some point... It
would make my life sooo much easier if it was possible to have modal
dialogs (btw, dialogs are modal on most of the GUI I know, so it's not
unreasonable to ask this). Is it possible to do so?

Matthieu
-- 
 (~._.~)Matthieu Weber - Université de Jyväskylä (~._.~)
  ( ? )email : [EMAIL PROTECTED]  ( ? ) 
 ()- -()   public key id : 452AE0AD  ()- -()
 (_)-(_)  Humor ist, wenn man trotzdem lacht (Germain Muller)  (_)-(_)


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-devel


Re: [Freevo-devel] Making ConfirmBox modal

2003-12-10 Thread Rob Shortt
Matthieu Weber wrote:
Is it possible to make the ConfirmBox (and AlertBox, and so on) modal?
Meaning that the ConfirmBox.show() function doesn't return unless the
user has chosen between OK or Cancel?
...
So it seems that the eventhandlers are messed up at some point... It
would make my life sooo much easier if it was possible to have modal
dialogs (btw, dialogs are modal on most of the GUI I know, so it's not
unreasonable to ask this). Is it possible to do so?
I think with some work it should be possible to get Freevo dialoge boxes 
to behave this way.  Perhaps we could have the show() method wait for an 
apropriate event.  In any case, the way it is now you must use a 
callback function to continue in your code.  Here is an example from 
src/directory.py, check_password_and_build() method:

   pb = PasswordInputBox(text=_('Enter Password'), 
handler=self.pass_cmp_cp)
pb.show()
else:
self.build(arg=arg, menuw=menuw)

def pass_cmp_cb(self, word=None):

We pass a handler to the PasswordInputBox, then show() it.  The 
check_password_and_build() method completes and does nothing else.  When 
the user presses ENTER (or whatever) the callback function pass_cmp_cb() 
continues on with the code.  This was the easiest way to impliment 
popups in Freevo.  I am sure with some work it could be changed but I 
don't have the time or will for that.  If anyone else feels like it go 
ahead. :)  I would rather spend time on pyui integration or similar.

-Rob (tired of building a UI toolkit from scratch)



---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-devel


Re: [Freevo-devel] Manual record displays third field of TV_CHANNELS as channel name.

2003-12-10 Thread Rob Shortt
Alex Polite wrote:
The list of channels contain the third field of the TV_CHANNELS
variable. I think that the second field would be more convenient for
most human users. 
In North America it is quite common for people to think of a channel 
name as the tuner id.  We'd say What's on channel 7 tonight? but I am 
sure European's don't go What's on channel E11?  It was just natural 
for me to use this field in the channel option box, besides I was saving 
space.

TV_CHANNELS = [ ('1', 'SVT1',  'E5'),
('2', 'TV4',   'E6'),
('3', 'SVT2',  'E7'),
('4', 'ZTV',   'E8'),
('5', 'Oppna kanalen', 'E9'),
('6', 'Discovery Mix', 'E10'),
('7', 'TV3',   'E11'),
('8', 'Kanal 5',   'SE11'),
('9', 'YLE1',  'SE12'),
('10', 'MTV',   'SE16'),
('11', 'Eurosport', 'SE17'),
('12', 'Comhem','SE19'),
('13', 'TV4+',  '57'),
]
Is this fixed in CVS?
Its not a bug its a feature!  I will change it though.  After all, the 
second field is the one intended for Freevo display.

-Rob



---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-devel


[Freevo-cvslog] freevo/src directory.py,1.74,1.75

2003-12-10 Thread rshortt
Update of /cvsroot/freevo/freevo/src
In directory sc8-pr-cvs1:/tmp/cvs-serv1691

Modified Files:
directory.py 
Log Message:
Fix a typo.


Index: directory.py
===
RCS file: /cvsroot/freevo/freevo/src/directory.py,v
retrieving revision 1.74
retrieving revision 1.75
diff -C2 -d -r1.74 -r1.75
*** directory.py8 Dec 2003 20:37:33 -   1.74
--- directory.py10 Dec 2003 13:14:24 -  1.75
***
*** 10,13 
--- 10,16 
  # ---
  # $Log$
+ # Revision 1.75  2003/12/10 13:14:24  rshortt
+ # Fix a typo.
+ #
  # Revision 1.74  2003/12/08 20:37:33  dischi
  # merged Playlist and RandomPlaylist into one class
***
*** 439,443 
  self.arg   = arg
  self.menuw = menuw
!   pb = PasswordInputBox(text=_('Enter Password'), handler=self.pass_cmp_cp)
pb.show()
else:
--- 442,446 
  self.arg   = arg
  self.menuw = menuw
!   pb = PasswordInputBox(text=_('Enter Password'), handler=self.pass_cmp_cb)
pb.show()
else:




---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-cvslog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog


Re: [Freevo-devel] Making ConfirmBox modal

2003-12-10 Thread Matthieu Weber
On Wed 10.12.2003 at 08:42:39AM -0400, Rob Shortt wrote:
 I think with some work it should be possible to get Freevo dialoge boxes 
 to behave this way.  Perhaps we could have the show() method wait for an 
 apropriate event.  In any case, the way it is now you must use a 
 callback function to continue in your code.  Here is an example from 
 src/directory.py, check_password_and_build() method:

Yes, but in my case I would need a callback also for cancel... Actually,
a 3 button dialog would be more suitable. I'll spend more time thinking
about this problem, maybe I'll find an even better solution.

 -Rob (tired of building a UI toolkit from scratch)

I know what you mean. I hate building GUIs. But of course, a command
line tool with a remote-control is not that handy :)

Matthieu
-- 
 (~._.~)Matthieu Weber - Université de Jyväskylä (~._.~)
  ( ? )email : [EMAIL PROTECTED]  ( ? ) 
 ()- -()   public key id : 452AE0AD  ()- -()
 (_)-(_)  Humor ist, wenn man trotzdem lacht (Germain Muller)  (_)-(_)


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-devel


Please integrate this patch (was: [Freevo-devel] Manual record displays third field of TV_CHANNELS as channel name.)

2003-12-10 Thread Alex Polite
On Wed, Dec 10, 2003 at 12:22:40AM +0100, Alex Polite wrote:
 I can't use xmltv for recordings cause tv_grab_sn is broken. (I know
 this has nothing to do with you guys.) So I choose manually record in
 the web interface.
 
 The list of channels contain the third field of the TV_CHANNELS
 variable. I think that the second field would be more convenient for
 most human users. 
 


Well as I understand it this is a bug rather than a feature.

Here's a patch against the latest release (1.4) to fix it.

Very small thing. Hope it get's integrated so I don't have to do it
all over again on the next release.


regards alex

-- 
Alex Polite
http://plusseven.com/whoami
*** ./usr/share/freevo/htdocs/manualrecord.rpy  2003-10-20 04:36:21.0 +0200
--- /usr/share/freevo/htdocs/manualrecord.rpy   2003-12-10 14:17:09.0 +0100
***
*** 133,139 
  guide = tv.epg_xmltv.get_guide()
  channelselect = 'select name=chan'
  for ch in guide.chan_list:
! channelselect = channelselect + 'option 
value='+ch.id+''+str(ch.tunerid)+\n
  channelselect = channelselect + /select\n
  
  #build some reusable date inputs
--- 133,139 
  guide = tv.epg_xmltv.get_guide()
  channelselect = 'select name=chan'
  for ch in guide.chan_list:
! channelselect = channelselect + 'option 
value='+ch.id+''+str(ch.displayname)+\n
  channelselect = channelselect + /select\n
  
  #build some reusable date inputs


[Freevo-wikilog] [Freevo Wiki] Update of AptGet

2003-12-10 Thread freevo-wikilog
Dear Wiki user,

You have subscribed to a wiki page or wiki category on Freevo Wiki for change 
notification.

The following page has been changed by 206.246.146.67:
http://freevo.sourceforge.net/cgi-bin/moin.cgi/AptGet

--
@@ -1,3 +1,12 @@
+style
+   body
+   {
+   padding: .5in;
+   font-family: Arial, Helvetica, sans-serif; 
+   font-size: 12px;
+   }
+/style
+
 = SUSE 9.0 =
 
 More information about apt-get for SUSE can be found at 
http://linux01.gwdg.de/apt4rpm/ . Reading that page is highly recommended.


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-wikilog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-wikilog


[Freevo-wikilog] [Freevo Wiki] Update of AptGet

2003-12-10 Thread freevo-wikilog
Dear Wiki user,

You have subscribed to a wiki page or wiki category on Freevo Wiki for change 
notification.

The following page has been changed by 206.246.146.67:
http://freevo.sourceforge.net/cgi-bin/moin.cgi/AptGet

--
@@ -1,12 +1,3 @@
-style
-   body
-   {
-   padding: .5in;
-   font-family: Arial, Helvetica, sans-serif; 
-   font-size: 12px;
-   }
-/style
-
 = SUSE 9.0 =
 
 More information about apt-get for SUSE can be found at 
http://linux01.gwdg.de/apt4rpm/ . Reading that page is highly recommended.


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-wikilog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-wikilog


[Freevo-wikilog] [Freevo Wiki] Update of FreevoRoadmap

2003-12-10 Thread freevo-wikilog
Dear Wiki user,

You have subscribed to a wiki page or wiki category on Freevo Wiki for change 
notification.

The following page has been changed by 62.252.0.5:
http://freevo.sourceforge.net/cgi-bin/moin.cgi/FreevoRoadmap

--
@@ -34,6 +34,7 @@
  * Dynamic Playlists. while playing editing of playlists. Cross Fading between 
songs ?? 
  * Freevo (kernel) boot Splash screen (from boot loader to a running freevo with no 
text-mode intermezzos!) (www.bootsplash.org ?)
  * Simpler TV Viewing/Recording setup
+ * Bootable Live CD/DVD version (eg: knoppix http://knopper.net/knoppix/ )
 
 == Work In Progress from the user wishlist ==
 


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-wikilog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-wikilog


[Freevo-cvslog] freevo/WIP/Dischi TODO,1.31,1.32

2003-12-10 Thread dischi
Update of /cvsroot/freevo/freevo/WIP/Dischi
In directory sc8-pr-cvs1:/tmp/cvs-serv7228

Modified Files:
TODO 
Log Message:


Index: TODO
===
RCS file: /cvsroot/freevo/freevo/WIP/Dischi/TODO,v
retrieving revision 1.31
retrieving revision 1.32
diff -C2 -d -r1.31 -r1.32
*** TODO29 Nov 2003 12:03:29 -  1.31
--- TODO10 Dec 2003 16:06:23 -  1.32
***
*** 17,20 
--- 17,22 
  o auto-join foo1.avi and foo2.avi (based on config)
  
+ o remove the ChildAppThread stuff and make polling to avoid
+   threading problems
  
  mid-term:




---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-cvslog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog


[Freevo-devel] Re: plugin data

2003-12-10 Thread Dirk Meyer
Robert Rozman wrote:
 Hi,

 I'm curious what are ways of sharing non-permanent data. For instance I get
 data with plugin that listens to tcp port and would like to have that data
 in idlebar plugin for instance.

 How can I do that ?

Each plugin is an object from your class. So you can save everything
in member variables. Or like the rom drive plugin, it starts a thread
to collect the data.


Dischi

-- 
Your job is being a professor and researcher: That's one hell of a
 good excuse for some of the brain-damages of minix.
-Linus Torvalds to Andrew Tanenbaum


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-devel


[Freevo-devel] Re: plugin data

2003-12-10 Thread Dirk Meyer
Aubin Paul wrote:
 On Tue, Dec 09, 2003 at 08:48:47PM +0100, Dirk Meyer wrote:
 1. Create a file for each directory to store that data. This is more
or less duplicate work since mmpython does that.

 I think this would be necessary, simply because mmpython is a seperate
 program now.

Agreed. But maybe we could store the mmpython data ourself and bypass
the mmpython cache?


 2. You the mmpython cache. This is bad, because a) a cache shouldn't
contain data that isn't stored somewhere else. Removing the cache
will destroy your meta infos.

 A generalized storage interface would be nice. For example, you would
 create a meta item for each media file.

 myfile = util.MetaStore(file)

 myfile.store('PLAYDATE',date)
 myfile.increment('PLAYCOUNT')

 As you can see, it's very simple. We store a item for the file, the
 item could be a string, int, float or boolean.  I don't think we would
 need to worry about type safety, but the increment function would want
 a number and it would be silly to have to pull out the old item, add
 one and then write it in every source file so an increment method
 would be good.

So MetaStore is a dict containing variables for a 'file' (not an
item)? The big question is: when is this informationen added to the
item? Should each item call the util.MetaStore function? Or could it
be simpler? We will only need the data through the getattr function,
maybe this function could add the meta info if not loaded?

How to store the data? One file for each file will slow things now,
one file at all may be too huge. One file for a directory like
mmpython uses may be a good idea. 

 And then, we could support multiple datastores outside of the code. So
 we could use flatfiles now, and then move to sqlite or CSV or mysql or
 whatever someone cared to write for. 

Maybe use shelve.py?

Maybe remove the links to the current player in the items and store
the whole item?



Dischi

-- 
Hello, you've reached the psychiatric hotline. If you are
obsessive/compulsive, press 1 repeatedly. If you have multiple
personalities, press 2, 3, 4, and 5. If you are simply paranoid, just
stay on the line - we know who you are.


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-devel


[Freevo-cvslog] freevo/src childapp.py,1.44,1.45

2003-12-10 Thread dischi
Update of /cvsroot/freevo/freevo/src
In directory sc8-pr-cvs1:/tmp/cvs-serv6291

Modified Files:
childapp.py 
Log Message:
Added ChildApp2 which is a ChildApp including the code in ChildThread to
avoid threads when they are not needed to prevert crashes because of bad
thread timing. ALL plugins using ChildThread should convert the code and
ChildThread should be removed after that.


Index: childapp.py
===
RCS file: /cvsroot/freevo/freevo/src/childapp.py,v
retrieving revision 1.44
retrieving revision 1.45
diff -C2 -d -r1.44 -r1.45
*** childapp.py 6 Dec 2003 17:50:52 -   1.44
--- childapp.py 10 Dec 2003 18:58:44 -  1.45
***
*** 10,13 
--- 10,19 
  # ---
  # $Log$
+ # Revision 1.45  2003/12/10 18:58:44  dischi
+ # Added ChildApp2 which is a ChildApp including the code in ChildThread to
+ # avoid threads when they are not needed to prevert crashes because of bad
+ # thread timing. ALL plugins using ChildThread should convert the code and
+ # ChildThread should be removed after that.
+ #
  # Revision 1.44  2003/12/06 17:50:52  mikeruelle
  # a small change. gonna use childapp in command.py soon. allows me to change 
filenames to ones command.py looks for
***
*** 41,70 
  # better stop() exception handling
  #
- # Revision 1.34  2003/10/20 13:46:41  outlyer
- # A small change to fix a frequent source of crashes. I don't know why,
- # but it happens on occaison, so it's better to silently skip over than
- # to crash horribly.
- #
- # Revision 1.33  2003/10/19 09:51:10  dischi
- # better debug
- #
- # Revision 1.32  2003/10/19 09:07:33  dischi
- # support for a list and no string as app to start
- #
- # Revision 1.31  2003/10/18 17:56:58  dischi
- # more childapp fixes
- #
- # Revision 1.30  2003/10/18 16:51:34  outlyer
- # Fix a crash when skipping through tracks.
- #
- # Revision 1.29  2003/10/18 10:46:37  dischi
- # use util popen3 for child control
- #
- # Revision 1.28  2003/10/14 17:57:32  dischi
- # more debug
- #
- # Revision 1.27  2003/10/11 11:21:14  dischi
- # use util killall function
- #
  # ---
  # Freevo - A Home Theater PC framework
--- 47,50 
***
*** 549,550 
--- 529,591 
  else:
  self.mode = 'idle'
+ 
+ 
+ 
+ running_children = []
+ 
+ class ChildApp2(ChildApp):
+ def __init__(self, app, debugname=None, doeslogging=0, stop_osd=2):
+ global running_children
+ running_children.append(self)
+ 
+ if stop_osd == 2:
+ stop_osd = config.OSD_STOP_WHEN_PLAYING
+ 
+ self.stop_osd = stop_osd
+ if self.stop_osd:
+ rc.post_event(Event(VIDEO_START))
+ osd.stop()
+ 
+ if hasattr(self, 'item'):
+ rc.post_event(Event(PLAY_START, arg=self.item))
+ 
+ # start the child
+ ChildApp.__init__(self, app, debugname, doeslogging)
+ 
+ 
+ def stop_event(self):
+ return PLAY_END
+ 
+ 
+ def stop(self, cmd=''):
+ try:
+ global running_children
+ running_children.remove(self)
+ except ValueError:
+ return
+ 
+ if cmd and self.isAlive():
+ _debug_('sending exit command to app')
+ self.write(cmd)
+ # wait for the app to terminate itself
+ for i in range(20):
+ if not self.isAlive():
+ break
+ time.sleep(0.1)
+ 
+ # kill the app
+ self.kill()
+ 
+ # Ok, we can use the OSD again.
+ if self.stop_osd:
+ osd.restart()
+ 
+ if self.stop_osd:   # Implies a video file
+ rc.post_event(Event(VIDEO_END))
+ 
+ 
+ def poll(self):
+ if not self.isAlive():
+ rc.post_event(self.stop_event())
+ self.stop()
+ 




---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-cvslog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog


[Freevo-cvslog] freevo/src main.py,1.98,1.99

2003-12-10 Thread dischi
Update of /cvsroot/freevo/freevo/src
In directory sc8-pr-cvs1:/tmp/cvs-serv7206

Modified Files:
main.py 
Log Message:
changes to the new Event.handler and Childapp2

Index: main.py
===
RCS file: /cvsroot/freevo/freevo/src/main.py,v
retrieving revision 1.98
retrieving revision 1.99
diff -C2 -d -r1.98 -r1.99
*** main.py 7 Dec 2003 19:40:30 -   1.98
--- main.py 10 Dec 2003 19:01:29 -  1.99
***
*** 11,14 
--- 11,17 
  # ---
  # $Log$
+ # Revision 1.99  2003/12/10 19:01:29  dischi
+ # changes to the new Event.handler and Childapp2
+ #
  # Revision 1.98  2003/12/07 19:40:30  dischi
  # convert OVERSCAN variable names
***
*** 358,361 
--- 361,366 
  _debug_('Main loop starting...',2)
  
+ from childapp import running_children
+ 
  while 1:
  
***
*** 379,390 
  p.poll_counter = 0
  p.poll()
  time.sleep(0.01)
  
- for p in poll_plugins:
- if not (rc_object.app and p.poll_menu_only):
- p.poll_counter += 1
- if p.poll_counter == p.poll_interval:
- p.poll_counter = 0
- p.poll()
  
  for p in eventlistener_plugins:
--- 384,393 
  p.poll_counter = 0
  p.poll()
+ 
+ for child in running_children:
+ child.poll()
+ 
  time.sleep(0.01)
  
  
  for p in eventlistener_plugins:
***
*** 394,397 
--- 397,403 
  event.arg()
  
+ elif event.handler:
+ event.handler(event=event)
+ 
  # Send events to either the current app or the menu handler
  elif rc_object.app:




---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-cvslog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog


[Freevo-cvslog] freevo/src event.py,1.31,1.32

2003-12-10 Thread dischi
Update of /cvsroot/freevo/freevo/src
In directory sc8-pr-cvs1:/tmp/cvs-serv7099

Modified Files:
event.py 
Log Message:
add handler for events who know the needed eventhandler

Index: event.py
===
RCS file: /cvsroot/freevo/freevo/src/event.py,v
retrieving revision 1.31
retrieving revision 1.32
diff -C2 -d -r1.31 -r1.32
*** event.py30 Nov 2003 19:41:19 -  1.31
--- event.py10 Dec 2003 19:01:04 -  1.32
***
*** 10,13 
--- 10,16 
  # ---
  # $Log$
+ # Revision 1.32  2003/12/10 19:01:04  dischi
+ # add handler for events who know the needed eventhandler
+ #
  # Revision 1.31  2003/11/30 19:41:19  dischi
  # add event to toggle interlacing, it is on no key and only works with xine
***
*** 86,98 
  activate some action.
  
! def __init__(self, name, arg=None, context=None):
  if isinstance(name, Event):
  self.name= name.name
  self.arg = name.arg
  self.context = name.context
  else:
  self.name= name
  self.arg = None
  self.context = None
  
  if arg or arg == 0:
--- 89,103 
  activate some action.
  
! def __init__(self, name, arg=None, context=None, handler=None):
  if isinstance(name, Event):
  self.name= name.name
  self.arg = name.arg
  self.context = name.context
+ self.handler = name.handler
  else:
  self.name= name
  self.arg = None
  self.context = None
+ self.handler = None
  
  if arg or arg == 0:
***
*** 101,104 
--- 106,112 
  if context:
  self.context = context
+ 
+ if handler:
+ self.handler = handler
  
  




---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-cvslog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog


[Freevo-devel] Shutting down a plugin.DaemonPlugin

2003-12-10 Thread Viggo Fredriksen
Hi!

I'm working on implementing an audio detach bar (with modified a detach.py).
From detach.py I call plugin.activate() for my DaemonPlugin. This
works as expected.  I also have a draw() function in this plugin, and I need
to have a reasonably high poll_interval for the time elapsed/remaining/etc
for the plugin to be usable. When playing is over, the poll of this plugin is
therefore unnecessary.

So, the problem is getting this plugin removed from the list of plugins
where the initial draw() is called. I've tried plugin.shutdown, but all this
seems to do is to call the shutdown for my own plugin.

I have tried to find answers in the code, but so far I've been unsuccessfull. 

Any thoughts? :)

Regards

Viggo Fredriksen


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-devel


[Freevo-cvslog] freevo/src/audio/plugins detach.py,1.9,1.10

2003-12-10 Thread dischi
Update of /cvsroot/freevo/freevo/src/audio/plugins
In directory sc8-pr-cvs1:/tmp/cvs-serv8156

Modified Files:
detach.py 
Log Message:
no need for the eventhandler anymore

Index: detach.py
===
RCS file: /cvsroot/freevo/freevo/src/audio/plugins/detach.py,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** detach.py   9 Dec 2003 20:32:29 -   1.9
--- detach.py   10 Dec 2003 19:07:42 -  1.10
***
*** 10,13 
--- 10,16 
  # ---
  # $Log$
+ # Revision 1.10  2003/12/10 19:07:42  dischi
+ # no need for the eventhandler anymore
+ #
  # Revision 1.9  2003/12/09 20:32:29  dischi
  # fix plugin to match the new player structure
***
*** 19,29 
  # check self.player before using it
  #
- # Revision 1.6  2003/09/13 10:08:22  dischi
- # i18n support
- #
- # Revision 1.5  2003/08/23 12:51:42  dischi
- # removed some old CVS log messages
- #
- #
  # ---
  # Freevo - A Home Theater PC framework
--- 22,25 
***
*** 103,112 
  menuw.hide()
  gui.show()
- 
- 
- def eventhandler(self, event, menuw=None):
- gui = audio.player.get()
- if gui and gui.player.is_playing() and event == AUDIO_PLAY_END:
- self.player.eventhandler(event=event)
- return True
- return False
--- 99,100 




---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-cvslog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog


[Freevo-devel] Steaming fresh cvs bug :-)

2003-12-10 Thread Peter Svensson
I was going to gointo a directory containingmp3's. No such luck :-)=

Spoiler;

AttributeError: Playlist instance has no attribute 'filename'


---
Freevo start at Wed Dec 10 19:23:26 2003

---
config.py (562): Logging to /var/log/freevo/main-0.log
OVERLAY_DIR not set, virtual filesystem won't work
WARNING: PyLirc not found, lirc remote control disabled!
__init__.py (196): Building the xml hash database...
__init__.py (223): done
mixer.py (169): Volume = 40
mixer.py (169): Volume = 90
mixer.py (169): Volume = 0
mixer.py (169): Volume = 0
tvtime.py (134): major is: 0
tvtime.py (135): minor is: 9
tvtime.py (136): version is: 10
Traceback (most recent call last):
  File /usr/local/lib/python2.3/site-packages/freevo/main.py, line 409, in
main_func
app.eventhandler(event)
  File /usr/local/lib/python2.3/site-packages/freevo/menu.py, line 542, in
eventhandler
action( arg=arg, menuw=self )
  File /usr/local/lib/python2.3/site-packages/freevo/directory.py, line
407, in cwd
self.check_password_and_build(arg=None, menuw=menuw)
  File /usr/local/lib/python2.3/site-packages/freevo/directory.py, line
444, in check_password_and_build
self.build(arg=arg, menuw=menuw)
  File /usr/local/lib/python2.3/site-packages/freevo/directory.py, line
586, in build
for i in p.get(self, files):
  File /usr/local/lib/python2.3/site-packages/freevo/playlist.py, line
510, in get
items.append(Playlist(playlist=filename, parent=parent, build=True))
  File /usr/local/lib/python2.3/site-packages/freevo/playlist.py, line
114, in __init__
self.build()
  File /usr/local/lib/python2.3/site-packages/freevo/playlist.py, line
245, in build
f=open(self.filename, r)
AttributeError: Playlist instance has no attribute 'filename'
AlertBox.py (169): AlertBox: EVENT = INPUT_ENTER for gui.AlertBox.AlertBox
instance at 0x42871fac
AlertBox.py (172): HIT OK
Traceback (most recent call last):
  File /usr/local/lib/python2.3/site-packages/freevo/main.py, line 409, in
main_func
app.eventhandler(event)
  File /usr/local/lib/python2.3/site-packages/freevo/menu.py, line 542, in
eventhandler
action( arg=arg, menuw=self )
  File /usr/local/lib/python2.3/site-packages/freevo/directory.py, line
407, in cwd
self.check_password_and_build(arg=None, menuw=menuw)
  File /usr/local/lib/python2.3/site-packages/freevo/directory.py, line
444, in check_password_and_build
self.build(arg=arg, menuw=menuw)
  File /usr/local/lib/python2.3/site-packages/freevo/directory.py, line
586, in build
for i in p.get(self, files):
  File /usr/local/lib/python2.3/site-packages/freevo/playlist.py, line
510, in get
items.append(Playlist(playlist=filename, parent=parent, build=True))
  File /usr/local/lib/python2.3/site-packages/freevo/playlist.py, line
114, in __init__
self.build()
  File /usr/local/lib/python2.3/site-packages/freevo/playlist.py, line
245, in build
f=open(self.filename, r)
AttributeError: Playlist instance has no attribute 'filename'


/PS


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-devel


[Freevo-cvslog] freevo/src/audio/plugins mplayer.py,1.28,1.29 radioplayer.py,1.4,1.5

2003-12-10 Thread dischi
Update of /cvsroot/freevo/freevo/src/audio/plugins
In directory sc8-pr-cvs1:/tmp/cvs-serv8649/src/audio/plugins

Modified Files:
mplayer.py radioplayer.py 
Log Message:
AUDIO_PLAY_END is not needed anymore

Index: mplayer.py
===
RCS file: /cvsroot/freevo/freevo/src/audio/plugins/mplayer.py,v
retrieving revision 1.28
retrieving revision 1.29
diff -C2 -d -r1.28 -r1.29
*** mplayer.py  10 Dec 2003 19:02:38 -  1.28
--- mplayer.py  10 Dec 2003 19:10:35 -  1.29
***
*** 10,13 
--- 10,16 
  # ---
  # $Log$
+ # Revision 1.29  2003/12/10 19:10:35  dischi
+ # AUDIO_PLAY_END is not needed anymore
+ #
  # Revision 1.28  2003/12/10 19:02:38  dischi
  # move to new ChildApp2 and remove the internal thread
***
*** 210,219 
  
  
! if event == AUDIO_PLAY_END:
! if event.arg:
! self.stop()
! if self.playerGUI.try_next_player():
! return True
! event = PLAY_END
  
  if event == AUDIO_SEND_MPLAYER_CMD:
--- 213,220 
  
  
! if event == PLAY_END and event.arg:
! self.stop()
! if self.playerGUI.try_next_player():
! return True
  
  if event == AUDIO_SEND_MPLAYER_CMD:

Index: radioplayer.py
===
RCS file: /cvsroot/freevo/freevo/src/audio/plugins/radioplayer.py,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** radioplayer.py  22 Sep 2003 20:36:18 -  1.4
--- radioplayer.py  10 Dec 2003 19:10:35 -  1.5
***
*** 10,13 
--- 10,16 
  # ---
  # $Log$
+ # Revision 1.5  2003/12/10 19:10:35  dischi
+ # AUDIO_PLAY_END is not needed anymore
+ #
  # Revision 1.4  2003/09/22 20:36:18  mikeruelle
  # more web interface help descriptions
***
*** 118,125 
  
  print 'Radio Player event handler %s' % event
- 
- if event == AUDIO_PLAY_END or event == MENU_BACK_ONE_MENU:
- event = PLAY_END
- 
  if event in ( STOP, PLAY_END, USER_END ):
  self.playerGUI.stop()
--- 121,124 




---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-cvslog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog


[Freevo-cvslog] freevo/src event.py,1.32,1.33

2003-12-10 Thread dischi
Update of /cvsroot/freevo/freevo/src
In directory sc8-pr-cvs1:/tmp/cvs-serv8649/src

Modified Files:
event.py 
Log Message:
AUDIO_PLAY_END is not needed anymore

Index: event.py
===
RCS file: /cvsroot/freevo/freevo/src/event.py,v
retrieving revision 1.32
retrieving revision 1.33
diff -C2 -d -r1.32 -r1.33
*** event.py10 Dec 2003 19:01:04 -  1.32
--- event.py10 Dec 2003 19:10:35 -  1.33
***
*** 10,13 
--- 10,16 
  # ---
  # $Log$
+ # Revision 1.33  2003/12/10 19:10:35  dischi
+ # AUDIO_PLAY_END is not needed anymore
+ #
  # Revision 1.32  2003/12/10 19:01:04  dischi
  # add handler for events who know the needed eventhandler
***
*** 547,551 
  USER_END = Event('USER_END')
  DVD_PROTECTED= Event('DVD_PROTECTED')
- AUDIO_PLAY_END   = Event('AUDIO_PLAY_END')
  PLAY_START   = Event('PLAY_START')
  
--- 550,553 




---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-cvslog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog


[Freevo-cvslog] freevo/src/util popen3.py,1.7,1.8

2003-12-10 Thread dischi
Update of /cvsroot/freevo/freevo/src/util
In directory sc8-pr-cvs1:/tmp/cvs-serv14801

Modified Files:
popen3.py 
Log Message:
add function to get the stdout of a command call

Index: popen3.py
===
RCS file: /cvsroot/freevo/freevo/src/util/popen3.py,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -d -r1.7 -r1.8
*** popen3.py   19 Oct 2003 14:19:44 -  1.7
--- popen3.py   10 Dec 2003 19:46:35 -  1.8
***
*** 11,14 
--- 11,17 
  # ---
  # $Log$
+ # Revision 1.8  2003/12/10 19:46:35  dischi
+ # add function to get the stdout of a command call
+ #
  # Revision 1.7  2003/10/19 14:19:44  rshortt
  # Added OS_EVENT_WAITPID event for popen3.waitpid() to post so that recordserver
***
*** 166,167 
--- 169,184 
  return 0
  
+ 
+ def stdout(app):
+ 
+ start app and return the stdout
+ 
+ ret = []
+ child = popen2.Popen3(app, 1, 100)
+ while(1):
+ data = child.fromchild.readline()
+ if not data:
+ break
+ ret.append(data)
+ child.wait()
+ return ret




---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-cvslog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog


[Freevo-cvslog] freevo/src/util misc.py,1.6,1.7

2003-12-10 Thread dischi
Update of /cvsroot/freevo/freevo/src/util
In directory sc8-pr-cvs1:/tmp/cvs-serv14932

Modified Files:
misc.py 
Log Message:
remove unneeded imports

Index: misc.py
===
RCS file: /cvsroot/freevo/freevo/src/util/misc.py,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -d -r1.6 -r1.7
*** misc.py 23 Nov 2003 16:57:36 -  1.6
--- misc.py 10 Dec 2003 19:47:12 -  1.7
***
*** 11,14 
--- 11,17 
  # ---
  # $Log$
+ # Revision 1.7  2003/12/10 19:47:12  dischi
+ # remove unneeded imports
+ #
  # Revision 1.6  2003/11/23 16:57:36  dischi
  # move xml help stuff to new fxdparser
***
*** 46,53 
  import os, sys
  import string, re
- import Image # PIL
  import copy
  import htmlentitydefs
! from xml.utils import qp_xml
  
  # Configuration file. Determines where to look for AVI/MP3 files, etc
--- 49,55 
  import os, sys
  import string, re
  import copy
  import htmlentitydefs
! 
  
  # Configuration file. Determines where to look for AVI/MP3 files, etc




---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-cvslog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog


[Freevo-cvslog] freevo/src/video/plugins mplayer.py,1.49,1.50 xine.py,1.31,1.32

2003-12-10 Thread dischi
Update of /cvsroot/freevo/freevo/src/video/plugins
In directory sc8-pr-cvs1:/tmp/cvs-serv15040/video/plugins

Modified Files:
mplayer.py xine.py 
Log Message:
make it possible to bypass version checking

Index: mplayer.py
===
RCS file: /cvsroot/freevo/freevo/src/video/plugins/mplayer.py,v
retrieving revision 1.49
retrieving revision 1.50
diff -C2 -d -r1.49 -r1.50
*** mplayer.py  10 Dec 2003 19:06:06 -  1.49
--- mplayer.py  10 Dec 2003 19:47:49 -  1.50
***
*** 10,13 
--- 10,16 
  # ---
  # $Log$
+ # Revision 1.50  2003/12/10 19:47:49  dischi
+ # make it possible to bypass version checking
+ #
  # Revision 1.49  2003/12/10 19:06:06  dischi
  # move to new ChildApp2 and remove the internal thread
***
*** 98,120 
  plugin.Plugin.__init__(self)
  
! child = popen2.Popen3( %s -v % config.MPLAYER_CMD, 1, 100)
! data = child.fromchild.readline() # Just need the first line
! if data:
! data = re.search( ^MPlayer (?Pversion\S+), data )
! if data:
! _debug_(MPlayer version is: %s % data.group( version ))
! data = data.group( version )
! if data[ 0 ] == 1:
! mplayer_version = 1.0
! elif data[ 0 ] == 0:
! mplayer_version = 0.9
! elif data[ 0 : 7 ] == dev-CVS:
! mplayer_version = 
! _debug_(MPlayer version set to: %s % mplayer_version)
! 
! child.wait()
  
  # register mplayer as the object to play video
! plugin.register(MPlayer(mplayer_version), plugin.VIDEO_PLAYER, True)
  
  
--- 101,123 
  plugin.Plugin.__init__(self)
  
! if not hasattr(config, 'MPLAYER_VERSION'):
! child = popen2.Popen3( %s -v % config.MPLAYER_CMD, 1, 100)
! data = child.fromchild.readline() # Just need the first line
! if data:
! data = re.search( ^MPlayer (?Pversion\S+), data )
! if data:
! _debug_(MPlayer version is: %s % data.group( version ))
! data = data.group( version )
! if data[ 0 ] == 1:
! config.MPLAYER_VERSION = 1.0
! elif data[ 0 ] == 0:
! config.MPLAYER_VERSION = 0.9
! elif data[ 0 : 7 ] == dev-CVS:
! config.MPLAYER_VERSION = 
! _debug_(MPlayer version set to: %s % config.MPLAYER_VERSION)
! child.wait()
  
  # register mplayer as the object to play video
! plugin.register(MPlayer(config.MPLAYER_VERSION), plugin.VIDEO_PLAYER, True)
  
  

Index: xine.py
===
RCS file: /cvsroot/freevo/freevo/src/video/plugins/xine.py,v
retrieving revision 1.31
retrieving revision 1.32
diff -C2 -d -r1.31 -r1.32
*** xine.py 10 Dec 2003 19:06:06 -  1.31
--- xine.py 10 Dec 2003 19:47:49 -  1.32
***
*** 18,21 
--- 18,24 
  # ---
  # $Log$
+ # Revision 1.32  2003/12/10 19:47:49  dischi
+ # make it possible to bypass version checking
+ #
  # Revision 1.31  2003/12/10 19:06:06  dischi
  # move to new ChildApp2 and remove the internal thread
***
*** 78,83 
  
  
! import time, os
! import popen2, re
  import copy
  
--- 81,85 
  
  
! import time, os, re
  import copy
  
***
*** 85,88 
--- 87,91 
  import childapp   # Handle child applications
  import rc # The RemoteControl class.
+ import util.popen3
  
  from event import *
***
*** 110,134 
  type = 'X'
  
! xine_version = 0
! xine_cvs = 0
! 
! child = popen2.Popen3('%s --version' % config.XINE_COMMAND, 1, 100)
! while(1):
! data = child.fromchild.readline()
! if not data:
! break
! m = re.match('^.* v?([0-9])\.([0-9]+)\.([0-9]*).*', data)
! if m:
! if data.find('cvs') = 0:
! xine_cvs = 1
! xine_version =int('%02d%02d%02d' % (int(m.group(1)), int(m.group(2)),
! int(m.group(3
! 
! child.wait()
  
! if xine_cvs:
! xine_version += 1
  
! if xine_version  922:
  if type == 'fb':
  print _( 'ERROR' ) + ': ' + \
--- 113,130 
  type = 'X'
  
! if not hasattr(config, 'XINE_VERSION'):
! config.XINE_VERSION = 0
! for data in util.popen3.stdout('%s 

[Freevo-cvslog] freevo/src/audio/plugins xine.py,1.10,1.11

2003-12-10 Thread dischi
Update of /cvsroot/freevo/freevo/src/audio/plugins
In directory sc8-pr-cvs1:/tmp/cvs-serv15040/audio/plugins

Modified Files:
xine.py 
Log Message:
make it possible to bypass version checking

Index: xine.py
===
RCS file: /cvsroot/freevo/freevo/src/audio/plugins/xine.py,v
retrieving revision 1.10
retrieving revision 1.11
diff -C2 -d -r1.10 -r1.11
*** xine.py 10 Dec 2003 19:02:38 -  1.10
--- xine.py 10 Dec 2003 19:47:49 -  1.11
***
*** 13,16 
--- 13,19 
  # ---
  # $Log$
+ # Revision 1.11  2003/12/10 19:47:49  dischi
+ # make it possible to bypass version checking
+ #
  # Revision 1.10  2003/12/10 19:02:38  dischi
  # move to new ChildApp2 and remove the internal thread
***
*** 48,57 
  
  
! import popen2, re
  
  import config # Configuration handler. reads config file.
  import childapp   # Handle child applications
  import rc # The RemoteControl class.
! 
  from event import *
  import plugin
--- 51,60 
  
  
! import re
  
  import config # Configuration handler. reads config file.
  import childapp   # Handle child applications
  import rc # The RemoteControl class.
! import util.popen3
  from event import *
  import plugin
***
*** 72,96 
  return
  
! xine_version = 0
! xine_cvs = 0
! 
! child = popen2.Popen3('%s --version' % config.CONF.fbxine, 1, 100)
! while(1):
! data = child.fromchild.readline()
! if not data:
! break
! m = re.match('^.* v?([0-9])\.([0-9]+)\.([0-9]*).*', data)
! if m:
! if data.find('cvs') = 0:
! xine_cvs = 1
! xine_version =int('%02d%02d%02d' % (int(m.group(1)), int(m.group(2)),
! int(m.group(3
  
! child.wait()
  
! if xine_cvs:
! xine_version += 1
! 
! if xine_version  923:
  print _( 'ERROR' ) + ': ' + \
_( 'fbxine' version too old, plugin 'xine' deactivated )
--- 75,93 
  return
  
! if not hasattr(config, 'FBXINE_VERSION'):
! config.FBXINE_VERSION = 0
! for data in util.popen3.stdout('%s --version' % config.CONF.fbxine):
! m = re.match('^.* v?([0-9])\.([0-9]+)\.([0-9]*).*', data)
! if m:
! config.FBXINE_VERSION = int('%02d%02d%02d' % (int(m.group(1)),
!   int(m.group(2)),
!   int(m.group(3
! if data.find('cvs') = 0:
! config.FBXINE_VERSION += 1
  
! _debug_('detect fbxine version %s' % config.FBXINE_VERSION)
  
! 
! if config.FBXINE_VERSION  923:
  print _( 'ERROR' ) + ': ' + \
_( 'fbxine' version too old, plugin 'xine' deactivated )
***
*** 99,103 
  
  # register xine as the object to play
! plugin.register(Xine(xine_version), plugin.AUDIO_PLAYER, True)
  
  
--- 96,100 
  
  # register xine as the object to play
! plugin.register(Xine(), plugin.AUDIO_PLAYER, True)
  
  
***
*** 109,115 
  
  
! def __init__(self, version):
  self.name = 'xine'
- self.xine_version = version
  self.app_mode = 'audio'
  self.app  = None
--- 106,111 
  
  
! def __init__(self):
  self.name = 'xine'
  self.app_mode = 'audio'
  self.app  = None




---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-cvslog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog


[Freevo-cvslog] freevo/src playlist.py,1.41,1.42

2003-12-10 Thread dischi
Update of /cvsroot/freevo/freevo/src
In directory sc8-pr-cvs1:/tmp/cvs-serv15756

Modified Files:
playlist.py 
Log Message:
make playlist files work again

Index: playlist.py
===
RCS file: /cvsroot/freevo/freevo/src/playlist.py,v
retrieving revision 1.41
retrieving revision 1.42
diff -C2 -d -r1.41 -r1.42
*** playlist.py 8 Dec 2003 20:40:57 -   1.41
--- playlist.py 10 Dec 2003 19:51:51 -  1.42
***
*** 10,13 
--- 10,16 
  # ---
  # $Log$
+ # Revision 1.42  2003/12/10 19:51:51  dischi
+ # make playlist files work again
+ #
  # Revision 1.41  2003/12/08 20:40:57  dischi
  # add doc
***
*** 243,255 
  # it's a filename with a playlist
  try:
! f=open(self.filename, r)
  line = f.readline()
  f.close
  if line.find([playlist])  -1:
! self.read_pls(self.filename)
  elif line.find([Slides])  -1:
! self.read_ssr(self.filename)
  else:
! self.read_m3u(self.filename)
  except OSError, e:
  print 'playlist error: %s' % e
--- 246,258 
  # it's a filename with a playlist
  try:
! f=open(playlist, r)
  line = f.readline()
  f.close
  if line.find([playlist])  -1:
! self.read_pls(playlist)
  elif line.find([Slides])  -1:
! self.read_ssr(playlist)
  else:
! self.read_m3u(playlist)
  except OSError, e:
  print 'playlist error: %s' % e




---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-cvslog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog


[Freevo-devel] Re: Steaming fresh cvs bug :-)

2003-12-10 Thread Dirk Meyer
Peter Svensson wrote:
 I was going to gointo a directory containingmp3's. No such luck :-)=

 Spoiler;

 AttributeError: Playlist instance has no attribute 'filename'

Oops, copy'paste error. Fixed in cvs. You can fix it for your copy by
replacing all self.filename with playlist.


Dischi

-- 
To alcohol! The cause of - and solution to - all of life's problems!
  -- Homer Simpson


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-devel


[Freevo-devel] Re: Shutting down a plugin.DaemonPlugin

2003-12-10 Thread Dirk Meyer
Viggo Fredriksen wrote:
 Hi!

 I'm working on implementing an audio detach bar (with modified a detach.py).
From detach.py I call plugin.activate() for my DaemonPlugin. This
 works as expected.  I also have a draw() function in this plugin, and I need
 to have a reasonably high poll_interval for the time elapsed/remaining/etc
 for the plugin to be usable. When playing is over, the poll of this plugin is
 therefore unnecessary.

 So, the problem is getting this plugin removed from the list of plugins
 where the initial draw() is called. I've tried plugin.shutdown, but all this
 seems to do is to call the shutdown for my own plugin.

 I have tried to find answers in the code, but so far I've been unsuccessfull. 

 Any thoughts? :)

Right now it's not possible to remove a plugin at runtime. Basicly you
need a low value for poll_interval when playing and you don't want to
be called when you are not playing, right? You can't do it, but you
could set poll_interval to something large 10 to avoid unneeded
polling. But still, you need to be prepared that the poll() function
is called when you don't need it. Just return than.


Does this help?


Dischi

-- 
We're back to the times when men were men and wrote their own device 
 drivers
 -- Linus Torvalds


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-devel


AW: [Freevo-devel] Shutting down a plugin.DaemonPlugin

2003-12-10 Thread Jan Grewe
Audio detach bar? Is that an idlebar plugin which display the status of the
currently playing track, like name and time? That would be great!!!

...if it's not something like that, anyone who would write one? ;)

/jan 

-Ursprüngliche Nachricht-
Von: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Im Auftrag von Viggo
Fredriksen
Gesendet: Mittwoch, 10. Dezember 2003 20:03
An: [EMAIL PROTECTED]
Betreff: [Freevo-devel] Shutting down a plugin.DaemonPlugin

Hi!

I'm working on implementing an audio detach bar (with modified a detach.py).
From detach.py I call plugin.activate() for my DaemonPlugin. This works as
expected.  I also have a draw() function in this plugin, and I need to have
a reasonably high poll_interval for the time elapsed/remaining/etc for the
plugin to be usable. When playing is over, the poll of this plugin is
therefore unnecessary.

So, the problem is getting this plugin removed from the list of plugins
where the initial draw() is called. I've tried plugin.shutdown, but all this
seems to do is to call the shutdown for my own plugin.

I have tried to find answers in the code, but so far I've been
unsuccessfull. 

Any thoughts? :)

Regards

Viggo Fredriksen


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it help you create
better code?  SHARE THE LOVE, and help us help YOU!  Click Here:
http://sourceforge.net/donate/
___
Freevo-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-devel



---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-devel


Re: AW: [Freevo-devel] Shutting down a plugin.DaemonPlugin

2003-12-10 Thread Viggo Fredriksen
That's what I am working on :)
I'll se if I can get it skinable, but for now it would only be the basic info.
Everything seems to be working except the described problem.


On Wednesday 10 December 2003 21:02, Jan Grewe wrote:
 Audio detach bar? Is that an idlebar plugin which display the status of the
 currently playing track, like name and time? That would be great!!!

 ..if it's not something like that, anyone who would write one? ;)

 /jan

 -Ursprüngliche Nachricht-
 Von: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED] Im Auftrag von Viggo
 Fredriksen
 Gesendet: Mittwoch, 10. Dezember 2003 20:03
 An: [EMAIL PROTECTED]
 Betreff: [Freevo-devel] Shutting down a plugin.DaemonPlugin

 Hi!

 I'm working on implementing an audio detach bar (with modified a
 detach.py). From detach.py I call plugin.activate() for my DaemonPlugin.
 This works as expected.  I also have a draw() function in this plugin, and
 I need to have a reasonably high poll_interval for the time
 elapsed/remaining/etc for the plugin to be usable. When playing is over,
 the poll of this plugin is therefore unnecessary.

 So, the problem is getting this plugin removed from the list of plugins
 where the initial draw() is called. I've tried plugin.shutdown, but all
 this seems to do is to call the shutdown for my own plugin.

 I have tried to find answers in the code, but so far I've been
 unsuccessfull.

 Any thoughts? :)

 Regards

 Viggo Fredriksen


 ---
 This SF.net email is sponsored by: SF.net Giveback Program.
 Does SourceForge.net help you be more productive?  Does it help you create
 better code?  SHARE THE LOVE, and help us help YOU!  Click Here:
 http://sourceforge.net/donate/
 ___
 Freevo-devel mailing list
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/freevo-devel



 ---
 This SF.net email is sponsored by: SF.net Giveback Program.
 Does SourceForge.net help you be more productive?  Does it
 help you create better code?  SHARE THE LOVE, and help us help
 YOU!  Click Here: http://sourceforge.net/donate/
 ___
 Freevo-devel mailing list
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/freevo-devel


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-devel


SV: [Freevo-devel] Re: Steaming fresh cvs bug :-)

2003-12-10 Thread Peter Svensson
Well, thanks, but I'm an all-out cvs kind of person :-)= 

Since I don't know python, the lest I can do is to test all latest cvs
builds.

/PS

-Ursprungligt meddelande-
Från: Dirk Meyer
Till: [EMAIL PROTECTED]
Skickat: 2003-12-10 20:52
Ämne: [Freevo-devel] Re: Steaming fresh cvs bug :-)

Peter Svensson wrote:
 I was going to gointo a directory containingmp3's. No such luck :-)=

 Spoiler;

 AttributeError: Playlist instance has no attribute 'filename'

Oops, copy'paste error. Fixed in cvs. You can fix it for your copy by
replacing all self.filename with playlist.


Dischi

-- 
To alcohol! The cause of - and solution to - all of life's problems!
  -- Homer Simpson


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-devel


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-devel


Re: [Freevo-devel] Re: Shutting down a plugin.DaemonPlugin

2003-12-10 Thread Viggo Fredriksen
On Wednesday 10 December 2003 20:58, Dirk Meyer wrote:
 Viggo Fredriksen wrote:

  Hi!
 
  I'm working on implementing an audio detach bar (with modified a
  detach.py).
 
 From detach.py I call plugin.activate() for my DaemonPlugin. This
 
  works as expected.  I also have a draw() function in this plugin, and I
  need
 to have a reasonably high poll_interval for the time
  elapsed/remaining/etc for the plugin to be usable. When playing is over,
  the poll of this plugin is therefore unnecessary.
 
  So, the problem is getting this plugin removed from the list of plugins
  where the initial draw() is called. I've tried plugin.shutdown, but all
  this
 seems to do is to call the shutdown for my own plugin.
 
  I have tried to find answers in the code, but so far I've been
  unsuccessfull. 
 
  Any thoughts? :)

 
 Right now it's not possible to remove a plugin at runtime. Basicly you
 need a low value for poll_interval when playing and you don't want to
 be called when you are not playing, right? You can't do it, but you
 could set poll_interval to something large 10 to avoid unneeded
 polling. But still, you need to be prepared that the poll() function
 is called when you don't need it. Just return than.
 
 
 Does this help?
 
 
 Dischi
 
 -- 
 We're back to the times when men were men and wrote their own device 
  drivers
  -- Linus Torvalds
 
 

I've tried adjusting the poll_interval when I don't need it to draw. Eg. 
setting it to 10 when drawing, 9 when not. It does however not
seem to change after the interval is set for the first time  in the __init__.

Regards

Viggo Fredriksen


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-devel


[Freevo-wikilog] [Freevo Wiki] Update of DocumentationPage

2003-12-10 Thread freevo-wikilog
Dear Wiki user,

You have subscribed to a wiki page or wiki category on Freevo Wiki for change 
notification.

The following page has been changed by 131.111.129.153:
http://freevo.sourceforge.net/cgi-bin/moin.cgi/DocumentationPage

--
@@ -21,7 +21,7 @@
 
 == Quick Install ==
 
-Consider getting the quick install version of Freevo.  This needs only the main 
freevo package, and a runtime that contains everything needed to run Freevo (except 
mplayer for legal resons). 
+Consider getting the quick install version of Freevo.  This needs only the main 
freevo package, and a runtime that contains everything needed to run Freevo (except 
m-player for legal resons). 
 
 An automated script is available for downloading freevo and the runtime package and 
installing it on your system.
  {{{


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-wikilog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-wikilog


[Freevo-cvslog] freevo/src/tv/plugins tvtime.py,1.23,1.24

2003-12-10 Thread mikeruelle
Update of /cvsroot/freevo/freevo/src/tv/plugins
In directory sc8-pr-cvs1:/tmp/cvs-serv25307

Modified Files:
tvtime.py 
Log Message:
remove childthread use new childapp2 class

Index: tvtime.py
===
RCS file: /cvsroot/freevo/freevo/src/tv/plugins/tvtime.py,v
retrieving revision 1.23
retrieving revision 1.24
diff -C2 -d -r1.23 -r1.24
*** tvtime.py   3 Dec 2003 20:40:34 -   1.23
--- tvtime.py   10 Dec 2003 20:40:57 -  1.24
***
*** 10,13 
--- 10,16 
  # ---
  # $Log$
+ # Revision 1.24  2003/12/10 20:40:57  mikeruelle
+ # remove childthread use new childapp2 class
+ #
  # Revision 1.23  2003/12/03 20:40:34  mikeruelle
  # a hack for those who do not use freevo -fs
***
*** 376,381 
  
  def __init__(self):
- self.thread = childapp.ChildThread()
- self.thread.stop_osd = True
  self.tuner_chidx = 0# Current channel, index into config.TV_CHANNELS
  self.app_mode = 'tv'
--- 379,382 
***
*** 486,490 
  
  # Start up the TV task
! self.thread.start(TVTimeApp, (command))
  
  self.prev_app = rc.app() # ???
--- 487,491 
  
  # Start up the TV task
! self.app=TVTimeApp(command)
  
  self.prev_app = rc.app() # ???
***
*** 515,519 
  mixer.setIgainVolume(0) # Input on emu10k cards.
  
! self.thread.stop('quit\n')
  rc.app(self.prev_app)
  
--- 516,520 
  mixer.setIgainVolume(0) # Input on emu10k cards.
  
! self.app.stop('quit\n')
  rc.app(self.prev_app)
  
***
*** 532,552 
  if event == em.TV_CHANNEL_UP:
  self.TunerPrevChannel()
! self.thread.app.setchannel('UP')
  else:
  self.TunerNextChannel()
! self.thread.app.setchannel('DOWN')
  
  return True
  
  elif event == em.TOGGLE_OSD:
! self.thread.app.write('DISPLAY_INFO\n')
  return True
  
  elif event == em.BUTTON:
if re.search('^\d+$', event.arg) and int(event.arg) in range(10):
! self.thread.app.write('CHANNEL_%s\n' % event.arg)
  return True
  if event.arg == 'PREV_CH':
! self.thread.app.write('CHANNEL_PREV\n')
  return True

--- 533,553 
  if event == em.TV_CHANNEL_UP:
  self.TunerPrevChannel()
! self.app.setchannel('UP')
  else:
  self.TunerNextChannel()
! self.app.setchannel('DOWN')
  
  return True
  
  elif event == em.TOGGLE_OSD:
! self.app.write('DISPLAY_INFO\n')
  return True
  
  elif event == em.BUTTON:
if re.search('^\d+$', event.arg) and int(event.arg) in range(10):
! self.app.write('CHANNEL_%s\n' % event.arg)
  return True
  if event.arg == 'PREV_CH':
! self.app.write('CHANNEL_PREV\n')
  return True

***
*** 557,561 
  
  # ==
! class TVTimeApp(childapp.ChildApp):
  
  class controlling the in and output from the tvtime process
--- 558,562 
  
  # ==
! class TVTimeApp(childapp.ChildApp2):
  
  class controlling the in and output from the tvtime process
***
*** 579,583 
  print 'TVTime logging to %s and %s' % (fname_out, fname_err)
  
! childapp.ChildApp.__init__(self, app)
  
  
--- 580,584 
  print 'TVTime logging to %s and %s' % (fname_out, fname_err)
  
! childapp.ChildApp2.__init__(self, app)
  
  




---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-cvslog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog


[Freevo-devel] Re: plugin data

2003-12-10 Thread Aubin Paul
On Wed, Dec 10, 2003 at 05:52:51PM +0100, Dirk Meyer wrote:
 Agreed. But maybe we could store the mmpython data ourself and bypass
 the mmpython cache?

What would be ideal is if we could override the mmpython cache
(inherit, whatever :) and then replace the write commands with our
own which could store extended information.

 So MetaStore is a dict containing variables for a 'file' (not an
 item)? The big question is: when is this informationen added to the
 item? Should each item call the util.MetaStore function? Or could it
 be simpler? We will only need the data through the getattr function,
 maybe this function could add the meta info if not loaded?

Not even a dict; just a general a=b type storage. Completely generic.
The calling application would just decided what it wanted to store and
shouldn't ever care about the structure.

i.e.

myfile.store('A','B')

would store A=B and you access it with myfile.get('A')

The storage would track where it was called from so the storage would
have:

audio.coversearch.A = 'B'

so there could be a namespace, but it would be possible to share
between plugins or keep them sandboxed.

 How to store the data? One file for each file will slow things now,
 one file at all may be too huge. One file for a directory like
 mmpython uses may be a good idea. 

Fine with me... it would be generic eventually so we could use SQLite
etc.

 Maybe use shelve.py?

I'm not familiar with it, but I'll take a look.

 Maybe remove the links to the current player in the items and store
 the whole item?


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-devel


[Freevo-cvslog] freevo/src/www/htdocs manualrecord.rpy,1.7,1.8

2003-12-10 Thread rshortt
Update of /cvsroot/freevo/freevo/src/www/htdocs
In directory sc8-pr-cvs1:/tmp/cvs-serv21279/src/www/htdocs

Modified Files:
manualrecord.rpy 
Log Message:
Display displayname instead of tunerid.


Index: manualrecord.rpy
===
RCS file: /cvsroot/freevo/freevo/src/www/htdocs/manualrecord.rpy,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -d -r1.7 -r1.8
*** manualrecord.rpy20 Oct 2003 02:36:21 -  1.7
--- manualrecord.rpy11 Dec 2003 01:56:31 -  1.8
***
*** 134,138 
  channelselect = 'select name=chan'
  for ch in guide.chan_list:
! channelselect = channelselect + 'option 
value='+ch.id+''+str(ch.tunerid)+\n
  channelselect = channelselect + /select\n
  
--- 134,138 
  channelselect = 'select name=chan'
  for ch in guide.chan_list:
! channelselect = channelselect + 'option 
value='+ch.id+''+str(ch.displayname)+\n
  channelselect = channelselect + /select\n
  




---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Freevo-cvslog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog