MCPcopy Create free account
hub / github.com/ProgerXP/Notepad2e / MRU_Add

Function MRU_Add

src/Helpers.c:1499–1514  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1497}
1498
1499BOOL MRU_Add ( LPMRULIST pmru, LPCWSTR pszNew )
1500{
1501 int i;
1502 for ( i = 0; i < pmru->iSize; i++ ) {
1503 if ( MRU_Compare ( pmru, pmru->pszItems[i], pszNew ) == 0 ) {
1504 LocalFree ( pmru->pszItems[i] );
1505 break;
1506 }
1507 }
1508 i = min ( i, pmru->iSize - 1 );
1509 for ( ; i > 0; i-- ) {
1510 pmru->pszItems[i] = pmru->pszItems[i - 1];
1511 }
1512 pmru->pszItems[0] = StrDup ( pszNew );
1513 return ( 1 );
1514}
1515
1516BOOL MRU_AddFile ( LPMRULIST pmru, LPCWSTR pszFile, BOOL bRelativePath, BOOL bUnexpandMyDocs )
1517{

Callers 2

MRU_MergeSaveFunction · 0.85
EditFindReplaceDlgProcWFunction · 0.85

Calls 1

MRU_CompareFunction · 0.85

Tested by

no test coverage detected