equal
deleted
inserted
replaced
437 |
437 |
438 //----------------------------------------------------------------------------- |
438 //----------------------------------------------------------------------------- |
439 /** |
439 /** |
440 Returns ETrue if aName is unique, EFalse if a matching name is found. |
440 Returns ETrue if aName is unique, EFalse if a matching name is found. |
441 */ |
441 */ |
442 TBool CFatMountCB::IsUniqueNameL(const TShortName& aName,TInt aDirCluster) |
442 TBool CFatMountCB::IsUniqueNameL(const TShortName& aName, TUint32 aDirCluster) |
443 { |
443 { |
444 |
444 |
445 __PRINT(_L("CFatMountCB::IsUniqueNameL")); |
445 __PRINT(_L("CFatMountCB::IsUniqueNameL")); |
446 TEntryPos entryPos(aDirCluster,0); |
446 TEntryPos entryPos(aDirCluster,0); |
447 if (FindShortNameL(aName,entryPos)) |
447 return ! FindShortNameL(aName,entryPos); |
448 return(EFalse); |
|
449 return(ETrue); |
|
450 } |
448 } |
451 |
449 |
452 //----------------------------------------------------------------------------- |
450 //----------------------------------------------------------------------------- |
453 /** |
451 /** |
454 A legal dos name has been typed that clashes with a computer generated shortname |
452 A legal dos name has been typed that clashes with a computer generated shortname |
476 if (entry.iData[0]&0x40) |
474 if (entry.iData[0]&0x40) |
477 break; |
475 break; |
478 } |
476 } |
479 } |
477 } |
480 |
478 |
481 //----------------------------------------------------------------------------- |
|
482 /** |
479 /** |
483 Generate a legal dos filename as an alias for aName. |
480 Generate a legal dos filename as an alias for aName. |
484 @return ETrue if aName is a legal dos name. |
481 @return ETrue if aName is a legal dos name. |
485 */ |
482 */ |
486 TBool CFatMountCB::GenerateShortNameL(TInt aDirCluster,const TDesC& aName,TShortName& aGeneratedName, TBool aForceRandomize) |
483 TBool CFatMountCB::GenerateShortNameL(TUint32 aDirCluster,const TDesC& aName,TShortName& aGeneratedName, TBool aForceRandomize) |
487 { |
484 { |
488 |
485 |
489 __PRINT1(_L("CFatMountCB::GenerateShortNameL() cl:%d"), aDirCluster); |
486 __PRINT1(_L("CFatMountCB::GenerateShortNameL() cl:%d"), aDirCluster); |
490 |
487 |
491 if(!ClusterNumberValid(aDirCluster)) |
488 if(!ClusterNumberValid(aDirCluster)) |