2012年12月18日 星期二
2012年12月16日 星期日
test
#include <iostream>
#include <string>
using namespace std;
string GetName()
{
string FirstName, LastName, FN;
cout << "Employee's First Name: ";
cin >> FirstName;
cout << "Employee's Last Name: ";
cin >> LastName;
FN = FirstName + " " + LastName;
return FN;
}
int main()
{
string FullName;
double Hours;
double GetHours(string FullName);
FullName = GetName();
Hours = GetHours(FullName);
cout << "\nEmployee's Name: " << FullName;
cout << "\nWeekly Hours: " << Hours << " hours\n\n";
return 0;
}
double GetHours(string FullName)
{
double Mon, Tue, Wed, Thu, Fri, TotalHours;
cout << endl << FullName << "'s Weekly Hours\n";
cout << "Monday: ";
cin >> Mon;
cout << "Tuesday: ";
cin >> Tue;
cout << "Wednesday: ";
cin >> Wed;
cout << "Thursday: ";
cin >> Thu;
cout << "Friday: ";
cin >> Fri;
TotalHours = Mon + Tue + Wed + Thu + Fri;
return TotalHours;
}
2012年12月14日 星期五
2012年12月13日 星期四
Adobe AIR Native Extension (iOS)
Requirements
- Adobe AIR SDK 裡面的FlashRuntimeExtensions.jar (TODO)
- Xcode
- Xcode Template For Easily Creating iOS Adobe Air Native Extensions (ANE)
Reference (TODO)
Samples
- Native extensions for Adobe AIR(Offical)
- Native extensions for Adobe AIR(Un-Offical)
- Free AIR Native Extensions Collection
Step By Step(TODO)
Step By Step
01. 建立Cocoa Touch Static Library
02. 移除自動建立的.h檔
03. 將FlashRuntimeExtensions.h拷貝至.m檔相同目錄
04. 在.m檔中加入 #import "FlashRuntimeExtensions.h"
05. 根據FREFunction 函式定義, 實作FREFunction
06. 根據FREContextInitializer函式定義, 實作FREContextInitializer (mapping FREFunction)
07. 根據FREContextFinalizer 函式定義, 實作FREContextFinalizer
08. 根據FREInitializer 函式定義, 實作FREInitializer (mapping FREContextInitializer & FREContextFinalizer)
09. 根據FREFinalizer 函式定義, 實作FREFinalizer
10. Generating the compiled library(http://www.adobe.com/devnet/air/articles/building-ane-ios-android-pt3.html)
Debug(TODO)
訂閱:
文章 (Atom)