Commit c90c55d4 authored by John Tapsell's avatar John Tapsell

CommConfigurationWindow - make it a proper QDialog, and not a floating widget

parent 13e5381d
...@@ -55,7 +55,7 @@ This file is part of the QGROUNDCONTROL project ...@@ -55,7 +55,7 @@ This file is part of the QGROUNDCONTROL project
#include "LinkManager.h" #include "LinkManager.h"
#include "MainWindow.h" #include "MainWindow.h"
CommConfigurationWindow::CommConfigurationWindow(LinkInterface* link, ProtocolInterface* protocol, QWidget *parent) : QWidget(parent) CommConfigurationWindow::CommConfigurationWindow(LinkInterface* link, ProtocolInterface* protocol, QWidget *parent) : QDialog(parent)
{ {
this->link = link; this->link = link;
......
...@@ -33,7 +33,7 @@ This file is part of the QGROUNDCONTROL project ...@@ -33,7 +33,7 @@ This file is part of the QGROUNDCONTROL project
#define _COMMCONFIGURATIONWINDOW_H_ #define _COMMCONFIGURATIONWINDOW_H_
#include <QObject> #include <QObject>
#include <QWidget> #include <QDialog>
#include <QAction> #include <QAction>
#include "LinkInterface.h" #include "LinkInterface.h"
#include "ProtocolInterface.h" #include "ProtocolInterface.h"
...@@ -62,7 +62,7 @@ enum qgc_protocol_t { ...@@ -62,7 +62,7 @@ enum qgc_protocol_t {
/** /**
* @brief Configuration window for communication links * @brief Configuration window for communication links
*/ */
class CommConfigurationWindow : public QWidget class CommConfigurationWindow : public QDialog
{ {
Q_OBJECT Q_OBJECT
......
...@@ -1683,7 +1683,7 @@ void MainWindow::addLink(LinkInterface *link) ...@@ -1683,7 +1683,7 @@ void MainWindow::addLink(LinkInterface *link)
if (!found) if (!found)
{ {
CommConfigurationWindow* commWidget = new CommConfigurationWindow(link, mavlink, NULL); CommConfigurationWindow* commWidget = new CommConfigurationWindow(link, mavlink, this);
commsWidgetList.append(commWidget); commsWidgetList.append(commWidget);
connect(commWidget,SIGNAL(destroyed(QObject*)),this,SLOT(commsWidgetDestroyed(QObject*))); connect(commWidget,SIGNAL(destroyed(QObject*)),this,SLOT(commsWidgetDestroyed(QObject*)));
QAction* action = commWidget->getAction(); QAction* action = commWidget->getAction();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment