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
200
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
48
"Ya Ne Lochu Comp" Challenge.
allomov
1
91
Catch and Throw in Ruby
allomov
0
44
Mortal Rubizza
allomov
0
89
Рэмбовидная проблема: особенности развития открытых технологий
allomov
0
52
Vault-tec: Safest Future
allomov
0
250
Promises and Reality
allomov
1
53
Cloud Theory for Rubizza Classes
allomov
0
90
Антология деплоя
allomov
0
75
Other Decks in Technology
See All in Technology
クラウドネイティブ時代の 開発プロセス再設計 〜速さと品質を両立するには〜
moritamasami
0
120
Greenは本当にGreenか? - B/GデプロイとAPI自動テストで安心デプロイ
kaz29
0
130
Service Monitoring Platformについて
lycorptech_jp
PRO
0
360
AI時代のインシデント対応 〜時代を切り抜ける、組織アーキテクチャ〜
jacopen
4
140
AI × クラウドで シイタケの収穫時期を判定してみた
lamaglama39
1
390
国産クラウドを支える設計とチームの変遷 “技術・組織・ミッション”
kazeburo
4
8.8k
レガシーで硬直したテーブル設計から変更容易で柔軟なテーブル設計にする
red_frasco
4
580
TypeScript 6.0で非推奨化されるオプションたち
uhyo
15
5.1k
JavaScript パーサーに using 対応をする過程で与えたエコシステムへの影響
baseballyama
1
150
AI エージェントを評価するための温故知新と Spec Driven Evaluation
icoxfog417
PRO
2
720
プロダクト負債と歩む持続可能なサービスを育てるための挑戦
sansantech
PRO
1
970
AI エージェント活用のベストプラクティスと今後の課題
asei
2
300
Featured
See All Featured
Facilitating Awesome Meetings
lara
57
6.6k
Building Flexible Design Systems
yeseniaperezcruz
329
39k
Code Review Best Practice
trishagee
72
19k
Build your cross-platform service in a week with App Engine
jlugia
234
18k
Building Better People: How to give real-time feedback that sticks.
wjessup
370
20k
For a Future-Friendly Web
brad_frost
180
10k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
36
6.1k
Optimising Largest Contentful Paint
csswizardry
37
3.5k
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
35
3.2k
A Tale of Four Properties
chriscoyier
162
23k
How GitHub (no longer) Works
holman
315
140k
Connecting the Dots Between Site Speed, User Experience & Your Business [WebExpo 2025]
tammyeverts
10
680
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
đ