谁知道水球...

symbian生肖和星座计算函数
根据原文:/blog/145759
void CHumanClockContainer::GetZodica(TDes&
aZodiac,TInt aYear) const{&
&CDesCArrayFlat* array = new
(ELeave)CDesCArrayFlat(12);
{ "猴", "鸡", "狗", "猪", "鼠", "牛", "虎", "兔", "龙", "蛇", "马", "羊"
&array-&AppendL(_L("\x7334"));
&array-&AppendL(_L("\x9E21"));
&array-&AppendL(_L("\x72D7"));
&array-&AppendL(_L("\x732A"));
&array-&AppendL(_L("\x9F20"));
&array-&AppendL(_L("\x725B"));
&array-&AppendL(_L("\x864E"));
&array-&AppendL(_L("\x5154"));
&array-&AppendL(_L("\x9F99"));
&array-&AppendL(_L("\x86C7"));
&array-&AppendL(_L("\x9A6C"));
&array-&AppendL(_L("\x7F8A"));
&aZodiac.Copy(array-&MdcaPoint(aYear
% 12));& &
&& &delete
void CHumanClockContainer::GetConstellation(TDes&
aConstellation,const TDateTime& aDate)
&& &TInt month =
aDate.Month();& &
&& &TInt day =
aDate.Day();& &
constellationEdgeDay[] = { 20, 19, 21, 21, 21, 22, 23, 23, 23, 23,
&CDesCArrayFlat* constellationArr = new
(ELeave)CDesCArrayFlat(12);
// { "水瓶座", "双鱼座", "牡羊座", "金牛座", "双子座", "巨蟹座", "狮子座", "处女座",
"天秤座",& &
// "天蝎座", "射手座", "魔羯座" };&&
&constellationArr-&AppendL(_L("\x6C34\x74F6"));
&constellationArr-&AppendL(_L("\x53CC\x9C7C"));
&constellationArr-&AppendL(_L("\xA"));
&constellationArr-&AppendL(_L("\x91D1\x725B"));
&constellationArr-&AppendL(_L("\x53CC\x5B50"));
&constellationArr-&AppendL(_L("\x5DE8\x87F9"));
&constellationArr-&AppendL(_L("\x72EE\x5B50"));
&constellationArr-&AppendL(_L("\x"));
&constellationArr-&AppendL(_L("\x"));
&constellationArr-&AppendL(_L("\xE"));
&constellationArr-&AppendL(_L("\x5C04\x624B"));
&constellationArr-&AppendL(_L("\x9B54\x7FAF"));
&& &if (day
& constellationEdgeDay[month]) {&
&month = month - 1;&
&& &if (month
&= 0) {& &
&aConstellation.Copy(constellationArr-&MdcaPoint(month))
&aConstellation.Copy(constellationArr-&MdcaPoint(11))
&aConstellation.Append(_L("\x5EA7"));
已投稿到:
以上网友发言只代表其个人观点,不代表新浪网的观点或立场。

参考资料

 

随机推荐