Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

44 lines
865 B

  1. #ifndef _ITRKADMN_HXX_
  2. #define _ITRKADMN_HXX_
  3. class CObjectOwnershipString
  4. {
  5. public:
  6. CObjectOwnershipString( ObjectOwnership objown )
  7. {
  8. _objown = objown;
  9. }
  10. CObjectOwnershipString( long objown )
  11. {
  12. _objown = static_cast<ObjectOwnership>(objown);
  13. }
  14. public:
  15. operator TCHAR*() // BUGBUG: Use string resources
  16. {
  17. switch( _objown )
  18. {
  19. case OBJOWN_DOESNT_EXIST:
  20. return( TEXT("Non-extant") );
  21. case OBJOWN_OWNED:
  22. return( TEXT("Owned") );
  23. case OBJOWN_NOT_OWNED:
  24. return( TEXT("Not owned") );
  25. case OBJOWN_NO_ID:
  26. return( TEXT("No ID") );
  27. default:
  28. return( TEXT("Unknown") );
  29. }
  30. }
  31. private:
  32. ObjectOwnership _objown;
  33. };
  34. #endif // #ifndef _ITRDADMN_HXX_