So I've been toying around with Totem's plugin API all day, with the intent of creating a simple Bookmarks plugin that would help me remember where I stopped watching videos and easily pick up where I left off.
Halfway through trying to merge my plugin's menu with Totem's through the really weird GtkUIManager (which I later learned is not actually a UI manager), I realised that I don't really need all of this, and all I had to do is just a simple Evince-like auto resuming on startup without any UI intervention at all.
The plugin saves the current time for each media file periodically, and when you load up that particular media file again; it remembers where you stopped last time and starts from there.
Pretty simple and straightforward.
You can try it out for yourself,
Download the tarball from http://pypi.python.org/pypi/totem-plugin-automagicalresume, extract it, and run sudo python setup.py install from the extracted dir.
Or if you're running Ubuntu, you can add the ppa https://launchpad.net/~amr-hassan/+archive/totem-plugins to your sources and then run sudo apt-get update && sudo apt-get install totem-plugin-automagicalresume from your favorite terminal.
If you're installing from the tarball, make sure you have the external dependencies: python >= 2.6, python-xdg, python-gtk2. If you're using the PPA, apt usually takes care of that for you ;)
Then you just have to enable the plugin from Totem's Edit > Plugins menu.
resurrection
I've decided to bring this blog back from the dead for some unknown strange reason, so i'm gonna leave it up for now in case i get bloggy.
Help yourself to some music from my music radio on the right, or scroll down to see some of the interesting stuff that i've shared from google reader recently.
Help yourself to some music from my music radio on the right, or scroll down to see some of the interesting stuff that i've shared from google reader recently.
i'm watching lost
Posted by
Amr Hassan
on Sunday, August 17, 2008
/
Labels:
things i did because i was bored,
tv
/
Comments: (1)
sadly, yes.i am watching lost.
it's been one the most boring weeks of my life and i've been tempted by the all downloaded-and-oh-so-complete four seasons of lost on my brother's computer. that's almost 70 hours of pure time wasting, and who was i to say no to that!
so here i am, already on my 21st episode in. been watching it back to back for three days now, and i know that at this point there's no going back...
remind me later to check if there's a record for who watched the most lost in a week because i'm pretty sure i'm going to break it soon.
python bindings for last.fm's shiny new api
everyone's been drooling over the new last.fm api since they came out, and i myself have had a million ideas on how to make use of them. but since that i get excited too quickly and get distracted by other things even quicker, i've settled with writing a set of wrapper classes in python for now.
be sure to check it out if you're a python or a last.fm geek or both. it's a lot of fun manipulating last.fm from the terminal..it's pretty much complete now, i'm just currently hunting down the bugs and completing the documentation.
you can checkout the current revision from the svn at google code, pyLast.
what! a blog! oh, god no!!
i know what you're thinking.. a blog! i mean, why!!
i don't know why either. probably for the same reason i did almost 96% of the things i've done in my life.
i'm so freakin bored.
i was checking out google services and it lead me here.. i said to myself "hey, it might be fun". so i did it. the guys at blogger sure know how to make it easy for everyone to start a blog. maybe a little too easy.
i know i'm the pretty much the least interesting person i know so whoever you are, i'll try to spare you most of the babble..
so... that's it for now.
i don't know why either. probably for the same reason i did almost 96% of the things i've done in my life.
i'm so freakin bored.
i was checking out google services and it lead me here.. i said to myself "hey, it might be fun". so i did it. the guys at blogger sure know how to make it easy for everyone to start a blog. maybe a little too easy.
i know i'm the pretty much the least interesting person i know so whoever you are, i'll try to spare you most of the babble..
so... that's it for now.