本文整理汇总了C++中CGUIDialogTextViewer::SetHeading方法的典型用法代码示例。如果您正苦于以下问题:C++ CGUIDialogTextViewer::SetHeading方法的具体用法?C++ CGUIDialogTextViewer::SetHeading怎么用?C++ CGUIDialogTextViewer::SetHeading使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CGUIDialogTextViewer
的用法示例。
在下文中一共展示了CGUIDialogTextViewer::SetHeading方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: OnChangeLog
void CGUIDialogAddonInfo::OnChangeLog()
{
CGUIDialogTextViewer* pDlgInfo = (CGUIDialogTextViewer*)g_windowManager.GetWindow(WINDOW_DIALOG_TEXT_VIEWER);
CStdString name;
if (m_addon)
name = m_addon->Name();
else if (m_localAddon)
name = m_localAddon->Name();
pDlgInfo->SetHeading(g_localizeStrings.Get(24054)+" - "+name);
if (m_item->GetProperty("Addon.Changelog").empty())
{
pDlgInfo->SetText(g_localizeStrings.Get(13413));
CFileItemList items;
if (m_localAddon &&
!m_item->GetProperty("Addon.UpdateAvail").asBoolean())
{
items.Add(CFileItemPtr(new CFileItem(m_localAddon->ChangeLog(),false)));
}
else
items.Add(CFileItemPtr(new CFileItem(m_addon->ChangeLog(),false)));
items[0]->Select(true);
m_jobid = CJobManager::GetInstance().AddJob(
new CFileOperationJob(CFileOperationJob::ActionCopy,items,
"special://temp/"),this);
}
else
pDlgInfo->SetText(m_item->GetProperty("Addon.Changelog").asString());
m_changelog = true;
pDlgInfo->DoModal();
m_changelog = false;
}
示例2: textviewer
void Dialog::textviewer(const String& heading, const String& text)
{
DelayedCallGuard dcguard(languageHook);
const int window = WINDOW_DIALOG_TEXT_VIEWER;
CGUIDialogTextViewer* pDialog = (CGUIDialogTextViewer*)g_windowManager.GetWindow(window);
if (pDialog == NULL)
throw WindowException("Error: Window is NULL, this is not possible :-)");
if (!heading.empty())
pDialog->SetHeading(heading);
if (!text.empty())
pDialog->SetText(text);
pDialog->Open();
}
示例3: open
void Interface_GUIDialogTextViewer::open(void* kodiBase, const char *heading, const char *text)
{
CAddonDll* addon = static_cast<CAddonDll*>(kodiBase);
if (!addon)
{
CLog::Log(LOGERROR, "Interface_GUIDialogTextViewer::%s - invalid data", __FUNCTION__);
return;
}
CGUIDialogTextViewer* dialog = g_windowManager.GetWindow<CGUIDialogTextViewer>(WINDOW_DIALOG_TEXT_VIEWER);
if (!heading || !text || !dialog)
{
CLog::Log(LOGERROR, "Interface_GUIDialogTextViewer::%s - invalid handler data (heading='%p', text='%p', dialog='%p') on addon '%s'", __FUNCTION__,
heading, text, dialog, addon->ID().c_str());
return;
}
dialog->SetHeading(heading);
dialog->SetText(text);
dialog->Open();
}