summary |
shortlog | log |
commit |
commitdiff |
tree
first ⋅ prev ⋅ next
W. Trevor King [Tue, 20 Jul 2010 20:05:32 +0000 (16:05 -0400)]
Tag-adding form added to dirtag.html
W. Trevor King [Tue, 20 Jul 2010 19:55:54 +0000 (15:55 -0400)]
Adjustment so that web.py works with unicode paths
W. Trevor King [Tue, 20 Jul 2010 19:01:13 +0000 (15:01 -0400)]
Transition a -> alpha (\u03b1) to test unicode paths
W. Trevor King [Tue, 20 Jul 2010 16:56:04 +0000 (12:56 -0400)]
Use 'raw' and 'tag' for the dir roots, to avoid exposing the underlying path.
For example:
root=/home/user/path/to/pics
may be a bit personal.
Also use raw paths in previews since they are the only ones available
under static/.
W. Trevor King [Tue, 20 Jul 2010 16:46:29 +0000 (12:46 -0400)]
Add preview ability to dir page.
Currently justs stuffs the file into an iframe and leaves it up to the
browser to handle it. However, the iframe is constructed in
dirtag.web.WebInterface._preview
so you can construct mime-type dependent preview holders if you want.
I changed b1.html -> b1.svg to demonstrate the ability to preview
images, etc.
W. Trevor King [Tue, 20 Jul 2010 16:16:21 +0000 (12:16 -0400)]
Add RESTful HTML interface.
Since I was having problems getting the XUL interface working on my
server. It works on my development box though... Strange.
Anyhow, the RESTful interface is less like a desktop application, but
it is less annoying and more robust than XUL+JavaScript.
W. Trevor King [Sun, 18 Jul 2010 19:10:32 +0000 (15:10 -0400)]
Remove old checkbox_activity hook from initialize()
Since that function has morphed into the button set_tags_button().
W. Trevor King [Sun, 18 Jul 2010 19:06:32 +0000 (15:06 -0400)]
Use relative links into static/... rather than /static/...
This allows us to mount dirtag/web.py to a non-root URL (e.g. with
Apache's mod_proxy).
W. Trevor King [Sun, 18 Jul 2010 19:02:36 +0000 (15:02 -0400)]
Add workarounds for Python 2.5.
Also sort list in doctests since listdir()'s output is not sorted by default.
W. Trevor King [Sun, 18 Jul 2010 18:40:09 +0000 (14:40 -0400)]
Add options to specify binding address and port.
W. Trevor King [Sun, 18 Jul 2010 18:12:46 +0000 (14:12 -0400)]
Adjust symlinks to point to new .html files (not old .dat files).
W. Trevor King [Sun, 18 Jul 2010 17:29:30 +0000 (13:29 -0400)]
Also convert the files themselves, and fill them with dummy content.
W. Trevor King [Sun, 18 Jul 2010 17:26:33 +0000 (13:26 -0400)]
Use .html instead of .dat so the iframe can display the files
W. Trevor King [Sun, 18 Jul 2010 17:23:00 +0000 (13:23 -0400)]
Set iframe src attribute to selected file, and serve those files through static/
W. Trevor King [Sun, 18 Jul 2010 12:56:02 +0000 (08:56 -0400)]
Use more reliable multiple select instead of checkboxes.
I couldn't figure out how to use setCellValue to change and display
the checkbox values. The current implementation adds a "Set Tags"
button which reads off the selected rows and uploads any tag changes.
Problem with the current implementation:
When the tree is rebuilt following a data refresh, the rebuild seems
to unselect any repainted rows. I'm not sure why. The current
workaround is to run setup_checkboxes() some reasonable delay after
refreshing the data. Too bad I can't find a blocking refresh, or
better yet, a post-refresh hook to use instead of setTimeout().
Anyhow, any tag selection activity by the user that happens during the
timeout will, obviously, be overwritten by the setup_checkboxes()
call.
W. Trevor King [Sun, 18 Jul 2010 00:07:48 +0000 (20:07 -0400)]
Added working RDF refresh.
The previous Components.classes approach required chrome:// permissions.
Also took a stab at updating the checkboxes when we reload data or
change the currently selected file. I think I'm writing the correct
value, but the checkboxes are not being displayed...
W. Trevor King [Sat, 17 Jul 2010 23:34:16 +0000 (19:34 -0400)]
Add dirtag.xul -> web.py data transfer.
Now the Dirtag instance in web.py carries out request made from dirtag.xul.
TODO: for some reason rdf refreshing isn't working/visible quite yet...
W. Trevor King [Sat, 17 Jul 2010 15:34:50 +0000 (11:34 -0400)]
Move dirtag.xul and *.rdf generation into CherryPy.
Now the intial data displayed by dirtag.xul matches the on-disk raw/tag
structure.
I made a few changes in node handling so traversals would have all the
information required (Node.root, Node.type, Node.tags, and associated
handlers).
W. Trevor King [Sat, 17 Jul 2010 14:08:34 +0000 (10:08 -0400)]
The checkboxes were not settable in the previous implementation.
The problem seems to stem from the old
flags="dont-build-content"
setting, which selects tree vs. content templating. See
https://developer.mozilla.org/en/XUL_Tutorial/Trees_and_Templates
https://developer.mozilla.org/en/XUL/Attribute/flags
for details.
Also hooked checkbox handler (checkbox_activity()) on as a method of
the tree.view, which makes it easier to only act on checkbox activity,
and locate the active row.
Other tidbits:
* Set type="application/javascript" in dirtag.js import.
Might as well to that formally.
* selstype="primary" in checkbox-tree.
I'd rather disable selection entirely, but this at least keeps it off the
checkbox column.
W. Trevor King [Fri, 16 Jul 2010 20:48:59 +0000 (16:48 -0400)]
Use checkbox tree rather than a simple array for element tags in dirtag.xul
W. Trevor King [Fri, 16 Jul 2010 17:55:53 +0000 (13:55 -0400)]
Added XUL frontend for a future dirtag/web.py
W. Trevor King [Fri, 16 Jul 2010 05:17:14 +0000 (01:17 -0400)]
Raise a more helpful error message is a directory does not exist
W. Trevor King [Fri, 16 Jul 2010 05:05:28 +0000 (01:05 -0400)]
Added .gitignore for *.pyc
W. Trevor King [Fri, 16 Jul 2010 05:04:56 +0000 (01:04 -0400)]
Began versioning