Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
qgroundcontrol
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Valentin Platzgummer
qgroundcontrol
Commits
e1eb9f42
Commit
e1eb9f42
authored
Aug 05, 2014
by
Lorenz Meier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix native menu bar on Mac OS
parent
334f0187
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
14 deletions
+8
-14
MainWindow.cc
src/ui/MainWindow.cc
+6
-7
QGCWelcomeMainWindow.cc
src/ui/main/QGCWelcomeMainWindow.cc
+0
-1
QGCWelcomeMainWindow.ui
src/ui/main/QGCWelcomeMainWindow.ui
+2
-6
No files found.
src/ui/MainWindow.cc
View file @
e1eb9f42
...
@@ -186,15 +186,8 @@ void MainWindow::init()
...
@@ -186,15 +186,8 @@ void MainWindow::init()
// Setup user interface
// Setup user interface
ui
.
setupUi
(
this
);
ui
.
setupUi
(
this
);
hide
();
menuActionHelper
->
setMenu
(
ui
.
menuTools
);
menuActionHelper
->
setMenu
(
ui
.
menuTools
);
// Qt 4 on Ubuntu does place the native menubar correctly so on Linux we revert back to in-window menu bar.
// TODO: Check that this is still necessary on Qt5 on Ubuntu
#ifdef Q_OS_LINUX
menuBar
()
->
setNativeMenuBar
(
false
);
#endif
// Set dock options
// Set dock options
setDockOptions
(
AnimatedDocks
|
AllowTabbedDocks
|
AllowNestedDocks
);
setDockOptions
(
AnimatedDocks
|
AllowTabbedDocks
|
AllowNestedDocks
);
...
@@ -203,6 +196,12 @@ void MainWindow::init()
...
@@ -203,6 +196,12 @@ void MainWindow::init()
// Setup corners
// Setup corners
setCorner
(
Qt
::
BottomRightCorner
,
Qt
::
BottomDockWidgetArea
);
setCorner
(
Qt
::
BottomRightCorner
,
Qt
::
BottomDockWidgetArea
);
// Qt 4 on Ubuntu does place the native menubar correctly so on Linux we revert back to in-window menu bar.
// TODO: Check that this is still necessary on Qt5 on Ubuntu
#ifdef Q_OS_LINUX
menuBar
()
->
setNativeMenuBar
(
false
);
#endif
// Setup UI state machines
// Setup UI state machines
centerStackActionGroup
->
setExclusive
(
true
);
centerStackActionGroup
->
setExclusive
(
true
);
...
...
src/ui/main/QGCWelcomeMainWindow.cc
View file @
e1eb9f42
...
@@ -9,7 +9,6 @@ QGCWelcomeMainWindow::QGCWelcomeMainWindow(QWidget *parent) :
...
@@ -9,7 +9,6 @@ QGCWelcomeMainWindow::QGCWelcomeMainWindow(QWidget *parent) :
storeSettings
(
false
)
storeSettings
(
false
)
{
{
ui
->
setupUi
(
this
);
ui
->
setupUi
(
this
);
statusBar
()
->
hide
();
QString
windowname
=
qApp
->
applicationName
()
+
" "
+
qApp
->
applicationVersion
();
QString
windowname
=
qApp
->
applicationName
()
+
" "
+
qApp
->
applicationVersion
();
setWindowTitle
(
windowname
);
setWindowTitle
(
windowname
);
...
...
src/ui/main/QGCWelcomeMainWindow.ui
View file @
e1eb9f42
<?xml version="1.0" encoding="UTF-8"?>
<ui
version=
"4.0"
>
<ui
version=
"4.0"
>
<author/>
<comment/>
<exportmacro/>
<class>
QGCWelcomeMainWindow
</class>
<class>
QGCWelcomeMainWindow
</class>
<widget
class=
"QMainWindow"
name=
"QGCWelcomeMainWindow"
>
<widget
class=
"QMainWindow"
name=
"QGCWelcomeMainWindow"
>
<property
name=
"geometry"
>
<property
name=
"geometry"
>
...
@@ -15,10 +13,8 @@
...
@@ -15,10 +13,8 @@
<property
name=
"windowTitle"
>
<property
name=
"windowTitle"
>
<string>
MainWindow
</string>
<string>
MainWindow
</string>
</property>
</property>
<widget class="QMenuBar" name="menubar"/>
<widget
class=
"QWidget"
name=
"centralwidget"
/>
<widget
class=
"QWidget"
name=
"centralwidget"
/>
<widget class="QStatusBar" name="statusbar"/>
</widget>
</widget>
<
pixmapfunction
/>
<
resources
/>
<connections/>
<connections/>
</ui>
</ui>
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a 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