Sha256: 6f00e3a042bd6281d0a6ea2d909202b7d5b4bd6fab1b1816ac219fc35be6140b

Contents?: true

Size: 719 Bytes

Versions: 2

Compression:

Stored size: 719 Bytes

Contents

require 'jruby'
require 'rbconfig'
org.jruby.ext.psych.PsychLibrary.new.load(JRuby.runtime, false)
$LOADED_FEATURES << 'psych.so'
$LOAD_PATH << File.join(Config::CONFIG['libdir'], 'ruby/1.9')
require 'psych.rb'

Psych::Parser
Psych::Handler

require 'ruboto'

ruboto_import_widgets :Button, :LinearLayout, :TextView

$activity.handle_create do |bundle|
  setTitle File.basename(__FILE__).chomp('_activity.rb').split('_').map { |s| "#{s[0..0].upcase}#{s[1..-1]}" }.join(' ')

  setup_content do
    linear_layout :orientation => LinearLayout::VERTICAL do
      @decoded_view = text_view :id => 42, :text => Psych.load('--- foo')
      # @encoded_view = text_view :id => 43, :text => Psych.dump("foo")
    end
  end

end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
ruboto-0.5.4 test/activity/psych_activity.rb
ruboto-0.5.3 test/activity/psych_activity.rb