mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-21 04:45:31 +08:00
refs #335, GUI finetuning
* combo boxes, size model changed - fixes the issue with the settings exceeding the boundaries * main window can be minimized * renaming the main page * style sheet
This commit is contained in:
committed by
Roland Winklmeier
parent
216b9f170d
commit
6f8d85e864
@@ -36,11 +36,17 @@
|
|||||||
<number>0</number>
|
<number>0</number>
|
||||||
</property>
|
</property>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QScrollArea" name="sa_AudioSetup">
|
<widget class="QScrollArea" name="sa_AudioComponent">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
<property name="widgetResizable">
|
<property name="widgetResizable">
|
||||||
<bool>true</bool>
|
<bool>true</bool>
|
||||||
</property>
|
</property>
|
||||||
<widget class="QWidget" name="saAudioSetupInner">
|
<widget class="QWidget" name="sa_AudioComponentInner">
|
||||||
<property name="geometry">
|
<property name="geometry">
|
||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
@@ -53,6 +59,9 @@
|
|||||||
<property name="spacing">
|
<property name="spacing">
|
||||||
<number>0</number>
|
<number>0</number>
|
||||||
</property>
|
</property>
|
||||||
|
<property name="sizeConstraint">
|
||||||
|
<enum>QLayout::SetMaximumSize</enum>
|
||||||
|
</property>
|
||||||
<property name="leftMargin">
|
<property name="leftMargin">
|
||||||
<number>0</number>
|
<number>0</number>
|
||||||
</property>
|
</property>
|
||||||
@@ -65,6 +74,75 @@
|
|||||||
<property name="bottomMargin">
|
<property name="bottomMargin">
|
||||||
<number>0</number>
|
<number>0</number>
|
||||||
</property>
|
</property>
|
||||||
|
<item>
|
||||||
|
<widget class="QFrame" name="fr_AudioComponentInner">
|
||||||
|
<property name="frameShape">
|
||||||
|
<enum>QFrame::StyledPanel</enum>
|
||||||
|
</property>
|
||||||
|
<property name="frameShadow">
|
||||||
|
<enum>QFrame::Raised</enum>
|
||||||
|
</property>
|
||||||
|
<layout class="QVBoxLayout" name="vl_AudioComponentInner">
|
||||||
|
<property name="spacing">
|
||||||
|
<number>2</number>
|
||||||
|
</property>
|
||||||
|
<property name="leftMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="topMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="rightMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="bottomMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<item>
|
||||||
|
<layout class="QFormLayout" name="fl_AudioVolume">
|
||||||
|
<item row="0" column="0">
|
||||||
|
<widget class="QLabel" name="lbl_AudioSound">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>Sound:</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="1" column="0">
|
||||||
|
<widget class="QLabel" name="lbl_VolumeCom1">
|
||||||
|
<property name="text">
|
||||||
|
<string>Volume COM1:</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="1" column="1">
|
||||||
|
<widget class="QSlider" name="hs_VolumeCom1">
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="2" column="0">
|
||||||
|
<widget class="QLabel" name="lbl_VolumeCom2">
|
||||||
|
<property name="text">
|
||||||
|
<string>Volume COM2:</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="2" column="1">
|
||||||
|
<widget class="QSlider" name="hs_VolumeCom2">
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="BlackGui::Components::CAudioSetup" name="comp_AudioSetup">
|
<widget class="BlackGui::Components::CAudioSetup" name="comp_AudioSetup">
|
||||||
<property name="frameShape">
|
<property name="frameShape">
|
||||||
@@ -77,6 +155,9 @@
|
|||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
|
|||||||
@@ -60,7 +60,17 @@
|
|||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="0" column="1">
|
<item row="0" column="1">
|
||||||
<widget class="QComboBox" name="cb_SetupAudioInputDevice"/>
|
<widget class="QComboBox" name="cb_SetupAudioInputDevice">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="sizeAdjustPolicy">
|
||||||
|
<enum>QComboBox::AdjustToMinimumContentsLength</enum>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="1" column="0">
|
<item row="1" column="0">
|
||||||
<widget class="QLabel" name="lbl_SetupAudioOutputDevice">
|
<widget class="QLabel" name="lbl_SetupAudioOutputDevice">
|
||||||
@@ -70,7 +80,17 @@
|
|||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="1" column="1">
|
<item row="1" column="1">
|
||||||
<widget class="QComboBox" name="cb_SetupAudioOutputDevice"/>
|
<widget class="QComboBox" name="cb_SetupAudioOutputDevice">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="sizeAdjustPolicy">
|
||||||
|
<enum>QComboBox::AdjustToMinimumContentsLength</enum>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="2" column="0">
|
<item row="2" column="0">
|
||||||
<widget class="QLabel" name="lbl_SetupAudioVoiceTests">
|
<widget class="QLabel" name="lbl_SetupAudioVoiceTests">
|
||||||
|
|||||||
@@ -540,7 +540,7 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item alignment="Qt::AlignRight">
|
||||||
<widget class="QPushButton" name="pb_ComPanelSelcalTest">
|
<widget class="QPushButton" name="pb_ComPanelSelcalTest">
|
||||||
<property name="sizePolicy">
|
<property name="sizePolicy">
|
||||||
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
|
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
|
||||||
@@ -552,7 +552,7 @@
|
|||||||
<string>test SELCAL</string>
|
<string>test SELCAL</string>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Test</string>
|
<string/>
|
||||||
</property>
|
</property>
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../../blackmisc/blackmisc.qrc">
|
<iconset resource="../../blackmisc/blackmisc.qrc">
|
||||||
|
|||||||
@@ -127,7 +127,7 @@
|
|||||||
<item row="3" column="0">
|
<item row="3" column="0">
|
||||||
<widget class="QLabel" name="lbl_SettingsFsxExistsSimconncetCfg">
|
<widget class="QLabel" name="lbl_SettingsFsxExistsSimconncetCfg">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>"simconnect.cfg" exists?</string>
|
<string>"simconnect.cfg"?</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
@@ -174,6 +174,9 @@
|
|||||||
</item>
|
</item>
|
||||||
<item row="0" column="0" colspan="2">
|
<item row="0" column="0" colspan="2">
|
||||||
<widget class="QLabel" name="lbl_HeaderFsxSimConnect">
|
<widget class="QLabel" name="lbl_HeaderFsxSimConnect">
|
||||||
|
<property name="toolTip">
|
||||||
|
<string>"simconnect.cfg" exists?</string>
|
||||||
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string><html><head/><body><p><span style=" font-size:10pt; font-weight:600;">FSX simconnect config files</span></p></body></html></string>
|
<string><html><head/><body><p><span style=" font-size:10pt; font-weight:600;">FSX simconnect config files</span></p></body></html></string>
|
||||||
</property>
|
</property>
|
||||||
|
|||||||
@@ -63,13 +63,20 @@
|
|||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="1" column="1">
|
<item row="1" column="1">
|
||||||
<widget class="QComboBox" name="cb_Plugins"/>
|
<widget class="QComboBox" name="cb_Plugins">
|
||||||
|
<property name="sizeAdjustPolicy">
|
||||||
|
<enum>QComboBox::AdjustToMinimumContentsLength</enum>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="2" column="0">
|
<item row="2" column="0">
|
||||||
<widget class="QLabel" name="lbl_TimeSync">
|
<widget class="QLabel" name="lbl_TimeSync">
|
||||||
<property name="text">
|
<property name="toolTip">
|
||||||
<string>Time synchronization</string>
|
<string>Time synchronization</string>
|
||||||
</property>
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>Time synch.</string>
|
||||||
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="2" column="1">
|
<item row="2" column="1">
|
||||||
|
|||||||
@@ -74,6 +74,7 @@ QAbstractScrollArea #pg_StatusPageConsole { background-color: black; }
|
|||||||
border-radius:3px;
|
border-radius:3px;
|
||||||
color: yellow;
|
color: yellow;
|
||||||
padding: 3px;
|
padding: 3px;
|
||||||
|
margin-right: 5px;
|
||||||
}
|
}
|
||||||
|
|
||||||
#wi_MainKeypadArea QPushButton {
|
#wi_MainKeypadArea QPushButton {
|
||||||
@@ -96,18 +97,23 @@ QAbstractScrollArea #pg_StatusPageConsole { background-color: black; }
|
|||||||
border-radius:3px;
|
border-radius:3px;
|
||||||
border-width: 0px;
|
border-width: 0px;
|
||||||
border-color: blue;
|
border-color: blue;
|
||||||
color: lightblue;
|
color: yellow;
|
||||||
padding: 1px;
|
padding: 1px;
|
||||||
margin: 2px;
|
margin: 2px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** fixes scroll area for audio setup and inner background **/
|
/** fixes scroll area for audio setup and inner background **/
|
||||||
#sa_AudioSetup { background-color: black; }
|
#sa_AudioSetup { background-color: black; }
|
||||||
#saAudioSetupInner {
|
#sa_AudioComponentInner {
|
||||||
background-image: url(:/textures/icons/textures/texture-inner.jpg);
|
background-image: url(:/textures/icons/textures/texture-inner.jpg);
|
||||||
background-color: black;
|
background-color: black;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** volume buttons **/
|
||||||
|
#wi_AudioSoundButtons QPushButton {
|
||||||
|
background-color: transparent;
|
||||||
|
}
|
||||||
|
|
||||||
/** COM panel **/
|
/** COM panel **/
|
||||||
#wip_CockpitComPanelShowHideBar QPushButton {
|
#wip_CockpitComPanelShowHideBar QPushButton {
|
||||||
background-color: transparent;
|
background-color: transparent;
|
||||||
@@ -252,6 +258,13 @@ QDoubleSpinBox {
|
|||||||
background: transparent;
|
background: transparent;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
QSpinBox {
|
||||||
|
border: 1px solid green;
|
||||||
|
border-radius: 5px;
|
||||||
|
padding: 1px;
|
||||||
|
background: transparent;
|
||||||
|
}
|
||||||
|
|
||||||
QMenuBar {
|
QMenuBar {
|
||||||
background-image: url(:/textures/icons/textures/texture-outer.jpg);
|
background-image: url(:/textures/icons/textures/texture-outer.jpg);
|
||||||
background-color: darkslategray;
|
background-color: darkslategray;
|
||||||
@@ -343,6 +356,7 @@ QScrollBar::sub-line:vertical {
|
|||||||
QHeaderView::section {
|
QHeaderView::section {
|
||||||
border: 1px solid black;
|
border: 1px solid black;
|
||||||
background-color: darkslategray;
|
background-color: darkslategray;
|
||||||
|
color: white; /** font **/
|
||||||
padding: 1px;
|
padding: 1px;
|
||||||
margin: 0px;
|
margin: 0px;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -37,7 +37,9 @@ using namespace BlackMisc::Hardware;
|
|||||||
* Constructor
|
* Constructor
|
||||||
*/
|
*/
|
||||||
MainWindow::MainWindow(GuiModes::WindowMode windowMode, QWidget *parent) :
|
MainWindow::MainWindow(GuiModes::WindowMode windowMode, QWidget *parent) :
|
||||||
QMainWindow(parent, windowMode == GuiModes::WindowFrameless ? (Qt::Window | Qt::FramelessWindowHint | Qt::WindowStaysOnTopHint) : (Qt::Tool | Qt::WindowStaysOnTopHint)),
|
QMainWindow(parent, windowMode == GuiModes::WindowFrameless ?
|
||||||
|
(Qt::Window | Qt::FramelessWindowHint | Qt::WindowStaysOnTopHint) :
|
||||||
|
(Qt::Tool | Qt::WindowStaysOnTopHint | Qt::WindowMinimizeButtonHint | Qt::WindowCloseButtonHint)),
|
||||||
ui(new Ui::MainWindow),
|
ui(new Ui::MainWindow),
|
||||||
m_windowMode(windowMode)
|
m_windowMode(windowMode)
|
||||||
{
|
{
|
||||||
@@ -154,7 +156,7 @@ void MainWindow::ps_setMainPage(bool start)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
this->ui->sw_MainMiddle->setCurrentIndex(MainPageFoo);
|
this->ui->sw_MainMiddle->setCurrentIndex(MainPageInfoArea);
|
||||||
|
|
||||||
if (sender == this->ui->pb_MainAircrafts)
|
if (sender == this->ui->pb_MainAircrafts)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -79,7 +79,7 @@ protected:
|
|||||||
enum MainPageIndex
|
enum MainPageIndex
|
||||||
{
|
{
|
||||||
MainPageCockpit = 0,
|
MainPageCockpit = 0,
|
||||||
MainPageFoo = 1
|
MainPageInfoArea = 1
|
||||||
};
|
};
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|||||||
@@ -461,7 +461,7 @@
|
|||||||
<enum>QFrame::NoFrame</enum>
|
<enum>QFrame::NoFrame</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="currentIndex">
|
<property name="currentIndex">
|
||||||
<number>1</number>
|
<number>0</number>
|
||||||
</property>
|
</property>
|
||||||
<widget class="QWidget" name="pg_Cockpit">
|
<widget class="QWidget" name="pg_Cockpit">
|
||||||
<layout class="QVBoxLayout" name="vl_CockpitPage">
|
<layout class="QVBoxLayout" name="vl_CockpitPage">
|
||||||
|
|||||||
@@ -49,7 +49,7 @@ void MainWindow::ps_onMenuClicked()
|
|||||||
}
|
}
|
||||||
else if (sender == this->ui->menu_FileFont)
|
else if (sender == this->ui->menu_FileFont)
|
||||||
{
|
{
|
||||||
this->ps_setMainPage(MainPageFoo);
|
this->ps_setMainPage(MainPageInfoArea);
|
||||||
this->ui->comp_MainInfoArea->selectSettingsTab(BlackGui::Components::CSettingsComponent::SettingTabGui);
|
this->ui->comp_MainInfoArea->selectSettingsTab(BlackGui::Components::CSettingsComponent::SettingTabGui);
|
||||||
}
|
}
|
||||||
else if (sender == this->ui->menu_FileClose)
|
else if (sender == this->ui->menu_FileClose)
|
||||||
|
|||||||
Reference in New Issue
Block a user