mirror of
https://github.com/processing/processing4.git
synced 2026-06-16 04:26:26 +02:00
Merge branch 'master' of github.com:processing/processing
This commit is contained in:
@@ -23,6 +23,7 @@
|
||||
package processing.app.platform;
|
||||
|
||||
import java.io.File;
|
||||
import java.awt.Toolkit;
|
||||
|
||||
import processing.app.Base;
|
||||
import processing.app.Platform;
|
||||
@@ -47,6 +48,20 @@ public class LinuxPlatform extends Platform {
|
||||
"placement. For more background, please read the wiki:\n" +
|
||||
"http://wiki.processing.org/w/Supported_Platforms#Linux", null);
|
||||
}
|
||||
//Set x11 WM_CLASS property which is
|
||||
//used as the application name by Gnome3
|
||||
//and other window managers
|
||||
try{
|
||||
Toolkit xToolkit = Toolkit.getDefaultToolkit();
|
||||
java.lang.reflect.Field awtAppClassNameField =
|
||||
xToolkit.getClass().getDeclaredField("awtAppClassName");
|
||||
awtAppClassNameField.setAccessible(true);
|
||||
awtAppClassNameField.set(xToolkit, "Processing");
|
||||
}
|
||||
catch(Exception e){
|
||||
//In case the implementation details change...
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user