看了神之雫還有侍酒師就一直對酒很有興趣.
尤其是料理跟酒的結婚真是很有意思啊!
也想要自己試試弄些配酒的菜.
之前已經煎過牛排搭紅酒.
這次就煮白酒海鮮義大利麵啦!
材料:
1. 淡菜 *約300g
2. 花枝 *忘記多少
3. 洋蔥 *1/3個
4. 蒜頭 *4瓣
5. 辣椒 *2支
6. 白酒 *250ml
7. 義大利麵 *用的是圓條形的
白酒用的是澳洲Preece酒莊的Sauvignon Blanc(白蘇維翁),
酒標很漂亮*O*
其實入菜應該要買更便宜的,
但是有很怕直接喝會不好喝那就很殘念XD
步驟:
1. 洋蔥切丁, 蒜頭切塊, 辣椒切絲
2. 淡菜隔水解凍, 花枝切條
3. 水煮滾把義大利麵丟進去再加點鹽巴, 麵熟後撈起
4. 熱鍋加橄欖油, 蒜頭稍微爆香後把洋蔥丁放進去炒到透明
5. 把花枝跟淡菜丟入鍋中加白酒悶炒
6. 花枝淡菜(好像XD)熟了就先撈起來, 湯汁留著把麵加進去炒到稍微收乾
完成,
味道挺不錯的但是花枝煮太老=.=
飯後甜點:草莓
光吃這些果然不會飽啊XD
後來又去買了炸雞還有煮湯圓 囧
Monday, December 27, 2010
Wednesday, December 22, 2010
How to integrate iAd into your iPhone app
STEPS
1. add iAd framework to your project
(1) Right click Frameworks: Add\Existing Frameworks…
(2) Select "iAd.framework"
(3) "iAd.framework" has been added to your project
2. add ADBannerView to your view
Why it's important to implement ADBannerViewDelegate?
To detect the status of loading advertisement.
In some situation, ads might not be available.
That's why view controller hide ADBannerView after iAd been created in step 2.
When the advertisement has been successfully loaded (- (void)bannerViewDidLoadAd:(ADBannerView *)banner is called),
the view controller then make ADBannerView visible.
If advertisement is not available, ADBannerView will never show up.
Therefore, user will not see a blank area on ADBannerView.
Here's the image that illustrates ADBannerView is added to a view and advertisement is successfully loaded.
If user touch ADBannerView, a popup view will show up and details of the advertisement will be displayed.
After user close the popup view by touching (X), he will go back to the app directly.
reference:
1. Technical Q&A: Hiding iAd banners when ads are not available
2. iAd programming guide
3. How to integrate iAd into your iPhone app include details about:
- solution for setting target sdk < 4.0
- display iAd according to current orientation
- put iAd in table view
1. add iAd framework to your project
(1) Right click Frameworks: Add\Existing Frameworks…
(2) Select "iAd.framework"
(3) "iAd.framework" has been added to your project
2. add ADBannerView to your view
ADBannerView *iAd = [[ADBannerView alloc] initWithFrame:CGRectMake(x, y, w, h)];3. implement ADBannerViewDelegate
iAd.delegate = self;
[self.view addSubview:iAd];
iAd.hidden = YES;
- (void)bannerViewDidLoadAd:(ADBannerView *)banner {
banner.hidden = FALSE;
NSLog(@"bannerViewDidLoadAd");
}
- (BOOL)bannerViewActionShouldBegin:(ADBannerView *)banner willLeaveApplication:(BOOL)willLeave {
NSLog(@"bannerViewActionShouldBegin");
return YES;
}
- (void)bannerViewActionDidFinish:(ADBannerView *)banner {
NSLog(@"bannerViewActionDidFinish");
}
- (void)bannerView:(ADBannerView *)banner didFailToReceiveAdWithError:(NSError *)error {
banner.hidden = TRUE;
NSLog(@"didFailToReceiveAdWithError, error:%d ", [error code]);
}
Why it's important to implement ADBannerViewDelegate?
To detect the status of loading advertisement.
In some situation, ads might not be available.
That's why view controller hide ADBannerView after iAd been created in step 2.
When the advertisement has been successfully loaded (- (void)bannerViewDidLoadAd:(ADBannerView *)banner is called),
the view controller then make ADBannerView visible.
If advertisement is not available, ADBannerView will never show up.
Therefore, user will not see a blank area on ADBannerView.
Here's the image that illustrates ADBannerView is added to a view and advertisement is successfully loaded.
If user touch ADBannerView, a popup view will show up and details of the advertisement will be displayed.
After user close the popup view by touching (X), he will go back to the app directly.
reference:
1. Technical Q&A: Hiding iAd banners when ads are not available
2. iAd programming guide
3. How to integrate iAd into your iPhone app include details about:
- solution for setting target sdk < 4.0
- display iAd according to current orientation
- put iAd in table view
青花菜炒香菇... 還有紅蘿蔔
Sunday, December 19, 2010
Tuesday, December 07, 2010
Monday, December 06, 2010
上海市區趴趴走: 孫中山紀念館, 周恩來故居, 田子坊, 丹咖啡
離開人民公園之後來到思南路,
忘記是從地鐵哪一站冒出來開始走XD
雖然說思南路兩旁種滿了梧桐挺美的是條適合散步的路,
但是我們走了超級久都沒看到什麼餐廳.
餓到快升天了=.=
[孫中山紀念館] 香山路7號
好不容易走到孫中山紀念館,
孫中山先生翹腳坐在椅子上還挺帥氣低.
不過因為門票要錢而且急著想吃飯就沒進去參觀囉!
[周公館] 思南路73號
沿著思南路繼續走沒多久來到周恩來故居又稱為周公館.
門票不用錢所以所以我們跑進去晃了一圈,
周公館是棟三層樓的洋房,
一進門就可以看到藤蔓攀爬在花架上,
後院有個綠油油的草坪還挺幽靜的.
[田子坊]
接著又繼續努力的走終於到了田子坊.
這裡有許多創意小店.
在覓食的途中看到幾個老井,
雖然今天一直下著綿綿細雨但是田子坊的人潮還是很多啊!
好不容易找到一間還有位子的餐廳.
[丹咖啡]
丹咖啡的老闆是日本人,
ㄧ樓的狹小的空間是老闆烘培咖啡豆的地方,
筷子套的前面折成鶴的樣子.
而且他是丹頂鶴優.
這是二三樓.
我們各自點了關東煮和漢堡排.
關東煮的沾醬是黃芥末挺特別低.
漢堡排超級好吃低.
可是某位先生只願意分我一口Q.Q
沙拉淋上的是胡麻醬!
吃飽之後樓下門口也都坐滿人啦!
吃飽之後就開始逛街 (飛舞)
在這家買了熊貓小龍/熊貓解放軍的便條紙還有個上海灘名片夾.
可是找不到拍的照片東西又都已經送出去惹=.=
就只能沒圖沒真相了.
在田子坊狹窄的巷弄穿梭,
樓舍間的上方有電線雜亂交錯著,
幾個鳥籠就這樣掛著.
其實還挺有生活的氣息.
因為雨還是持續的下,
我們就提早回到徐家匯啦!
忘記是從地鐵哪一站冒出來開始走XD
雖然說思南路兩旁種滿了梧桐挺美的是條適合散步的路,
但是我們走了超級久都沒看到什麼餐廳.
餓到快升天了=.=
[孫中山紀念館] 香山路7號
好不容易走到孫中山紀念館,
孫中山先生翹腳坐在椅子上還挺帥氣低.
不過因為門票要錢而且急著想吃飯就沒進去參觀囉!
[周公館] 思南路73號
沿著思南路繼續走沒多久來到周恩來故居又稱為周公館.
門票不用錢所以所以我們跑進去晃了一圈,
周公館是棟三層樓的洋房,
一進門就可以看到藤蔓攀爬在花架上,
後院有個綠油油的草坪還挺幽靜的.
[田子坊]
接著又繼續努力的走終於到了田子坊.
這裡有許多創意小店.
在覓食的途中看到幾個老井,
雖然今天一直下著綿綿細雨但是田子坊的人潮還是很多啊!
好不容易找到一間還有位子的餐廳.
[丹咖啡]
丹咖啡的老闆是日本人,
ㄧ樓的狹小的空間是老闆烘培咖啡豆的地方,
筷子套的前面折成鶴的樣子.
而且他是丹頂鶴優.
這是二三樓.
我們各自點了關東煮和漢堡排.
關東煮的沾醬是黃芥末挺特別低.
漢堡排超級好吃低.
可是某位先生只願意分我一口Q.Q
沙拉淋上的是胡麻醬!
吃飽之後樓下門口也都坐滿人啦!
吃飽之後就開始逛街 (飛舞)
在這家買了熊貓小龍/熊貓解放軍的便條紙還有個上海灘名片夾.
可是找不到拍的照片東西又都已經送出去惹=.=
就只能沒圖沒真相了.
在田子坊狹窄的巷弄穿梭,
樓舍間的上方有電線雜亂交錯著,
幾個鳥籠就這樣掛著.
其實還挺有生活的氣息.
因為雨還是持續的下,
我們就提早回到徐家匯啦!
Thursday, December 02, 2010
How to support facebook single sign-on in your iphone app
PREPARATION
1. download latest facebook sdk for iOS
2. register your application with facebook: http://www.facebook.com/developers/createapp.php
3. set name and picture for your application (for user to have an idea about the application they are going to authenticate)
HOW TO INTEGRATE FACEBOOK SDK WITH YOUR PROJECT
1. add source code under folder FBConnect to your project
2. include the FBConnect headers in your code
WHAT IS SINGLE SIGN-ON?
The new authentication mechanism that users no longer have to re-enter their credentials to authenticate each app if valid session already exists Facebook official app or Safari.
HOW SINGLE SIGN-ON WORKS?
It relies on iOS's fast app switching. Your app trigger FBApp/Safari for authentication. After the user grants or declines the authorization, the FBApp/Safari redirects back to your app, passing the authorization token, expiration, and any other parameters the Facebook OAuth server may return.
SINGLE SIGN-ON FLOW
SUPPORT SINGLE SIGN-ON
1. bind your app to a URL scheme corresponding to your Facebook application ID by modifying .plist file of your app
2. catch FBApp/Safari redirection by implementing this in your app's main AppDelegate
START AUTHENTICATION
1. call authorize method
HOW TO DISABLE SINGLE SIGN-ON?
1. in Facebook.m authorize method
ref: https://github.com/facebook/facebook-ios-sdk/
1. download latest facebook sdk for iOS
2. register your application with facebook: http://www.facebook.com/developers/createapp.php
3. set name and picture for your application (for user to have an idea about the application they are going to authenticate)
HOW TO INTEGRATE FACEBOOK SDK WITH YOUR PROJECT
1. add source code under folder FBConnect to your project
2. include the FBConnect headers in your code
#import "[RELATIVE_PATH]/FBConnect.h"3. init Facebook object
Facebook* facebook = [[Facebook alloc] init];
WHAT IS SINGLE SIGN-ON?
The new authentication mechanism that users no longer have to re-enter their credentials to authenticate each app if valid session already exists Facebook official app or Safari.
HOW SINGLE SIGN-ON WORKS?
It relies on iOS's fast app switching. Your app trigger FBApp/Safari for authentication. After the user grants or declines the authorization, the FBApp/Safari redirects back to your app, passing the authorization token, expiration, and any other parameters the Facebook OAuth server may return.
SINGLE SIGN-ON FLOW
SUPPORT SINGLE SIGN-ON
1. bind your app to a URL scheme corresponding to your Facebook application ID by modifying .plist file of your app
2. catch FBApp/Safari redirection by implementing this in your app's main AppDelegate
- (BOOL)application:(UIApplication *)application handleOpenURL:(NSURL *)url{
[facebook handleOpenURL:url];
}
START AUTHENTICATION
1. call authorize method
[facebook authorize:{YOUR_APP_ID} permissions:{PERMISSIONS} delegate:self];
HOW TO DISABLE SINGLE SIGN-ON?
1. in Facebook.m authorize method
[self authorizeWithFBAppAuth:NO safariAuth:NO];
ref: https://github.com/facebook/facebook-ios-sdk/
Subscribe to:
Posts (Atom)