Mercurial > hg > decoupage
diff decoupage/web.py @ 33:e384d4569ac3
include components necessary to make decoupage feel almost like a framework
author | k0s <k0scist@gmail.com> |
---|---|
date | Mon, 08 Feb 2010 11:40:57 -0500 |
parents | f306089d6def |
children | 527ccb76d043 |
line wrap: on
line diff
--- a/decoupage/web.py Mon Feb 08 11:10:54 2010 -0500 +++ b/decoupage/web.py Mon Feb 08 11:40:57 2010 -0500 @@ -1,5 +1,5 @@ """ -decoupage: a view with webob +decoupage: a view with webob to index and serve static content """ import os @@ -102,13 +102,17 @@ # get the configuraton conf = self.conf(path) - # build data dictionary + ### build data dictionary files = self.filedata(path, directory, conf) data = {'path': path, 'files': files, 'request': request } + + # defaults; TODO: make this better data['title'] = conf.get('/title') data['directory'] = directory data['include'] = None data['css'] = () + data['scripts'] = () + data['icon'] = None # apply formatters # XXX this should be cached if not self.auto_reload