forked from qt-creator/qt-creator
Restrict Unity workaround to Unity session
Allow explicit native menubar disabling as there are platforms with known broken implementations. Change-Id: Ice5fb1270969b422eb1a964fab5e305bc658c667 Reviewed-by: Orgad Shaneh <orgads@gmail.com> Reviewed-by: André Hartmann <aha_1980@gmx.de> Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
committed by
Orgad Shaneh
parent
e098134d43
commit
bf464875f6
@@ -298,8 +298,10 @@ void loadFonts()
|
||||
|
||||
int main(int argc, char **argv)
|
||||
{
|
||||
if (Utils::HostOsInfo::isLinuxHost())
|
||||
if (qEnvironmentVariableIsSet("QTCREATOR_DISABLE_NATIVE_MENUBAR")
|
||||
|| qgetenv("XDG_CURRENT_DESKTOP").startsWith("Unity")) {
|
||||
QApplication::setAttribute(Qt::AA_DontUseNativeMenuBar);
|
||||
}
|
||||
|
||||
Utils::TemporaryDirectory::setMasterTemporaryDirectory(QDir::tempPath() + "/" + Core::Constants::IDE_CASED_ID + "-XXXXXX");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user