Leaked source code of windows server 2003
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.

86 lines
2.3 KiB

  1. //=--------------------------------------------------------------------------=
  2. // Internet.H
  3. //=--------------------------------------------------------------------------=
  4. // Copyright 1995-1996 Microsoft Corporation. All Rights Reserved.
  5. //
  6. // THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF
  7. // ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO
  8. // THE IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A
  9. // PARTICULAR PURPOSE.
  10. //=--------------------------------------------------------------------------=
  11. //
  12. // class declaration for the URLDib2 control.
  13. //
  14. #ifndef _INTERNET_H
  15. #define _INTERNET_H
  16. #define DISPID_PROGRESS 1958
  17. #ifndef __MKTYPLIB__
  18. #include "urlmon.H"
  19. #include "ocidl.h"
  20. #include "datapath.h" // for IBindHost
  21. #include "docobj.h" // for IServiceProvider
  22. #include "IPServer.H"
  23. #include "CtrlObj.H"
  24. class CInternetControl : public COleControl
  25. {
  26. public:
  27. CInternetControl(IUnknown * pUnkOuter,
  28. int iPrimaryDispatch,
  29. void * pMainInterface);
  30. virtual ~CInternetControl();
  31. // IUnknown methods
  32. //
  33. DECLARE_STANDARD_UNKNOWN();
  34. // Call this method to start the download of a URL. 'propId' will
  35. // be passed back to you OnData below.
  36. HRESULT SetupDownload( LPOLESTR url, DISPID propId);
  37. // Derived classes implement this method. It will be called when
  38. // data has arrived for a given dispid.
  39. virtual HRESULT OnData( DISPID id, DWORD grfBSCF,
  40. IStream * bitstrm, DWORD amount );
  41. // Derived classes can implement this method. It will be
  42. // called at various times during the download.
  43. virtual HRESULT OnProgress( DISPID id, ULONG ulProgress,
  44. ULONG ulProgressMax,
  45. ULONG ulStatusCode,
  46. LPCWSTR pwzStatusText);
  47. // Call this method to turn a URL into a Moniker.
  48. HRESULT GetAMoniker( LPOLESTR url, IMoniker ** );
  49. HRESULT FireReadyStateChange( long newState );
  50. HRESULT FireProgress( ULONG dwAmount );
  51. // Override base class implementation...
  52. virtual HRESULT InternalQueryInterface(REFIID, void **);
  53. protected:
  54. HRESULT GetBindHost();
  55. IBindHost * m_host;
  56. long m_readyState;
  57. // BUGBUG: We should track all the downloads
  58. };
  59. #endif __MKTYPLIB__
  60. #endif _INTERNET_H