require 'phi'
include Phi
require 'direct'

form1 = Direct::Form.new
draw1 = Direct::Draw.new form1
draw1.align = Phi::AL_CLIENT

draw1.on_click = proc do |sender|
  opts = draw1.options
  if opts.include? Direct::DO_FULL_SCREEN
    opts.delete Direct::DO_FULL_SCREEN
  else
    opts.push Direct::DO_FULL_SCREEN
  end
  draw1.options = opts
  draw1.init
end

form1.show
Phi.mainloop
