crecentcalls.h 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. #ifndef CRECENTCALLS_H
  2. #define CRECENTCALLS_H
  3. #include <e32base.h>
  4. #include <logcli.h> // CLogClient
  5. #include <logview.h> // CLogViewRecent
  6. #include <f32file.h>
  7. enum TTask {
  8. EGetRecent,
  9. ESleep,
  10. EWaitingChange = 1,
  11. EReadingLog,
  12. EReadingLogItems,
  13. EFindingDuplicates,
  14. EReadingDupeItems
  15. };
  16. class CRecentCalls : public CActive
  17. {
  18. public:
  19. /**
  20. * Symbian OS default constructor
  21. */
  22. CRecentCalls();
  23. /**
  24. * 2nd phase constructor.
  25. */
  26. static CRecentCalls* NewL();
  27. /**
  28. * Destructor
  29. */
  30. ~CRecentCalls();
  31. /**
  32. * Reads recent events from the main event database
  33. */
  34. void ReadRecentEventsL();
  35. private:
  36. /**
  37. * Symbian 2-phase constructor
  38. */
  39. void ConstructL();
  40. /**
  41. * From CActive
  42. */
  43. void RunL();
  44. /**
  45. * From CActive
  46. */
  47. TInt RunError(TInt anError);
  48. /**
  49. * From CActive
  50. */
  51. void DoCancel();
  52. /**
  53. * Handles a single recent event.
  54. */
  55. void HandleRecentEventL(const CLogEvent& anEvent);
  56. private: // Data
  57. RFs iFs;
  58. CLogClient* iLogClient;
  59. CLogViewRecent* iLogViewRecent;
  60. TTask iTask; // Task for RunL
  61. };
  62. #endif // CRECENTCALLS_H