mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-12 07:15:34 +08:00
Ref T297, network setup form (dynamic offset times)
This commit is contained in:
@@ -13,19 +13,25 @@
|
|||||||
<property name="windowTitle">
|
<property name="windowTitle">
|
||||||
<string>Frame</string>
|
<string>Frame</string>
|
||||||
</property>
|
</property>
|
||||||
<property name="frameShape">
|
<layout class="QVBoxLayout" name="vl_SettingsNetworkComponent">
|
||||||
<enum>QFrame::StyledPanel</enum>
|
<item>
|
||||||
</property>
|
<widget class="QGroupBox" name="gb_Network">
|
||||||
<property name="frameShadow">
|
<property name="title">
|
||||||
<enum>QFrame::Raised</enum>
|
<string>Network</string>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QGridLayout" name="gridLayout">
|
<layout class="QVBoxLayout" name="vl_Network">
|
||||||
<item row="0" column="0" colspan="2">
|
<item>
|
||||||
|
<widget class="BlackGui::Editors::CNetworkSetupForm" name="ediitor_NetworkSetup"/>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
<widget class="QGroupBox" name="gb_Services">
|
<widget class="QGroupBox" name="gb_Services">
|
||||||
<property name="title">
|
<property name="title">
|
||||||
<string>Services</string>
|
<string>Services</string>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QVBoxLayout" name="verticalLayout">
|
<layout class="QVBoxLayout" name="vl_NetworkServices">
|
||||||
<item>
|
<item>
|
||||||
<widget class="BlackGui::Components::CSettingsVatsimReadersComponent" name="comp_ReaderSettings">
|
<widget class="BlackGui::Components::CSettingsVatsimReadersComponent" name="comp_ReaderSettings">
|
||||||
<property name="minimumSize">
|
<property name="minimumSize">
|
||||||
@@ -45,7 +51,7 @@
|
|||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="1" column="0">
|
<item>
|
||||||
<spacer name="vs_NetworkSettings">
|
<spacer name="vs_NetworkSettings">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Vertical</enum>
|
<enum>Qt::Vertical</enum>
|
||||||
@@ -67,6 +73,12 @@
|
|||||||
<header>blackgui/components/settingsvatsimreaderscomponent.h</header>
|
<header>blackgui/components/settingsvatsimreaderscomponent.h</header>
|
||||||
<container>1</container>
|
<container>1</container>
|
||||||
</customwidget>
|
</customwidget>
|
||||||
|
<customwidget>
|
||||||
|
<class>BlackGui::Editors::CNetworkSetupForm</class>
|
||||||
|
<extends>QFrame</extends>
|
||||||
|
<header>blackgui/editors/networksetupform.h</header>
|
||||||
|
<container>1</container>
|
||||||
|
</customwidget>
|
||||||
</customwidgets>
|
</customwidgets>
|
||||||
<resources/>
|
<resources/>
|
||||||
<connections/>
|
<connections/>
|
||||||
|
|||||||
35
src/blackgui/editors/networksetupform.cpp
Normal file
35
src/blackgui/editors/networksetupform.cpp
Normal file
@@ -0,0 +1,35 @@
|
|||||||
|
/* Copyright (C) 2018
|
||||||
|
* swift project Community / Contributors
|
||||||
|
*
|
||||||
|
* This file is part of swift Project. It is subject to the license terms in the LICENSE file found in the top-level
|
||||||
|
* directory of this distribution and at http://www.swift-project.org/license.html. No part of swift project,
|
||||||
|
* including this file, may be copied, modified, propagated, or distributed except according to the terms
|
||||||
|
* contained in the LICENSE file.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include "networksetupform.h"
|
||||||
|
#include "ui_networksetupform.h"
|
||||||
|
#include "guiutility.h"
|
||||||
|
|
||||||
|
using namespace BlackMisc;
|
||||||
|
|
||||||
|
namespace BlackGui
|
||||||
|
{
|
||||||
|
namespace Editors
|
||||||
|
{
|
||||||
|
CNetworkSetupForm::CNetworkSetupForm(QWidget *parent) :
|
||||||
|
CForm(parent),
|
||||||
|
ui(new Ui::CNetworkSetupForm)
|
||||||
|
{
|
||||||
|
ui->setupUi(this);
|
||||||
|
}
|
||||||
|
|
||||||
|
CNetworkSetupForm::~CNetworkSetupForm()
|
||||||
|
{ }
|
||||||
|
|
||||||
|
void CNetworkSetupForm::setReadOnly(bool readonly)
|
||||||
|
{
|
||||||
|
CGuiUtility::checkBoxReadOnly(ui->cb_DynamicOffsetTimes, readonly);
|
||||||
|
}
|
||||||
|
} // ns
|
||||||
|
} // ns
|
||||||
46
src/blackgui/editors/networksetupform.h
Normal file
46
src/blackgui/editors/networksetupform.h
Normal file
@@ -0,0 +1,46 @@
|
|||||||
|
/* Copyright (C) 2018
|
||||||
|
* swift project Community / Contributors
|
||||||
|
*
|
||||||
|
* This file is part of swift Project. It is subject to the license terms in the LICENSE file found in the top-level
|
||||||
|
* directory of this distribution and at http://www.swift-project.org/license.html. No part of swift project,
|
||||||
|
* including this file, may be copied, modified, propagated, or distributed except according to the terms
|
||||||
|
* contained in the LICENSE file.
|
||||||
|
*/
|
||||||
|
|
||||||
|
//! \file
|
||||||
|
|
||||||
|
#ifndef BLACKGUI_EDITORS_NETWORKSETUPFORM_H
|
||||||
|
#define BLACKGUI_EDITORS_NETWORKSETUPFORM_H
|
||||||
|
|
||||||
|
#include "form.h"
|
||||||
|
#include <QScopedPointer>
|
||||||
|
|
||||||
|
namespace Ui { class CNetworkSetupForm; }
|
||||||
|
namespace BlackGui
|
||||||
|
{
|
||||||
|
namespace Editors
|
||||||
|
{
|
||||||
|
//! Setup form
|
||||||
|
class CNetworkSetupForm : public CForm
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
|
||||||
|
public:
|
||||||
|
//! Constructor
|
||||||
|
explicit CNetworkSetupForm(QWidget *parent = nullptr);
|
||||||
|
|
||||||
|
//! Destructor
|
||||||
|
virtual ~CNetworkSetupForm() override;
|
||||||
|
|
||||||
|
//! \name Form class implementations
|
||||||
|
//! @{
|
||||||
|
virtual void setReadOnly(bool readonly) override;
|
||||||
|
//! @}
|
||||||
|
|
||||||
|
private:
|
||||||
|
QScopedPointer<Ui::CNetworkSetupForm> ui;
|
||||||
|
};
|
||||||
|
} // ns
|
||||||
|
} // ns
|
||||||
|
|
||||||
|
#endif // guard
|
||||||
28
src/blackgui/editors/networksetupform.ui
Normal file
28
src/blackgui/editors/networksetupform.ui
Normal file
@@ -0,0 +1,28 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<ui version="4.0">
|
||||||
|
<class>CNetworkSetupForm</class>
|
||||||
|
<widget class="QFrame" name="CNetworkSetupForm">
|
||||||
|
<property name="geometry">
|
||||||
|
<rect>
|
||||||
|
<x>0</x>
|
||||||
|
<y>0</y>
|
||||||
|
<width>118</width>
|
||||||
|
<height>31</height>
|
||||||
|
</rect>
|
||||||
|
</property>
|
||||||
|
<property name="windowTitle">
|
||||||
|
<string>Network offset times</string>
|
||||||
|
</property>
|
||||||
|
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||||
|
<item>
|
||||||
|
<widget class="QCheckBox" name="cb_DynamicOffsetTimes">
|
||||||
|
<property name="text">
|
||||||
|
<string>dynamic offset times</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
<resources/>
|
||||||
|
<connections/>
|
||||||
|
</ui>
|
||||||
Reference in New Issue
Block a user