Author: tack
Date: Sat Jun 23 20:47:08 2007
New Revision: 9727

Modified:
   trunk/core/src/xmlconfig.py
   trunk/ui/setup.py
   trunk/ui/src/__init__.py

Log:
Sync to recent xmlconfig changes (specify package name); add missing -*- to
hash line.


Modified: trunk/core/src/xmlconfig.py
==============================================================================
--- trunk/core/src/xmlconfig.py (original)
+++ trunk/core/src/xmlconfig.py Sat Jun 23 20:47:08 2007
@@ -41,7 +41,7 @@
 import kaa.distribution.xmlconfig
 
 
-def xmlconfig(configfile, sources):
+def xmlconfig(configfile, sources, package):
 
     hashkey = [ f+str(os.stat(f)[stat.ST_MTIME]) for f in sources ]
     hashkey = md5.new(''.join(hashkey)).hexdigest()
@@ -49,7 +49,7 @@
     if os.path.isfile(configfile):
         fd = open(configfile)
         fd.readline()
-        if fd.readline() == '# -*- hash: %s\n' % hashkey:
+        if fd.readline() == '# -*- hash: %s -*-\n' % hashkey:
             fd.close()
             return True
         fd.close()
@@ -124,11 +124,11 @@
     
     out = open(configfile, 'w')
     out.write('# -*- coding: iso-8859-1 -*-\n')
-    out.write('# -*- hash: %s\n' % hashkey)
+    out.write('# -*- hash: %s -*-\n' % hashkey)
     out.write('# auto generated file\n\n')
     out.write('from kaa.config import *\n\n')
     out.write('config = ')
-    kaa.distribution.xmlconfig.Parser().parse(doc.firstChild, out)
+    kaa.distribution.xmlconfig.Parser(package).parse(doc.firstChild, out)
 
     def find_plugins(node, position=''):
         for child in node.childNodes:

Modified: trunk/ui/setup.py
==============================================================================
--- trunk/ui/setup.py   (original)
+++ trunk/ui/setup.py   Sat Jun 23 20:47:08 2007
@@ -69,7 +69,7 @@
        max(*[os.stat(x)[stat.ST_MTIME] for x in cxml_files ]):
         if not os.path.isdir('build'):
             os.mkdir('build')
-        xmlconfig('build/config.cxml', cxml_files)
+        xmlconfig('build/config.cxml', cxml_files, 'freevo.ui')
 
     data_files.append(('share/freevo/config', [ 'build/config.cxml' ]))
     

Modified: trunk/ui/src/__init__.py
==============================================================================
--- trunk/ui/src/__init__.py    (original)
+++ trunk/ui/src/__init__.py    Sat Jun 23 20:47:08 2007
@@ -46,7 +46,7 @@
 pycfgfile = freevo.conf.datafile('freevo_config.py')
 cfgdir = os.path.join(SHAREDIR, 'config')
 cfgsource = [ os.path.join(cfgdir, f) for f in os.listdir(cfgdir) ]
-freevo.xmlconfig.xmlconfig(pycfgfile, cfgsource)
+freevo.xmlconfig.xmlconfig(pycfgfile, cfgsource, 'freevo.ui')
 
 # load config structure. This will add 'config', 'plugins' and 'events'
 execfile(pycfgfile)

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Freevo-cvslog mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog

Reply via email to