* src/gramps_main.py (on_export_activate): Switch to new Exporter.

* src/WriteXML.py: Change registration. Return 1 on success and
0 when on failure.
* src/Utils.py (get_new_filename): Add function.
* src/DbPrompter.py (get_new_filename): Remove function.
* src/Exporter.py: Add to CVS.
* src/Makefile.am: Ship Exporter.py.
* src/Plugins.py (register_export): Change to the new scheme.


svn: r3254
This commit is contained in:
Alex Roitman
2004-07-09 18:19:47 +00:00
parent 1333c80f7f
commit b76bc6d42d
8 changed files with 279 additions and 36 deletions

View File

@@ -460,13 +460,13 @@ def reload_plugins(obj):
# Plugin registering
#
#-------------------------------------------------------------------------
def register_export(task, ffilter, pattern_list=None):
def register_export(exportData,_title,_description='',_config=None,_filename=''):
"""
Register an export filter, taking the task, file filter,
and the list of patterns for the filename matching.
"""
if pattern_list:
_exports.append((task, ffilter, pattern_list))
if _description and _filename:
_exports.append((exportData,_title,_description,_config,_filename))
def register_import(task, ffilter, mime=None):
"""Register an import filter, taking the task and file filter"""