Sha256: ec76f865f32dbc2b04ea0eb17d85e50c2d5650535709470d942ee9644611bb86

Contents?: true

Size: 1.17 KB

Versions: 77

Compression:

Stored size: 1.17 KB

Contents

module RubyApp

  module Elements

    module Mobile

      module Pages

        module Information
          require 'ruby_app/elements/mobile/dialogs/acknowledgement_dialog'
          require 'ruby_app/elements/mobile/navigation/back_button'
          require 'ruby_app/elements/mobile/pages/information/scripts_list'
          require 'ruby_app/elements/mobile/page'

          class ScriptsPage < RubyApp::Elements::Mobile::Page

            template_path(:all, File.dirname(__FILE__))

            def initialize
              super

              @back_button = RubyApp::Elements::Mobile::Navigation::BackButton.new

              @scripts_list = RubyApp::Elements::Mobile::Pages::Information::ScriptsList.new
              @scripts_list.item_clicked do |element, event|
                if RubyApp::Session.configuration.scripts.enabled
                  event.go(event.item.script.url)
                else
                  RubyApp::Elements::Mobile::Dialog.show(event, RubyApp::Elements::Mobile::Dialogs::AcknowledgementDialog.new('Scripts', 'Scripts are currently disabled.'))
                end
              end

            end

          end

        end

      end

    end

  end

end

Version data entries

77 entries across 77 versions & 1 rubygems

Version Path
RubyApp-0.6.38 lib/ruby_app/elements/mobile/pages/information/scripts_page.rb
RubyApp-0.6.36 lib/ruby_app/elements/mobile/pages/information/scripts_page.rb
RubyApp-0.6.35 lib/ruby_app/elements/mobile/pages/information/scripts_page.rb
RubyApp-0.6.34 lib/ruby_app/elements/mobile/pages/information/scripts_page.rb
RubyApp-0.6.33 lib/ruby_app/elements/mobile/pages/information/scripts_page.rb
RubyApp-0.6.32 lib/ruby_app/elements/mobile/pages/information/scripts_page.rb
RubyApp-0.6.31 lib/ruby_app/elements/mobile/pages/information/scripts_page.rb
RubyApp-0.6.29 lib/ruby_app/elements/mobile/pages/information/scripts_page.rb
RubyApp-0.6.28 lib/ruby_app/elements/mobile/pages/information/scripts_page.rb
RubyApp-0.6.27 lib/ruby_app/elements/mobile/pages/information/scripts_page.rb
RubyApp-0.6.26 lib/ruby_app/elements/mobile/pages/information/scripts_page.rb
RubyApp-0.6.25 lib/ruby_app/elements/mobile/pages/information/scripts_page.rb
RubyApp-0.6.24 lib/ruby_app/elements/mobile/pages/information/scripts_page.rb
RubyApp-0.6.22 lib/ruby_app/elements/mobile/pages/information/scripts_page.rb
RubyApp-0.6.21 lib/ruby_app/elements/mobile/pages/information/scripts_page.rb
RubyApp-0.6.16 lib/ruby_app/elements/mobile/pages/information/scripts_page.rb
RubyApp-0.6.12 lib/ruby_app/elements/mobile/pages/information/scripts_page.rb
RubyApp-0.6.11 lib/ruby_app/elements/mobile/pages/information/scripts_page.rb
RubyApp-0.6.10 lib/ruby_app/elements/mobile/pages/information/scripts_page.rb
RubyApp-0.6.8 lib/ruby_app/elements/mobile/pages/information/scripts_page.rb