with GNATCOM.IInterface;

with GNATCOM.Errors;

package body MSHTML.IHTMLMediaElement2_Interface is

   procedure Initialize (This : in out IHTMLMediaElement2_Type) is
   begin
      Set_IID (This, IID_IHTMLMediaElement2);
   end Initialize;

   function Pointer (This : IHTMLMediaElement2_Type)
     return Pointer_To_IHTMLMediaElement2
   is
   begin
      return To_Pointer_To_IHTMLMediaElement2 (Address (This));
   end Pointer;

   procedure Attach (This    : in out IHTMLMediaElement2_Type;
                     Pointer : in     Pointer_To_IHTMLMediaElement2)
   is
   begin
      Attach (This, GNATCOM.IInterface.To_Pointer_To_IUnknown
              (Pointer.all'Address));
   end Attach;

   procedure Put_currentTimeDouble
     (This : IHTMLMediaElement2_Type;
      p    : Interfaces.C.double)
   is
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Put_currentTimeDouble
         (Pointer (This),
          p));

   end Put_currentTimeDouble;

   function Get_currentTimeDouble
     (This : IHTMLMediaElement2_Type)
     return Interfaces.C.double
   is
       RetVal : aliased Interfaces.C.double;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_currentTimeDouble
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_currentTimeDouble;

   function Get_initialTimeDouble
     (This : IHTMLMediaElement2_Type)
     return Interfaces.C.double
   is
       RetVal : aliased Interfaces.C.double;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_initialTimeDouble
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_initialTimeDouble;

   function Get_durationDouble
     (This : IHTMLMediaElement2_Type)
     return Interfaces.C.double
   is
       RetVal : aliased Interfaces.C.double;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_durationDouble
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_durationDouble;

   procedure Put_defaultPlaybackRateDouble
     (This : IHTMLMediaElement2_Type;
      p    : Interfaces.C.double)
   is
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Put_defaultPlaybackRateDouble
         (Pointer (This),
          p));

   end Put_defaultPlaybackRateDouble;

   function Get_defaultPlaybackRateDouble
     (This : IHTMLMediaElement2_Type)
     return Interfaces.C.double
   is
       RetVal : aliased Interfaces.C.double;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_defaultPlaybackRateDouble
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_defaultPlaybackRateDouble;

   procedure Put_playbackRateDouble
     (This : IHTMLMediaElement2_Type;
      p    : Interfaces.C.double)
   is
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Put_playbackRateDouble
         (Pointer (This),
          p));

   end Put_playbackRateDouble;

   function Get_playbackRateDouble
     (This : IHTMLMediaElement2_Type)
     return Interfaces.C.double
   is
       RetVal : aliased Interfaces.C.double;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_playbackRateDouble
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_playbackRateDouble;

   procedure Put_volumeDouble
     (This : IHTMLMediaElement2_Type;
      p    : Interfaces.C.double)
   is
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Put_volumeDouble
         (Pointer (This),
          p));

   end Put_volumeDouble;

   function Get_volumeDouble
     (This : IHTMLMediaElement2_Type)
     return Interfaces.C.double
   is
       RetVal : aliased Interfaces.C.double;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_volumeDouble
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_volumeDouble;

end MSHTML.IHTMLMediaElement2_Interface;

