MCPcopy Create free account
hub / github.com/cinience/RedisStudio / SetText

Method SetText

DuiLib/Control/UIList.cpp:1957–1972  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1955}
1956
1957void CListTextElementUI::SetText(int iIndex, LPCTSTR pstrText)
1958{
1959 if( m_pOwner == NULL ) return;
1960 TListInfoUI* pInfo = m_pOwner->GetListInfo();
1961 if( iIndex < 0 || iIndex >= pInfo->nColumns ) return;
1962 while( m_aTexts.GetSize() < pInfo->nColumns ) { m_aTexts.Add(NULL); }
1963
1964 CDuiString* pText = static_cast<CDuiString*>(m_aTexts[iIndex]);
1965 if( (pText == NULL && pstrText == NULL) || (pText && *pText == pstrText) ) return;
1966
1967 if ( pText ) //by cddjr 2011/10/20
1968 pText->Assign(pstrText);
1969 else
1970 m_aTexts.SetAt(iIndex, new CDuiString(pstrText));
1971 Invalidate();
1972}
1973
1974void CListTextElementUI::SetOwner(CControlUI* pOwner)
1975{

Callers 15

SetItemTextMethod · 0.45
SetAttributeMethod · 0.45
OnInfoRefreshMethod · 0.45
InitWindowMethod · 0.45
OnConnectedMethod · 0.45
OnConnectingMethod · 0.45
DoFillDataMethod · 0.45
InitWindowMethod · 0.45
InitWindowMethod · 0.45
OnItemActiveForTreeMethod · 0.45
OnPaginateMethod · 0.45
OnCommitMethod · 0.45

Calls 5

AssignMethod · 0.80
SetAtMethod · 0.80
GetListInfoMethod · 0.45
GetSizeMethod · 0.45
AddMethod · 0.45

Tested by

no test coverage detected