Пример #1
0
 def __init__(self,
              db,
              scol=0,
              order=gtk.SORT_ASCENDING,
              search=None,
              skip=set(),
              sort_map=None):
     self.map = db.get_raw_citation_data
     self.gen_cursor = db.get_citation_cursor
     self.fmap = [
         self.citation_page, self.citation_id, self.citation_date,
         self.citation_confidence, self.citation_change,
         self.citation_src_title, self.citation_src_id,
         self.citation_src_auth, self.citation_src_abbr,
         self.citation_src_pinfo, self.citation_src_chan,
         self.citation_handle, self.citation_tooltip
     ]
     self.smap = [
         self.citation_page, self.citation_id, self.citation_sort_date,
         self.citation_confidence, self.citation_sort_change,
         self.citation_src_title, self.citation_src_id,
         self.citation_src_auth, self.citation_src_abbr,
         self.citation_src_pinfo, self.citation_src_chan,
         self.citation_handle, self.citation_tooltip
     ]
     FlatBaseModel.__init__(self,
                            db,
                            scol,
                            order,
                            tooltip_column=12,
                            search=search,
                            skip=skip,
                            sort_map=sort_map)
Пример #2
0
 def __init__(self, db, scol=0, order=gtk.SORT_ASCENDING, search=None, 
              skip=set(), sort_map=None):
     self.gen_cursor = db.get_family_cursor
     self.map = db.get_raw_family_data
     self.fmap = [
         self.column_id, 
         self.column_father, 
         self.column_mother, 
         self.column_type, 
         self.column_marriage, 
         self.column_tags,
         self.column_change, 
         self.column_handle, 
         self.column_tag_color,
         self.column_tooltip,
         ]
     self.smap = [
         self.column_id, 
         self.sort_father, 
         self.sort_mother, 
         self.column_type, 
         self.sort_marriage, 
         self.column_tags,
         self.sort_change, 
         self.column_handle, 
         self.column_tag_color,
         self.column_tooltip,
         ]
     FlatBaseModel.__init__(self, db, scol, order, tooltip_column=9, 
                        search=search, skip=skip, sort_map=sort_map)
Пример #3
0
 def __init__(self,
              db,
              scol=0,
              order=gtk.SORT_ASCENDING,
              search=None,
              skip=set(),
              sort_map=None):
     """Setup initial values for instance variables."""
     self.gen_cursor = db.get_note_cursor
     self.map = db.get_raw_note_data
     self.fmap = [
         self.column_preview, self.column_id, self.column_type,
         self.column_tags, self.column_change, self.column_handle,
         self.column_tag_color
     ]
     self.smap = [
         self.column_preview, self.column_id, self.column_type,
         self.column_tags, self.sort_change, self.column_handle,
         self.column_tag_color
     ]
     FlatBaseModel.__init__(self,
                            db,
                            scol,
                            order,
                            search=search,
                            skip=skip,
                            sort_map=sort_map)
Пример #4
0
 def __init__(self,
              db,
              scol=0,
              order=gtk.SORT_ASCENDING,
              search=None,
              skip=set(),
              sort_map=None):
     self.map = db.get_raw_source_data
     self.gen_cursor = db.get_source_cursor
     self.fmap = [
         self.column_title, self.column_id, self.column_author,
         self.column_abbrev, self.column_pubinfo, self.column_change,
         self.column_handle, self.column_tooltip
     ]
     self.smap = [
         self.column_title,
         self.column_id,
         self.column_author,
         self.column_abbrev,
         self.column_pubinfo,
         self.sort_change,
     ]
     FlatBaseModel.__init__(self,
                            db,
                            scol,
                            order,
                            tooltip_column=7,
                            search=search,
                            skip=skip,
                            sort_map=sort_map)
Пример #5
0
 def __init__(self, db, scol=0, order=gtk.SORT_ASCENDING, search=None,
              skip=set(), sort_map=None):
     self.gen_cursor = db.get_event_cursor
     self.map = db.get_raw_event_data
     
     self.fmap = [
         self.column_description,
         self.column_id,
         self.column_type,
         self.column_date,
         self.column_place,
         self.column_change,
         self.column_participant,
         self.column_handle,
         self.column_tooltip,
         ]
     self.smap = [
         self.column_description,
         self.column_id,
         self.column_type,
         self.sort_date,
         self.column_place,
         self.sort_change,
         self.column_participant,
         self.column_handle,
         self.column_tooltip,
         ]
     FlatBaseModel.__init__(self, db, scol, order, tooltip_column=8,
                        search=search, skip=skip, sort_map=sort_map)
Пример #6
0
 def destroy(self):
     """
     Unset all elements that can prevent garbage collection
     """
     self.db = None
     self.gen_cursor = None
     self.map = None
     self.fmap = None
     self.smap = None
     FlatBaseModel.destroy(self)
Пример #7
0
 def __init__(self,
              db,
              scol=0,
              order=gtk.SORT_ASCENDING,
              search=None,
              skip=set(),
              sort_map=None):
     PeopleBaseModel.__init__(self, db)
     FlatBaseModel.__init__(self,
                            db,
                            search=search,
                            skip=skip,
                            tooltip_column=13,
                            scol=scol,
                            order=order,
                            sort_map=sort_map)
Пример #8
0
    def __init__(self,
                 db,
                 scol=0,
                 order=gtk.SORT_ASCENDING,
                 search=None,
                 skip=set(),
                 sort_map=None):
        self.gen_cursor = db.get_repository_cursor
        self.get_handles = db.get_repository_handles
        self.map = db.get_raw_repository_data
        self.fmap = [
            self.column_name, self.column_id, self.column_type,
            self.column_home_url, self.column_street, self.column_locality,
            self.column_city, self.column_state, self.column_country,
            self.column_postal_code, self.column_email, self.column_search_url,
            self.column_change, self.column_handle, self.column_tooltip
        ]

        self.smap = [
            self.column_name,
            self.column_id,
            self.column_type,
            self.column_home_url,
            self.column_street,
            self.column_locality,
            self.column_city,
            self.column_state,
            self.column_country,
            self.column_postal_code,
            self.column_email,
            self.column_search_url,
            self.sort_change,
            self.column_handle,
        ]

        FlatBaseModel.__init__(self,
                               db,
                               scol,
                               order,
                               tooltip_column=14,
                               search=search,
                               skip=skip,
                               sort_map=sort_map)
Пример #9
0
 def destroy(self):
     """
     Unset all elements that can prevent garbage collection
     """
     PeopleBaseModel.destroy(self)
     FlatBaseModel.destroy(self)