Sha256: f3f0d4dc647db2ecbab5b3f7e51ac602436a4c990a2c471c2f0a6cfdb31a156d
Contents?: true
Size: 906 Bytes
Versions: 17
Compression:
Stored size: 906 Bytes
Contents
module Dedalus class ApplicationView < Joyce::ApplicationView def initialize(app) super(app) Dedalus.activate!(self) end def render compose(app_screen) end def click p [ :app_view_click ] composer.click_molecule(app_screen, [window.width, window.height], mouse_position: mouse_position) end def compose(screen) screen = composer.hover_molecule(screen, dimensions, mouse_position: mouse_position) composer.render!(screen, dimensions) # cursor.position = mouse_position # cursor.render end def dimensions [window.width, window.height] end def mouse_position if @application.window.fullscreen? x0,y0 = *super [ x0 * 2, y0 * 2 ] else super end end private def composer @composer ||= Dedalus::ApplicationViewComposer.new end end end
Version data entries
17 entries across 17 versions & 1 rubygems