From 9789ed626bc69f348b55cfa5f1a79abbdc994204 Mon Sep 17 00:00:00 2001 From: Saul Wold Date: Tue, 10 Apr 2012 17:57:15 -0700 Subject: hig/builder: use the new which_terminal() function Also adjusted the cmdline ordering to work correctly with both xterm and vte. (Bitbake rev: 4219e2ea033232d95117211947b751bdb5efafd4) Signed-off-by: Saul Wold Signed-off-by: Richard Purdie --- bitbake/lib/bb/ui/crumbs/hig.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'bitbake/lib/bb/ui/crumbs/hig.py') diff --git a/bitbake/lib/bb/ui/crumbs/hig.py b/bitbake/lib/bb/ui/crumbs/hig.py index 016fb59acb..5cc8a5931a 100644 --- a/bitbake/lib/bb/ui/crumbs/hig.py +++ b/bitbake/lib/bb/ui/crumbs/hig.py @@ -30,6 +30,7 @@ import shlex from bb.ui.crumbs.hobcolor import HobColors from bb.ui.crumbs.hobwidget import hcc, hic, HobViewTable, HobInfoButton, HobButton, HobAltButton, HobIconChecker from bb.ui.crumbs.progressbar import HobProgressBar +import bb.ui.crumbs.utils """ The following are convenience classes for implementing GNOME HIG compliant @@ -739,9 +740,10 @@ class DeployImageDialog (CrumbsDialog): if response_id == gtk.RESPONSE_YES: combo_item = self.usb_combo.get_active_text() if combo_item and combo_item != self.__dummy_usb__: - cmdline = "/usr/bin/xterm -e " - cmdline += "\"sudo dd if=" + self.image_path + " of=" + combo_item + "; bash\"" - subprocess.Popen(args=shlex.split(cmdline)) + cmdline = bb.ui.crumbs.utils.which_terminal() + if cmdline: + cmdline += "\"sudo dd if=" + self.image_path + " of=" + combo_item + "\"" + subprocess.Popen(args=shlex.split(cmdline)) def update_progress_bar(self, title, fraction, status=None): self.progress_bar.update(fraction) -- cgit v1.2.3-54-g00ecf