diff -Nru qtoctave-0.10.1/debian/changelog qtoctave-0.10.1/debian/changelog --- qtoctave-0.10.1/debian/changelog 2011-06-27 22:48:50.000000000 +0200 +++ qtoctave-0.10.1/debian/changelog 2011-09-14 11:25:00.000000000 +0200 @@ -1,3 +1,10 @@ +qtoctave (0.10.1-1ubuntu1) oneiric; urgency=low + + * New patch: no-native-menubars: do not export dock window menubars to Unity + panel (LP: #673210). + + -- Aurélien Gâteau Wed, 14 Sep 2011 11:20:16 +0200 + qtoctave (0.10.1-1) unstable; urgency=low [ Sébastien Villemot ] diff -Nru qtoctave-0.10.1/debian/patches/no-native-menubars qtoctave-0.10.1/debian/patches/no-native-menubars --- qtoctave-0.10.1/debian/patches/no-native-menubars 1970-01-01 01:00:00.000000000 +0100 +++ qtoctave-0.10.1/debian/patches/no-native-menubars 2011-09-14 12:21:47.000000000 +0200 @@ -0,0 +1,35 @@ +# Description: Do not export docked window menubars to desktop panel +# Author: Aurélien Gâteau +# Forwarded: Sent to http://groups.google.com/group/qtoctave-english +# Bug-Ubuntu: https://bugs.launchpad.net/appmenu-qt/+bug/673210 +Index: qtoctave-0.10.1/qtoctave/src/basewidget.cpp +=================================================================== +--- qtoctave-0.10.1.orig/qtoctave/src/basewidget.cpp 2011-01-06 22:48:07.000000000 +0100 ++++ qtoctave-0.10.1/qtoctave/src/basewidget.cpp 2011-09-14 11:03:11.000000000 +0200 +@@ -30,6 +30,7 @@ + //setFocusPolicy(Qt::StrongFocus); + session=NULL; + QWidget *central=new QWidget(this); ++ menuBar()->setNativeMenuBar(false); + setCentralWidget(central); + + QMenu *windows_menu=menuBar()->addMenu(tr("View")); +Index: qtoctave-0.10.1/qtoctave/src/mainwindow.cpp +=================================================================== +--- qtoctave-0.10.1.orig/qtoctave/src/mainwindow.cpp 2011-01-06 22:48:07.000000000 +0100 ++++ qtoctave-0.10.1/qtoctave/src/mainwindow.cpp 2011-09-14 12:03:14.000000000 +0200 +@@ -39,7 +39,13 @@ + setSession(session); + setWindowIcon(QIcon(QString(ICON_PATH) + "/qtoctave.png")); + +- menuBar()->clear(); ++ //The menubar provided by BaseWidget is set as not-native to avoid showing up ++ //in top-panel menubars on desktops like Unity, but we want a native menubar ++ //here, and we also want to get rid of the generic "View" item BaseWidget ++ //added to the menubar. Setting a new menubar is the simplest way to do this ++ //(the old one gets deleted). ++ //[1] https://bugs.launchpad.net/appmenu-qt/+bug/673210 ++ setMenuBar(new QMenuBar()); + + setWindowTitle("QtOctave ["+session->getProjectName()+"]"); + //resize(QSize(800, 600).expandedTo(minimumSizeHint())); diff -Nru qtoctave-0.10.1/debian/patches/series qtoctave-0.10.1/debian/patches/series --- qtoctave-0.10.1/debian/patches/series 2011-06-26 23:28:47.000000000 +0200 +++ qtoctave-0.10.1/debian/patches/series 2011-09-14 10:54:20.000000000 +0200 @@ -1,3 +1,4 @@ use_octave_htmldoc build-out-of-source build-widgetserver +no-native-menubars