mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-03-22 23:05:36 +08:00
refs #209, open directory of settings file in startup GUI
This commit is contained in:
@@ -2,8 +2,10 @@
|
||||
#include "ui_introwindow.h"
|
||||
#include "blackcore/dbus_server.h"
|
||||
#include "blackmisc/networkutils.h"
|
||||
#include "blackmisc/settingutilities.h"
|
||||
#include <QDesktopServices>
|
||||
#include <QUrl>
|
||||
#include <QDir>
|
||||
|
||||
/*
|
||||
* Constructor
|
||||
@@ -70,4 +72,9 @@ void CIntroWindow::buttonClicked() const
|
||||
{
|
||||
QDesktopServices::openUrl(QUrl("https://dev.vatsim-germany.org/", QUrl::TolerantMode));
|
||||
}
|
||||
else if (sender == this->ui->pb_SettingsDir)
|
||||
{
|
||||
QString path = QDir::toNativeSeparators(BlackMisc::Settings::CSettingUtilities::getSettingsDirectory());
|
||||
QDesktopServices::openUrl(QUrl("file:///" + path));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -188,9 +188,9 @@ voice included</string>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="pb_DeleteSettingsFile">
|
||||
<widget class="QPushButton" name="pb_SettingsDir">
|
||||
<property name="text">
|
||||
<string>del.settings</string>
|
||||
<string>settings dir.</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
@@ -256,8 +256,8 @@ voice included</string>
|
||||
<slot>accept()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>257</x>
|
||||
<y>230</y>
|
||||
<x>240</x>
|
||||
<y>290</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>157</x>
|
||||
@@ -272,8 +272,8 @@ voice included</string>
|
||||
<slot>reject()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>310</x>
|
||||
<y>230</y>
|
||||
<x>240</x>
|
||||
<y>290</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>286</x>
|
||||
@@ -304,8 +304,8 @@ voice included</string>
|
||||
<slot>buttonClicked()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>262</x>
|
||||
<y>58</y>
|
||||
<x>238</x>
|
||||
<y>75</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>322</x>
|
||||
@@ -313,6 +313,22 @@ voice included</string>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>pb_SettingsDir</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>CIntroWindow</receiver>
|
||||
<slot>buttonClicked()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>197</x>
|
||||
<y>97</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>86</x>
|
||||
<y>250</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
<slots>
|
||||
<slot>buttonClicked()</slot>
|
||||
|
||||
Reference in New Issue
Block a user