|
|
|
|||||||||||
Christine: rola_christine.pyApril
12
![]() Similar to what Gnuget do with rola-banshee.py I did the same but for christine:
#! /usr/bin/env python # -*- coding: utf-8 -*- #Author: Marco Islas #Correo: markuz@islascruz.org #Based on rola-banshee.py http://gnuget.org/blog/view/203/rola-banshee-py version = "1.0" __module_name__ = "rola_christine.py" __module_version__ = version __module_description = 'Shows the track in christine (requires christine from SVN)' import dbus import xchat from dbus.mainloop.glib import DBusGMainLoop class RolaChristine: def __init__(self): mainloop = DBusGMainLoop() self.dbus_session = dbus.SessionBus(mainloop = mainloop) self.christine = self.dbus_session.get_object('org.christine', '/org/christine') xchat.prnt("rola-christine.py Version %s loaded!" %version) xchat.prnt("/rola-christine") def rola(self,word,word_eol,userdata): tags = self.christine.now_playing() title = '%s'%tags.get('title','') if not title: xchat.command('Nada a mostrar..') return xchat.EAT_XCHAT artist = "%s"%tags.get('artist','') if artist: artist = "%s -"%artist xchat.command("me esta escuchando: %s %s" %(artist,title)) return xchat.EAT_XCHAT control = RolaChristine() xchat.hook_command("rola-christine",control.rola) #1.1 Re: Re: Christine: rola_christine.py
Marco Antonio Islas Cruz, <E-Mail> / Sunday 02 August 2009 12:34am
Checando. [ Reply (0) ]
Comment XML feeds: RSS | Atom
|
|||||||||||
|
|
|||||||||||
#1 Re: Christine: rola_christine.py
Oye mi buen markuz estoy tratando de usar tu pluing para xchat pero no jala, me marca el mismo error del que acabo de reportar https://sourceforge.net/apps/trac/christine/ticket/13