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
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Tiago Bastos
April 08, 2013
Programming
98
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
290
Não está feito até estar testado
bastos
2
190
Other Decks in Programming
See All in Programming
jQueryをバージョンアップする前に使いたいjQuery Migrate
matsuo_atsushi
0
190
Old Dog, New Tricks: The Java 25 Reinvention - JNation
bazlur_rahman
0
150
Oxcを導入して開発体験が向上した話
yug1224
4
290
JavaDoc 再入門
nagise
0
300
正しくソフトウェアを作る、前提を疑うための認知の視点 / doubt-premise
minodriven
17
6.2k
今さら聞けないCancellationToken
htkym
0
220
These Five Tricks Can Make Your Apps Greener, Cheaper, & Nicer
hollycummins
0
280
RTSPクライアントを自作してみた話
simotin13
0
510
AIとASP.NET Coreで雑Webアプリを作った話
mayuki
0
430
Swiftのレキシカルスコープ管理
kntkymt
0
220
IBM Bobを活用したレガシーアプリの最新化
oniak3ibm
PRO
1
180
TAKTでAI駆動開発の品質を設計する
j5ik2o
6
1k
Featured
See All Featured
How to train your dragon (web standard)
notwaldorf
97
6.7k
Designing for Performance
lara
611
70k
SEO in 2025: How to Prepare for the Future of Search
ipullrank
3
3.5k
Introduction to Domain-Driven Design and Collaborative software design
baasie
1
820
Tell your own story through comics
letsgokoyo
1
950
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
122
22k
How to make the Groovebox
asonas
2
2.2k
Speed Design
sergeychernyshev
33
1.8k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
49
10k
Groundhog Day: Seeking Process in Gaming for Health
codingconduct
0
200
SEO Brein meetup: CTRL+C is not how to scale international SEO
lindahogenes
1
2.7k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
250
1.3M
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