本文整理汇总了C++中CAknTitlePane::SetFromResourceL方法的典型用法代码示例。如果您正苦于以下问题:C++ CAknTitlePane::SetFromResourceL方法的具体用法?C++ CAknTitlePane::SetFromResourceL怎么用?C++ CAknTitlePane::SetFromResourceL使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CAknTitlePane
的用法示例。
在下文中一共展示了CAknTitlePane::SetFromResourceL方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: SetupStatusPaneL
void CNPRStoryListBoxView::SetupStatusPaneL()
{
// reset the context pane
TUid contextPaneUid = TUid::Uid( EEikStatusPaneUidContext );
CEikStatusPaneBase::TPaneCapabilities subPaneContext =
StatusPane()->PaneCapabilities( contextPaneUid );
if ( subPaneContext.IsPresent() && subPaneContext.IsAppOwned() )
{
CAknContextPane* context = static_cast< CAknContextPane* > (
StatusPane()->ControlL( contextPaneUid ) );
context->SetPictureToDefaultL();
}
// setup the title pane
TUid titlePaneUid = TUid::Uid( EEikStatusPaneUidTitle );
CEikStatusPaneBase::TPaneCapabilities subPaneTitle =
StatusPane()->PaneCapabilities( titlePaneUid );
if ( subPaneTitle.IsPresent() && subPaneTitle.IsAppOwned() )
{
CAknTitlePane* title = static_cast< CAknTitlePane* >(
StatusPane()->ControlL( titlePaneUid ) );
TResourceReader reader;
iEikonEnv->CreateResourceReaderLC( reader, R_NPRSTORY_LIST_BOX_TITLE_RESOURCE );
title->SetFromResourceL( reader );
CleanupStack::PopAndDestroy(); // reader internal state
}
}
示例2: SetTitleL
// ----------------------------------------------------
// CCcorAppUi::SetTitleL
// Set title pane text from a resource.
// ----------------------------------------------------
//
void CTrkAppUi::SetTitleL(TInt aResourceId)
{
// Set title
CAknTitlePane* title = static_cast<CAknTitlePane*>(StatusPane()->ControlL(TUid::Uid(EEikStatusPaneUidTitle)));
TResourceReader reader;
iCoeEnv->CreateResourceReaderLC(reader, aResourceId);
title->SetFromResourceL(reader);
CleanupStack::PopAndDestroy(); // resource reader
}