×
Namespaces

Variants
Actions

如何创建不加载资源文件的程序

From Nokia Developer Wiki
Jump to: navigation, search
Article Metadata

文章
翻译:
hoolee
最后由 hamishwillee 在 22 Dec 2011 编辑

为了停止所有资源的加载,你需要做如下2件事:

  1. 你需要重载CEikApplication::ResourceFileName()函数,这个一般在CEikAppUi派生类的ConstructL函数中调用,具体如下:
    TFileName CMyApplication::ResourceFileName() const
    {
    return TFileName();
    }
  2. 当调用CEikAppUi::BaseConstructL时需要传递ENoAppResourceFile参数进去,这个主要在CEikAppUi派生类的ConstructL函数调用的。
    void CMyEmptyUi::ConstructL()
    {
    BaseConstructL(ENoAppResourceFile);
    //Now construct the other parts of my application...
    }

这里CMyEmptyUi为CEikAppUi的派生类

This page was last modified on 22 December 2011, at 07:57.
104 page views in the last 30 days.

Was this page helpful?

Your feedback about this content is important. Let us know what you think.

 

Thank you!

We appreciate your feedback.

×