- new button to access owncloud
authorJosef Spillner <josef.spillner@tu-dresden.de>
Fri, 7 Feb 2014 08:15:47 +0000 (09:15 +0100)
committerJosef Spillner <josef.spillner@tu-dresden.de>
Fri, 7 Feb 2014 08:15:47 +0000 (09:15 +0100)
integration/nubigate

index f3c5172..469d49b 100755 (executable)
@@ -27,19 +27,22 @@ class NubiGatePanel(QtGui.QDialog):
                self.button_stop = QtGui.QPushButton("Cloud Storage Gateway Stop")
                self.progress = QtGui.QProgressBar()
 
-               self.button_gate_open = QtGui.QPushButton("Open Cloud Drive (WebDAV)")
-               self.button_gate_view = QtGui.QPushButton("View Files (Browser)")
-               self.button_gate_conf = QtGui.QPushButton("Configure (SSH CLI)")
-               self.button_gate_edit = QtGui.QPushButton("Use Editor (VNC GUI)")
+               self.button_gate_open = QtGui.QPushButton("Cloud Drive (WebDAV)")
+               self.button_gate_view = QtGui.QPushButton("Visualisation (Browser)")
+               self.button_gate_shar = QtGui.QPushButton("Sharing (Browser)")
+               self.button_gate_conf = QtGui.QPushButton("Settings (SSH)")
+               self.button_gate_edit = QtGui.QPushButton("Editor (VNC)")
 
                self.button_gate_open.setEnabled(False)
                self.button_gate_view.setEnabled(False)
+               self.button_gate_shar.setEnabled(False)
                self.button_gate_conf.setEnabled(False)
                self.button_gate_edit.setEnabled(False)
 
                hlayout = QtGui.QHBoxLayout()
                hlayout.addWidget(self.button_gate_open)
                hlayout.addWidget(self.button_gate_view)
+               hlayout.addWidget(self.button_gate_shar)
                hlayout.addWidget(self.button_gate_conf)
                hlayout.addWidget(self.button_gate_edit)
 
@@ -77,6 +80,7 @@ class NubiGatePanel(QtGui.QDialog):
 
                self.connect(self.button_gate_open, QtCore.SIGNAL("clicked()"), self, QtCore.SLOT("slot_button_gate_open()"))
                self.connect(self.button_gate_view, QtCore.SIGNAL("clicked()"), self, QtCore.SLOT("slot_button_gate_view()"))
+               self.connect(self.button_gate_shar, QtCore.SIGNAL("clicked()"), self, QtCore.SLOT("slot_button_gate_shar()"))
                self.connect(self.button_gate_conf, QtCore.SIGNAL("clicked()"), self, QtCore.SLOT("slot_button_gate_conf()"))
                self.connect(self.button_gate_edit, QtCore.SIGNAL("clicked()"), self, QtCore.SLOT("slot_button_gate_edit()"))
 
@@ -96,8 +100,10 @@ class NubiGatePanel(QtGui.QDialog):
 
                self.button_gate_open.setEnabled(True)
                self.button_gate_view.setEnabled(True)
-               self.button_gate_conf.setEnabled(True)
-               self.button_gate_edit.setEnabled(True)
+               self.button_gate_shar.setEnabled(True)
+               # FIXME: only works with private bridge to forward multiple ports
+               #self.button_gate_conf.setEnabled(True)
+               #self.button_gate_edit.setEnabled(True)
 
        @pyqtSlot()
        def slot_button_stop(self):
@@ -109,6 +115,7 @@ class NubiGatePanel(QtGui.QDialog):
 
                self.button_gate_open.setEnabled(False)
                self.button_gate_view.setEnabled(False)
+               self.button_gate_shar.setEnabled(False)
                self.button_gate_conf.setEnabled(False)
                self.button_gate_edit.setEnabled(False)
 
@@ -161,6 +168,10 @@ class NubiGatePanel(QtGui.QDialog):
                os.system("xdg-open http://localhost:18080/nubivis/")
 
        @pyqtSlot()
+       def slot_button_gate_shar(self):
+               os.system("xdg-open http://localhost:18080/owncloud/")
+
+       @pyqtSlot()
        def slot_button_gate_conf(self):
                os.system("xterm -T 'NubiGate Configuration' -e 'ssh -p 10022 root@localhost'")