Просмотр исходного кода

make console available from toolchain

mikymod 12 лет назад
Родитель
Сommit
4c82e90374
2 измененных файлов с 8 добавлено и 4 удалено
  1. 6 3
      tools/gui/toolchain/toolchain.py
  2. 2 1
      tools/gui/toolchain/ui/toolchain.glade

+ 6 - 3
tools/gui/toolchain/toolchain.py

@@ -76,11 +76,14 @@ class Toolchain:
 		root_path = str(self.m_root_path)
 		dest_path = root_path + "_" + self.m_current_platform
 
-		comp = subprocess.call(["python", "resource-compiler.py", str(self.m_root_path), self.m_current_platform])
-		crown = subprocess.call(["../bin/crown-linux", "--root-path", dest_path, "--dev"])
+		comp = subprocess.Popen(["python", "resource-compiler.py", str(self.m_root_path), self.m_current_platform])
+		crown = subprocess.Popen(["../bin/crown-linux", "--root-path", dest_path, "--dev"])
 
 	def on_browser_button_clicked(self, button):
-		browser = subprocess.call(["python", "resource-browser.py", str(self.m_root_path)])
+		browser = subprocess.Popen(["python", "resource-browser.py", str(self.m_root_path)])
+
+	def on_console_button_clicked(self, button):
+		console = subprocess.Popen(["python", "console.py", "localhost"])
 
 
 #------------------------------------------------------------------------------

+ 2 - 1
tools/gui/toolchain/ui/toolchain.glade

@@ -226,10 +226,11 @@
             </child>
             <child>
               <object class="GtkButton" id="button4">
-                <property name="label" translatable="yes">Something else</property>
+                <property name="label" translatable="yes">Console</property>
                 <property name="visible">True</property>
                 <property name="can_focus">True</property>
                 <property name="receives_default">True</property>
+                <signal name="clicked" handler="on_console_button_clicked" swapped="no"/>
               </object>
               <packing>
                 <property name="expand">False</property>