BaseObject.cs 396 B

123456789101112131415161718192021
  1. using Sonic;
  2. using System;
  3. using System.Diagnostics;
  4. namespace VideoPlayLib
  5. {
  6. internal class BaseObject
  7. {
  8. //---- internal utility
  9. [DebuggerHidden]
  10. protected static void CheckError(int result)
  11. {
  12. var h = new HRESULT(result);
  13. if (h.Failed)
  14. {
  15. throw new Exception(h.Text);
  16. }
  17. }
  18. }
  19. }