summaryrefslogtreecommitdiff
path: root/client/netcom.cc
diff options
context:
space:
mode:
Diffstat (limited to 'client/netcom.cc')
-rw-r--r--client/netcom.cc6
1 files changed, 4 insertions, 2 deletions
diff --git a/client/netcom.cc b/client/netcom.cc
index b6b5bd9..18af92e 100644
--- a/client/netcom.cc
+++ b/client/netcom.cc
@@ -101,7 +101,7 @@ void NetCom::send(QVector< Widget* > widgets, QString macro, QString version)
printf("Socket state: %d\n", socket.state());
if(socket.state() != 3) printf("Socket state not connected: %s\n", socket.errorString().toStdString().c_str());
- if(qApp->activeWindow()) qApp->activeWindow()->setEnabled(false);
+ // if(qApp->activeWindow()) qApp->activeWindow()->setEnabled(false); // Moved down!
QDomDocument doc;
@@ -124,7 +124,7 @@ void NetCom::send(QVector< Widget* > widgets, QString macro, QString version)
while (i != widgets.end()) {
Widget* w = *i;
- if(!w->isDisabled()) {
+ if(!w->isDisabled() && w->getName() != "") {
QDomElement field_elem = doc.createElement("field");
field_elem.setAttribute("name", w->getName());
field_elem.setAttribute("value", w->getValue());
@@ -134,6 +134,8 @@ void NetCom::send(QVector< Widget* > widgets, QString macro, QString version)
i++;
}
+ if(qApp->activeWindow()) qApp->activeWindow()->setEnabled(false);
+
printf("\nSending commit:\n%s", doc.toString().toStdString().c_str());
socket.write(doc.toByteArray());