Permalink
Browse files

on linux platform set special SWT appName because Ubuntu Unity hardcode

  • Loading branch information...
1 parent 1e80785 commit 04e943fabb91417574f52d0ee0a1f92d8ef7d89c @tka tka committed Apr 26, 2013
Showing with 9 additions and 0 deletions.
  1. +9 −0 src/swt_wrapper.rb
View
9 src/swt_wrapper.rb
@@ -14,11 +14,20 @@
arch="32"
end
+# for Ubuntu Unity, because they hard code the white list
+# http://bazaar.launchpad.net/~unity-team/unity/trunk/view/head:/panel/PanelTray.cpp#L33
+if org.jruby.platform.Platform::IS_LINUX
+ SWT_APP_NAME = "JavaEmbeddedFrame" # for Ubuntu Unity
+else
+ SWT_APP_NAME = "Fire.app"
+end
+
require "#{SWT_LIB_PATH}/swt_#{os}#{arch}"
module Swt
import org.eclipse.swt.SWT
import org.eclipse.swt.program.Program
+ import org.eclipse.swt.internal.gtk.OS if org.jruby.platform.Platform::IS_LINUX
module Widgets
import org.eclipse.swt.widgets.Button

0 comments on commit 04e943f

Please sign in to comment.