本文整理汇总了C++中GetDisplayName函数的典型用法代码示例。如果您正苦于以下问题:C++ GetDisplayName函数的具体用法?C++ GetDisplayName怎么用?C++ GetDisplayName使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了GetDisplayName函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: GetDisplayName
wxString DocumentListCtrl::OnGetItemText (long item, long column) const
{
int sorteditem = _sortedIndices[(int)item];
int num_docs = _ferretparent->GetDocumentList().Size();
if (num_docs > 0)
{
int doc1 = _document1 [sorteditem];
int doc2 = _document2 [sorteditem];
int position = 0;
if (column == 0)
{
return GetDisplayName (doc1);
}
else if (column == 1)
{
return GetDisplayName (doc2);
}
else // if (column == 2)
{
return wxString::Format("%f",
_ferretparent->GetDocumentList().ComputeResemblance (doc1, doc2, _remove_common_trigrams, _ignore_template_material));
}
}
else
{
return "No items in document list";
}
}
示例2: GetDisplayName
void Explorerplusplus::HandleAddressBarText(void)
{
LPITEMIDLIST pidl = NULL;
TCHAR szAddressBarTitle[MAX_PATH];
pidl = m_pActiveShellBrowser->QueryCurrentDirectoryIdl();
TCHAR szParsingPath[MAX_PATH];
GetDisplayName(pidl,szParsingPath,SHGDN_FORPARSING);
/* If the path is a GUID (i.e. of the form
::{20D04FE0-3AEA-1069-A2D8-08002B30309D}), we'll
switch to showing the in folder name.
Otherwise, we'll show the full path.
Driven by the principle that GUID's should NOT
be shown directly to users. */
if(IsPathGUID(szParsingPath))
{
GetDisplayName(pidl,szAddressBarTitle,SHGDN_INFOLDER);
}
else
{
StringCchCopy(szAddressBarTitle,SIZEOF_ARRAY(szAddressBarTitle),
szParsingPath);
}
SetComboBoxExTitleString(m_hAddressBar,pidl,szAddressBarTitle);
CoTaskMemFree(pidl);
}
示例3: GetDisplayID
int CBillReview::OnCreate(LPCREATESTRUCT lpCreateStruct)
{
int is_business; //CAMqa66752
TCHAR bill_company[GAL_SI_SERVICE_COMPANY_LEN];
GAL_ERROR Error;
CString AccountName;
if (CDialog::OnCreate(lpCreateStruct) == -1)
return -1;
// TODO: Add your specialized creation code here
// get the account info....
m_sBillRevAccountId = GetDisplayID();
is_business = m_lpAccount->GetIsBusinessCode(); //CAMqa66752
if (is_business)
{
if(galGetAccount_bill_company(m_lpAccount->m_Account, bill_company, &Error ) == GAL_FAILURE )
AccountName = GetDisplayName();
else
AccountName = bill_company;
}
else
{
AccountName = GetDisplayName();
}
m_sBillRevAccountName = AccountName;
return 0;
}
示例4: LOG
void ExeComponent::Wait(DWORD tt)
{
ProcessComponent::Wait(tt);
DWORD exitcode = ProcessComponent::GetProcessExitCode();
LOG(L"Component '" << id << "' return code " << exitcode
<< DVLib::FormatMessage(L" (0x%x).", exitcode));
// check for reboot
if (! returncodes_reboot.empty() && IsReturnCode(exitcode, returncodes_reboot))
{
LOG(L"Component '" << id << "' return code '" << exitcode
<< L", defined as reboot required in '" << returncodes_reboot << L".");
return;
}
// check for explicit success, where defined
if (returncodes_success.empty())
{
CHECK_BOOL(ERROR_SUCCESS == exitcode,
L"Error executing '" << id << "' (" << GetDisplayName() << L"): " << exitcode << DVLib::FormatMessage(L" (0x%x)", exitcode));
}
else
{
CHECK_BOOL(IsReturnCode(exitcode, returncodes_success),
L"Error executing component '" << id << "' (" << GetDisplayName() << L"), return code "
<< exitcode << DVLib::FormatMessage(L" (0x%x)", exitcode)
<< L" is not in '" << returncodes_success << L"'");
LOG(L"Component '" << id << "' (" << GetDisplayName() << L") return code " << exitcode
<< DVLib::FormatMessage(L" (0x%x)", exitcode)
<< L", defined as success in '" << returncodes_success << L"'.");
}
}
示例5: ParseProperties
bool CUDisks2Provider::FilesystemPropertiesChanged(const char *object, DBusMessageIter *propsIter, IStorageEventsCallback *callback)
{
if (m_filesystems.count(object) > 0)
{
auto fs = m_filesystems[object];
CLog::Log(LOGDEBUG, LOGDBUS, "UDisks2: Before update: %s", fs->toString());
bool wasMounted = fs->m_isMounted;
auto ParseFilesystemProperty = std::bind(&CUDisks2Provider::ParseFilesystemProperty, this,
std::placeholders::_1,
std::placeholders::_2, std::placeholders::_3);
ParseProperties(fs, propsIter, ParseFilesystemProperty);
CLog::Log(LOGDEBUG, LOGDBUS, "UDisks2: After update: %s", fs->toString());
if (!wasMounted && fs->m_isMounted && fs->IsApproved())
{
CLog::Log(LOGINFO, "UDisks2: Added %s", fs->m_mountPoint);
if (callback)
callback->OnStorageAdded(fs->GetDisplayName(), fs->m_mountPoint);
return true;
}
else if (wasMounted && !fs->m_isMounted)
{
CLog::Log(LOGINFO, "UDisks2: Removed %s", fs->m_block->m_device);
if (callback)
callback->OnStorageSafelyRemoved(fs->GetDisplayName());
return true;
}
}
return false;
}
示例6: GetDisplayName
inline VmbErrorType EnumEntry::GetDisplayName( std::string &rStrDisplayName ) const
{
VmbErrorType res;
VmbUint32_t nLength;
res = GetDisplayName( NULL, nLength );
if ( VmbErrorSuccess == res )
{
if ( 0 < nLength )
{
rStrDisplayName.resize( nLength );
res = GetDisplayName( &rStrDisplayName[0], nLength );
if ( VmbErrorSuccess == res )
{
size_t nPos = rStrDisplayName.find( '\0' );
if ( nLength-1 > nPos )
{
rStrDisplayName.resize( nPos );
}
}
}
else
{
rStrDisplayName.clear();
}
}
return res;
}
示例7: ILCombine
int CALLBACK CShellBrowser::SortByType(int InternalIndex1,int InternalIndex2) const
{
if(m_bVirtualFolder)
{
TCHAR FullFileName1[MAX_PATH];
LPITEMIDLIST pidlComplete1 = ILCombine(m_pidlDirectory,m_pExtraItemInfo[InternalIndex1].pridl);
GetDisplayName(pidlComplete1,FullFileName1,SHGDN_FORPARSING);
CoTaskMemFree(pidlComplete1);
TCHAR FullFileName2[MAX_PATH];
LPITEMIDLIST pidlComplete2 = ILCombine(m_pidlDirectory,m_pExtraItemInfo[InternalIndex2].pridl);
GetDisplayName(pidlComplete2,FullFileName2,SHGDN_FORPARSING);
CoTaskMemFree(pidlComplete2);
BOOL IsRoot1 = PathIsRoot(FullFileName1);
BOOL IsRoot2 = PathIsRoot(FullFileName2);
if(IsRoot1 && !IsRoot2)
{
return -1;
}
else if(!IsRoot1 && IsRoot2)
{
return 1;
}
}
std::wstring Type1 = GetTypeColumnText(InternalIndex1);
std::wstring Type2 = GetTypeColumnText(InternalIndex2);
return StrCmpLogicalW(Type1.c_str(),Type2.c_str());
}
示例8: GetDisplayName
int CALLBACK CShellBrowser::SortByType(const BasicItemInfo_t &itemInfo1, const BasicItemInfo_t &itemInfo2) const
{
if(m_bVirtualFolder)
{
TCHAR FullFileName1[MAX_PATH];
GetDisplayName(itemInfo1.pidlComplete.get(),FullFileName1,SIZEOF_ARRAY(FullFileName1),SHGDN_FORPARSING);
TCHAR FullFileName2[MAX_PATH];
GetDisplayName(itemInfo2.pidlComplete.get(),FullFileName2,SIZEOF_ARRAY(FullFileName2),SHGDN_FORPARSING);
BOOL IsRoot1 = PathIsRoot(FullFileName1);
BOOL IsRoot2 = PathIsRoot(FullFileName2);
if(IsRoot1 && !IsRoot2)
{
return -1;
}
else if(!IsRoot1 && IsRoot2)
{
return 1;
}
}
std::wstring Type1 = GetTypeColumnText(itemInfo1);
std::wstring Type2 = GetTypeColumnText(itemInfo2);
return StrCmpLogicalW(Type1.c_str(),Type2.c_str());
}
示例9: if
BOOL CDownloadWithTiger::SetHashset(BYTE* pSource, DWORD nSource)
{
if ( m_nSize == SIZE_UNKNOWN ) return FALSE;
if ( m_pHashset.IsAvailable() ) return TRUE;
if ( nSource == 0 && m_bED2K )
{
m_pHashset.FromRoot( &m_pED2K );
}
else if ( m_pHashset.FromBytes( pSource, nSource, m_nSize ) )
{
MD4 pRoot;
m_pHashset.GetRoot( &pRoot );
if ( m_bED2K && m_pED2K != pRoot )
{
m_pHashset.Clear();
theApp.Message( MSG_ERROR, IDS_DOWNLOAD_HASHSET_CORRUPT,
(LPCTSTR)GetDisplayName() );
return FALSE;
}
else if ( ! m_bED2K )
{
m_bED2K = TRUE;
m_pED2K = pRoot;
}
}
else
{
theApp.Message( MSG_ERROR, IDS_DOWNLOAD_HASHSET_CORRUPT,
(LPCTSTR)GetDisplayName() );
return FALSE;
}
m_nHashsetBlock = m_pHashset.GetBlockCount();
m_pHashsetBlock = new BYTE[ m_nHashsetBlock ];
ZeroMemory( m_pHashsetBlock, sizeof(BYTE) * m_nHashsetBlock );
SetModified();
theApp.Message( MSG_DEFAULT, IDS_DOWNLOAD_HASHSET_READY,
(LPCTSTR)GetDisplayName(),
(LPCTSTR)Settings.SmartVolume( ED2K_PART_SIZE, FALSE ) );
Neighbours.SendDonkeyDownload( reinterpret_cast<CDownload*>( this ) );
return TRUE;
}
示例10: ASSERT
void CDownload::OnDownloaded()
{
ASSERT( m_bComplete == false );
theApp.Message( MSG_NOTICE, IDS_DOWNLOAD_COMPLETED, GetDisplayName() );
m_tCompleted = GetTickCount();
m_bDownloading = false;
StopSearch();
CloseTransfers();
//AppendMetadata();
if ( GetTaskType() == dtaskMergeFile || GetTaskType() == dtaskPreviewRequest )
AbortTask();
// LibraryBuilder.m_bBusy = true; // ?
m_pTask.Copy();
Statistics.Current.Downloads.Files++;
SetModified();
}
示例11: SNew
TSharedRef<ITableRow> FDetailCategoryImpl::GenerateNodeWidget( const TSharedRef<STableViewBase>& OwnerTable, const FDetailColumnSizeData& ColumnSizeData, const TSharedRef<IPropertyUtilities>& PropertyUtilities )
{
return
SNew( SDetailCategoryTableRow, AsShared(), OwnerTable )
.DisplayName( GetDisplayName() )
.HeaderContent( HeaderContentWidget );
}
示例12: InitBackendInfo
void VideoBackend::ShowConfig(void* parent_handle)
{
if (!m_initialized)
InitBackendInfo();
Host_ShowVideoConfig(parent_handle, GetDisplayName(), "gfx_opengl");
}
示例13: SetTriggerTextOfCommand
bool pawsConfigKeys::OnFingering(csString string, psControl::Device device, uint button, uint32 mods)
{
if (fingWnd == NULL || !fingWnd->IsVisible())
return true;
bool changed = false;
if (string == NO_BIND) // Removing trigger
{
psengine->GetCharControl()->RemapTrigger(editedCmd,psControl::NONE,0,0);
changed = true;
}
else // Changing trigger
{
changed = psengine->GetCharControl()->RemapTrigger(editedCmd,device,button,mods);
}
if (changed)
{
SetTriggerTextOfCommand(editedCmd,string);
dirty = true;
return true; // Hide fingering window
}
else // Map already exists
{
const psControl* other = psengine->GetCharControl()->GetMappedTrigger(device,button,mods);
CS_ASSERT(other);
if (other->name != editedCmd)
{
fingWnd->SetCollisionInfo(GetDisplayName(other->name));
return false; // Keep fingering window up; invalid combo to set
}
else return true; // Hide fingering window; combo is the same as old
}
}
示例14: TreeView_GetSelection
void Explorerplusplus::OnTreeViewSetFileAttributes(void)
{
HTREEITEM hItem = TreeView_GetSelection(m_hTreeView);
if(hItem == NULL)
{
return;
}
std::list<NSetFileAttributesDialogExternal::SetFileAttributesInfo_t> sfaiList;
NSetFileAttributesDialogExternal::SetFileAttributesInfo_t sfai;
LPITEMIDLIST pidlItem = m_pMyTreeView->BuildPath(hItem);
HRESULT hr = GetDisplayName(pidlItem,sfai.szFullFileName,SIZEOF_ARRAY(sfai.szFullFileName),SHGDN_FORPARSING);
CoTaskMemFree(pidlItem);
if(hr == S_OK)
{
HANDLE hFindFile = FindFirstFile(sfai.szFullFileName,&sfai.wfd);
if(hFindFile != INVALID_HANDLE_VALUE)
{
FindClose(hFindFile);
sfaiList.push_back(sfai);
CSetFileAttributesDialog SetFileAttributesDialog(m_hLanguageModule,
IDD_SETFILEATTRIBUTES,m_hContainer,sfaiList);
SetFileAttributesDialog.ShowModalDialog();
}
}
}
示例15: CS_ASSERT
void pawsConfigKeys::UpdateNicks(pawsTreeNode * subtreeRoot)
{
if (subtreeRoot == NULL)
subtreeRoot = tree->GetRoot();
if (subtreeRoot == NULL) return;
pawsSeqTreeNode * rootAsSeq;
pawsTreeNode * child;
pawsTextBox * label;
rootAsSeq = dynamic_cast<pawsSeqTreeNode*> (subtreeRoot);
if (rootAsSeq != NULL && rootAsSeq != tree->GetRoot())
{
label = dynamic_cast<pawsTextBox*> (rootAsSeq->GetSeqWidget(0));
CS_ASSERT(label);
psCharController* manager = psengine->GetCharControl();
// Update the name label
const psControl* ctrl = manager->GetTrigger( subtreeRoot->GetName() );
if (ctrl)
label->SetText( GetDisplayName(ctrl->name) );
}
child = subtreeRoot->GetFirstChild();
while (child != NULL)
{
UpdateNicks(child);
child = child->GetNextSibling();
}
}