6085: Remove import from the gui module
This commit is contained in:
parent
dfdb11bfc9
commit
c3c8a632de
@ -404,9 +404,7 @@ class Gramplet:
|
|||||||
"""
|
"""
|
||||||
Add an option to the GUI gramplet.
|
Add an option to the GUI gramplet.
|
||||||
"""
|
"""
|
||||||
from gramps.gui.plug import make_gui_option
|
widget, label = self.gui.add_gui_option(option)
|
||||||
widget, label = make_gui_option(
|
|
||||||
option, self.dbstate, self.uistate, self.track)
|
|
||||||
self.option_dict.update({option.get_label(): [widget, option]})
|
self.option_dict.update({option.get_label(): [widget, option]})
|
||||||
self.option_order.append(option.get_label())
|
self.option_order.append(option.get_label())
|
||||||
|
|
||||||
|
@ -50,6 +50,7 @@ from ..editors import EditPerson, EditFamily
|
|||||||
from ..managedwindow import ManagedWindow
|
from ..managedwindow import ManagedWindow
|
||||||
from ..utils import is_right_click, rgb_to_hex
|
from ..utils import is_right_click, rgb_to_hex
|
||||||
from .menuitem import add_menuitem
|
from .menuitem import add_menuitem
|
||||||
|
from ..plug import make_gui_option
|
||||||
from ..plug.quick import run_quick_report_by_name
|
from ..plug.quick import run_quick_report_by_name
|
||||||
from ..display import display_help, display_url
|
from ..display import display_help, display_url
|
||||||
from ..glade import Glade
|
from ..glade import Glade
|
||||||
@ -345,6 +346,7 @@ class GuiGramplet:
|
|||||||
self.view = pane.pageview
|
self.view = pane.pageview
|
||||||
self.dbstate = dbstate
|
self.dbstate = dbstate
|
||||||
self.uistate = uistate
|
self.uistate = uistate
|
||||||
|
self.track = []
|
||||||
self.title = title
|
self.title = title
|
||||||
self.detached_window = None
|
self.detached_window = None
|
||||||
self.force_update = False
|
self.force_update = False
|
||||||
@ -549,6 +551,12 @@ class GuiGramplet:
|
|||||||
def get_container_widget(self):
|
def get_container_widget(self):
|
||||||
raise NotImplementedError
|
raise NotImplementedError
|
||||||
|
|
||||||
|
def add_gui_option(self, option):
|
||||||
|
"""
|
||||||
|
Add an option to the GUI gramplet.
|
||||||
|
"""
|
||||||
|
return make_gui_option(option, self.dbstate, self.uistate, self.track)
|
||||||
|
|
||||||
def make_gui_options(self):
|
def make_gui_options(self):
|
||||||
if not self.pui: return
|
if not self.pui: return
|
||||||
# BEGIN WORKAROUND:
|
# BEGIN WORKAROUND:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user