mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-04 16:56:53 +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>
|
||||
</property>
|
||||
<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">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<widget class="QWidget" name="saAudioSetupInner">
|
||||
<widget class="QWidget" name="sa_AudioComponentInner">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
@@ -53,6 +59,9 @@
|
||||
<property name="spacing">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="sizeConstraint">
|
||||
<enum>QLayout::SetMaximumSize</enum>
|
||||
</property>
|
||||
<property name="leftMargin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
@@ -66,13 +75,85 @@
|
||||
<number>0</number>
|
||||
</property>
|
||||
<item>
|
||||
<widget class="BlackGui::Components::CAudioSetup" name="comp_AudioSetup">
|
||||
<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>
|
||||
<widget class="BlackGui::Components::CAudioSetup" name="comp_AudioSetup">
|
||||
<property name="frameShape">
|
||||
<enum>QFrame::StyledPanel</enum>
|
||||
</property>
|
||||
<property name="frameShadow">
|
||||
<enum>QFrame::Raised</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
|
||||
@@ -60,7 +60,17 @@
|
||||
</widget>
|
||||
</item>
|
||||
<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 row="1" column="0">
|
||||
<widget class="QLabel" name="lbl_SetupAudioOutputDevice">
|
||||
@@ -70,7 +80,17 @@
|
||||
</widget>
|
||||
</item>
|
||||
<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 row="2" column="0">
|
||||
<widget class="QLabel" name="lbl_SetupAudioVoiceTests">
|
||||
|
||||
@@ -540,7 +540,7 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<item alignment="Qt::AlignRight">
|
||||
<widget class="QPushButton" name="pb_ComPanelSelcalTest">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
|
||||
@@ -552,7 +552,7 @@
|
||||
<string>test SELCAL</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Test</string>
|
||||
<string/>
|
||||
</property>
|
||||
<property name="icon">
|
||||
<iconset resource="../../blackmisc/blackmisc.qrc">
|
||||
|
||||
@@ -127,7 +127,7 @@
|
||||
<item row="3" column="0">
|
||||
<widget class="QLabel" name="lbl_SettingsFsxExistsSimconncetCfg">
|
||||
<property name="text">
|
||||
<string>"simconnect.cfg" exists?</string>
|
||||
<string>"simconnect.cfg"?</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
@@ -174,6 +174,9 @@
|
||||
</item>
|
||||
<item row="0" column="0" colspan="2">
|
||||
<widget class="QLabel" name="lbl_HeaderFsxSimConnect">
|
||||
<property name="toolTip">
|
||||
<string>"simconnect.cfg" exists?</string>
|
||||
</property>
|
||||
<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>
|
||||
</property>
|
||||
|
||||
@@ -63,13 +63,20 @@
|
||||
</widget>
|
||||
</item>
|
||||
<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 row="2" column="0">
|
||||
<widget class="QLabel" name="lbl_TimeSync">
|
||||
<property name="text">
|
||||
<property name="toolTip">
|
||||
<string>Time synchronization</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Time synch.</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="1">
|
||||
|
||||
@@ -74,6 +74,7 @@ QAbstractScrollArea #pg_StatusPageConsole { background-color: black; }
|
||||
border-radius:3px;
|
||||
color: yellow;
|
||||
padding: 3px;
|
||||
margin-right: 5px;
|
||||
}
|
||||
|
||||
#wi_MainKeypadArea QPushButton {
|
||||
@@ -96,16 +97,21 @@ QAbstractScrollArea #pg_StatusPageConsole { background-color: black; }
|
||||
border-radius:3px;
|
||||
border-width: 0px;
|
||||
border-color: blue;
|
||||
color: lightblue;
|
||||
color: yellow;
|
||||
padding: 1px;
|
||||
margin: 2px;
|
||||
}
|
||||
|
||||
/** fixes scroll area for audio setup and inner background **/
|
||||
#sa_AudioSetup { background-color: black; }
|
||||
#saAudioSetupInner {
|
||||
background-image: url(:/textures/icons/textures/texture-inner.jpg);
|
||||
background-color: black;
|
||||
#sa_AudioComponentInner {
|
||||
background-image: url(:/textures/icons/textures/texture-inner.jpg);
|
||||
background-color: black;
|
||||
}
|
||||
|
||||
/** volume buttons **/
|
||||
#wi_AudioSoundButtons QPushButton {
|
||||
background-color: transparent;
|
||||
}
|
||||
|
||||
/** COM panel **/
|
||||
@@ -127,7 +133,7 @@ QAbstractScrollArea #pg_StatusPageConsole { background-color: black; }
|
||||
QProgressBar {
|
||||
border: 1px solid green;
|
||||
border-radius: 5px;
|
||||
background-color: black;
|
||||
background-color: black;
|
||||
text-align: center;
|
||||
padding: 0px;
|
||||
height: 16px;
|
||||
@@ -252,6 +258,13 @@ QDoubleSpinBox {
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
QSpinBox {
|
||||
border: 1px solid green;
|
||||
border-radius: 5px;
|
||||
padding: 1px;
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
QMenuBar {
|
||||
background-image: url(:/textures/icons/textures/texture-outer.jpg);
|
||||
background-color: darkslategray;
|
||||
@@ -343,7 +356,8 @@ QScrollBar::sub-line:vertical {
|
||||
QHeaderView::section {
|
||||
border: 1px solid black;
|
||||
background-color: darkslategray;
|
||||
padding: 1px;
|
||||
color: white; /** font **/
|
||||
padding: 1px;
|
||||
margin: 0px;
|
||||
}
|
||||
|
||||
|
||||
@@ -37,7 +37,9 @@ using namespace BlackMisc::Hardware;
|
||||
* Constructor
|
||||
*/
|
||||
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),
|
||||
m_windowMode(windowMode)
|
||||
{
|
||||
@@ -154,7 +156,7 @@ void MainWindow::ps_setMainPage(bool start)
|
||||
}
|
||||
else
|
||||
{
|
||||
this->ui->sw_MainMiddle->setCurrentIndex(MainPageFoo);
|
||||
this->ui->sw_MainMiddle->setCurrentIndex(MainPageInfoArea);
|
||||
|
||||
if (sender == this->ui->pb_MainAircrafts)
|
||||
{
|
||||
|
||||
@@ -78,8 +78,8 @@ protected:
|
||||
//! \remarks keep the values in sync with the real tab indexes
|
||||
enum MainPageIndex
|
||||
{
|
||||
MainPageCockpit = 0,
|
||||
MainPageFoo = 1
|
||||
MainPageCockpit = 0,
|
||||
MainPageInfoArea = 1
|
||||
};
|
||||
|
||||
private:
|
||||
|
||||
@@ -461,7 +461,7 @@
|
||||
<enum>QFrame::NoFrame</enum>
|
||||
</property>
|
||||
<property name="currentIndex">
|
||||
<number>1</number>
|
||||
<number>0</number>
|
||||
</property>
|
||||
<widget class="QWidget" name="pg_Cockpit">
|
||||
<layout class="QVBoxLayout" name="vl_CockpitPage">
|
||||
|
||||
@@ -49,7 +49,7 @@ void MainWindow::ps_onMenuClicked()
|
||||
}
|
||||
else if (sender == this->ui->menu_FileFont)
|
||||
{
|
||||
this->ps_setMainPage(MainPageFoo);
|
||||
this->ps_setMainPage(MainPageInfoArea);
|
||||
this->ui->comp_MainInfoArea->selectSettingsTab(BlackGui::Components::CSettingsComponent::SettingTabGui);
|
||||
}
|
||||
else if (sender == this->ui->menu_FileClose)
|
||||
|
||||
Reference in New Issue
Block a user