phonegapでハイブリッド開発 for firefox os
TRANSCRIPT
© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
PhoneGapでハイブリッド開発 for Firefox OS Andy Hall 開発エバンジェリスト、アドビジャパン
© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
だれだこいつ
@fenomas § 日本在住歴もFlash歴も十ん年 § 物理学専攻 → ウェブ制作 → Flash開発 → アドビで色々 § 現在の肩書がテクニカルエバンジェリスト § 興味はデザインとコードをまたぐところ § カタコトでゴメンね § ゲーム好き、などなど
© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
Hybridアプリは箱です。
HTML, JS, CSS など
ネイティブの シェルアプリ (WebViewを実装)
© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
Firefox OS
メリット1:クロスプラットフォーム
© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
Dreamweaver Muse
メリット2:デザインツールなど
© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
ツールの入手はCreative Cloudから
creative.adobe.com/
© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
Hybridアプリ難点
1.純HTML5からデバイス機能に アクセス出来なかったりする
CameraRoll
(または、出来るけどAPIが デバイス毎に変わる)
© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
Hybridアプリ難点
2.プラットフォーム毎に 箱の作り方が変わる
© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
PhoneGapとは、 難点を解決してくれる ハイブリッド開発 フレームワークのこと。
© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
PhoneGapの由来
iPhoneDevCampで始まった (2009) ニトビ社にて作られ
アドビ社にて買収され (2011)
© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
PhoneGapの特徴
無料 オープンソース
(Apache Cordovaとして)
© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
> sudo npm install –g cordova
© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
> cordova create appFolder com.hoge.app HogeApp > cd appFolder
© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
箱はこれ! 適当に
上書きしよう。
(後、Firefox OS用のconfig.xmlの追加など)
© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
> cordova platform add firefoxos > cordova prepare firefoxos
© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
> cordova platform add android > cordova run android
ほかに build、install
© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
実機
アプリ (HTML)
プラグイン設計
実機 実機
プラグイン
© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
実機
アプリ (HTML)
プラグイン設計
実機 実機
navigator.vibrate()
プラグイン
ネイティブAPI ネイティブAPI ネイティブAPI
© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
> cordova plugin add org.apache.cordova.device-motion
© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
ご清聴ありがとうございました!
phonegap.com/ html.adobe.com/jp
@fenomas
aphall.com/