22 |
from Thuban.Model.layer import Layer |
from Thuban.Model.layer import Layer |
23 |
from Thuban.Model.map import Map |
from Thuban.Model.map import Map |
24 |
|
|
25 |
from dialogs import NonModalDialog |
from dialogs import NonModalNonParentDialog |
26 |
from messages import SESSION_REPLACED, LAYER_SELECTED |
from messages import SESSION_REPLACED, LAYER_SELECTED |
27 |
|
|
28 |
BMP_SIZE = 15 |
BMP_SIZE = 15 |
219 |
self.SelectItem(item) |
self.SelectItem(item) |
220 |
|
|
221 |
|
|
222 |
class SessionTreeView(NonModalDialog): |
class SessionTreeView(NonModalNonParentDialog): |
223 |
|
|
224 |
"""Non modal dialog showing the session as a tree""" |
"""Non modal dialog showing the session as a tree""" |
225 |
|
|
226 |
def __init__(self, parent, app, name): |
def __init__(self, parent, app, name): |
227 |
NonModalDialog.__init__(self, parent, name, _("Session")) |
NonModalNonParentDialog.__init__(self, parent, name, _("Session")) |
228 |
self.tree = SessionTreeCtrl(self, -1, parent, app) |
self.tree = SessionTreeCtrl(self, -1, parent, app) |
229 |
|
|
230 |
def OnClose(self, event): |
def OnClose(self, event): |
231 |
NonModalDialog.OnClose(self, event) |
NonModalNonParentDialog.OnClose(self, event) |
232 |
|
|
233 |
# if there were a way to get notified when the tree control |
# if there were a way to get notified when the tree control |
234 |
# itself is destroyed we could use that to unsubscribe instead |
# itself is destroyed we could use that to unsubscribe instead |