Fixed the way the subject is initialized.

The first pane can now create the subject from its constructor. It is no more overwritten by the frame if no subject is passed at Frame construction time.
This commit is contained in:
David Soulayrol 2011-08-28 15:14:19 +02:00
commit 406a5b0055

View file

@ -326,7 +326,7 @@ class Frame(gtk.Dialog):
forward the subject between them.
"""
def __init__(self, start_klass, subject="", title='Wizard', min_size=(400, 200)):
def __init__(self, start_klass, subject=None, title='Wizard', min_size=(400, 200)):
"""Constructor.
A frame must be provided at least the initial pane class. If
@ -359,7 +359,8 @@ class Frame(gtk.Dialog):
self.connect("response", self._on_button)
start_pane = start_klass(self)
start_pane.subject = subject
if not subject is None:
start_pane.subject = subject
self._track = [start_pane]
self._enter_pane(start_pane, True)