Class: E

Inherits:
Z
  • Object
show all
Defined in:
app/controllers/e.rb

Constant Summary

Constants included from MotionAwesome

MotionAwesome::VERSION

Instance Attribute Summary

Attributes inherited from Z

#comp

Instance Method Summary collapse

Methods inherited from Z

#didRotateFromInterfaceOrientation, #initialize, #viewWillAppear

Methods included from MotionAwesome

attributed_text, button, button_types, font, hex_for_icon, label, map_types, parse_options, plist, xform_icon

Constructor Details

This class inherits a constructor from Z

Instance Method Details

#viewDidLoadObject



2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
# File 'app/controllers/e.rb', line 2

def viewDidLoad
  @comp = button( :github,
                  size:35,
                  text:%q{Fork it!},
                  color:0xD6FF18.uicolor,
                  type: :custom ) do |button|
    button.titleLabel.textColor = 0x2D31CE.uicolor
    button.titleLabel.font =
      UIFont.fontWithName( "Vermin Vibes Out Of Ink", size:55 )

    button.setBackgroundImage( UIImage.imageNamed( 'button-bg.png'),
                               forState: UIControlStateNormal )
    button.layer.cornerRadius  = 5
    button.layer.masksToBounds = true

    button.frame             = CGRectMake( 0, 0, 300, 70 )
    button.center            = center
    button.contentEdgeInsets = UIEdgeInsetsMake( 0, 0, 0, 0 )
    button.addTarget( self,
                      action: "callback:",
                      forControlEvents: UIControlEventTouchUpInside )
    self.view.addSubview( button )
  end
  super
end