Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Rubymotion. Sugar for iOS.
Search
Aliaksandr Lomau
December 07, 2013
Technology
1
190
Rubymotion. Sugar for iOS.
Cocoaheads, Grodno, December, 2013
Aliaksandr Lomau
December 07, 2013
Tweet
Share
More Decks by Aliaksandr Lomau
See All by Aliaksandr Lomau
Fails Night
allomov
0
32
"Ya Ne Lochu Comp" Challenge.
allomov
1
80
Catch and Throw in Ruby
allomov
0
35
Mortal Rubizza
allomov
0
71
Рэмбовидная проблема: особенности развития открытых технологий
allomov
0
44
Vault-tec: Safest Future
allomov
0
190
Promises and Reality
allomov
1
49
Cloud Theory for Rubizza Classes
allomov
0
81
Антология деплоя
allomov
0
71
Other Decks in Technology
See All in Technology
バクラクのドキュメント解析技術と実データにおける課題 / layerx-ccc-winter-2024
shimacos
2
1.1k
終了の危機にあった15年続くWebサービスを全力で存続させる - phpcon2024
yositosi
20
19k
Amazon Kendra GenAI Index 登場でどう変わる? 評価から学ぶ最適なRAG構成
naoki_0531
0
120
生成AIをより賢く エンジニアのための RAG入門 - Oracle AI Jam Session #20
kutsushitaneko
4
260
10分で学ぶKubernetesコンテナセキュリティ/10min-k8s-container-sec
mochizuki875
3
360
TSKaigi 2024 の登壇から広がったコミュニティ活動について
tsukuha
0
160
LINEヤフーのフロントエンド組織・体制の紹介【24年12月】
lycorp_recruit_jp
0
530
複雑性の高いオブジェクト編集に向き合う: プラガブルなReactフォーム設計
righttouch
PRO
0
120
Fanstaの1年を大解剖! 一人SREはどこまでできるのか!?
syossan27
2
170
ハイテク休憩
sat
PRO
2
170
組織に自動テストを書く文化を根付かせる戦略(2024冬版) / Building Automated Test Culture 2024 Winter Edition
twada
PRO
17
4.8k
APIとはなにか
mikanichinose
0
100
Featured
See All Featured
4 Signs Your Business is Dying
shpigford
181
21k
A Tale of Four Properties
chriscoyier
157
23k
Six Lessons from altMBA
skipperchong
27
3.5k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
28
4.4k
Docker and Python
trallard
42
3.1k
Dealing with People You Can't Stand - Big Design 2015
cassininazir
365
25k
Building an army of robots
kneath
302
44k
The Straight Up "How To Draw Better" Workshop
denniskardys
232
140k
Visualization
eitanlees
146
15k
Making Projects Easy
brettharned
116
5.9k
How to Think Like a Performance Engineer
csswizardry
22
1.2k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
127
18k
Transcript
rubymotion Sugar for iOS
HELLO code1n « allomov đ
I will talk about rubymotion
I will talk about rubymotion RubyMotion Laurent Sansonetti
How it works? 1 2 3 4 RUBY CODE AST
(semantic tree) LLVM IR Machine code Ruby parser RubyMotion LLVM code generator
How it works? # Ruby "Hello BRUG".class.ancestors => [String, Comparable,
Object, Kernel, BasicObject] # RubyMotion "Hello BRUG".class.ancestors => [String, NSMutableString, NSString, Comparable, NSObject, Kernel] OBJECTS
Ruby is neat RubyMotion Objective-C
met aprogramming is almost magic
Objective-C <objc/runtime.h>
send def tableView(tableView, didSelectRowAtIndexPath:indexPath) menu_row = self.menu_items[indexPath.row] # => 'profile'
self.send("open_#{menu_row}") end ! def open_profile; #...; end def open_messages; #...; end ! def open_feed; # ...; end
method_missing Slide is missing Please, imagine suitable image
define_method module Mouth def self.can_say(name) define_method("say_#{name}") do name.upcase end end
end ! class Person include Mouth can_say :hello end ! person.say_hello # => "HELLO"
DSl Domain Specific Language
Teacup teacup :main_window do style :UILabel, text: 'Hello!' style :hi_button,
origin: [10, 10], title: 'Hi!' end
20.times do rmq.append(UIButton).tag(:foo).move(l: rand(200), t: rand(500), w: 80, h: 20).style
do |st| st.text = rand(200).to_s st.background_color = rmq.color.blue end end RMQ
REPL Wanna see some magic?
TDD RubyMotion integrates Bacon Bacon is small clone of the
popular RSpec it can simulate user behaviour on device
Game in 15 minutes?
REPL Wanna see some magic? AppStore
THANK YOU FOR YOUR ATTENTION. Bye ! code1n « allomov
đ