GNOME Bugzilla – Bug 497136
new extension, retroactively adding old photos to new rolls
Last modified: 2008-07-04 15:15:44 UTC
Hello hackers, I wrote an extension to retroactively add old photos to newly-created rolls. A tarball with the source, makefile, and addin xml is attached. The code creates a new roll with the import time being the maximum time of the currently selected photos. I wrote the extension because I am interested in the presentational possibilities for the "roll" information -- specifically, I think that it forms a nice way for navigating in time from a web interface. It would be cleaner if there were API to assign an existing photo to a roll. Let me know if you need anything, Andy
Created attachment 99154 [details] source, makefile, and addin.xml for extension
Nice small Extension :) Small nitpicking here... Perhaps refactor it a bit to bring out a few commands into small methods. No Exception catching on the database update. Like the extension, and nice job getting a proper timestamp :) Wish this one was there when I imported all my photos before...
Two trivial comments: 1. I believe p.RollId = roll.Id; is useless. When filtering by roll a new query is issued so you don't need to keep the actual photo updated... 2. The description is reductive, because you may wish to split even a recent roll. i.e. if you imported in one batch the wedding photos and the trekking ones and want to divide them. ;)
(In reply to comment #2) > Small nitpicking here... > Perhaps refactor it a bit to bring out a few commands into small methods. It's just a hack :) > No Exception catching on the database update. I assume the exceptions will propagate up and print some kind of backtrace. I don't care to learn what exceptions need to be caught here. > Like the extension, and nice job getting a proper timestamp :) > Wish this one was there when I imported all my photos before... Thanks! (In reply to comment #3) > Two trivial comments: > > 1. I believe p.RollId = roll.Id; is useless. When filtering by roll a new query > is issued so you don't need to keep the actual photo updated... Better safe than sorry? But ok. > 2. The description is reductive, because you may wish to split even a recent > roll. i.e. if you imported in one batch the wedding photos and the trekking > ones and want to divide them. ;) Good point. Anyways what's happening with this bug?
Ping? :-(
I guess that ping mean you'd like to have your extension on svn and in the repository ?
committed in r4154 I'll build it and make it available for 0.4.4 and svn