* src/Plugins.py: Use doc lists from PluginMgr.

* src/Exporter.py: Use exports list from PluginMgr.
* src/plugins/BookReport.py: Import Plugins module.
* src/NameEdit.py (NameEditor.__init__): Typos.


svn: r3881
This commit is contained in:
Alex Roitman 2005-01-08 00:20:42 +00:00
parent c47db9780f
commit bad8f0ba76
5 changed files with 30 additions and 23 deletions

View File

@ -1,3 +1,9 @@
2005-01-07 Alex Roitman <shura@alex.neuro.umn.edu>
* src/Plugins.py: Use doc lists from PluginMgr.
* src/Exporter.py: Use exports list from PluginMgr.
* src/plugins/BookReport.py: Import Plugins module.
* src/NameEdit.py (NameEditor.__init__): Typos.
2005-01-07 Eero Tamminen <eerot@sf> 2005-01-07 Eero Tamminen <eerot@sf>
* src/Makefile.am: Added GrampsKeys.py and GrampsIniKeys.py so * src/Makefile.am: Added GrampsKeys.py and GrampsIniKeys.py so
that Gramps starts up after installation that Gramps starts up after installation

View File

@ -49,7 +49,7 @@ import gnome.ui
#------------------------------------------------------------------------- #-------------------------------------------------------------------------
import const import const
import Utils import Utils
import Plugins import PluginMgr
import QuestionDialog import QuestionDialog
import GrampsKeys import GrampsKeys
@ -376,7 +376,7 @@ class Exporter:
def build_exports(self): def build_exports(self):
""" """
This method builds its own list of available exports. This method builds its own list of available exports.
The list is built from the Plugins._exports list The list is built from the PluginMgr.export_list list
and from the locally defined exports (i.e. native export defined here). and from the locally defined exports (i.e. native export defined here).
""" """
native_title = _('GRAMPS _GRDB database') native_title = _('GRAMPS _GRDB database')
@ -390,4 +390,4 @@ class Exporter:
self.exports = [ (native_export,native_title,native_description, self.exports = [ (native_export,native_title,native_description,
native_config,native_ext) ] native_config,native_ext) ]
self.exports = self.exports + [ item for item in Plugins._exports ] self.exports = self.exports + [ item for item in PluginMgr.export_list ]

View File

@ -90,14 +90,14 @@ class NameEditor:
types = const.NameTypesMap.get_values() types = const.NameTypesMap.get_values()
types.sort() types.sort()
AutoComp.fill_combo(self.type_combo,types) AutoComp.fill_combo(self.type_combo,types)
self.type_field = self.type_combo.get_child() self.type_field = self.type_combo.get_child()
if self.name: if self.name:
self.srcreflist = self.name.get_source_references() self.srcreflist = self.name.get_source_references()
else: else:
self.srcreflist = [] self.srcreflist = []
full_name = NameDisplay.displayer.display(parent) full_name = NameDisplay.displayer.display_name(name)
alt_title = self.top.get_widget("title") alt_title = self.top.get_widget("title")

View File

@ -511,9 +511,9 @@ class GrampsTextFormatComboBox(gtk.ComboBox):
out_pref = GrampsKeys.get_output_preference() out_pref = GrampsKeys.get_output_preference()
index = 0 index = 0
_textdoc.sort() PluginMgr.textdoc_list.sort()
active_index = 0 active_index = 0
for item in _textdoc: for item in PluginMgr.textdoc_list:
if tables and item[2] == 0: if tables and item[2] == 0:
continue continue
name = item[0] name = item[0]
@ -528,22 +528,22 @@ class GrampsTextFormatComboBox(gtk.ComboBox):
self.set_active(active_index) self.set_active(active_index)
def get_label(self): def get_label(self):
return _textdoc[self.get_active()][0] return PluginMgr.textdoc_list[self.get_active()][0]
def get_reference(self): def get_reference(self):
return _textdoc[self.get_active()][1] return PluginMgr.textdoc_list[self.get_active()][1]
def get_paper(self): def get_paper(self):
return _textdoc[self.get_active()][3] return PluginMgr.textdoc_list[self.get_active()][3]
def get_styles(self): def get_styles(self):
return _textdoc[self.get_active()][4] return PluginMgr.textdoc_list[self.get_active()][4]
def get_ext(self): def get_ext(self):
return _textdoc[self.get_active()][5] return PluginMgr.textdoc_list[self.get_active()][5]
def get_printable(self): def get_printable(self):
return _textdoc[self.get_active()][6] return PluginMgr.textdoc_list[self.get_active()][6]
class GrampsDrawFormatComboBox(gtk.ComboBox): class GrampsDrawFormatComboBox(gtk.ComboBox):
@ -556,9 +556,9 @@ class GrampsDrawFormatComboBox(gtk.ComboBox):
out_pref = GrampsKeys.get_output_preference() out_pref = GrampsKeys.get_output_preference()
index = 0 index = 0
_drawdoc.sort() PluginMgr.drawdoc_list.sort()
active_index = 0 active_index = 0
for item in _drawdoc: for item in PluginMgr.drawdoc_list:
if tables and item[2] == 0: if tables and item[2] == 0:
continue continue
name = item[0] name = item[0]
@ -573,22 +573,22 @@ class GrampsDrawFormatComboBox(gtk.ComboBox):
self.set_active(active_index) self.set_active(active_index)
def get_reference(self): def get_reference(self):
return _drawdoc[self.get_active()][1] return PluginMgr.drawdoc_list[self.get_active()][1]
def get_label(self): def get_label(self):
return _drawdoc[self.get_active()][0] return PluginMgr.drawdoc_list[self.get_active()][0]
def get_paper(self): def get_paper(self):
return _drawdoc[self.get_active()][2] return PluginMgr.drawdoc_list[self.get_active()][2]
def get_styles(self): def get_styles(self):
return _drawdoc[self.get_active()][3] return PluginMgr.drawdoc_list[self.get_active()][3]
def get_ext(self): def get_ext(self):
return _drawdoc[self.get_active()][4] return PluginMgr.drawdoc_list[self.get_active()][4]
def get_printable(self): def get_printable(self):
return _drawdoc[self.get_active()][5] return PluginMgr.drawdoc_list[self.get_active()][5]
class GrampsBookFormatComboBox(gtk.ComboBox): class GrampsBookFormatComboBox(gtk.ComboBox):
@ -601,10 +601,10 @@ class GrampsBookFormatComboBox(gtk.ComboBox):
out_pref = GrampsKeys.get_output_preference() out_pref = GrampsKeys.get_output_preference()
index = 0 index = 0
_drawdoc.sort() PluginMgr.drawdoc_list.sort()
active_index = 0 active_index = 0
self.data = [] self.data = []
for item in _bookdoc: for item in PluginMgr.bookdoc_list:
if tables and item[2] == 0: if tables and item[2] == 0:
continue continue
self.data.append(item) self.data.append(item)

View File

@ -63,6 +63,7 @@ import Report
import BaseDoc import BaseDoc
from QuestionDialog import WarningDialog from QuestionDialog import WarningDialog
import ReportOptions import ReportOptions
import Plugins
#------------------------------------------------------------------------ #------------------------------------------------------------------------
# #