Browse Source

Merge branch 'master' of github.com:Ultimaker/JediWifiPrintingPlugin

Jack Ha 8 years ago
parent
commit
d8d1bd92d3
3 changed files with 11 additions and 4 deletions
  1. 2 2
      DiscoverUM3Action.qml
  2. 1 1
      NetworkPrinterOutputDevice.py
  3. 8 1
      UM3InfoComponents.qml

+ 2 - 2
DiscoverUM3Action.qml

@@ -165,7 +165,7 @@ Cura.MachineAction
             Column
             {
                 width: parent.width * 0.5
-                visible: base.selectedPrinter
+                visible: base.selectedPrinter ? true : false
                 spacing: UM.Theme.getSize("default_margin").height
                 Label
                 {
@@ -220,7 +220,7 @@ Cura.MachineAction
                 Button
                 {
                     text: catalog.i18nc("@action:button", "Connect")
-                    enabled: base.selectedPrinter
+                    enabled: base.selectedPrinter ? true : false
                     onClicked: connectToPrinter()
                 }
             }

+ 1 - 1
NetworkPrinterOutputDevice.py

@@ -245,7 +245,7 @@ class NetworkPrinterOutputDevice(PrinterOutputDevice):
         self._authentication_state = auth_state
 
     @pyqtSlot()
-    def requestAuthentication(self, message_id, action_id):
+    def requestAuthentication(self, message_id = None, action_id = "Retry"):
         if action_id == "Request" or action_id == "Retry":
             self._authentication_failed_message.hide()
             self._not_authenticated_message.hide()

+ 8 - 1
UM3InfoComponents.qml

@@ -37,6 +37,7 @@ Item
             text: catalog.i18nc("@action:button", "Connect")
             style: UM.Theme.styles.sidebar_action_button
             onClicked: connectActionDialog.show()
+            enabled: true
             visible: !base.printerConnected
         }
     }
@@ -64,12 +65,18 @@ Item
         visible: isUM3
         Button
         {
-            height: UM.Theme.getSize("save_button_save_to_button").height
             tooltip: catalog.i18nc("@info:tooltip", "Send access request to the printer")
             text: catalog.i18nc("@action:button", "Request Access")
             onClicked: Cura.MachineManager.printerOutputDevices[0].requestAuthentication()
             visible: base.printerConnected && !base.printerAcceptsCommands
         }
+
+        Button
+        {
+            tooltip: catalog.i18nc("@info:tooltip", "Load the configuration of the printer into Cura")
+            text: catalog.i18nc("@action:button", "Activate Configuration")
+            visible: false
+        }
     }
 
     UM.I18nCatalog{id: catalog; name:"cura"}