You Are Here:

Community: Wiki

This page was last modified on 29 August 2008, at 08:47.

多个html页面的WRT widget

From Forum Nokia Wiki


  有些widget的文档中说, WRT widget只能有一个html文件,这个主文件不能被其它html文件替换。

  但在widget的开发实践中, 也有些widget有多个html文件的。这会带来一些影响,需要考虑以下方面。

1. 导航路径的设计

  多个html页面应该部署在本地终端上,不能在网络服务器上。否则,如果导航到在网络側的页面,就没有办法返回widget主html页面。在本地的页面如果设计好导航路径,可以互相跳转。

2. javascript扩展对象的使用

  为了方便widget的开发,WRT支持widget,menu,menuitem等javascript对象。在widget主页面被替换或重新载入的情况下,如果是在emulator上测试,以上widget对象均为null。但是在实机上,这些javascript对象都能正常使用。

  根据有关widget文档,一个widget最好只有一个html页面。要实现多个页面互相切换的效果,可以在同一个页面内利用
标签实现多个视图,通过隐藏/显示视图达到同样的效果。

Related Wiki Articles

No related wiki articles found

Rate This

 
Bookmark this page: DeliciousDiggFacebookGoogleYahooStumbleUponRedditDiigoTechnocratiTwitter  Share this page Share this page Print this Page Print this page Invite a friend Invite a friend
京ICP备05048969号    Email Newsletters Press Terms & Conditions Privacy Policy Sitemap Contact Us © 2009 Nokia 
RDF Facets: qdcZidentifierQSxhttpE3aE2fE2fwikiE2eforumE2enokiaE2ecomE2findeE78E2ephpE2fHttpE3aE2fE2f217E2e218E2e225E2e2E3a2082E2findeE78E2ehtmlE253FX qdcZtypeQUqfnZE45E78cludedFromGeneralE4cistingsQ qdcZtypeQUqfntypeZCommunityContentQ qdcZtypeQUqfntypeZE52esourceQ qdcZtypeQUqfntypeZWebpageQ qdcZtypeQUqfntypeZWikiContentQ qdcZtypeQUqmarsZManagedE52esourceQ qdcZtypeQUqwebZInformationE52esourceQ qdcZtypeQUqwebZPageQ qdcZtypeQUqwebZE52esourceQ qdcZtypeQUqrdfsZE52esourceQ qfnZtypeQUqfntypeZCommunityContentQ qfnZtypeQUqfntypeZE52esourceQ qfnZtypeQUqfntypeZWebpageQ qfnZtypeQUqfntypeZWikiContentQ qmarsZlanguageQUxhttpE3aE2fE2fswE2enokiaE2ecomE2flanguageE2d1E2fenX qrdfZtypeQUqfnZE45E78cludedFromGeneralE4cistingsQ qrdfZtypeQUqfntypeZCommunityContentQ qrdfZtypeQUqfntypeZE52esourceQ qrdfZtypeQUqfntypeZWebpageQ qrdfZtypeQUqfntypeZWikiContentQ qrdfZtypeQUqmarsZManagedE52esourceQ qrdfZtypeQUqwebZInformationE52esourceQ qrdfZtypeQUqwebZPageQ qrdfZtypeQUqwebZE52esourceQ qrdfZtypeQUqrdfsZE52esourceQ