From: Harishankar Date: Thu, 25 Mar 2010 15:28:14 +0000 (+0530) Subject: Removed the confirmation dialog on encode X-Git-Url: https://harishankar.org/repos/?p=biamove.git;a=commitdiff_plain;h=2136857e26a118c5a15ef67a41612a4f73830ad5;hp=81d67ae9cd2c27ac180871c69be6dcf79e8daf88 Removed the confirmation dialog on encode Removed the confirmation dialog on encode because of a tkinter bug. --- diff --git a/mainwindow.py b/mainwindow.py index f696d69..821207d 100644 --- a/mainwindow.py +++ b/mainwindow.py @@ -89,19 +89,21 @@ class MainWindow (Tkinter.Frame): tkMessageBox.showerror ("Cannot encode", "No input and/or output file specified") else: commandlist = self.build_mencoder_command () - - if tkMessageBox.askyesno ("Confirm", "Are you sure you wish to encode (in *NIX you must have TERM environment variable set)?"): - if sys.platform.startswith ('win'): - po, pi = os.popen2 ("cmd /K " + subprocess.list2cmdline (commandlist)) - else: - if "TERM" in os.environ: - if os.environ["TERM"] == "xterm": - term_command = os.environ["TERM"] + " -hold -e " + subprocess.list2cmdline (commandlist) - else: - term_command = os.environ["TERM"] + " -e " + subprocess.list2cmdline(commandlist) - po, pi = os.popen2 (term_command) + + # this line is commented out because the confirmation dialog box is not working properly + # TKinter bug... +# if tkMessageBox.askyesno ("Confirm", "Are you sure you wish to encode (in *NIX you must have TERM environment variable set)?"): + if sys.platform.startswith ('win'): + po, pi = os.popen2 ("cmd /K " + subprocess.list2cmdline (commandlist)) + else: + if "TERM" in os.environ: + if os.environ["TERM"] == "xterm": + term_command = os.environ["TERM"] + " -hold -e " + subprocess.list2cmdline (commandlist) else: - tkMessageBox.showerror ("Cannot encode", "The TERM environment variable is not set. Cannot find a suitable terminal.") + term_command = os.environ["TERM"] + " -e " + subprocess.list2cmdline(commandlist) + po, pi = os.popen2 (term_command) + else: + tkMessageBox.showerror ("Cannot encode", "The TERM environment variable is not set. Cannot find a suitable terminal.") def on_save_profile (self): """ Called when the save profile button is clicked""" diff --git a/mainwindow.pyc b/mainwindow.pyc index 6c7e9df..8ccc363 100644 Binary files a/mainwindow.pyc and b/mainwindow.pyc differ