Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Valentin Platzgummer
qgroundcontrol
Commits
6a5e0f49
Commit
6a5e0f49
authored
May 14, 2010
by
pixhawk
Browse files
Fixed path dependency in audio output, added settings for main window
parent
4f579073
Changes
3
Hide whitespace changes
Inline
Side-by-side
src/GAudioOutput.cc
View file @
6a5e0f49
...
...
@@ -165,10 +165,11 @@ bool GAudioOutput::alert(QString text)
if
(
!
emergency
)
{
// Play alert sound
m_media
->
setCurrentSource
(
Phonon
::
MediaSource
(
QString
(
"alert.wav"
).
toStdString
().
c_str
()));
QString
alertFile
=
QCoreApplication
::
applicationDirPath
()
+
"alert.wav"
;
m_media
->
setCurrentSource
(
Phonon
::
MediaSource
(
alertFile
.
toStdString
().
c_str
()));
qDebug
()
<<
"FILENAME:"
<<
m_media
->
currentSource
().
fileName
();
qDebug
()
<<
"TYPE:"
<<
m_media
->
currentSource
().
type
();
qDebug
()
<<
QString
(
"alert.wav"
)
.
toStdString
().
c_str
();
qDebug
()
<<
alertFile
.
toStdString
().
c_str
();
m_media
->
play
();
m_media
->
setCurrentSource
(
Phonon
::
MediaSource
(
QString
(
"alert.wav"
).
toStdString
().
c_str
()));
m_media
->
play
();
...
...
src/ui/MainWindow.cc
View file @
6a5e0f49
...
...
@@ -58,19 +58,13 @@ This file is part of the QGROUNDCONTROL project
*
* @see QMainWindow::show()
**/
MainWindow
::
MainWindow
(
QWidget
*
parent
)
:
QMainWindow
(
parent
)
MainWindow
::
MainWindow
(
QWidget
*
parent
)
:
QMainWindow
(
parent
),
settings
()
{
this
->
hide
();
this
->
setVisible
(
false
);
// Quick hack
//comp = new LogCompressor("/home/pixhawk/Desktop/test.txt");
mavlink
=
new
MAVLinkProtocol
();
//as4link = new AS4Protocol();
// MG::DISPLAY::setPixelSize(0.224f);
// Setup user interface
ui
.
setupUi
(
this
);
...
...
@@ -107,6 +101,9 @@ MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent)
acceptList
->
append
(
"roll IMU"
);
acceptList
->
append
(
"pitch IMU"
);
acceptList
->
append
(
"yaw IMU"
);
acceptList
->
append
(
"vx"
);
acceptList
->
append
(
"vy"
);
acceptList
->
append
(
"vz"
);
headDown1
=
new
HDDisplay
(
acceptList
,
this
);
headDown1
->
setVisible
(
false
);
...
...
@@ -502,6 +499,11 @@ void MainWindow::loadEngineerView()
this
->
show
();
}
void
MainWindow
::
loadAllView
()
{
}
void
MainWindow
::
loadWidgets
()
{
loadOperatorView
();
...
...
src/ui/MainWindow.h
View file @
6a5e0f49
...
...
@@ -34,6 +34,7 @@ This file is part of the PIXHAWK project
#include
<QtGui/QMainWindow>
#include
<QStatusBar>
#include
<QStackedWidget>
#include
<QSettings>
#include
"ui_MainWindow.h"
#include
"LinkManager.h"
...
...
@@ -75,6 +76,7 @@ public:
MainWindow
(
QWidget
*
parent
=
0
);
~
MainWindow
();
QSettings
settings
;
UASControlWidget
*
control
;
LinechartWidget
*
linechart
;
UASInfoWidget
*
info
;
...
...
@@ -128,6 +130,8 @@ public slots:
void
loadOperatorView
();
/** @brief Load view for general settings */
void
loadSettingsView
();
/** @brief Load view with all widgets */
void
loadAllView
();
void
reloadStylesheet
();
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment