Join Now
Quality Rating:
  • Currently 0.0 / 5
(0.0 / 5 - 0 votes cast)
Expertise Level:
  • Currently 0.0 / 5
(0.0 / 5 - 0 votes cast)

This page was last modified 03:38, 29 June 2007.

如何保证主要程序在多个开发平台上都可使用

From Forum Nokia Wiki

开发者开发的跨平台程序可能融合了各平台不同的方法及属性,因此需要小心对待这样的情况。如需将程序设计为适应多平台特性,则需要做一些额外的工作。此外代码重用也是我们必须达到的目标之一。

我们可以通过标准预处理宏来解决跨平台的问题,这样我们即可为每个发行版本来分别编译了。

#ifdef __SERIES60_30__
    // call new supported method in Series 60 Developer Platform 3rd Edition
  #elif __SERIES60_20__
    // call new supported method in Series 60 Developer Platform 2nd Edition
  #else
    // call old supported method in Series 60 Developer Platform 1.0
  #endif
 
Powered by MediaWiki
     
     RDF Facets:
     
     
     qfnZtopicQUqfnTopicZseriesE5f60Q
     qfnZtypeQUqfnTypeZCommunityContentQ
     qfnZtypeQUqfnTypeZWebpageQ
     qfnZtypeQUqfnTypeZWikiContentQ
     qmarsZlanguageQUxhttpE3aE2fE2fswE2enokiaE2ecomE2flanguageE2d1E2fenX