From 3664c5f5fe30884d3c0962fc24648b5883d9ebfe Mon Sep 17 00:00:00 2001 From: Nikos Skalkotos <skalkoto@grnet.gr> Date: Thu, 3 Jan 2013 15:30:34 +0200 Subject: [PATCH] Remember the working dir media selection dialog --- image_creator/dialog_main.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/image_creator/dialog_main.py b/image_creator/dialog_main.py index 7af17f2..a32a977 100644 --- a/image_creator/dialog_main.py +++ b/image_creator/dialog_main.py @@ -133,7 +133,7 @@ def image_creator(d, media, out): def select_file(d, media): - root = os.sep + default = os.getcwd() + os.sep while 1: if media is not None: if not os.path.exists(media): @@ -143,8 +143,9 @@ def select_file(d, media): mode = os.stat(media).st_mode if not stat.S_ISDIR(mode): break + default = media - (code, media) = d.fselect(root, 10, 60, extra_button=1, + (code, media) = d.fselect(default, 10, 60, extra_button=1, title="Please select an input media.", extra_label="Bundle Host") if code in (d.DIALOG_CANCEL, d.DIALOG_ESC): -- GitLab