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 - Ruby <3 iOS
Search
Tiago Bastos
April 08, 2013
Programming
100
5
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Rubymotion - Ruby <3 iOS
Tiago Bastos
April 08, 2013
More Decks by Tiago Bastos
See All by Tiago Bastos
Ruby & Elixir - Real time applications
bastos
4
300
Não está feito até estar testado
bastos
2
190
Other Decks in Programming
See All in Programming
5分で問診!Composer セキュリティ健康診断
codmoninc
0
580
Apache Hive: Toward a Cloud Native Lakehouse
okumin
0
160
ソフトウェア設計に溶けるインフラ ― AWS CDK のインフラ認識論
konokenj
2
630
Lean は証明の正しさを確認するためだけのツールって思ってませんか?
inoueasei
1
110
為什麼你並不需要ViewModel / No, you don't need a ViewModel
lovee
1
300
Laravelで学ぶ Webアプリケーションチューニング入門/web_application_tuning_101
hanhan1978
4
1.3k
任せる範囲はこう広がった / How the Scope of AI Delegation Has Expanded
nrslib
1
270
型も通る、synthも通る、それでも危ない 〜AIのCDKの権限とコストを機械で検証する〜 / It Passes Type Checks, It Passes Synth Checks, but It’s Still Risky — Automatically Verifying Permissions and Costs in AI’s CDK —
seike460
PRO
1
420
共通化で考えるべきは、実装より公開する型だった
codeegg
0
270
初めてのKubernetes 本番運用でハマった話
oku053
0
130
Augmenting AI with the Power of Jakarta EE
ivargrimstad
0
180
地域 SRE コミュニティ最前線 - ホンマでっかSRE勉強会
tk3fftk
0
270
Featured
See All Featured
Future Trends and Review - Lecture 12 - Web Technologies (1019888BNR)
signer
PRO
0
3.6k
For a Future-Friendly Web
brad_frost
183
10k
Paper Plane
katiecoart
PRO
2
52k
The SEO identity crisis: Don't let AI make you average
varn
0
520
brightonSEO & MeasureFest 2025 - Christian Goodrich - Winning strategies for Black Friday CRO & PPC
cargoodrich
3
750
The Language of Interfaces
destraynor
162
27k
From π to Pie charts
rasagy
0
240
The Organizational Zoo: Understanding Human Behavior Agility Through Metaphoric Constructive Conversations (based on the works of Arthur Shelley, Ph.D)
kimpetersen
PRO
0
390
Into the Great Unknown - MozCon
thekraken
41
2.6k
How to train your dragon (web standard)
notwaldorf
97
6.7k
A brief & incomplete history of UX Design for the World Wide Web: 1989–2019
jct
2
420
Measuring & Analyzing Core Web Vitals
bluesmoon
9
900
Transcript
Rubymotion Ruby <3 iOS Monday, 8 April 13
Tiago Bastos • @bastos • github/bastos •
[email protected]
Monday, 8
April 13
Monday, 8 April 13
Why? • Ruby • Ruby • Ruby • Nativo •
Ferramentas Monday, 8 April 13
Why? • Ruby • Ruby • Ruby • Nativo •
Ferramentas (VIM) Monday, 8 April 13
Nativo? Monday, 8 April 13
NATIVO Monday, 8 April 13
LLVM Monday, 8 April 13
Monday, 8 April 13
Runtime Unificada Monday, 8 April 13
Mais • Gerenciamento de memória ARC Like • Concorrência (GCD)
• Rápido (já falei, nativo!) • App Store (TM) Safe Monday, 8 April 13
Ruby Monday, 8 April 13
Ruby • Módulos (Namespace) • Re exão e meta programação
• O Ruby que você conhece, Menos Eval • DSLs Monday, 8 April 13
DSLs e Wrappers • Teacup • SugarCube • Bubblewrap Monday,
8 April 13
Monday, 8 April 13
class MyController < UIViewController stylesheet :main_screen layout do
subview(UIButton, :finished_button) end end Monday, 8 April 13
Teacup::Stylesheet.new :main_screen do style :finished_button, origin:
[10, 10], title: 'Hi!' end Monday, 8 April 13
[[UIApplication sharedApplication] openURL:[NSURL URLWithString: @"https://github.com"]]; Monday, 8 April 13
"https://github.com".nsurl.open Monday, 8 April 13
UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"Do you want to
say hello?" message:@"More info..." delegate:self cancelButtonTitle:@"Cancel" otherButtonTitles:@"Say Hello",nil]; [alert show]; -‐ (void)alertView:(UIAlertView *)alertView didDismissWithButtonIndex:(NSInteger)buttonIndex { if (buttonIndex == 0) { NSLog(@"Cancel Tapped."); } else if (buttonIndex == 1) { NSLog(@"OK Tapped. Hello World!"); } } Monday, 8 April 13
UIAlertView.alert "Is this cool?", buttons: %w[No! Sure! Hmmmm],
message: "No going back now", cancel: proc { self.cancel }, success: proc { |pressed| self.proceed if pressed == "Sure!" } Monday, 8 April 13
UIView.animation_chain { view.slide(:left, 20) }.and_then { view.slide(:up, 20)
}.and_then { view.slide(:right, 20) }.and_then { view.slide(:down, 20) }.and_then { view.fade_out }.start Monday, 8 April 13
BW::Location.get do |result| p "From Lat #{result[:from].latitude}, Lng
#{result[:from].longitude}" p "To Lat #{result[:to].latitude}, Lng #{result[:to].longitude}" end Monday, 8 April 13
Testes Monday, 8 April 13
button = UIButton.buttonWithType(UIButtonTypeRoundedRect) button.setTitle('Take over the world', forState:UIControlStateNormal) window.addSubview(button)
tap 'Take over the world' Monday, 8 April 13
Mais! • Bootstrap Simples • Rubygems • Testes • Usar
bibliotecas em Objective-C (não é bridge!) Monday, 8 April 13
Ferramentas • Terminal based • Rake • Debugging (GDB based)
• Use seu Editor • CocoaPods Monday, 8 April 13
Monday, 8 April 13
Monday, 8 April 13
Monday, 8 April 13
app.version = '1.0.0' app.device_family = [:iphone] app.interface_orientations
= [:portrait] app.files += Dir.glob(File.join(app.project_dir, 'styles/**/*.rb')) app.development do app.codesign_certificate = "iPhone Developer: Tiago Bastos da Silva (HL4267W8QH)" app.provisioning_profile = File.expand_path("~/Library/MobileDevice/Provisioning Profiles/CE5529C9-‐0F02-‐40BA-‐ B2D9-‐8A342757DBB9.mobileprovision") end app.libs += %w(/usr/lib/libz.dylib /usr/lib/libsqlite3.dylib) app.pods do pod 'Facebook-‐iOS-‐SDK', '~> 3.2.1' pod 'MBProgressHUD' end app.frameworks += [ 'AudioToolbox', 'CFNetwork', 'CoreGraphics', 'CoreLocation', 'MobileCoreServices', 'QuartzCore', 'Security', 'StoreKit', 'SystemConfiguration', 'Accounts', 'AdSupport', 'Social' Monday, 8 April 13
Perguntas? Monday, 8 April 13
Perguntas? Não? Monday, 8 April 13
Perguntas? Não? Ok Monday, 8 April 13