Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
小 白蛋
Intellij Community
Commits
cbbaa713
Commit
cbbaa713
authored
6 years ago
by
Egor Zhdan
Browse files
Options
Download
Email Patches
Plain Diff
OC-18001 Re-enable linux native menu in CLion except for Swift plugin users
parent
c9e22852
Branches unavailable
Tags unavailable
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
platform/platform-impl/src/com/intellij/openapi/wm/impl/GlobalMenuLinux.java
+8
-2
...mpl/src/com/intellij/openapi/wm/impl/GlobalMenuLinux.java
with
8 additions
and
2 deletions
+8
-2
platform/platform-impl/src/com/intellij/openapi/wm/impl/GlobalMenuLinux.java
+
8
-
2
View file @
cbbaa713
// Copyright 2000-2018 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package
com.intellij.openapi.wm.impl
;
import
com.intellij.ide.plugins.PluginManager
;
import
com.intellij.openapi.Disposable
;
import
com.intellij.openapi.actionSystem.AnAction
;
import
com.intellij.openapi.actionSystem.impl.ActionMenu
;
...
...
@@ -9,9 +10,9 @@ import com.intellij.openapi.actionSystem.impl.StubItem;
import
com.intellij.openapi.application.ApplicationManager
;
import
com.intellij.openapi.application.Experiments
;
import
com.intellij.openapi.diagnostic.Logger
;
import
com.intellij.openapi.extensions.PluginId
;
import
com.intellij.openapi.util.SystemInfo
;
import
com.intellij.openapi.util.registry.Registry
;
import
com.intellij.util.PlatformUtils
;
import
com.intellij.util.lang.UrlClassLoader
;
import
com.intellij.util.ui.UIUtil
;
import
com.sun.javafx.application.PlatformImpl
;
...
...
@@ -586,7 +587,7 @@ public class GlobalMenuLinux implements GlobalMenuLib.EventHandler, Disposable {
private
static
GlobalMenuLib
_loadLibrary
()
{
try
{
if
(!
SystemInfo
.
isLinux
||
Registry
.
is
(
"linux.native.menu.force.disable"
)
||
PlatformUtils
.
isCLion
())
if
(!
SystemInfo
.
isLinux
||
Registry
.
is
(
"linux.native.menu.force.disable"
)
||
isCLionSwiftPluginInstalled
())
return
null
;
if
(!
Experiments
.
isFeatureEnabled
(
"linux.native.menu"
))
return
null
;
...
...
@@ -616,6 +617,11 @@ public class GlobalMenuLinux implements GlobalMenuLib.EventHandler, Disposable {
return
null
;
}
private
static
boolean
isCLionSwiftPluginInstalled
()
{
// Workaround OC-18001 CLion crashes after opening Swift project on Linux
return
PluginManager
.
isPluginInstalled
(
PluginId
.
getId
(
"com.intellij.clion-swift"
));
}
private
static
class
MenuItemInternal
{
final
int
rootPos
;
final
int
uid
;
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
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
Menu
Projects
Groups
Snippets
Help