lib/shoes/swt.rb in shoes-swt-4.0.0.pre4 vs lib/shoes/swt.rb in shoes-swt-4.0.0.pre5

- old
+ new

@@ -54,11 +54,10 @@ require 'shoes/swt/disposed_protection' require 'shoes/swt/click_listener' require 'shoes/swt/color' require 'shoes/swt/color_factory' - require 'shoes/swt/common/child' require 'shoes/swt/common/remove' require 'shoes/swt/common/clickable' require 'shoes/swt/common/container' require 'shoes/swt/common/fill' require 'shoes/swt/common/resource' @@ -120,20 +119,21 @@ require 'shoes/swt/tooling/leak_hunter' if ENV["LEAK_HUNTER"] # redrawing aspect needs to know all the classes require 'shoes/swt/redrawing_aspect' + ::Shoes::Swt::App.setup_system_colors @initialized = true rescue Java::OrgEclipseSwt::SWTException => e if e.message == "Invalid thread access" puts "Ooops, we couldn't start properly. We'll try again." puts "" puts "To avoid this restarting behavior, try one of the following:" puts " * Use the shoes executable to start your app" puts " * Add JRUBY_OPTS='-J-XstartOnFirstThread' to your environment before starting." - `JRUBY_OPTS=-J-XstartOnFirstThread #{$0} #{ARGV.join(" ")}` - exit $?.exitstatus + `JRUBY_OPTS=-J-XstartOnFirstThread #{$PROGRAM_NAME} #{ARGV.join(" ")}` + exit $CHILD_STATUS.exitstatus end end end end