home *** CD-ROM | disk | FTP | other *** search
/ QBasic & Borland Pascal & C / Delphi5.iso / Runimage / Delphi50 / Source / Internet / SHDOCVW.PAS < prev    next >
Encoding:
Pascal/Delphi Source File  |  1999-08-11  |  129.9 KB  |  3,549 lines

  1. unit SHDocVw;
  2.  
  3. // ************************************************************************ //
  4. // WARNING                                                                    
  5. // -------                                                                    
  6. // The types declared in this file were generated from data read from a       
  7. // Type Library. If this type library is explicitly or indirectly (via        
  8. // another type library referring to this type library) re-imported, or the   
  9. // 'Refresh' command of the Type Library Editor activated while editing the   
  10. // Type Library, the contents of this file will be regenerated and all        
  11. // manual modifications will be lost.                                         
  12. // ************************************************************************ //
  13.  
  14. // PASTLWTR : $Revision:   1.8  $
  15. // File generated on 7/26/99 12:22:56 PM from Type Library described below.
  16.  
  17. // *************************************************************************//
  18. // NOTE:                                                                      
  19. // Items guarded by $IFDEF_LIVE_SERVER_AT_DESIGN_TIME are used by properties  
  20. // which return objects that may need to be explicitly created via a function 
  21. // call prior to any access via the property. These items have been disabled  
  22. // in order to prevent accidental use from within the object inspector. You   
  23. // may enable them by defining LIVE_SERVER_AT_DESIGN_TIME or by selectively   
  24. // removing them from the $IFDEF blocks. However, such items must still be    
  25. // programmatically created via a method of the appropriate CoClass before    
  26. // they can be used.                                                          
  27. // ************************************************************************ //
  28. // Type Lib: C:\WINNT\System32\shdocvw.dll (1)
  29. // IID\LCID: {EAB22AC0-30C1-11CF-A7EB-0000C05BAE0B}\0
  30. // Helpfile: 
  31. // DepndLst: 
  32. //   (1) v2.0 stdole, (C:\WINNT\System32\STDOLE2.TLB)
  33. //   (2) v4.0 StdVCL, (C:\WINNT\System32\STDVCL40.DLL)
  34. // Errors:
  35. //   Hint: Member 'Type' of 'IWebBrowser' changed to 'Type_'
  36. //   Hint: Parameter 'Type' of IWebBrowser.Type changed to 'Type_'
  37. //   Hint: Parameter 'Property' of DWebBrowserEvents.PropertyChange changed to 'Property_'
  38. //   Hint: Parameter 'Property' of IWebBrowserApp.PutProperty changed to 'Property_'
  39. //   Hint: Parameter 'Property' of IWebBrowserApp.GetProperty changed to 'Property_'
  40. //   Hint: Parameter 'Type' of IShellUIHelper.AddDesktopComponent changed to 'Type_'
  41. //   Error creating palette bitmap of (TInternetExplorer) : Invalid GUID format
  42. // ************************************************************************ //
  43. {$TYPEDADDRESS OFF} // Unit must be compiled without type-checked pointers. 
  44. interface
  45.  
  46. uses Windows, ActiveX, Classes, Graphics, OleServer, OleCtrls, StdVCL;
  47.  
  48. // *********************************************************************//
  49. // GUIDS declared in the TypeLibrary. Following prefixes are used:        
  50. //   Type Libraries     : LIBID_xxxx                                      
  51. //   CoClasses          : CLASS_xxxx                                      
  52. //   DISPInterfaces     : DIID_xxxx                                       
  53. //   Non-DISP interfaces: IID_xxxx                                        
  54. // *********************************************************************//
  55. const
  56.   // TypeLibrary Major and minor versions
  57.   SHDocVwMajorVersion = 1;
  58.   SHDocVwMinorVersion = 1;
  59.  
  60.   LIBID_SHDocVw: TGUID = '{EAB22AC0-30C1-11CF-A7EB-0000C05BAE0B}';
  61.  
  62.   IID_IWebBrowser: TGUID = '{EAB22AC1-30C1-11CF-A7EB-0000C05BAE0B}';
  63.   DIID_DWebBrowserEvents: TGUID = '{EAB22AC2-30C1-11CF-A7EB-0000C05BAE0B}';
  64.   IID_IWebBrowserApp: TGUID = '{0002DF05-0000-0000-C000-000000000046}';
  65.   IID_IWebBrowser2: TGUID = '{D30C1661-CDAF-11D0-8A3E-00C04FC9E26E}';
  66.   DIID_DWebBrowserEvents2: TGUID = '{34A715A0-6587-11D0-924A-0020AFC7AC4D}';
  67.   CLASS_WebBrowser_V1: TGUID = '{EAB22AC3-30C1-11CF-A7EB-0000C05BAE0B}';
  68.   CLASS_WebBrowser: TGUID = '{8856F961-340A-11D0-A96B-00C04FD705A2}';
  69.   CLASS_InternetExplorer: TGUID = '{0002DF01-0000-0000-C000-000000000046}';
  70.   CLASS_ShellBrowserWindow: TGUID = '{C08AFD90-F2A1-11D1-8455-00A0C91F3880}';
  71.   DIID_DShellWindowsEvents: TGUID = '{FE4106E0-399A-11D0-A48C-00A0C90A8F39}';
  72.   IID_IShellWindows: TGUID = '{85CB6900-4D95-11CF-960C-0080C7F4EE85}';
  73.   CLASS_ShellWindows: TGUID = '{9BA05972-F6A8-11CF-A442-00A0C90A8F39}';
  74.   IID_IShellUIHelper: TGUID = '{729FE2F8-1EA8-11D1-8F85-00C04FC2FBE1}';
  75.   CLASS_ShellUIHelper: TGUID = '{64AB4BB7-111E-11D1-8F79-00C04FC2FBE1}';
  76.   DIID__ShellFavoritesNameSpaceEvents: TGUID = '{55136806-B2DE-11D1-B9F2-00A0C98BC547}';
  77.   IID_IShellFavoritesNameSpace: TGUID = '{55136804-B2DE-11D1-B9F2-00A0C98BC547}';
  78.   CLASS_ShellFavoritesNameSpace: TGUID = '{55136805-B2DE-11D1-B9F2-00A0C98BC547}';
  79.   IID_IScriptErrorList: TGUID = '{F3470F24-15FD-11D2-BB2E-00805FF7EFCA}';
  80.   CLASS_CScriptErrorList: TGUID = '{EFD01300-160F-11D2-BB2E-00805FF7EFCA}';
  81.   IID_ISearch: TGUID = '{BA9239A4-3DD5-11D2-BF8B-00C04FB93661}';
  82.   IID_ISearches: TGUID = '{47C922A2-3DD5-11D2-BF8B-00C04FB93661}';
  83.   IID_ISearchAssistantOC: TGUID = '{72423E8F-8011-11D2-BE79-00A0C9A83DA1}';
  84.   DIID__SearchAssistantEvents: TGUID = '{1611FDDA-445B-11D2-85DE-00C04FA35C89}';
  85.   CLASS_SearchAssistantOC: TGUID = '{B45FF030-4447-11D2-85DE-00C04FA35C89}';
  86.  
  87. // *********************************************************************//
  88. // Declaration of Enumerations defined in Type Library                    
  89. // *********************************************************************//
  90. // CommandStateChangeConstants constants
  91. type
  92.   CommandStateChangeConstants = TOleEnum;
  93. const
  94.   CSC_UPDATECOMMANDS = $FFFFFFFF;
  95.   CSC_NAVIGATEFORWARD = $00000001;
  96.   CSC_NAVIGATEBACK = $00000002;
  97.  
  98. // OLECMDID constants
  99. type
  100.   OLECMDID = TOleEnum;
  101. const
  102.   OLECMDID_OPEN = $00000001;
  103.   OLECMDID_NEW = $00000002;
  104.   OLECMDID_SAVE = $00000003;
  105.   OLECMDID_SAVEAS = $00000004;
  106.   OLECMDID_SAVECOPYAS = $00000005;
  107.   OLECMDID_PRINT = $00000006;
  108.   OLECMDID_PRINTPREVIEW = $00000007;
  109.   OLECMDID_PAGESETUP = $00000008;
  110.   OLECMDID_SPELL = $00000009;
  111.   OLECMDID_PROPERTIES = $0000000A;
  112.   OLECMDID_CUT = $0000000B;
  113.   OLECMDID_COPY = $0000000C;
  114.   OLECMDID_PASTE = $0000000D;
  115.   OLECMDID_PASTESPECIAL = $0000000E;
  116.   OLECMDID_UNDO = $0000000F;
  117.   OLECMDID_REDO = $00000010;
  118.   OLECMDID_SELECTALL = $00000011;
  119.   OLECMDID_CLEARSELECTION = $00000012;
  120.   OLECMDID_ZOOM = $00000013;
  121.   OLECMDID_GETZOOMRANGE = $00000014;
  122.   OLECMDID_UPDATECOMMANDS = $00000015;
  123.   OLECMDID_REFRESH = $00000016;
  124.   OLECMDID_STOP = $00000017;
  125.   OLECMDID_HIDETOOLBARS = $00000018;
  126.   OLECMDID_SETPROGRESSMAX = $00000019;
  127.   OLECMDID_SETPROGRESSPOS = $0000001A;
  128.   OLECMDID_SETPROGRESSTEXT = $0000001B;
  129.   OLECMDID_SETTITLE = $0000001C;
  130.   OLECMDID_SETDOWNLOADSTATE = $0000001D;
  131.   OLECMDID_STOPDOWNLOAD = $0000001E;
  132.   OLECMDID_ONTOOLBARACTIVATED = $0000001F;
  133.   OLECMDID_FIND = $00000020;
  134.   OLECMDID_DELETE = $00000021;
  135.   OLECMDID_HTTPEQUIV = $00000022;
  136.   OLECMDID_HTTPEQUIV_DONE = $00000023;
  137.   OLECMDID_ENABLE_INTERACTION = $00000024;
  138.   OLECMDID_ONUNLOAD = $00000025;
  139.   OLECMDID_PROPERTYBAG2 = $00000026;
  140.   OLECMDID_PREREFRESH = $00000027;
  141.   OLECMDID_SHOWSCRIPTERROR = $00000028;
  142.   OLECMDID_SHOWMESSAGE = $00000029;
  143.   OLECMDID_SHOWFIND = $0000002A;
  144.   OLECMDID_SHOWPAGESETUP = $0000002B;
  145.   OLECMDID_SHOWPRINT = $0000002C;
  146.   OLECMDID_CLOSE = $0000002D;
  147.   OLECMDID_ALLOWUILESSSAVEAS = $0000002E;
  148.   OLECMDID_DONTDOWNLOADCSS = $0000002F;
  149.  
  150. // OLECMDF constants
  151. type
  152.   OLECMDF = TOleEnum;
  153. const
  154.   OLECMDF_SUPPORTED = $00000001;
  155.   OLECMDF_ENABLED = $00000002;
  156.   OLECMDF_LATCHED = $00000004;
  157.   OLECMDF_NINCHED = $00000008;
  158.   OLECMDF_INVISIBLE = $00000010;
  159.   OLECMDF_DEFHIDEONCTXTMENU = $00000020;
  160.  
  161. // OLECMDEXECOPT constants
  162. type
  163.   OLECMDEXECOPT = TOleEnum;
  164. const
  165.   OLECMDEXECOPT_DODEFAULT = $00000000;
  166.   OLECMDEXECOPT_PROMPTUSER = $00000001;
  167.   OLECMDEXECOPT_DONTPROMPTUSER = $00000002;
  168.   OLECMDEXECOPT_SHOWHELP = $00000003;
  169.  
  170. // tagREADYSTATE constants
  171. type
  172.   tagREADYSTATE = TOleEnum;
  173. const
  174.   READYSTATE_UNINITIALIZED = $00000000;
  175.   READYSTATE_LOADING = $00000001;
  176.   READYSTATE_LOADED = $00000002;
  177.   READYSTATE_INTERACTIVE = $00000003;
  178.   READYSTATE_COMPLETE = $00000004;
  179.  
  180. // ShellWindowTypeConstants constants
  181. type
  182.   ShellWindowTypeConstants = TOleEnum;
  183. const
  184.   SWC_EXPLORER = $00000000;
  185.   SWC_BROWSER = $00000001;
  186.   SWC_3RDPARTY = $00000002;
  187.   SWC_CALLBACK = $00000004;
  188.  
  189. // ShellWindowFindWindowOptions constants
  190. type
  191.   ShellWindowFindWindowOptions = TOleEnum;
  192. const
  193.   SWFO_NEEDDISPATCH = $00000001;
  194.   SWFO_INCLUDEPENDING = $00000002;
  195.   SWFO_COOKIEPASSED = $00000004;
  196.  
  197. type
  198.   RefreshConstants = TOleEnum;
  199. const
  200.   REFRESH_NORMAL = 0;
  201.   REFRESH_IFEXPIRED = 1;
  202.   REFRESH_CONTINUE = 2;
  203.   REFRESH_COMPLETELY = 3;
  204.  
  205. type
  206.   BrowserNavConstants = TOleEnum;
  207. const
  208.   navOpenInNewWindow = $00000001;
  209.   navNoHistory       = $00000002;
  210.   navNoReadFromCache = $00000004;
  211.   navNoWriteToCache  = $00000008;
  212.   navAllowAutosearch = $00000010;
  213.   navBrowserBar      = $00000020;
  214.  
  215. type
  216.  
  217. // *********************************************************************//
  218. // Forward declaration of types defined in TypeLibrary                    
  219. // *********************************************************************//
  220.   IWebBrowser = interface;
  221.   IWebBrowserDisp = dispinterface;
  222.   DWebBrowserEvents = dispinterface;
  223.   IWebBrowserApp = interface;
  224.   IWebBrowserAppDisp = dispinterface;
  225.   IWebBrowser2 = interface;
  226.   IWebBrowser2Disp = dispinterface;
  227.   DWebBrowserEvents2 = dispinterface;
  228.   DShellWindowsEvents = dispinterface;
  229.   IShellWindows = interface;
  230.   IShellWindowsDisp = dispinterface;
  231.   IShellUIHelper = interface;
  232.   IShellUIHelperDisp = dispinterface;
  233.   _ShellFavoritesNameSpaceEvents = dispinterface;
  234.   IShellFavoritesNameSpace = interface;
  235.   IShellFavoritesNameSpaceDisp = dispinterface;
  236.   IScriptErrorList = interface;
  237.   IScriptErrorListDisp = dispinterface;
  238.   ISearch = interface;
  239.   ISearchDisp = dispinterface;
  240.   ISearches = interface;
  241.   ISearchesDisp = dispinterface;
  242.   ISearchAssistantOC = interface;
  243.   ISearchAssistantOCDisp = dispinterface;
  244.   _SearchAssistantEvents = dispinterface;
  245.  
  246. // *********************************************************************//
  247. // Declaration of CoClasses defined in Type Library                       
  248. // (NOTE: Here we map each CoClass to its Default Interface)              
  249. // *********************************************************************//
  250.   WebBrowser_V1 = IWebBrowser;
  251.   WebBrowser = IWebBrowser2;
  252.   InternetExplorer = IWebBrowser2;
  253.   ShellBrowserWindow = IWebBrowser2;
  254.   ShellWindows = IShellWindows;
  255.   ShellUIHelper = IShellUIHelper;
  256.   ShellFavoritesNameSpace = IShellFavoritesNameSpace;
  257.   CScriptErrorList = IScriptErrorList;
  258.   SearchAssistantOC = ISearchAssistantOC;
  259.  
  260.  
  261. // *********************************************************************//
  262. // Declaration of structures, unions and aliases.                         
  263. // *********************************************************************//
  264.   POleVariant1 = ^OleVariant; {*}
  265.  
  266.  
  267. // *********************************************************************//
  268. // Interface: IWebBrowser
  269. // Flags:     (4432) Hidden Dual OleAutomation Dispatchable
  270. // GUID:      {EAB22AC1-30C1-11CF-A7EB-0000C05BAE0B}
  271. // *********************************************************************//
  272.   IWebBrowser = interface(IDispatch)
  273.     ['{EAB22AC1-30C1-11CF-A7EB-0000C05BAE0B}']
  274.     procedure GoBack; safecall;
  275.     procedure GoForward; safecall;
  276.     procedure GoHome; safecall;
  277.     procedure GoSearch; safecall;
  278.     procedure Navigate(const URL: WideString; var Flags: OleVariant; 
  279.                        var TargetFrameName: OleVariant; var PostData: OleVariant; 
  280.                        var Headers: OleVariant); safecall;
  281.     procedure Refresh; safecall;
  282.     procedure Refresh2(var Level: OleVariant); safecall;
  283.     procedure Stop; safecall;
  284.     function  Get_Application: IDispatch; safecall;
  285.     function  Get_Parent: IDispatch; safecall;
  286.     function  Get_Container: IDispatch; safecall;
  287.     function  Get_Document: IDispatch; safecall;
  288.     function  Get_TopLevelContainer: WordBool; safecall;
  289.     function  Get_Type_: WideString; safecall;
  290.     function  Get_Left: Integer; safecall;
  291.     procedure Set_Left(pl: Integer); safecall;
  292.     function  Get_Top: Integer; safecall;
  293.     procedure Set_Top(pl: Integer); safecall;
  294.     function  Get_Width: Integer; safecall;
  295.     procedure Set_Width(pl: Integer); safecall;
  296.     function  Get_Height: Integer; safecall;
  297.     procedure Set_Height(pl: Integer); safecall;
  298.     function  Get_LocationName: WideString; safecall;
  299.     function  Get_LocationURL: WideString; safecall;
  300.     function  Get_Busy: WordBool; safecall;
  301.     property Application: IDispatch read Get_Application;
  302.     property Parent: IDispatch read Get_Parent;
  303.     property Container: IDispatch read Get_Container;
  304.     property Document: IDispatch read Get_Document;
  305.     property TopLevelContainer: WordBool read Get_TopLevelContainer;
  306.     property Type_: WideString read Get_Type_;
  307.     property Left: Integer read Get_Left write Set_Left;
  308.     property Top: Integer read Get_Top write Set_Top;
  309.     property Width: Integer read Get_Width write Set_Width;
  310.     property Height: Integer read Get_Height write Set_Height;
  311.     property LocationName: WideString read Get_LocationName;
  312.     property LocationURL: WideString read Get_LocationURL;
  313.     property Busy: WordBool read Get_Busy;
  314.   end;
  315.  
  316. // *********************************************************************//
  317. // DispIntf:  IWebBrowserDisp
  318. // Flags:     (4432) Hidden Dual OleAutomation Dispatchable
  319. // GUID:      {EAB22AC1-30C1-11CF-A7EB-0000C05BAE0B}
  320. // *********************************************************************//
  321.   IWebBrowserDisp = dispinterface
  322.     ['{EAB22AC1-30C1-11CF-A7EB-0000C05BAE0B}']
  323.     procedure GoBack; dispid 100;
  324.     procedure GoForward; dispid 101;
  325.     procedure GoHome; dispid 102;
  326.     procedure GoSearch; dispid 103;
  327.     procedure Navigate(const URL: WideString; var Flags: OleVariant; 
  328.                        var TargetFrameName: OleVariant; var PostData: OleVariant; 
  329.                        var Headers: OleVariant); dispid 104;
  330.     procedure Refresh; dispid -550;
  331.     procedure Refresh2(var Level: OleVariant); dispid 105;
  332.     procedure Stop; dispid 106;
  333.     property Application: IDispatch readonly dispid 200;
  334.     property Parent: IDispatch readonly dispid 201;
  335.     property Container: IDispatch readonly dispid 202;
  336.     property Document: IDispatch readonly dispid 203;
  337.     property TopLevelContainer: WordBool readonly dispid 204;
  338.     property Type_: WideString readonly dispid 205;
  339.     property Left: Integer dispid 206;
  340.     property Top: Integer dispid 207;
  341.     property Width: Integer dispid 208;
  342.     property Height: Integer dispid 209;
  343.     property LocationName: WideString readonly dispid 210;
  344.     property LocationURL: WideString readonly dispid 211;
  345.     property Busy: WordBool readonly dispid 212;
  346.   end;
  347.  
  348. // *********************************************************************//
  349. // DispIntf:  DWebBrowserEvents
  350. // Flags:     (4112) Hidden Dispatchable
  351. // GUID:      {EAB22AC2-30C1-11CF-A7EB-0000C05BAE0B}
  352. // *********************************************************************//
  353.   DWebBrowserEvents = dispinterface
  354.     ['{EAB22AC2-30C1-11CF-A7EB-0000C05BAE0B}']
  355.     procedure BeforeNavigate(const URL: WideString; Flags: Integer; 
  356.                              const TargetFrameName: WideString; var PostData: OleVariant; 
  357.                              const Headers: WideString; var Cancel: WordBool); dispid 100;
  358.     procedure NavigateComplete(const URL: WideString); dispid 101;
  359.     procedure StatusTextChange(const Text: WideString); dispid 102;
  360.     procedure ProgressChange(Progress: Integer; ProgressMax: Integer); dispid 108;
  361.     procedure DownloadComplete; dispid 104;
  362.     procedure CommandStateChange(Command: Integer; Enable: WordBool); dispid 105;
  363.     procedure DownloadBegin; dispid 106;
  364.     procedure NewWindow(const URL: WideString; Flags: Integer; const TargetFrameName: WideString; 
  365.                         var PostData: OleVariant; const Headers: WideString; var Processed: WordBool); dispid 107;
  366.     procedure TitleChange(const Text: WideString); dispid 113;
  367.     procedure FrameBeforeNavigate(const URL: WideString; Flags: Integer; 
  368.                                   const TargetFrameName: WideString; var PostData: OleVariant; 
  369.                                   const Headers: WideString; var Cancel: WordBool); dispid 200;
  370.     procedure FrameNavigateComplete(const URL: WideString); dispid 201;
  371.     procedure FrameNewWindow(const URL: WideString; Flags: Integer; 
  372.                              const TargetFrameName: WideString; var PostData: OleVariant; 
  373.                              const Headers: WideString; var Processed: WordBool); dispid 204;
  374.     procedure Quit(var Cancel: WordBool); dispid 103;
  375.     procedure WindowMove; dispid 109;
  376.     procedure WindowResize; dispid 110;
  377.     procedure WindowActivate; dispid 111;
  378.     procedure PropertyChange(const Property_: WideString); dispid 112;
  379.   end;
  380.  
  381. // *********************************************************************//
  382. // Interface: IWebBrowserApp
  383. // Flags:     (4432) Hidden Dual OleAutomation Dispatchable
  384. // GUID:      {0002DF05-0000-0000-C000-000000000046}
  385. // *********************************************************************//
  386.   IWebBrowserApp = interface(IWebBrowser)
  387.     ['{0002DF05-0000-0000-C000-000000000046}']
  388.     procedure Quit; safecall;
  389.     procedure ClientToWindow(var pcx: SYSINT; var pcy: SYSINT); safecall;
  390.     procedure PutProperty(const Property_: WideString; vtValue: OleVariant); safecall;
  391.     function  GetProperty(const Property_: WideString): OleVariant; safecall;
  392.     function  Get_Name: WideString; safecall;
  393.     function  Get_HWND: Integer; safecall;
  394.     function  Get_FullName: WideString; safecall;
  395.     function  Get_Path: WideString; safecall;
  396.     function  Get_Visible: WordBool; safecall;
  397.     procedure Set_Visible(pBool: WordBool); safecall;
  398.     function  Get_StatusBar: WordBool; safecall;
  399.     procedure Set_StatusBar(pBool: WordBool); safecall;
  400.     function  Get_StatusText: WideString; safecall;
  401.     procedure Set_StatusText(const StatusText: WideString); safecall;
  402.     function  Get_ToolBar: SYSINT; safecall;
  403.     procedure Set_ToolBar(Value: SYSINT); safecall;
  404.     function  Get_MenuBar: WordBool; safecall;
  405.     procedure Set_MenuBar(Value: WordBool); safecall;
  406.     function  Get_FullScreen: WordBool; safecall;
  407.     procedure Set_FullScreen(pbFullScreen: WordBool); safecall;
  408.     property Name: WideString read Get_Name;
  409.     property HWND: Integer read Get_HWND;
  410.     property FullName: WideString read Get_FullName;
  411.     property Path: WideString read Get_Path;
  412.     property Visible: WordBool read Get_Visible write Set_Visible;
  413.     property StatusBar: WordBool read Get_StatusBar write Set_StatusBar;
  414.     property StatusText: WideString read Get_StatusText write Set_StatusText;
  415.     property ToolBar: SYSINT read Get_ToolBar write Set_ToolBar;
  416.     property MenuBar: WordBool read Get_MenuBar write Set_MenuBar;
  417.     property FullScreen: WordBool read Get_FullScreen write Set_FullScreen;
  418.   end;
  419.  
  420. // *********************************************************************//
  421. // DispIntf:  IWebBrowserAppDisp
  422. // Flags:     (4432) Hidden Dual OleAutomation Dispatchable
  423. // GUID:      {0002DF05-0000-0000-C000-000000000046}
  424. // *********************************************************************//
  425.   IWebBrowserAppDisp = dispinterface
  426.     ['{0002DF05-0000-0000-C000-000000000046}']
  427.     procedure Quit; dispid 300;
  428.     procedure ClientToWindow(var pcx: SYSINT; var pcy: SYSINT); dispid 301;
  429.     procedure PutProperty(const Property_: WideString; vtValue: OleVariant); dispid 302;
  430.     function  GetProperty(const Property_: WideString): OleVariant; dispid 303;
  431.     property Name: WideString readonly dispid 0;
  432.     property HWND: Integer readonly dispid -515;
  433.     property FullName: WideString readonly dispid 400;
  434.     property Path: WideString readonly dispid 401;
  435.     property Visible: WordBool dispid 402;
  436.     property StatusBar: WordBool dispid 403;
  437.     property StatusText: WideString dispid 404;
  438.     property ToolBar: SYSINT dispid 405;
  439.     property MenuBar: WordBool dispid 406;
  440.     property FullScreen: WordBool dispid 407;
  441.     procedure GoBack; dispid 100;
  442.     procedure GoForward; dispid 101;
  443.     procedure GoHome; dispid 102;
  444.     procedure GoSearch; dispid 103;
  445.     procedure Navigate(const URL: WideString; var Flags: OleVariant; 
  446.                        var TargetFrameName: OleVariant; var PostData: OleVariant; 
  447.                        var Headers: OleVariant); dispid 104;
  448.     procedure Refresh; dispid -550;
  449.     procedure Refresh2(var Level: OleVariant); dispid 105;
  450.     procedure Stop; dispid 106;
  451.     property Application: IDispatch readonly dispid 200;
  452.     property Parent: IDispatch readonly dispid 201;
  453.     property Container: IDispatch readonly dispid 202;
  454.     property Document: IDispatch readonly dispid 203;
  455.     property TopLevelContainer: WordBool readonly dispid 204;
  456.     property Type_: WideString readonly dispid 205;
  457.     property Left: Integer dispid 206;
  458.     property Top: Integer dispid 207;
  459.     property Width: Integer dispid 208;
  460.     property Height: Integer dispid 209;
  461.     property LocationName: WideString readonly dispid 210;
  462.     property LocationURL: WideString readonly dispid 211;
  463.     property Busy: WordBool readonly dispid 212;
  464.   end;
  465.  
  466. // *********************************************************************//
  467. // Interface: IWebBrowser2
  468. // Flags:     (4432) Hidden Dual OleAutomation Dispatchable
  469. // GUID:      {D30C1661-CDAF-11D0-8A3E-00C04FC9E26E}
  470. // *********************************************************************//
  471.   IWebBrowser2 = interface(IWebBrowserApp)
  472.     ['{D30C1661-CDAF-11D0-8A3E-00C04FC9E26E}']
  473.     procedure Navigate2(var URL: OleVariant; var Flags: OleVariant; 
  474.                         var TargetFrameName: OleVariant; var PostData: OleVariant; 
  475.                         var Headers: OleVariant); safecall;
  476.     function  QueryStatusWB(cmdID: OLECMDID): OLECMDF; safecall;
  477.     procedure ExecWB(cmdID: OLECMDID; cmdexecopt: OLECMDEXECOPT; var pvaIn: OleVariant; 
  478.                      var pvaOut: OleVariant); safecall;
  479.     procedure ShowBrowserBar(var pvaClsid: OleVariant; var pvarShow: OleVariant; 
  480.                              var pvarSize: OleVariant); safecall;
  481.     function  Get_ReadyState: tagREADYSTATE; safecall;
  482.     function  Get_Offline: WordBool; safecall;
  483.     procedure Set_Offline(pbOffline: WordBool); safecall;
  484.     function  Get_Silent: WordBool; safecall;
  485.     procedure Set_Silent(pbSilent: WordBool); safecall;
  486.     function  Get_RegisterAsBrowser: WordBool; safecall;
  487.     procedure Set_RegisterAsBrowser(pbRegister: WordBool); safecall;
  488.     function  Get_RegisterAsDropTarget: WordBool; safecall;
  489.     procedure Set_RegisterAsDropTarget(pbRegister: WordBool); safecall;
  490.     function  Get_TheaterMode: WordBool; safecall;
  491.     procedure Set_TheaterMode(pbRegister: WordBool); safecall;
  492.     function  Get_AddressBar: WordBool; safecall;
  493.     procedure Set_AddressBar(Value: WordBool); safecall;
  494.     function  Get_Resizable: WordBool; safecall;
  495.     procedure Set_Resizable(Value: WordBool); safecall;
  496.     property ReadyState: tagREADYSTATE read Get_ReadyState;
  497.     property Offline: WordBool read Get_Offline write Set_Offline;
  498.     property Silent: WordBool read Get_Silent write Set_Silent;
  499.     property RegisterAsBrowser: WordBool read Get_RegisterAsBrowser write Set_RegisterAsBrowser;
  500.     property RegisterAsDropTarget: WordBool read Get_RegisterAsDropTarget write Set_RegisterAsDropTarget;
  501.     property TheaterMode: WordBool read Get_TheaterMode write Set_TheaterMode;
  502.     property AddressBar: WordBool read Get_AddressBar write Set_AddressBar;
  503.     property Resizable: WordBool read Get_Resizable write Set_Resizable;
  504.   end;
  505.  
  506. // *********************************************************************//
  507. // DispIntf:  IWebBrowser2Disp
  508. // Flags:     (4432) Hidden Dual OleAutomation Dispatchable
  509. // GUID:      {D30C1661-CDAF-11D0-8A3E-00C04FC9E26E}
  510. // *********************************************************************//
  511.   IWebBrowser2Disp = dispinterface
  512.     ['{D30C1661-CDAF-11D0-8A3E-00C04FC9E26E}']
  513.     procedure Navigate2(var URL: OleVariant; var Flags: OleVariant; 
  514.                         var TargetFrameName: OleVariant; var PostData: OleVariant; 
  515.                         var Headers: OleVariant); dispid 500;
  516.     function  QueryStatusWB(cmdID: OLECMDID): OLECMDF; dispid 501;
  517.     procedure ExecWB(cmdID: OLECMDID; cmdexecopt: OLECMDEXECOPT; var pvaIn: OleVariant; 
  518.                      var pvaOut: OleVariant); dispid 502;
  519.     procedure ShowBrowserBar(var pvaClsid: OleVariant; var pvarShow: OleVariant; 
  520.                              var pvarSize: OleVariant); dispid 503;
  521.     property ReadyState: tagREADYSTATE readonly dispid -525;
  522.     property Offline: WordBool dispid 550;
  523.     property Silent: WordBool dispid 551;
  524.     property RegisterAsBrowser: WordBool dispid 552;
  525.     property RegisterAsDropTarget: WordBool dispid 553;
  526.     property TheaterMode: WordBool dispid 554;
  527.     property AddressBar: WordBool dispid 555;
  528.     property Resizable: WordBool dispid 556;
  529.     procedure Quit; dispid 300;
  530.     procedure ClientToWindow(var pcx: SYSINT; var pcy: SYSINT); dispid 301;
  531.     procedure PutProperty(const Property_: WideString; vtValue: OleVariant); dispid 302;
  532.     function  GetProperty(const Property_: WideString): OleVariant; dispid 303;
  533.     property Name: WideString readonly dispid 0;
  534.     property HWND: Integer readonly dispid -515;
  535.     property FullName: WideString readonly dispid 400;
  536.     property Path: WideString readonly dispid 401;
  537.     property Visible: WordBool dispid 402;
  538.     property StatusBar: WordBool dispid 403;
  539.     property StatusText: WideString dispid 404;
  540.     property ToolBar: SYSINT dispid 405;
  541.     property MenuBar: WordBool dispid 406;
  542.     property FullScreen: WordBool dispid 407;
  543.     procedure GoBack; dispid 100;
  544.     procedure GoForward; dispid 101;
  545.     procedure GoHome; dispid 102;
  546.     procedure GoSearch; dispid 103;
  547.     procedure Navigate(const URL: WideString; var Flags: OleVariant; 
  548.                        var TargetFrameName: OleVariant; var PostData: OleVariant; 
  549.                        var Headers: OleVariant); dispid 104;
  550.     procedure Refresh; dispid -550;
  551.     procedure Refresh2(var Level: OleVariant); dispid 105;
  552.     procedure Stop; dispid 106;
  553.     property Application: IDispatch readonly dispid 200;
  554.     property Parent: IDispatch readonly dispid 201;
  555.     property Container: IDispatch readonly dispid 202;
  556.     property Document: IDispatch readonly dispid 203;
  557.     property TopLevelContainer: WordBool readonly dispid 204;
  558.     property Type_: WideString readonly dispid 205;
  559.     property Left: Integer dispid 206;
  560.     property Top: Integer dispid 207;
  561.     property Width: Integer dispid 208;
  562.     property Height: Integer dispid 209;
  563.     property LocationName: WideString readonly dispid 210;
  564.     property LocationURL: WideString readonly dispid 211;
  565.     property Busy: WordBool readonly dispid 212;
  566.   end;
  567.  
  568. // *********************************************************************//
  569. // DispIntf:  DWebBrowserEvents2
  570. // Flags:     (4112) Hidden Dispatchable
  571. // GUID:      {34A715A0-6587-11D0-924A-0020AFC7AC4D}
  572. // *********************************************************************//
  573.   DWebBrowserEvents2 = dispinterface
  574.     ['{34A715A0-6587-11D0-924A-0020AFC7AC4D}']
  575.     procedure StatusTextChange(const Text: WideString); dispid 102;
  576.     procedure ProgressChange(Progress: Integer; ProgressMax: Integer); dispid 108;
  577.     procedure CommandStateChange(Command: Integer; Enable: WordBool); dispid 105;
  578.     procedure DownloadBegin; dispid 106;
  579.     procedure DownloadComplete; dispid 104;
  580.     procedure TitleChange(const Text: WideString); dispid 113;
  581.     procedure PropertyChange(const szProperty: WideString); dispid 112;
  582.     procedure BeforeNavigate2(const pDisp: IDispatch; var URL: OleVariant; var Flags: OleVariant; 
  583.                               var TargetFrameName: OleVariant; var PostData: OleVariant; 
  584.                               var Headers: OleVariant; var Cancel: WordBool); dispid 250;
  585.     procedure NewWindow2(var ppDisp: IDispatch; var Cancel: WordBool); dispid 251;
  586.     procedure NavigateComplete2(const pDisp: IDispatch; var URL: OleVariant); dispid 252;
  587.     procedure DocumentComplete(const pDisp: IDispatch; var URL: OleVariant); dispid 259;
  588.     procedure OnQuit; dispid 253;
  589.     procedure OnVisible(Visible: WordBool); dispid 254;
  590.     procedure OnToolBar(ToolBar: WordBool); dispid 255;
  591.     procedure OnMenuBar(MenuBar: WordBool); dispid 256;
  592.     procedure OnStatusBar(StatusBar: WordBool); dispid 257;
  593.     procedure OnFullScreen(FullScreen: WordBool); dispid 258;
  594.     procedure OnTheaterMode(TheaterMode: WordBool); dispid 260;
  595.   end;
  596.  
  597. // *********************************************************************//
  598. // DispIntf:  DShellWindowsEvents
  599. // Flags:     (4096) Dispatchable
  600. // GUID:      {FE4106E0-399A-11D0-A48C-00A0C90A8F39}
  601. // *********************************************************************//
  602.   DShellWindowsEvents = dispinterface
  603.     ['{FE4106E0-399A-11D0-A48C-00A0C90A8F39}']
  604.     procedure WindowRegistered(lCookie: Integer); dispid 200;
  605.     procedure WindowRevoked(lCookie: Integer); dispid 201;
  606.   end;
  607.  
  608. // *********************************************************************//
  609. // Interface: IShellWindows
  610. // Flags:     (4416) Dual OleAutomation Dispatchable
  611. // GUID:      {85CB6900-4D95-11CF-960C-0080C7F4EE85}
  612. // *********************************************************************//
  613.   IShellWindows = interface(IDispatch)
  614.     ['{85CB6900-4D95-11CF-960C-0080C7F4EE85}']
  615.     function  Get_Count: Integer; safecall;
  616.     function  Item(index: OleVariant): IDispatch; safecall;
  617.     function  _NewEnum: IUnknown; safecall;
  618.     procedure Register(const pid: IDispatch; HWND: Integer; swClass: SYSINT; out plCookie: Integer); safecall;
  619.     procedure RegisterPending(lThreadId: Integer; var pvarloc: OleVariant; 
  620.                               var pvarlocRoot: OleVariant; swClass: SYSINT; out plCookie: Integer); safecall;
  621.     procedure Revoke(lCookie: Integer); safecall;
  622.     procedure OnNavigate(lCookie: Integer; var pvarloc: OleVariant); safecall;
  623.     procedure OnActivated(lCookie: Integer; fActive: WordBool); safecall;
  624.     function  FindWindow(var pvarloc: OleVariant; var pvarlocRoot: OleVariant; swClass: SYSINT; 
  625.                          out pHWND: Integer; swfwOptions: SYSINT): IDispatch; safecall;
  626.     procedure OnCreated(lCookie: Integer; const punk: IUnknown); safecall;
  627.     procedure ProcessAttachDetach(fAttach: WordBool); safecall;
  628.     property Count: Integer read Get_Count;
  629.   end;
  630.  
  631. // *********************************************************************//
  632. // DispIntf:  IShellWindowsDisp
  633. // Flags:     (4416) Dual OleAutomation Dispatchable
  634. // GUID:      {85CB6900-4D95-11CF-960C-0080C7F4EE85}
  635. // *********************************************************************//
  636.   IShellWindowsDisp = dispinterface
  637.     ['{85CB6900-4D95-11CF-960C-0080C7F4EE85}']
  638.     property Count: Integer readonly dispid 1610743808;
  639.     function  Item(index: OleVariant): IDispatch; dispid 0;
  640.     function  _NewEnum: IUnknown; dispid -4;
  641.     procedure Register(const pid: IDispatch; HWND: Integer; swClass: SYSINT; out plCookie: Integer); dispid 1610743811;
  642.     procedure RegisterPending(lThreadId: Integer; var pvarloc: OleVariant; 
  643.                               var pvarlocRoot: OleVariant; swClass: SYSINT; out plCookie: Integer); dispid 1610743812;
  644.     procedure Revoke(lCookie: Integer); dispid 1610743813;
  645.     procedure OnNavigate(lCookie: Integer; var pvarloc: OleVariant); dispid 1610743814;
  646.     procedure OnActivated(lCookie: Integer; fActive: WordBool); dispid 1610743815;
  647.     function  FindWindow(var pvarloc: OleVariant; var pvarlocRoot: OleVariant; swClass: SYSINT; 
  648.                          out pHWND: Integer; swfwOptions: SYSINT): IDispatch; dispid 1610743816;
  649.     procedure OnCreated(lCookie: Integer; const punk: IUnknown); dispid 1610743817;
  650.     procedure ProcessAttachDetach(fAttach: WordBool); dispid 1610743818;
  651.   end;
  652.  
  653. // *********************************************************************//
  654. // Interface: IShellUIHelper
  655. // Flags:     (4416) Dual OleAutomation Dispatchable
  656. // GUID:      {729FE2F8-1EA8-11D1-8F85-00C04FC2FBE1}
  657. // *********************************************************************//
  658.   IShellUIHelper = interface(IDispatch)
  659.     ['{729FE2F8-1EA8-11D1-8F85-00C04FC2FBE1}']
  660.     procedure ResetFirstBootMode; safecall;
  661.     procedure ResetSafeMode; safecall;
  662.     procedure RefreshOfflineDesktop; safecall;
  663.     procedure AddFavorite(const URL: WideString; var Title: OleVariant); safecall;
  664.     procedure AddChannel(const URL: WideString); safecall;
  665.     procedure AddDesktopComponent(const URL: WideString; const Type_: WideString; 
  666.                                   var Left: OleVariant; var Top: OleVariant; var Width: OleVariant; 
  667.                                   var Height: OleVariant); safecall;
  668.     function  IsSubscribed(const URL: WideString): WordBool; safecall;
  669.     procedure NavigateAndFind(const URL: WideString; const strQuery: WideString; 
  670.                               var varTargetFrame: OleVariant); safecall;
  671.     procedure ImportExportFavorites(fImport: WordBool; const strImpExpPath: WideString); safecall;
  672.     procedure AutoCompleteSaveForm(var Form: OleVariant); safecall;
  673.     procedure AutoScan(const strSearch: WideString; const strFailureUrl: WideString; 
  674.                        var pvarTargetFrame: OleVariant); safecall;
  675.     procedure AutoCompleteAttach(var Reserved: OleVariant); safecall;
  676.     function  ShowBrowserUI(const bstrName: WideString; var pvarIn: OleVariant): OleVariant; safecall;
  677.   end;
  678.  
  679. // *********************************************************************//
  680. // DispIntf:  IShellUIHelperDisp
  681. // Flags:     (4416) Dual OleAutomation Dispatchable
  682. // GUID:      {729FE2F8-1EA8-11D1-8F85-00C04FC2FBE1}
  683. // *********************************************************************//
  684.   IShellUIHelperDisp = dispinterface
  685.     ['{729FE2F8-1EA8-11D1-8F85-00C04FC2FBE1}']
  686.     procedure ResetFirstBootMode; dispid 1;
  687.     procedure ResetSafeMode; dispid 2;
  688.     procedure RefreshOfflineDesktop; dispid 3;
  689.     procedure AddFavorite(const URL: WideString; var Title: OleVariant); dispid 4;
  690.     procedure AddChannel(const URL: WideString); dispid 5;
  691.     procedure AddDesktopComponent(const URL: WideString; const Type_: WideString; 
  692.                                   var Left: OleVariant; var Top: OleVariant; var Width: OleVariant; 
  693.                                   var Height: OleVariant); dispid 6;
  694.     function  IsSubscribed(const URL: WideString): WordBool; dispid 7;
  695.     procedure NavigateAndFind(const URL: WideString; const strQuery: WideString; 
  696.                               var varTargetFrame: OleVariant); dispid 8;
  697.     procedure ImportExportFavorites(fImport: WordBool; const strImpExpPath: WideString); dispid 9;
  698.     procedure AutoCompleteSaveForm(var Form: OleVariant); dispid 10;
  699.     procedure AutoScan(const strSearch: WideString; const strFailureUrl: WideString; 
  700.                        var pvarTargetFrame: OleVariant); dispid 11;
  701.     procedure AutoCompleteAttach(var Reserved: OleVariant); dispid 12;
  702.     function  ShowBrowserUI(const bstrName: WideString; var pvarIn: OleVariant): OleVariant; dispid 13;
  703.   end;
  704.  
  705. // *********************************************************************//
  706. // DispIntf:  _ShellFavoritesNameSpaceEvents
  707. // Flags:     (4096) Dispatchable
  708. // GUID:      {55136806-B2DE-11D1-B9F2-00A0C98BC547}
  709. // *********************************************************************//
  710.   _ShellFavoritesNameSpaceEvents = dispinterface
  711.     ['{55136806-B2DE-11D1-B9F2-00A0C98BC547}']
  712.     procedure FavoritesSelectionChange(cItems: Integer; hItem: Integer; const strName: WideString; 
  713.                                        const strUrl: WideString; cVisits: Integer; 
  714.                                        const strDate: WideString; fAvailableOffline: Integer); dispid 1;
  715.   end;
  716.  
  717. // *********************************************************************//
  718. // Interface: IShellFavoritesNameSpace
  719. // Flags:     (4416) Dual OleAutomation Dispatchable
  720. // GUID:      {55136804-B2DE-11D1-B9F2-00A0C98BC547}
  721. // *********************************************************************//
  722.   IShellFavoritesNameSpace = interface(IDispatch)
  723.     ['{55136804-B2DE-11D1-B9F2-00A0C98BC547}']
  724.     procedure MoveSelectionUp; safecall;
  725.     procedure MoveSelectionDown; safecall;
  726.     procedure ResetSort; safecall;
  727.     procedure NewFolder; safecall;
  728.     procedure Synchronize; safecall;
  729.     procedure Import; safecall;
  730.     procedure Export; safecall;
  731.     procedure InvokeContextMenuCommand(const strCommand: WideString); safecall;
  732.     procedure MoveSelectionTo; safecall;
  733.     function  Get_FOfflinePackInstalled: WordBool; safecall;
  734.     function  CreateSubscriptionForSelection: WordBool; safecall;
  735.     function  DeleteSubscriptionForSelection: WordBool; safecall;
  736.     procedure SetRoot(const bstrFullPath: WideString); safecall;
  737.     property FOfflinePackInstalled: WordBool read Get_FOfflinePackInstalled;
  738.   end;
  739.  
  740. // *********************************************************************//
  741. // DispIntf:  IShellFavoritesNameSpaceDisp
  742. // Flags:     (4416) Dual OleAutomation Dispatchable
  743. // GUID:      {55136804-B2DE-11D1-B9F2-00A0C98BC547}
  744. // *********************************************************************//
  745.   IShellFavoritesNameSpaceDisp = dispinterface
  746.     ['{55136804-B2DE-11D1-B9F2-00A0C98BC547}']
  747.     procedure MoveSelectionUp; dispid 1;
  748.     procedure MoveSelectionDown; dispid 2;
  749.     procedure ResetSort; dispid 3;
  750.     procedure NewFolder; dispid 4;
  751.     procedure Synchronize; dispid 5;
  752.     procedure Import; dispid 6;
  753.     procedure Export; dispid 7;
  754.     procedure InvokeContextMenuCommand(const strCommand: WideString); dispid 8;
  755.     procedure MoveSelectionTo; dispid 9;
  756.     property FOfflinePackInstalled: WordBool readonly dispid 10;
  757.     function  CreateSubscriptionForSelection: WordBool; dispid 11;
  758.     function  DeleteSubscriptionForSelection: WordBool; dispid 12;
  759.     procedure SetRoot(const bstrFullPath: WideString); dispid 13;
  760.   end;
  761.  
  762. // *********************************************************************//
  763. // Interface: IScriptErrorList
  764. // Flags:     (4432) Hidden Dual OleAutomation Dispatchable
  765. // GUID:      {F3470F24-15FD-11D2-BB2E-00805FF7EFCA}
  766. // *********************************************************************//
  767.   IScriptErrorList = interface(IDispatch)
  768.     ['{F3470F24-15FD-11D2-BB2E-00805FF7EFCA}']
  769.     procedure advanceError; safecall;
  770.     procedure retreatError; safecall;
  771.     function  canAdvanceError: Integer; safecall;
  772.     function  canRetreatError: Integer; safecall;
  773.     function  getErrorLine: Integer; safecall;
  774.     function  getErrorChar: Integer; safecall;
  775.     function  getErrorCode: Integer; safecall;
  776.     function  getErrorMsg: WideString; safecall;
  777.     function  getErrorUrl: WideString; safecall;
  778.     function  getAlwaysShowLockState: Integer; safecall;
  779.     function  getDetailsPaneOpen: Integer; safecall;
  780.     procedure setDetailsPaneOpen(fDetailsPaneOpen: Integer); safecall;
  781.     function  getPerErrorDisplay: Integer; safecall;
  782.     procedure setPerErrorDisplay(fPerErrorDisplay: Integer); safecall;
  783.   end;
  784.  
  785. // *********************************************************************//
  786. // DispIntf:  IScriptErrorListDisp
  787. // Flags:     (4432) Hidden Dual OleAutomation Dispatchable
  788. // GUID:      {F3470F24-15FD-11D2-BB2E-00805FF7EFCA}
  789. // *********************************************************************//
  790.   IScriptErrorListDisp = dispinterface
  791.     ['{F3470F24-15FD-11D2-BB2E-00805FF7EFCA}']
  792.     procedure advanceError; dispid 10;
  793.     procedure retreatError; dispid 11;
  794.     function  canAdvanceError: Integer; dispid 12;
  795.     function  canRetreatError: Integer; dispid 13;
  796.     function  getErrorLine: Integer; dispid 14;
  797.     function  getErrorChar: Integer; dispid 15;
  798.     function  getErrorCode: Integer; dispid 16;
  799.     function  getErrorMsg: WideString; dispid 17;
  800.     function  getErrorUrl: WideString; dispid 18;
  801.     function  getAlwaysShowLockState: Integer; dispid 23;
  802.     function  getDetailsPaneOpen: Integer; dispid 19;
  803.     procedure setDetailsPaneOpen(fDetailsPaneOpen: Integer); dispid 20;
  804.     function  getPerErrorDisplay: Integer; dispid 21;
  805.     procedure setPerErrorDisplay(fPerErrorDisplay: Integer); dispid 22;
  806.   end;
  807.  
  808. // *********************************************************************//
  809. // Interface: ISearch
  810. // Flags:     (4432) Hidden Dual OleAutomation Dispatchable
  811. // GUID:      {BA9239A4-3DD5-11D2-BF8B-00C04FB93661}
  812. // *********************************************************************//
  813.   ISearch = interface(IDispatch)
  814.     ['{BA9239A4-3DD5-11D2-BF8B-00C04FB93661}']
  815.     function  Get_Title: WideString; safecall;
  816.     function  Get_Id: WideString; safecall;
  817.     function  Get_URL: WideString; safecall;
  818.     property Title: WideString read Get_Title;
  819.     property Id: WideString read Get_Id;
  820.     property URL: WideString read Get_URL;
  821.   end;
  822.  
  823. // *********************************************************************//
  824. // DispIntf:  ISearchDisp
  825. // Flags:     (4432) Hidden Dual OleAutomation Dispatchable
  826. // GUID:      {BA9239A4-3DD5-11D2-BF8B-00C04FB93661}
  827. // *********************************************************************//
  828.   ISearchDisp = dispinterface
  829.     ['{BA9239A4-3DD5-11D2-BF8B-00C04FB93661}']
  830.     property Title: WideString readonly dispid 1610743808;
  831.     property Id: WideString readonly dispid 1610743809;
  832.     property URL: WideString readonly dispid 1610743810;
  833.   end;
  834.  
  835. // *********************************************************************//
  836. // Interface: ISearches
  837. // Flags:     (4432) Hidden Dual OleAutomation Dispatchable
  838. // GUID:      {47C922A2-3DD5-11D2-BF8B-00C04FB93661}
  839. // *********************************************************************//
  840.   ISearches = interface(IDispatch)
  841.     ['{47C922A2-3DD5-11D2-BF8B-00C04FB93661}']
  842.     function  Get_Count: Integer; safecall;
  843.     function  Get_Default: WideString; safecall;
  844.     function  Item(index: OleVariant): ISearch; safecall;
  845.     function  _NewEnum: IUnknown; safecall;
  846.     property Count: Integer read Get_Count;
  847.     property Default: WideString read Get_Default;
  848.   end;
  849.  
  850. // *********************************************************************//
  851. // DispIntf:  ISearchesDisp
  852. // Flags:     (4432) Hidden Dual OleAutomation Dispatchable
  853. // GUID:      {47C922A2-3DD5-11D2-BF8B-00C04FB93661}
  854. // *********************************************************************//
  855.   ISearchesDisp = dispinterface
  856.     ['{47C922A2-3DD5-11D2-BF8B-00C04FB93661}']
  857.     property Count: Integer readonly dispid 1610743808;
  858.     property Default: WideString readonly dispid 1610743809;
  859.     function  Item(index: OleVariant): ISearch; dispid 1610743810;
  860.     function  _NewEnum: IUnknown; dispid -4;
  861.   end;
  862.  
  863. // *********************************************************************//
  864. // Interface: ISearchAssistantOC
  865. // Flags:     (4432) Hidden Dual OleAutomation Dispatchable
  866. // GUID:      {72423E8F-8011-11D2-BE79-00A0C9A83DA1}
  867. // *********************************************************************//
  868.   ISearchAssistantOC = interface(IDispatch)
  869.     ['{72423E8F-8011-11D2-BE79-00A0C9A83DA1}']
  870.     procedure AddNextMenuItem(const bstrText: WideString; idItem: Integer); safecall;
  871.     procedure SetDefaultSearchUrl(const bstrUrl: WideString); safecall;
  872.     procedure NavigateToDefaultSearch; safecall;
  873.     function  IsRestricted(const bstrGuid: WideString): WordBool; safecall;
  874.     function  Get_ShellFeaturesEnabled: WordBool; safecall;
  875.     function  Get_SearchAssistantDefault: WordBool; safecall;
  876.     function  Get_Searches: ISearches; safecall;
  877.     function  Get_InWebFolder: WordBool; safecall;
  878.     procedure PutProperty(bPerLocale: WordBool; const bstrName: WideString; 
  879.                           const bstrValue: WideString); safecall;
  880.     function  GetProperty(bPerLocale: WordBool; const bstrName: WideString): WideString; safecall;
  881.     procedure Set_EventHandled(Param1: WordBool); safecall;
  882.     procedure ResetNextMenu; safecall;
  883.     procedure FindOnWeb; safecall;
  884.     procedure FindFilesOrFolders; safecall;
  885.     procedure FindComputer; safecall;
  886.     procedure FindPrinter; safecall;
  887.     procedure FindPeople; safecall;
  888.     function  GetSearchAssistantURL(bSubstitute: WordBool; bCustomize: WordBool): WideString; safecall;
  889.     procedure NotifySearchSettingsChanged; safecall;
  890.     procedure Set_ASProvider(const pProvider: WideString); safecall;
  891.     function  Get_ASProvider: WideString; safecall;
  892.     procedure Set_ASSetting(pSetting: SYSINT); safecall;
  893.     function  Get_ASSetting: SYSINT; safecall;
  894.     procedure NETDetectNextNavigate; safecall;
  895.     procedure PutFindText(const FindText: WideString); safecall;
  896.     function  Get_Version: SYSINT; safecall;
  897.     function  EncodeString(const bstrValue: WideString; const bstrCharSet: WideString; 
  898.                            bUseUTF8: WordBool): WideString; safecall;
  899.     property ShellFeaturesEnabled: WordBool read Get_ShellFeaturesEnabled;
  900.     property SearchAssistantDefault: WordBool read Get_SearchAssistantDefault;
  901.     property Searches: ISearches read Get_Searches;
  902.     property InWebFolder: WordBool read Get_InWebFolder;
  903.     property EventHandled: WordBool write Set_EventHandled;
  904.     property ASProvider: WideString read Get_ASProvider write Set_ASProvider;
  905.     property ASSetting: SYSINT read Get_ASSetting write Set_ASSetting;
  906.     property Version: SYSINT read Get_Version;
  907.   end;
  908.  
  909. // *********************************************************************//
  910. // DispIntf:  ISearchAssistantOCDisp
  911. // Flags:     (4432) Hidden Dual OleAutomation Dispatchable
  912. // GUID:      {72423E8F-8011-11D2-BE79-00A0C9A83DA1}
  913. // *********************************************************************//
  914.   ISearchAssistantOCDisp = dispinterface
  915.     ['{72423E8F-8011-11D2-BE79-00A0C9A83DA1}']
  916.     procedure AddNextMenuItem(const bstrText: WideString; idItem: Integer); dispid 1;
  917.     procedure SetDefaultSearchUrl(const bstrUrl: WideString); dispid 2;
  918.     procedure NavigateToDefaultSearch; dispid 3;
  919.     function  IsRestricted(const bstrGuid: WideString): WordBool; dispid 4;
  920.     property ShellFeaturesEnabled: WordBool readonly dispid 5;
  921.     property SearchAssistantDefault: WordBool readonly dispid 6;
  922.     property Searches: ISearches readonly dispid 7;
  923.     property InWebFolder: WordBool readonly dispid 8;
  924.     procedure PutProperty(bPerLocale: WordBool; const bstrName: WideString; 
  925.                           const bstrValue: WideString); dispid 9;
  926.     function  GetProperty(bPerLocale: WordBool; const bstrName: WideString): WideString; dispid 10;
  927.     property EventHandled: WordBool writeonly dispid 11;
  928.     procedure ResetNextMenu; dispid 12;
  929.     procedure FindOnWeb; dispid 13;
  930.     procedure FindFilesOrFolders; dispid 14;
  931.     procedure FindComputer; dispid 15;
  932.     procedure FindPrinter; dispid 16;
  933.     procedure FindPeople; dispid 17;
  934.     function  GetSearchAssistantURL(bSubstitute: WordBool; bCustomize: WordBool): WideString; dispid 18;
  935.     procedure NotifySearchSettingsChanged; dispid 19;
  936.     property ASProvider: WideString dispid 20;
  937.     property ASSetting: SYSINT dispid 21;
  938.     procedure NETDetectNextNavigate; dispid 22;
  939.     procedure PutFindText(const FindText: WideString); dispid 23;
  940.     property Version: SYSINT readonly dispid 24;
  941.     function  EncodeString(const bstrValue: WideString; const bstrCharSet: WideString; 
  942.                            bUseUTF8: WordBool): WideString; dispid 25;
  943.   end;
  944.  
  945. // *********************************************************************//
  946. // DispIntf:  _SearchAssistantEvents
  947. // Flags:     (4112) Hidden Dispatchable
  948. // GUID:      {1611FDDA-445B-11D2-85DE-00C04FA35C89}
  949. // *********************************************************************//
  950.   _SearchAssistantEvents = dispinterface
  951.     ['{1611FDDA-445B-11D2-85DE-00C04FA35C89}']
  952.     procedure OnNextMenuSelect(idItem: Integer); dispid 1;
  953.     procedure OnNewSearch; dispid 2;
  954.   end;
  955.  
  956.  
  957. // *********************************************************************//
  958. // OLE Control Proxy class declaration
  959. // Control Name     : TWebBrowser_V1
  960. // Help String      : WebBrowser Control
  961. // Default Interface: IWebBrowser
  962. // Def. Intf. DISP? : No
  963. // Event   Interface: DWebBrowserEvents
  964. // TypeFlags        : (34) CanCreate Control
  965. // *********************************************************************//
  966.   TWebBrowser_V1BeforeNavigate = procedure(Sender: TObject; const URL: WideString; Flags: Integer; 
  967.                                                             const TargetFrameName: WideString; 
  968.                                                             var PostData: OleVariant; 
  969.                                                             const Headers: WideString; 
  970.                                                             var Cancel: WordBool) of object;
  971.   TWebBrowser_V1NavigateComplete = procedure(Sender: TObject; const URL: WideString) of object;
  972.   TWebBrowser_V1StatusTextChange = procedure(Sender: TObject; const Text: WideString) of object;
  973.   TWebBrowser_V1ProgressChange = procedure(Sender: TObject; Progress: Integer; ProgressMax: Integer) of object;
  974.   TWebBrowser_V1CommandStateChange = procedure(Sender: TObject; Command: Integer; Enable: WordBool) of object;
  975.   TWebBrowser_V1NewWindow = procedure(Sender: TObject; const URL: WideString; Flags: Integer; 
  976.                                                        const TargetFrameName: WideString; 
  977.                                                        var PostData: OleVariant; 
  978.                                                        const Headers: WideString; 
  979.                                                        var Processed: WordBool) of object;
  980.   TWebBrowser_V1TitleChange = procedure(Sender: TObject; const Text: WideString) of object;
  981.   TWebBrowser_V1FrameBeforeNavigate = procedure(Sender: TObject; const URL: WideString; 
  982.                                                                  Flags: Integer; 
  983.                                                                  const TargetFrameName: WideString; 
  984.                                                                  var PostData: OleVariant; 
  985.                                                                  const Headers: WideString; 
  986.                                                                  var Cancel: WordBool) of object;
  987.   TWebBrowser_V1FrameNavigateComplete = procedure(Sender: TObject; const URL: WideString) of object;
  988.   TWebBrowser_V1FrameNewWindow = procedure(Sender: TObject; const URL: WideString; Flags: Integer; 
  989.                                                             const TargetFrameName: WideString; 
  990.                                                             var PostData: OleVariant; 
  991.                                                             const Headers: WideString; 
  992.                                                             var Processed: WordBool) of object;
  993.   TWebBrowser_V1Quit = procedure(Sender: TObject; var Cancel: WordBool) of object;
  994.   TWebBrowser_V1PropertyChange = procedure(Sender: TObject; const Property_: WideString) of object;
  995.  
  996.   TWebBrowser_V1 = class(TOleControl)
  997.   private
  998.     FOnBeforeNavigate: TWebBrowser_V1BeforeNavigate;
  999.     FOnNavigateComplete: TWebBrowser_V1NavigateComplete;
  1000.     FOnStatusTextChange: TWebBrowser_V1StatusTextChange;
  1001.     FOnProgressChange: TWebBrowser_V1ProgressChange;
  1002.     FOnDownloadComplete: TNotifyEvent;
  1003.     FOnCommandStateChange: TWebBrowser_V1CommandStateChange;
  1004.     FOnDownloadBegin: TNotifyEvent;
  1005.     FOnNewWindow: TWebBrowser_V1NewWindow;
  1006.     FOnTitleChange: TWebBrowser_V1TitleChange;
  1007.     FOnFrameBeforeNavigate: TWebBrowser_V1FrameBeforeNavigate;
  1008.     FOnFrameNavigateComplete: TWebBrowser_V1FrameNavigateComplete;
  1009.     FOnFrameNewWindow: TWebBrowser_V1FrameNewWindow;
  1010.     FOnQuit: TWebBrowser_V1Quit;
  1011.     FOnWindowMove: TNotifyEvent;
  1012.     FOnWindowResize: TNotifyEvent;
  1013.     FOnWindowActivate: TNotifyEvent;
  1014.     FOnPropertyChange: TWebBrowser_V1PropertyChange;
  1015.     FIntf: IWebBrowser;
  1016.     function  GetControlInterface: IWebBrowser;
  1017.   protected
  1018.     procedure CreateControl;
  1019.     procedure InitControlData; override;
  1020.     function  Get_Application: IDispatch;
  1021.     function  Get_Parent: IDispatch;
  1022.     function  Get_Container: IDispatch;
  1023.     function  Get_Document: IDispatch;
  1024.   public
  1025.     procedure GoBack;
  1026.     procedure GoForward;
  1027.     procedure GoHome;
  1028.     procedure GoSearch;
  1029.     procedure Navigate(const URL: WideString); overload;
  1030.     procedure Navigate(const URL: WideString; var Flags: OleVariant); overload;
  1031.     procedure Navigate(const URL: WideString; var Flags: OleVariant; var TargetFrameName: OleVariant); overload;
  1032.     procedure Navigate(const URL: WideString; var Flags: OleVariant; 
  1033.                        var TargetFrameName: OleVariant; var PostData: OleVariant); overload;
  1034.     procedure Navigate(const URL: WideString; var Flags: OleVariant; 
  1035.                        var TargetFrameName: OleVariant; var PostData: OleVariant; 
  1036.                        var Headers: OleVariant); overload;
  1037.     procedure Refresh;
  1038.     procedure Refresh2; overload;
  1039.     procedure Refresh2(var Level: OleVariant); overload;
  1040.     procedure Stop;
  1041.     property  ControlInterface: IWebBrowser read GetControlInterface;
  1042.     property  DefaultInterface: IWebBrowser read GetControlInterface;
  1043.     property Application: IDispatch index 200 read GetIDispatchProp;
  1044.     property Parent: IDispatch index 201 read GetIDispatchProp;
  1045.     property Container: IDispatch index 202 read GetIDispatchProp;
  1046.     property Document: IDispatch index 203 read GetIDispatchProp;
  1047.     property TopLevelContainer: WordBool index 204 read GetWordBoolProp;
  1048.     property Type_: WideString index 205 read GetWideStringProp;
  1049.     property LocationName: WideString index 210 read GetWideStringProp;
  1050.     property LocationURL: WideString index 211 read GetWideStringProp;
  1051.     property Busy: WordBool index 212 read GetWordBoolProp;
  1052.   published
  1053.     property  TabStop;
  1054.     property  Align;
  1055.     property  DragCursor;
  1056.     property  DragMode;
  1057.     property  ParentShowHint;
  1058.     property  PopupMenu;
  1059.     property  ShowHint;
  1060.     property  TabOrder;
  1061.     property  Visible;
  1062.     property  OnDragDrop;
  1063.     property  OnDragOver;
  1064.     property  OnEndDrag;
  1065.     property  OnEnter;
  1066.     property  OnExit;
  1067.     property  OnStartDrag;
  1068.     property OnBeforeNavigate: TWebBrowser_V1BeforeNavigate read FOnBeforeNavigate write FOnBeforeNavigate;
  1069.     property OnNavigateComplete: TWebBrowser_V1NavigateComplete read FOnNavigateComplete write FOnNavigateComplete;
  1070.     property OnStatusTextChange: TWebBrowser_V1StatusTextChange read FOnStatusTextChange write FOnStatusTextChange;
  1071.     property OnProgressChange: TWebBrowser_V1ProgressChange read FOnProgressChange write FOnProgressChange;
  1072.     property OnDownloadComplete: TNotifyEvent read FOnDownloadComplete write FOnDownloadComplete;
  1073.     property OnCommandStateChange: TWebBrowser_V1CommandStateChange read FOnCommandStateChange write FOnCommandStateChange;
  1074.     property OnDownloadBegin: TNotifyEvent read FOnDownloadBegin write FOnDownloadBegin;
  1075.     property OnNewWindow: TWebBrowser_V1NewWindow read FOnNewWindow write FOnNewWindow;
  1076.     property OnTitleChange: TWebBrowser_V1TitleChange read FOnTitleChange write FOnTitleChange;
  1077.     property OnFrameBeforeNavigate: TWebBrowser_V1FrameBeforeNavigate read FOnFrameBeforeNavigate write FOnFrameBeforeNavigate;
  1078.     property OnFrameNavigateComplete: TWebBrowser_V1FrameNavigateComplete read FOnFrameNavigateComplete write FOnFrameNavigateComplete;
  1079.     property OnFrameNewWindow: TWebBrowser_V1FrameNewWindow read FOnFrameNewWindow write FOnFrameNewWindow;
  1080.     property OnQuit: TWebBrowser_V1Quit read FOnQuit write FOnQuit;
  1081.     property OnWindowMove: TNotifyEvent read FOnWindowMove write FOnWindowMove;
  1082.     property OnWindowResize: TNotifyEvent read FOnWindowResize write FOnWindowResize;
  1083.     property OnWindowActivate: TNotifyEvent read FOnWindowActivate write FOnWindowActivate;
  1084.     property OnPropertyChange: TWebBrowser_V1PropertyChange read FOnPropertyChange write FOnPropertyChange;
  1085.   end;
  1086.  
  1087.  
  1088. // *********************************************************************//
  1089. // OLE Control Proxy class declaration
  1090. // Control Name     : TWebBrowser
  1091. // Help String      : WebBrowser Control
  1092. // Default Interface: IWebBrowser2
  1093. // Def. Intf. DISP? : No
  1094. // Event   Interface: DWebBrowserEvents2
  1095. // TypeFlags        : (34) CanCreate Control
  1096. // *********************************************************************//
  1097.   TWebBrowserStatusTextChange = procedure(Sender: TObject; const Text: WideString) of object;
  1098.   TWebBrowserProgressChange = procedure(Sender: TObject; Progress: Integer; ProgressMax: Integer) of object;
  1099.   TWebBrowserCommandStateChange = procedure(Sender: TObject; Command: Integer; Enable: WordBool) of object;
  1100.   TWebBrowserTitleChange = procedure(Sender: TObject; const Text: WideString) of object;
  1101.   TWebBrowserPropertyChange = procedure(Sender: TObject; const szProperty: WideString) of object;
  1102.   TWebBrowserBeforeNavigate2 = procedure(Sender: TObject; const pDisp: IDispatch; 
  1103.                                                           var URL: OleVariant; 
  1104.                                                           var Flags: OleVariant; 
  1105.                                                           var TargetFrameName: OleVariant; 
  1106.                                                           var PostData: OleVariant; 
  1107.                                                           var Headers: OleVariant; 
  1108.                                                           var Cancel: WordBool) of object;
  1109.   TWebBrowserNewWindow2 = procedure(Sender: TObject; var ppDisp: IDispatch; var Cancel: WordBool) of object;
  1110.   TWebBrowserNavigateComplete2 = procedure(Sender: TObject; const pDisp: IDispatch; 
  1111.                                                             var URL: OleVariant) of object;
  1112.   TWebBrowserDocumentComplete = procedure(Sender: TObject; const pDisp: IDispatch; 
  1113.                                                            var URL: OleVariant) of object;
  1114.   TWebBrowserOnVisible = procedure(Sender: TObject; Visible: WordBool) of object;
  1115.   TWebBrowserOnToolBar = procedure(Sender: TObject; ToolBar: WordBool) of object;
  1116.   TWebBrowserOnMenuBar = procedure(Sender: TObject; MenuBar: WordBool) of object;
  1117.   TWebBrowserOnStatusBar = procedure(Sender: TObject; StatusBar: WordBool) of object;
  1118.   TWebBrowserOnFullScreen = procedure(Sender: TObject; FullScreen: WordBool) of object;
  1119.   TWebBrowserOnTheaterMode = procedure(Sender: TObject; TheaterMode: WordBool) of object;
  1120.  
  1121.   TWebBrowser = class(TOleControl)
  1122.   private
  1123.     FOnStatusTextChange: TWebBrowserStatusTextChange;
  1124.     FOnProgressChange: TWebBrowserProgressChange;
  1125.     FOnCommandStateChange: TWebBrowserCommandStateChange;
  1126.     FOnDownloadBegin: TNotifyEvent;
  1127.     FOnDownloadComplete: TNotifyEvent;
  1128.     FOnTitleChange: TWebBrowserTitleChange;
  1129.     FOnPropertyChange: TWebBrowserPropertyChange;
  1130.     FOnBeforeNavigate2: TWebBrowserBeforeNavigate2;
  1131.     FOnNewWindow2: TWebBrowserNewWindow2;
  1132.     FOnNavigateComplete2: TWebBrowserNavigateComplete2;
  1133.     FOnDocumentComplete: TWebBrowserDocumentComplete;
  1134.     FOnQuit: TNotifyEvent;
  1135.     FOnVisible: TWebBrowserOnVisible;
  1136.     FOnToolBar: TWebBrowserOnToolBar;
  1137.     FOnMenuBar: TWebBrowserOnMenuBar;
  1138.     FOnStatusBar: TWebBrowserOnStatusBar;
  1139.     FOnFullScreen: TWebBrowserOnFullScreen;
  1140.     FOnTheaterMode: TWebBrowserOnTheaterMode;
  1141.     FIntf: IWebBrowser2;
  1142.     function  GetControlInterface: IWebBrowser2;
  1143.   protected
  1144.     procedure CreateControl;
  1145.     procedure InitControlData; override;
  1146.     function  Get_Application: IDispatch;
  1147.     function  Get_Parent: IDispatch;
  1148.     function  Get_Container: IDispatch;
  1149.     function  Get_Document: IDispatch;
  1150.   public
  1151.     procedure GoBack;
  1152.     procedure GoForward;
  1153.     procedure GoHome;
  1154.     procedure GoSearch;
  1155.     procedure Navigate(const URL: WideString); overload;
  1156.     procedure Navigate(const URL: WideString; var Flags: OleVariant); overload;
  1157.     procedure Navigate(const URL: WideString; var Flags: OleVariant; var TargetFrameName: OleVariant); overload;
  1158.     procedure Navigate(const URL: WideString; var Flags: OleVariant; 
  1159.                        var TargetFrameName: OleVariant; var PostData: OleVariant); overload;
  1160.     procedure Navigate(const URL: WideString; var Flags: OleVariant; 
  1161.                        var TargetFrameName: OleVariant; var PostData: OleVariant; 
  1162.                        var Headers: OleVariant); overload;
  1163.     procedure Refresh;
  1164.     procedure Refresh2; overload;
  1165.     procedure Refresh2(var Level: OleVariant); overload;
  1166.     procedure Stop;
  1167.     procedure Quit;
  1168.     procedure ClientToWindow(var pcx: SYSINT; var pcy: SYSINT);
  1169.     procedure PutProperty(const Property_: WideString; vtValue: OleVariant);
  1170.     function  GetProperty(const Property_: WideString): OleVariant;
  1171.     procedure Navigate2(var URL: OleVariant); overload;
  1172.     procedure Navigate2(var URL: OleVariant; var Flags: OleVariant); overload;
  1173.     procedure Navigate2(var URL: OleVariant; var Flags: OleVariant; var TargetFrameName: OleVariant); overload;
  1174.     procedure Navigate2(var URL: OleVariant; var Flags: OleVariant; 
  1175.                         var TargetFrameName: OleVariant; var PostData: OleVariant); overload;
  1176.     procedure Navigate2(var URL: OleVariant; var Flags: OleVariant; 
  1177.                         var TargetFrameName: OleVariant; var PostData: OleVariant; 
  1178.                         var Headers: OleVariant); overload;
  1179.     function  QueryStatusWB(cmdID: OLECMDID): OLECMDF;
  1180.     procedure ExecWB(cmdID: OLECMDID; cmdexecopt: OLECMDEXECOPT); overload;
  1181.     procedure ExecWB(cmdID: OLECMDID; cmdexecopt: OLECMDEXECOPT; var pvaIn: OleVariant); overload;
  1182.     procedure ExecWB(cmdID: OLECMDID; cmdexecopt: OLECMDEXECOPT; var pvaIn: OleVariant; 
  1183.                      var pvaOut: OleVariant); overload;
  1184.     procedure ShowBrowserBar(var pvaClsid: OleVariant); overload;
  1185.     procedure ShowBrowserBar(var pvaClsid: OleVariant; var pvarShow: OleVariant); overload;
  1186.     procedure ShowBrowserBar(var pvaClsid: OleVariant; var pvarShow: OleVariant; 
  1187.                              var pvarSize: OleVariant); overload;
  1188.     property  ControlInterface: IWebBrowser2 read GetControlInterface;
  1189.     property  DefaultInterface: IWebBrowser2 read GetControlInterface;
  1190.     property Application: IDispatch index 200 read GetIDispatchProp;
  1191.     property Parent: IDispatch index 201 read GetIDispatchProp;
  1192.     property Container: IDispatch index 202 read GetIDispatchProp;
  1193.     property Document: IDispatch index 203 read GetIDispatchProp;
  1194.     property TopLevelContainer: WordBool index 204 read GetWordBoolProp;
  1195.     property Type_: WideString index 205 read GetWideStringProp;
  1196.     property LocationName: WideString index 210 read GetWideStringProp;
  1197.     property LocationURL: WideString index 211 read GetWideStringProp;
  1198.     property Busy: WordBool index 212 read GetWordBoolProp;
  1199.     property Name: WideString index 0 read GetWideStringProp;
  1200.     property HWND: Integer index -515 read GetIntegerProp;
  1201.     property FullName: WideString index 400 read GetWideStringProp;
  1202.     property Path: WideString index 401 read GetWideStringProp;
  1203.     property ReadyState: TOleEnum index -525 read GetTOleEnumProp;
  1204.   published
  1205.     property  TabStop;
  1206.     property  Align;
  1207.     property  DragCursor;
  1208.     property  DragMode;
  1209.     property  ParentShowHint;
  1210.     property  PopupMenu;
  1211.     property  ShowHint;
  1212.     property  TabOrder;
  1213.     property  OnDragDrop;
  1214.     property  OnDragOver;
  1215.     property  OnEndDrag;
  1216.     property  OnEnter;
  1217.     property  OnExit;
  1218.     property  OnStartDrag;
  1219.     property Visible: WordBool index 402 read GetWordBoolProp write SetWordBoolProp stored False;
  1220.     property StatusBar: WordBool index 403 read GetWordBoolProp write SetWordBoolProp stored False;
  1221.     property StatusText: WideString index 404 read GetWideStringProp write SetWideStringProp stored False;
  1222.     property ToolBar: Integer index 405 read GetIntegerProp write SetIntegerProp stored False;
  1223.     property MenuBar: WordBool index 406 read GetWordBoolProp write SetWordBoolProp stored False;
  1224.     property FullScreen: WordBool index 407 read GetWordBoolProp write SetWordBoolProp stored False;
  1225.     property Offline: WordBool index 550 read GetWordBoolProp write SetWordBoolProp stored False;
  1226.     property Silent: WordBool index 551 read GetWordBoolProp write SetWordBoolProp stored False;
  1227.     property RegisterAsBrowser: WordBool index 552 read GetWordBoolProp write SetWordBoolProp stored False;
  1228.     property RegisterAsDropTarget: WordBool index 553 read GetWordBoolProp write SetWordBoolProp stored False;
  1229.     property TheaterMode: WordBool index 554 read GetWordBoolProp write SetWordBoolProp stored False;
  1230.     property AddressBar: WordBool index 555 read GetWordBoolProp write SetWordBoolProp stored False;
  1231.     property Resizable: WordBool index 556 read GetWordBoolProp write SetWordBoolProp stored False;
  1232.     property OnStatusTextChange: TWebBrowserStatusTextChange read FOnStatusTextChange write FOnStatusTextChange;
  1233.     property OnProgressChange: TWebBrowserProgressChange read FOnProgressChange write FOnProgressChange;
  1234.     property OnCommandStateChange: TWebBrowserCommandStateChange read FOnCommandStateChange write FOnCommandStateChange;
  1235.     property OnDownloadBegin: TNotifyEvent read FOnDownloadBegin write FOnDownloadBegin;
  1236.     property OnDownloadComplete: TNotifyEvent read FOnDownloadComplete write FOnDownloadComplete;
  1237.     property OnTitleChange: TWebBrowserTitleChange read FOnTitleChange write FOnTitleChange;
  1238.     property OnPropertyChange: TWebBrowserPropertyChange read FOnPropertyChange write FOnPropertyChange;
  1239.     property OnBeforeNavigate2: TWebBrowserBeforeNavigate2 read FOnBeforeNavigate2 write FOnBeforeNavigate2;
  1240.     property OnNewWindow2: TWebBrowserNewWindow2 read FOnNewWindow2 write FOnNewWindow2;
  1241.     property OnNavigateComplete2: TWebBrowserNavigateComplete2 read FOnNavigateComplete2 write FOnNavigateComplete2;
  1242.     property OnDocumentComplete: TWebBrowserDocumentComplete read FOnDocumentComplete write FOnDocumentComplete;
  1243.     property OnQuit: TNotifyEvent read FOnQuit write FOnQuit;
  1244.     property OnVisible: TWebBrowserOnVisible read FOnVisible write FOnVisible;
  1245.     property OnToolBar: TWebBrowserOnToolBar read FOnToolBar write FOnToolBar;
  1246.     property OnMenuBar: TWebBrowserOnMenuBar read FOnMenuBar write FOnMenuBar;
  1247.     property OnStatusBar: TWebBrowserOnStatusBar read FOnStatusBar write FOnStatusBar;
  1248.     property OnFullScreen: TWebBrowserOnFullScreen read FOnFullScreen write FOnFullScreen;
  1249.     property OnTheaterMode: TWebBrowserOnTheaterMode read FOnTheaterMode write FOnTheaterMode;
  1250.   end;
  1251.  
  1252. // *********************************************************************//
  1253. // The Class CoInternetExplorer provides a Create and CreateRemote method to          
  1254. // create instances of the default interface IWebBrowser2 exposed by              
  1255. // the CoClass InternetExplorer. The functions are intended to be used by             
  1256. // clients wishing to automate the CoClass objects exposed by the         
  1257. // server of this typelibrary.                                            
  1258. // *********************************************************************//
  1259.   CoInternetExplorer = class
  1260.     class function Create: IWebBrowser2;
  1261.     class function CreateRemote(const MachineName: string): IWebBrowser2;
  1262.   end;
  1263.  
  1264.   TInternetExplorerStatusTextChange = procedure(Sender: TObject; var Text: OleVariant) of object;
  1265.   TInternetExplorerProgressChange = procedure(Sender: TObject; Progress: Integer; 
  1266.                                                                ProgressMax: Integer) of object;
  1267.   TInternetExplorerCommandStateChange = procedure(Sender: TObject; Command: Integer; 
  1268.                                                                    Enable: WordBool) of object;
  1269.   TInternetExplorerTitleChange = procedure(Sender: TObject; var Text: OleVariant) of object;
  1270.   TInternetExplorerPropertyChange = procedure(Sender: TObject; var szProperty: OleVariant) of object;
  1271.   TInternetExplorerBeforeNavigate2 = procedure(Sender: TObject; var pDisp: OleVariant;
  1272.                                                                 var URL: OleVariant;
  1273.                                                                 var Flags: OleVariant;
  1274.                                                                 var TargetFrameName: OleVariant;
  1275.                                                                 var PostData: OleVariant;
  1276.                                                                 var Headers: OleVariant;
  1277.                                                                 var Cancel: OleVariant) of object;
  1278.   TInternetExplorerNewWindow2 = procedure(Sender: TObject; var ppDisp: OleVariant;
  1279.                                                            var Cancel: OleVariant) of object;
  1280.   TInternetExplorerNavigateComplete2 = procedure(Sender: TObject; var pDisp: OleVariant;
  1281.                                                                   var URL: OleVariant) of object;
  1282.   TInternetExplorerDocumentComplete = procedure(Sender: TObject; var pDisp: OleVariant;
  1283.                                                                  var URL: OleVariant) of object;
  1284.   TInternetExplorerOnVisible = procedure(Sender: TObject; Visible: WordBool) of object;
  1285.   TInternetExplorerOnToolBar = procedure(Sender: TObject; ToolBar: WordBool) of object;
  1286.   TInternetExplorerOnMenuBar = procedure(Sender: TObject; MenuBar: WordBool) of object;
  1287.   TInternetExplorerOnStatusBar = procedure(Sender: TObject; StatusBar: WordBool) of object;
  1288.   TInternetExplorerOnFullScreen = procedure(Sender: TObject; FullScreen: WordBool) of object;
  1289.   TInternetExplorerOnTheaterMode = procedure(Sender: TObject; TheaterMode: WordBool) of object;
  1290.  
  1291.  
  1292. // *********************************************************************//
  1293. // OLE Server Proxy class declaration
  1294. // Server Object    : TInternetExplorer
  1295. // Help String      : Internet Explorer Application.
  1296. // Default Interface: IWebBrowser2
  1297. // Def. Intf. DISP? : No
  1298. // Event   Interface: DWebBrowserEvents2
  1299. // TypeFlags        : (2) CanCreate
  1300. // *********************************************************************//
  1301.  
  1302.  
  1303.   TInternetExplorer = class(TOleServer)
  1304.   private
  1305.     FOnStatusTextChange: TInternetExplorerStatusTextChange;
  1306.     FOnProgressChange: TInternetExplorerProgressChange;
  1307.     FOnCommandStateChange: TInternetExplorerCommandStateChange;
  1308.     FOnDownloadBegin: TNotifyEvent;
  1309.     FOnDownloadComplete: TNotifyEvent;
  1310.     FOnTitleChange: TInternetExplorerTitleChange;
  1311.     FOnPropertyChange: TInternetExplorerPropertyChange;
  1312.     FOnBeforeNavigate2: TInternetExplorerBeforeNavigate2;
  1313.     FOnNewWindow2: TInternetExplorerNewWindow2;
  1314.     FOnNavigateComplete2: TInternetExplorerNavigateComplete2;
  1315.     FOnDocumentComplete: TInternetExplorerDocumentComplete;
  1316.     FOnQuit: TNotifyEvent;
  1317.     FOnVisible: TInternetExplorerOnVisible;
  1318.     FOnToolBar: TInternetExplorerOnToolBar;
  1319.     FOnMenuBar: TInternetExplorerOnMenuBar;
  1320.     FOnStatusBar: TInternetExplorerOnStatusBar;
  1321.     FOnFullScreen: TInternetExplorerOnFullScreen;
  1322.     FOnTheaterMode: TInternetExplorerOnTheaterMode;
  1323.     FIntf:        IWebBrowser2;
  1324.  
  1325.  
  1326.  
  1327.     function      GetDefaultInterface: IWebBrowser2;
  1328.   protected
  1329.     procedure InitServerData; override;
  1330.     procedure InvokeEvent(DispID: TDispID; var Params: TVariantArray); override;
  1331.     function  Get_Application: IDispatch;
  1332.     function  Get_Parent: IDispatch;
  1333.     function  Get_Container: IDispatch;
  1334.     function  Get_Document: IDispatch;
  1335.     function  Get_TopLevelContainer: WordBool;
  1336.     function  Get_Type_: WideString;
  1337.     function  Get_Left: Integer;
  1338.     procedure Set_Left(pl: Integer);
  1339.     function  Get_Top: Integer;
  1340.     procedure Set_Top(pl: Integer);
  1341.     function  Get_Width: Integer;
  1342.     procedure Set_Width(pl: Integer);
  1343.     function  Get_Height: Integer;
  1344.     procedure Set_Height(pl: Integer);
  1345.     function  Get_LocationName: WideString;
  1346.     function  Get_LocationURL: WideString;
  1347.     function  Get_Busy: WordBool;
  1348.     function  Get_Name: WideString;
  1349.     function  Get_HWND: Integer;
  1350.     function  Get_FullName: WideString;
  1351.     function  Get_Path: WideString;
  1352.     function  Get_Visible: WordBool;
  1353.     procedure Set_Visible(pBool: WordBool);
  1354.     function  Get_StatusBar: WordBool;
  1355.     procedure Set_StatusBar(pBool: WordBool);
  1356.     function  Get_StatusText: WideString;
  1357.     procedure Set_StatusText(const StatusText: WideString);
  1358.     function  Get_ToolBar: SYSINT;
  1359.     procedure Set_ToolBar(Value: SYSINT);
  1360.     function  Get_MenuBar: WordBool;
  1361.     procedure Set_MenuBar(Value: WordBool);
  1362.     function  Get_FullScreen: WordBool;
  1363.     procedure Set_FullScreen(pbFullScreen: WordBool);
  1364.     function  Get_ReadyState: tagREADYSTATE;
  1365.     function  Get_Offline: WordBool;
  1366.     procedure Set_Offline(pbOffline: WordBool);
  1367.     function  Get_Silent: WordBool;
  1368.     procedure Set_Silent(pbSilent: WordBool);
  1369.     function  Get_RegisterAsBrowser: WordBool;
  1370.     procedure Set_RegisterAsBrowser(pbRegister: WordBool);
  1371.     function  Get_RegisterAsDropTarget: WordBool;
  1372.     procedure Set_RegisterAsDropTarget(pbRegister: WordBool);
  1373.     function  Get_TheaterMode: WordBool;
  1374.     procedure Set_TheaterMode(pbRegister: WordBool);
  1375.     function  Get_AddressBar: WordBool;
  1376.     procedure Set_AddressBar(Value: WordBool);
  1377.     function  Get_Resizable: WordBool;
  1378.     procedure Set_Resizable(Value: WordBool);
  1379.   public
  1380.     constructor Create(AOwner: TComponent); override;
  1381.     destructor  Destroy; override;
  1382.     procedure Connect; override;
  1383.     procedure ConnectTo(svrIntf: IWebBrowser2);
  1384.     procedure Disconnect; override;
  1385.     procedure GoBack;
  1386.     procedure GoForward;
  1387.     procedure GoHome;
  1388.     procedure GoSearch;
  1389.     procedure Navigate(const URL: WideString); overload;
  1390.     procedure Navigate(const URL: WideString; var Flags: OleVariant); overload;
  1391.     procedure Navigate(const URL: WideString; var Flags: OleVariant; var TargetFrameName: OleVariant); overload;
  1392.     procedure Navigate(const URL: WideString; var Flags: OleVariant; 
  1393.                        var TargetFrameName: OleVariant; var PostData: OleVariant); overload;
  1394.     procedure Navigate(const URL: WideString; var Flags: OleVariant; 
  1395.                        var TargetFrameName: OleVariant; var PostData: OleVariant; 
  1396.                        var Headers: OleVariant); overload;
  1397.     procedure Refresh;
  1398.     procedure Refresh2; overload;
  1399.     procedure Refresh2(var Level: OleVariant); overload;
  1400.     procedure Stop;
  1401.     procedure Quit;
  1402.     procedure ClientToWindow(var pcx: SYSINT; var pcy: SYSINT);
  1403.     procedure PutProperty(const Property_: WideString; vtValue: OleVariant);
  1404.     function  GetProperty(const Property_: WideString): OleVariant;
  1405.     procedure Navigate2(var URL: OleVariant); overload;
  1406.     procedure Navigate2(var URL: OleVariant; var Flags: OleVariant); overload;
  1407.     procedure Navigate2(var URL: OleVariant; var Flags: OleVariant; var TargetFrameName: OleVariant); overload;
  1408.     procedure Navigate2(var URL: OleVariant; var Flags: OleVariant; 
  1409.                         var TargetFrameName: OleVariant; var PostData: OleVariant); overload;
  1410.     procedure Navigate2(var URL: OleVariant; var Flags: OleVariant; 
  1411.                         var TargetFrameName: OleVariant; var PostData: OleVariant; 
  1412.                         var Headers: OleVariant); overload;
  1413.     function  QueryStatusWB(cmdID: OLECMDID): OLECMDF;
  1414.     procedure ExecWB(cmdID: OLECMDID; cmdexecopt: OLECMDEXECOPT); overload;
  1415.     procedure ExecWB(cmdID: OLECMDID; cmdexecopt: OLECMDEXECOPT; var pvaIn: OleVariant); overload;
  1416.     procedure ExecWB(cmdID: OLECMDID; cmdexecopt: OLECMDEXECOPT; var pvaIn: OleVariant; 
  1417.                      var pvaOut: OleVariant); overload;
  1418.     procedure ShowBrowserBar(var pvaClsid: OleVariant); overload;
  1419.     procedure ShowBrowserBar(var pvaClsid: OleVariant; var pvarShow: OleVariant); overload;
  1420.     procedure ShowBrowserBar(var pvaClsid: OleVariant; var pvarShow: OleVariant; 
  1421.                              var pvarSize: OleVariant); overload;
  1422.     property  DefaultInterface: IWebBrowser2 read GetDefaultInterface;
  1423.     property Application: IDispatch read Get_Application;
  1424.     property Parent: IDispatch read Get_Parent;
  1425.     property Container: IDispatch read Get_Container;
  1426.     property Document: IDispatch read Get_Document;
  1427.     property TopLevelContainer: WordBool read Get_TopLevelContainer;
  1428.     property Type_: WideString read Get_Type_;
  1429.     property LocationName: WideString read Get_LocationName;
  1430.     property LocationURL: WideString read Get_LocationURL;
  1431.     property Busy: WordBool read Get_Busy;
  1432.     property Name: WideString read Get_Name;
  1433.     property HWND: Integer read Get_HWND;
  1434.     property FullName: WideString read Get_FullName;
  1435.     property Path: WideString read Get_Path;
  1436.     property ReadyState: tagREADYSTATE read Get_ReadyState;
  1437.     property Left: Integer read Get_Left write Set_Left;
  1438.     property Top: Integer read Get_Top write Set_Top;
  1439.     property Width: Integer read Get_Width write Set_Width;
  1440.     property Height: Integer read Get_Height write Set_Height;
  1441.     property Visible: WordBool read Get_Visible write Set_Visible;
  1442.     property StatusBar: WordBool read Get_StatusBar write Set_StatusBar;
  1443.     property StatusText: WideString read Get_StatusText write Set_StatusText;
  1444.     property ToolBar: SYSINT read Get_ToolBar write Set_ToolBar;
  1445.     property MenuBar: WordBool read Get_MenuBar write Set_MenuBar;
  1446.     property FullScreen: WordBool read Get_FullScreen write Set_FullScreen;
  1447.     property Offline: WordBool read Get_Offline write Set_Offline;
  1448.     property Silent: WordBool read Get_Silent write Set_Silent;
  1449.     property RegisterAsBrowser: WordBool read Get_RegisterAsBrowser write Set_RegisterAsBrowser;
  1450.     property RegisterAsDropTarget: WordBool read Get_RegisterAsDropTarget write Set_RegisterAsDropTarget;
  1451.     property TheaterMode: WordBool read Get_TheaterMode write Set_TheaterMode;
  1452.     property AddressBar: WordBool read Get_AddressBar write Set_AddressBar;
  1453.     property Resizable: WordBool read Get_Resizable write Set_Resizable;
  1454.   published
  1455.  
  1456.  
  1457.     property OnStatusTextChange: TInternetExplorerStatusTextChange read FOnStatusTextChange write FOnStatusTextChange;
  1458.     property OnProgressChange: TInternetExplorerProgressChange read FOnProgressChange write FOnProgressChange;
  1459.     property OnCommandStateChange: TInternetExplorerCommandStateChange read FOnCommandStateChange write FOnCommandStateChange;
  1460.     property OnDownloadBegin: TNotifyEvent read FOnDownloadBegin write FOnDownloadBegin;
  1461.     property OnDownloadComplete: TNotifyEvent read FOnDownloadComplete write FOnDownloadComplete;
  1462.     property OnTitleChange: TInternetExplorerTitleChange read FOnTitleChange write FOnTitleChange;
  1463.     property OnPropertyChange: TInternetExplorerPropertyChange read FOnPropertyChange write FOnPropertyChange;
  1464.     property OnBeforeNavigate2: TInternetExplorerBeforeNavigate2 read FOnBeforeNavigate2 write FOnBeforeNavigate2;
  1465.     property OnNewWindow2: TInternetExplorerNewWindow2 read FOnNewWindow2 write FOnNewWindow2;
  1466.     property OnNavigateComplete2: TInternetExplorerNavigateComplete2 read FOnNavigateComplete2 write FOnNavigateComplete2;
  1467.     property OnDocumentComplete: TInternetExplorerDocumentComplete read FOnDocumentComplete write FOnDocumentComplete;
  1468.     property OnQuit: TNotifyEvent read FOnQuit write FOnQuit;
  1469.     property OnVisible: TInternetExplorerOnVisible read FOnVisible write FOnVisible;
  1470.     property OnToolBar: TInternetExplorerOnToolBar read FOnToolBar write FOnToolBar;
  1471.     property OnMenuBar: TInternetExplorerOnMenuBar read FOnMenuBar write FOnMenuBar;
  1472.     property OnStatusBar: TInternetExplorerOnStatusBar read FOnStatusBar write FOnStatusBar;
  1473.     property OnFullScreen: TInternetExplorerOnFullScreen read FOnFullScreen write FOnFullScreen;
  1474.     property OnTheaterMode: TInternetExplorerOnTheaterMode read FOnTheaterMode write FOnTheaterMode;
  1475.   end;
  1476.  
  1477.  
  1478.  
  1479.  
  1480.  
  1481.  
  1482.  
  1483.  
  1484.  
  1485.  
  1486.  
  1487.  
  1488.  
  1489.  
  1490.  
  1491.  
  1492.  
  1493.  
  1494.  
  1495.  
  1496.  
  1497.  
  1498.  
  1499.  
  1500.  
  1501.  
  1502.  
  1503.  
  1504.  
  1505.  
  1506.  
  1507.  
  1508.  
  1509.  
  1510.  
  1511.  
  1512.  
  1513.  
  1514.  
  1515.  
  1516.  
  1517.  
  1518.  
  1519.  
  1520.  
  1521.  
  1522.  
  1523.  
  1524.  
  1525.  
  1526.  
  1527.  
  1528.  
  1529.  
  1530.  
  1531.  
  1532.  
  1533.  
  1534.  
  1535.  
  1536.  
  1537.  
  1538.  
  1539.  
  1540.  
  1541.  
  1542.  
  1543.  
  1544.  
  1545.  
  1546.  
  1547.  
  1548.  
  1549.  
  1550.  
  1551.  
  1552.  
  1553.  
  1554.  
  1555.  
  1556.  
  1557.  
  1558.  
  1559.  
  1560.  
  1561. // *********************************************************************//
  1562. // The Class CoShellBrowserWindow provides a Create and CreateRemote method to          
  1563. // create instances of the default interface IWebBrowser2 exposed by              
  1564. // the CoClass ShellBrowserWindow. The functions are intended to be used by             
  1565. // clients wishing to automate the CoClass objects exposed by the         
  1566. // server of this typelibrary.                                            
  1567. // *********************************************************************//
  1568.   CoShellBrowserWindow = class
  1569.     class function Create: IWebBrowser2;
  1570.     class function CreateRemote(const MachineName: string): IWebBrowser2;
  1571.   end;
  1572.  
  1573. // *********************************************************************//
  1574. // The Class CoShellWindows provides a Create and CreateRemote method to          
  1575. // create instances of the default interface IShellWindows exposed by              
  1576. // the CoClass ShellWindows. The functions are intended to be used by             
  1577. // clients wishing to automate the CoClass objects exposed by the         
  1578. // server of this typelibrary.                                            
  1579. // *********************************************************************//
  1580.   CoShellWindows = class
  1581.     class function Create: IShellWindows;
  1582.     class function CreateRemote(const MachineName: string): IShellWindows;
  1583.   end;
  1584.  
  1585.   TShellWindowsWindowRegistered = procedure(Sender: TObject; lCookie: Integer) of object;
  1586.   TShellWindowsWindowRevoked = procedure(Sender: TObject; lCookie: Integer) of object;
  1587.  
  1588.  
  1589. // *********************************************************************//
  1590. // OLE Server Proxy class declaration
  1591. // Server Object    : TShellWindows
  1592. // Help String      : ShellDispatch Load in Shell Context
  1593. // Default Interface: IShellWindows
  1594. // Def. Intf. DISP? : No
  1595. // Event   Interface: DShellWindowsEvents
  1596. // TypeFlags        : (2) CanCreate
  1597. // *********************************************************************//
  1598.  
  1599.  
  1600.   TShellWindows = class(TOleServer)
  1601.   private
  1602.     FOnWindowRegistered: TShellWindowsWindowRegistered;
  1603.     FOnWindowRevoked: TShellWindowsWindowRevoked;
  1604.     FIntf:        IShellWindows;
  1605.  
  1606.  
  1607.  
  1608.     function      GetDefaultInterface: IShellWindows;
  1609.   protected
  1610.     procedure InitServerData; override;
  1611.     procedure InvokeEvent(DispID: TDispID; var Params: TVariantArray); override;
  1612.     function  Get_Count: Integer;
  1613.   public
  1614.     constructor Create(AOwner: TComponent); override;
  1615.     destructor  Destroy; override;
  1616.     procedure Connect; override;
  1617.     procedure ConnectTo(svrIntf: IShellWindows);
  1618.     procedure Disconnect; override;
  1619.     function  Item: IDispatch; overload;
  1620.     function  Item(index: OleVariant): IDispatch; overload;
  1621.     function  _NewEnum: IUnknown;
  1622.     procedure Register(const pid: IDispatch; HWND: Integer; swClass: SYSINT; out plCookie: Integer);
  1623.     procedure RegisterPending(lThreadId: Integer; var pvarloc: OleVariant; 
  1624.                               var pvarlocRoot: OleVariant; swClass: SYSINT; out plCookie: Integer);
  1625.     procedure Revoke(lCookie: Integer);
  1626.     procedure OnNavigate(lCookie: Integer; var pvarloc: OleVariant);
  1627.     procedure OnActivated(lCookie: Integer; fActive: WordBool);
  1628.     function  FindWindow(var pvarloc: OleVariant; var pvarlocRoot: OleVariant; swClass: SYSINT; 
  1629.                          out pHWND: Integer; swfwOptions: SYSINT): IDispatch;
  1630.     procedure OnCreated(lCookie: Integer; const punk: IUnknown);
  1631.     procedure ProcessAttachDetach(fAttach: WordBool);
  1632.     property  DefaultInterface: IShellWindows read GetDefaultInterface;
  1633.     property Count: Integer read Get_Count;
  1634.   published
  1635.  
  1636.  
  1637.     property OnWindowRegistered: TShellWindowsWindowRegistered read FOnWindowRegistered write FOnWindowRegistered;
  1638.     property OnWindowRevoked: TShellWindowsWindowRevoked read FOnWindowRevoked write FOnWindowRevoked;
  1639.   end;
  1640.  
  1641.  
  1642.  
  1643.  
  1644.  
  1645.  
  1646.  
  1647.  
  1648.  
  1649.  
  1650.  
  1651.  
  1652.  
  1653.  
  1654.  
  1655.  
  1656.  
  1657.  
  1658.  
  1659.  
  1660.  
  1661. // *********************************************************************//
  1662. // The Class CoShellUIHelper provides a Create and CreateRemote method to          
  1663. // create instances of the default interface IShellUIHelper exposed by              
  1664. // the CoClass ShellUIHelper. The functions are intended to be used by             
  1665. // clients wishing to automate the CoClass objects exposed by the         
  1666. // server of this typelibrary.                                            
  1667. // *********************************************************************//
  1668.   CoShellUIHelper = class
  1669.     class function Create: IShellUIHelper;
  1670.     class function CreateRemote(const MachineName: string): IShellUIHelper;
  1671.   end;
  1672.  
  1673.  
  1674. // *********************************************************************//
  1675. // OLE Server Proxy class declaration
  1676. // Server Object    : TShellUIHelper
  1677. // Help String      : 
  1678. // Default Interface: IShellUIHelper
  1679. // Def. Intf. DISP? : No
  1680. // Event   Interface: 
  1681. // TypeFlags        : (2) CanCreate
  1682. // *********************************************************************//
  1683.  
  1684.  
  1685.   TShellUIHelper = class(TOleServer)
  1686.   private
  1687.     FIntf:        IShellUIHelper;
  1688.  
  1689.  
  1690.  
  1691.     function      GetDefaultInterface: IShellUIHelper;
  1692.   protected
  1693.     procedure InitServerData; override;
  1694.   public
  1695.     constructor Create(AOwner: TComponent); override;
  1696.     destructor  Destroy; override;
  1697.     procedure Connect; override;
  1698.     procedure ConnectTo(svrIntf: IShellUIHelper);
  1699.     procedure Disconnect; override;
  1700.     procedure ResetFirstBootMode;
  1701.     procedure ResetSafeMode;
  1702.     procedure RefreshOfflineDesktop;
  1703.     procedure AddFavorite(const URL: WideString); overload;
  1704.     procedure AddFavorite(const URL: WideString; var Title: OleVariant); overload;
  1705.     procedure AddChannel(const URL: WideString);
  1706.     procedure AddDesktopComponent(const URL: WideString; const Type_: WideString); overload;
  1707.     procedure AddDesktopComponent(const URL: WideString; const Type_: WideString; 
  1708.                                   var Left: OleVariant); overload;
  1709.     procedure AddDesktopComponent(const URL: WideString; const Type_: WideString; 
  1710.                                   var Left: OleVariant; var Top: OleVariant); overload;
  1711.     procedure AddDesktopComponent(const URL: WideString; const Type_: WideString; 
  1712.                                   var Left: OleVariant; var Top: OleVariant; var Width: OleVariant); overload;
  1713.     procedure AddDesktopComponent(const URL: WideString; const Type_: WideString; 
  1714.                                   var Left: OleVariant; var Top: OleVariant; var Width: OleVariant; 
  1715.                                   var Height: OleVariant); overload;
  1716.     function  IsSubscribed(const URL: WideString): WordBool;
  1717.     procedure NavigateAndFind(const URL: WideString; const strQuery: WideString; 
  1718.                               var varTargetFrame: OleVariant);
  1719.     procedure ImportExportFavorites(fImport: WordBool; const strImpExpPath: WideString);
  1720.     procedure AutoCompleteSaveForm; overload;
  1721.     procedure AutoCompleteSaveForm(var Form: OleVariant); overload;
  1722.     procedure AutoScan(const strSearch: WideString; const strFailureUrl: WideString); overload;
  1723.     procedure AutoScan(const strSearch: WideString; const strFailureUrl: WideString; 
  1724.                        var pvarTargetFrame: OleVariant); overload;
  1725.     procedure AutoCompleteAttach; overload;
  1726.     procedure AutoCompleteAttach(var Reserved: OleVariant); overload;
  1727.     function  ShowBrowserUI(const bstrName: WideString; var pvarIn: OleVariant): OleVariant;
  1728.     property  DefaultInterface: IShellUIHelper read GetDefaultInterface;
  1729.   published
  1730.  
  1731.  
  1732.   end;
  1733.  
  1734.  
  1735.  
  1736.  
  1737.  
  1738.  
  1739.  
  1740.  
  1741.  
  1742.  
  1743.  
  1744.  
  1745.  
  1746.  
  1747.  
  1748.  
  1749.  
  1750.  
  1751.  
  1752.  
  1753. // *********************************************************************//
  1754. // The Class CoShellFavoritesNameSpace provides a Create and CreateRemote method to          
  1755. // create instances of the default interface IShellFavoritesNameSpace exposed by              
  1756. // the CoClass ShellFavoritesNameSpace. The functions are intended to be used by             
  1757. // clients wishing to automate the CoClass objects exposed by the         
  1758. // server of this typelibrary.                                            
  1759. // *********************************************************************//
  1760.   CoShellFavoritesNameSpace = class
  1761.     class function Create: IShellFavoritesNameSpace;
  1762.     class function CreateRemote(const MachineName: string): IShellFavoritesNameSpace;
  1763.   end;
  1764.  
  1765.   TShellFavoritesNameSpaceFavoritesSelectionChange = procedure(Sender: TObject; cItems: Integer; 
  1766.                                                                                 hItem: Integer; 
  1767.                                                                                 var strName: OleVariant;
  1768.                                                                                 var strUrl: OleVariant;
  1769.                                                                                 cVisits: Integer; 
  1770.                                                                                 var strDate: OleVariant;
  1771.                                                                                 fAvailableOffline: Integer) of object;
  1772.  
  1773.  
  1774. // *********************************************************************//
  1775. // OLE Server Proxy class declaration
  1776. // Server Object    : TShellFavoritesNameSpace
  1777. // Help String      : 
  1778. // Default Interface: IShellFavoritesNameSpace
  1779. // Def. Intf. DISP? : No
  1780. // Event   Interface: _ShellFavoritesNameSpaceEvents
  1781. // TypeFlags        : (2) CanCreate
  1782. // *********************************************************************//
  1783.  
  1784.  
  1785.   TShellFavoritesNameSpace = class(TOleServer)
  1786.   private
  1787.     FOnFavoritesSelectionChange: TShellFavoritesNameSpaceFavoritesSelectionChange;
  1788.     FIntf:        IShellFavoritesNameSpace;
  1789.  
  1790.  
  1791.  
  1792.     function      GetDefaultInterface: IShellFavoritesNameSpace;
  1793.   protected
  1794.     procedure InitServerData; override;
  1795.     procedure InvokeEvent(DispID: TDispID; var Params: TVariantArray); override;
  1796.     function  Get_FOfflinePackInstalled: WordBool;
  1797.   public
  1798.     constructor Create(AOwner: TComponent); override;
  1799.     destructor  Destroy; override;
  1800.     procedure Connect; override;
  1801.     procedure ConnectTo(svrIntf: IShellFavoritesNameSpace);
  1802.     procedure Disconnect; override;
  1803.     procedure MoveSelectionUp;
  1804.     procedure MoveSelectionDown;
  1805.     procedure ResetSort;
  1806.     procedure NewFolder;
  1807.     procedure Synchronize;
  1808.     procedure Import;
  1809.     procedure Export;
  1810.     procedure InvokeContextMenuCommand(const strCommand: WideString);
  1811.     procedure MoveSelectionTo;
  1812.     function  CreateSubscriptionForSelection: WordBool;
  1813.     function  DeleteSubscriptionForSelection: WordBool;
  1814.     procedure SetRoot(const bstrFullPath: WideString);
  1815.     property  DefaultInterface: IShellFavoritesNameSpace read GetDefaultInterface;
  1816.     property FOfflinePackInstalled: WordBool read Get_FOfflinePackInstalled;
  1817.   published
  1818.  
  1819.  
  1820.     property OnFavoritesSelectionChange: TShellFavoritesNameSpaceFavoritesSelectionChange read FOnFavoritesSelectionChange write FOnFavoritesSelectionChange;
  1821.   end;
  1822.  
  1823.  
  1824.  
  1825.  
  1826.  
  1827.  
  1828.  
  1829.  
  1830.  
  1831.  
  1832.  
  1833.  
  1834.  
  1835.  
  1836.  
  1837.  
  1838.  
  1839.  
  1840.  
  1841.  
  1842.  
  1843. // *********************************************************************//
  1844. // The Class CoCScriptErrorList provides a Create and CreateRemote method to          
  1845. // create instances of the default interface IScriptErrorList exposed by              
  1846. // the CoClass CScriptErrorList. The functions are intended to be used by             
  1847. // clients wishing to automate the CoClass objects exposed by the         
  1848. // server of this typelibrary.                                            
  1849. // *********************************************************************//
  1850.   CoCScriptErrorList = class
  1851.     class function Create: IScriptErrorList;
  1852.     class function CreateRemote(const MachineName: string): IScriptErrorList;
  1853.   end;
  1854.  
  1855. // *********************************************************************//
  1856. // The Class CoSearchAssistantOC provides a Create and CreateRemote method to          
  1857. // create instances of the default interface ISearchAssistantOC exposed by              
  1858. // the CoClass SearchAssistantOC. The functions are intended to be used by             
  1859. // clients wishing to automate the CoClass objects exposed by the         
  1860. // server of this typelibrary.                                            
  1861. // *********************************************************************//
  1862.   CoSearchAssistantOC = class
  1863.     class function Create: ISearchAssistantOC;
  1864.     class function CreateRemote(const MachineName: string): ISearchAssistantOC;
  1865.   end;
  1866.  
  1867. implementation
  1868.  
  1869. uses ComObj;
  1870.  
  1871. procedure TWebBrowser_V1.InitControlData;
  1872. const
  1873.   CEventDispIDs: array [0..16] of DWORD = (
  1874.     $00000064, $00000065, $00000066, $0000006C, $00000068, $00000069,
  1875.     $0000006A, $0000006B, $00000071, $000000C8, $000000C9, $000000CC,
  1876.     $00000067, $0000006D, $0000006E, $0000006F, $00000070);
  1877.   CControlData: TControlData2 = (
  1878.     ClassID: '{EAB22AC3-30C1-11CF-A7EB-0000C05BAE0B}';
  1879.     EventIID: '{EAB22AC2-30C1-11CF-A7EB-0000C05BAE0B}';
  1880.     EventCount: 17;
  1881.     EventDispIDs: @CEventDispIDs;
  1882.     LicenseKey: nil (*HR:$80040154*);
  1883.     Flags: $00000000;
  1884.     Version: 401);
  1885. begin
  1886.   ControlData := @CControlData;
  1887.   TControlData2(CControlData).FirstEventOfs := Cardinal(@@FOnBeforeNavigate) - Cardinal(Self);
  1888. end;
  1889.  
  1890. procedure TWebBrowser_V1.CreateControl;
  1891.  
  1892.   procedure DoCreate;
  1893.   begin
  1894.     FIntf := IUnknown(OleObject) as IWebBrowser;
  1895.   end;
  1896.  
  1897. begin
  1898.   if FIntf = nil then DoCreate;
  1899. end;
  1900.  
  1901. function TWebBrowser_V1.GetControlInterface: IWebBrowser;
  1902. begin
  1903.   CreateControl;
  1904.   Result := FIntf;
  1905. end;
  1906.  
  1907. function  TWebBrowser_V1.Get_Application: IDispatch;
  1908. begin
  1909.   Result := DefaultInterface.Get_Application;
  1910. end;
  1911.  
  1912. function  TWebBrowser_V1.Get_Parent: IDispatch;
  1913. begin
  1914.   Result := DefaultInterface.Get_Parent;
  1915. end;
  1916.  
  1917. function  TWebBrowser_V1.Get_Container: IDispatch;
  1918. begin
  1919.   Result := DefaultInterface.Get_Container;
  1920. end;
  1921.  
  1922. function  TWebBrowser_V1.Get_Document: IDispatch;
  1923. begin
  1924.   Result := DefaultInterface.Get_Document;
  1925. end;
  1926.  
  1927. procedure TWebBrowser_V1.GoBack;
  1928. begin
  1929.   DefaultInterface.GoBack;
  1930. end;
  1931.  
  1932. procedure TWebBrowser_V1.GoForward;
  1933. begin
  1934.   DefaultInterface.GoForward;
  1935. end;
  1936.  
  1937. procedure TWebBrowser_V1.GoHome;
  1938. begin
  1939.   DefaultInterface.GoHome;
  1940. end;
  1941.  
  1942. procedure TWebBrowser_V1.GoSearch;
  1943. begin
  1944.   DefaultInterface.GoSearch;
  1945. end;
  1946.  
  1947. procedure TWebBrowser_V1.Navigate(const URL: WideString);
  1948. begin
  1949.   DefaultInterface.Navigate(URL, EmptyParam, EmptyParam, EmptyParam, EmptyParam);
  1950. end;
  1951.  
  1952. procedure TWebBrowser_V1.Navigate(const URL: WideString; var Flags: OleVariant);
  1953. begin
  1954.   DefaultInterface.Navigate(URL, Flags, EmptyParam, EmptyParam, EmptyParam);
  1955. end;
  1956.  
  1957. procedure TWebBrowser_V1.Navigate(const URL: WideString; var Flags: OleVariant; 
  1958.                                   var TargetFrameName: OleVariant);
  1959. begin
  1960.   DefaultInterface.Navigate(URL, Flags, TargetFrameName, EmptyParam, EmptyParam);
  1961. end;
  1962.  
  1963. procedure TWebBrowser_V1.Navigate(const URL: WideString; var Flags: OleVariant; 
  1964.                                   var TargetFrameName: OleVariant; var PostData: OleVariant);
  1965. begin
  1966.   DefaultInterface.Navigate(URL, Flags, TargetFrameName, PostData, EmptyParam);
  1967. end;
  1968.  
  1969. procedure TWebBrowser_V1.Navigate(const URL: WideString; var Flags: OleVariant; 
  1970.                                   var TargetFrameName: OleVariant; var PostData: OleVariant; 
  1971.                                   var Headers: OleVariant);
  1972. begin
  1973.   DefaultInterface.Navigate(URL, Flags, TargetFrameName, PostData, Headers);
  1974. end;
  1975.  
  1976. procedure TWebBrowser_V1.Refresh;
  1977. begin
  1978.   DefaultInterface.Refresh;
  1979. end;
  1980.  
  1981. procedure TWebBrowser_V1.Refresh2;
  1982. begin
  1983.   DefaultInterface.Refresh2(EmptyParam);
  1984. end;
  1985.  
  1986. procedure TWebBrowser_V1.Refresh2(var Level: OleVariant);
  1987. begin
  1988.   DefaultInterface.Refresh2(Level);
  1989. end;
  1990.  
  1991. procedure TWebBrowser_V1.Stop;
  1992. begin
  1993.   DefaultInterface.Stop;
  1994. end;
  1995.  
  1996. procedure TWebBrowser.InitControlData;
  1997. const
  1998.   CEventDispIDs: array [0..17] of DWORD = (
  1999.     $00000066, $0000006C, $00000069, $0000006A, $00000068, $00000071,
  2000.     $00000070, $000000FA, $000000FB, $000000FC, $00000103, $000000FD,
  2001.     $000000FE, $000000FF, $00000100, $00000101, $00000102, $00000104);
  2002.   CControlData: TControlData2 = (
  2003.     ClassID: '{8856F961-340A-11D0-A96B-00C04FD705A2}';
  2004.     EventIID: '{34A715A0-6587-11D0-924A-0020AFC7AC4D}';
  2005.     EventCount: 18;
  2006.     EventDispIDs: @CEventDispIDs;
  2007.     LicenseKey: nil (*HR:$80040154*);
  2008.     Flags: $00000000;
  2009.     Version: 401);
  2010. begin
  2011.   ControlData := @CControlData;
  2012.   TControlData2(CControlData).FirstEventOfs := Cardinal(@@FOnStatusTextChange) - Cardinal(Self);
  2013. end;
  2014.  
  2015. procedure TWebBrowser.CreateControl;
  2016.  
  2017.   procedure DoCreate;
  2018.   begin
  2019.     FIntf := IUnknown(OleObject) as IWebBrowser2;
  2020.   end;
  2021.  
  2022. begin
  2023.   if FIntf = nil then DoCreate;
  2024. end;
  2025.  
  2026. function TWebBrowser.GetControlInterface: IWebBrowser2;
  2027. begin
  2028.   CreateControl;
  2029.   Result := FIntf;
  2030. end;
  2031.  
  2032. function  TWebBrowser.Get_Application: IDispatch;
  2033. begin
  2034.   Result := DefaultInterface.Get_Application;
  2035. end;
  2036.  
  2037. function  TWebBrowser.Get_Parent: IDispatch;
  2038. begin
  2039.   Result := DefaultInterface.Get_Parent;
  2040. end;
  2041.  
  2042. function  TWebBrowser.Get_Container: IDispatch;
  2043. begin
  2044.   Result := DefaultInterface.Get_Container;
  2045. end;
  2046.  
  2047. function  TWebBrowser.Get_Document: IDispatch;
  2048. begin
  2049.   Result := DefaultInterface.Get_Document;
  2050. end;
  2051.  
  2052. procedure TWebBrowser.GoBack;
  2053. begin
  2054.   DefaultInterface.GoBack;
  2055. end;
  2056.  
  2057. procedure TWebBrowser.GoForward;
  2058. begin
  2059.   DefaultInterface.GoForward;
  2060. end;
  2061.  
  2062. procedure TWebBrowser.GoHome;
  2063. begin
  2064.   DefaultInterface.GoHome;
  2065. end;
  2066.  
  2067. procedure TWebBrowser.GoSearch;
  2068. begin
  2069.   DefaultInterface.GoSearch;
  2070. end;
  2071.  
  2072. procedure TWebBrowser.Navigate(const URL: WideString);
  2073. begin
  2074.   DefaultInterface.Navigate(URL, EmptyParam, EmptyParam, EmptyParam, EmptyParam);
  2075. end;
  2076.  
  2077. procedure TWebBrowser.Navigate(const URL: WideString; var Flags: OleVariant);
  2078. begin
  2079.   DefaultInterface.Navigate(URL, Flags, EmptyParam, EmptyParam, EmptyParam);
  2080. end;
  2081.  
  2082. procedure TWebBrowser.Navigate(const URL: WideString; var Flags: OleVariant; 
  2083.                                var TargetFrameName: OleVariant);
  2084. begin
  2085.   DefaultInterface.Navigate(URL, Flags, TargetFrameName, EmptyParam, EmptyParam);
  2086. end;
  2087.  
  2088. procedure TWebBrowser.Navigate(const URL: WideString; var Flags: OleVariant; 
  2089.                                var TargetFrameName: OleVariant; var PostData: OleVariant);
  2090. begin
  2091.   DefaultInterface.Navigate(URL, Flags, TargetFrameName, PostData, EmptyParam);
  2092. end;
  2093.  
  2094. procedure TWebBrowser.Navigate(const URL: WideString; var Flags: OleVariant; 
  2095.                                var TargetFrameName: OleVariant; var PostData: OleVariant; 
  2096.                                var Headers: OleVariant);
  2097. begin
  2098.   DefaultInterface.Navigate(URL, Flags, TargetFrameName, PostData, Headers);
  2099. end;
  2100.  
  2101. procedure TWebBrowser.Refresh;
  2102. begin
  2103.   DefaultInterface.Refresh;
  2104. end;
  2105.  
  2106. procedure TWebBrowser.Refresh2;
  2107. begin
  2108.   DefaultInterface.Refresh2(EmptyParam);
  2109. end;
  2110.  
  2111. procedure TWebBrowser.Refresh2(var Level: OleVariant);
  2112. begin
  2113.   DefaultInterface.Refresh2(Level);
  2114. end;
  2115.  
  2116. procedure TWebBrowser.Stop;
  2117. begin
  2118.   DefaultInterface.Stop;
  2119. end;
  2120.  
  2121. procedure TWebBrowser.Quit;
  2122. begin
  2123.   DefaultInterface.Quit;
  2124. end;
  2125.  
  2126. procedure TWebBrowser.ClientToWindow(var pcx: SYSINT; var pcy: SYSINT);
  2127. begin
  2128.   DefaultInterface.ClientToWindow(pcx, pcy);
  2129. end;
  2130.  
  2131. procedure TWebBrowser.PutProperty(const Property_: WideString; vtValue: OleVariant);
  2132. begin
  2133.   DefaultInterface.PutProperty(Property_, vtValue);
  2134. end;
  2135.  
  2136. function  TWebBrowser.GetProperty(const Property_: WideString): OleVariant;
  2137. begin
  2138.   Result := DefaultInterface.GetProperty(Property_);
  2139. end;
  2140.  
  2141. procedure TWebBrowser.Navigate2(var URL: OleVariant);
  2142. begin
  2143.   DefaultInterface.Navigate2(URL, EmptyParam, EmptyParam, EmptyParam, EmptyParam);
  2144. end;
  2145.  
  2146. procedure TWebBrowser.Navigate2(var URL: OleVariant; var Flags: OleVariant);
  2147. begin
  2148.   DefaultInterface.Navigate2(URL, Flags, EmptyParam, EmptyParam, EmptyParam);
  2149. end;
  2150.  
  2151. procedure TWebBrowser.Navigate2(var URL: OleVariant; var Flags: OleVariant; 
  2152.                                 var TargetFrameName: OleVariant);
  2153. begin
  2154.   DefaultInterface.Navigate2(URL, Flags, TargetFrameName, EmptyParam, EmptyParam);
  2155. end;
  2156.  
  2157. procedure TWebBrowser.Navigate2(var URL: OleVariant; var Flags: OleVariant; 
  2158.                                 var TargetFrameName: OleVariant; var PostData: OleVariant);
  2159. begin
  2160.   DefaultInterface.Navigate2(URL, Flags, TargetFrameName, PostData, EmptyParam);
  2161. end;
  2162.  
  2163. procedure TWebBrowser.Navigate2(var URL: OleVariant; var Flags: OleVariant; 
  2164.                                 var TargetFrameName: OleVariant; var PostData: OleVariant; 
  2165.                                 var Headers: OleVariant);
  2166. begin
  2167.   DefaultInterface.Navigate2(URL, Flags, TargetFrameName, PostData, Headers);
  2168. end;
  2169.  
  2170. function  TWebBrowser.QueryStatusWB(cmdID: OLECMDID): OLECMDF;
  2171. begin
  2172.   Result := DefaultInterface.QueryStatusWB(cmdID);
  2173. end;
  2174.  
  2175. procedure TWebBrowser.ExecWB(cmdID: OLECMDID; cmdexecopt: OLECMDEXECOPT);
  2176. begin
  2177.   DefaultInterface.ExecWB(cmdID, cmdexecopt, EmptyParam, EmptyParam);
  2178. end;
  2179.  
  2180. procedure TWebBrowser.ExecWB(cmdID: OLECMDID; cmdexecopt: OLECMDEXECOPT; var pvaIn: OleVariant);
  2181. begin
  2182.   DefaultInterface.ExecWB(cmdID, cmdexecopt, pvaIn, EmptyParam);
  2183. end;
  2184.  
  2185. procedure TWebBrowser.ExecWB(cmdID: OLECMDID; cmdexecopt: OLECMDEXECOPT; var pvaIn: OleVariant; 
  2186.                              var pvaOut: OleVariant);
  2187. begin
  2188.   DefaultInterface.ExecWB(cmdID, cmdexecopt, pvaIn, pvaOut);
  2189. end;
  2190.  
  2191. procedure TWebBrowser.ShowBrowserBar(var pvaClsid: OleVariant);
  2192. begin
  2193.   DefaultInterface.ShowBrowserBar(pvaClsid, EmptyParam, EmptyParam);
  2194. end;
  2195.  
  2196. procedure TWebBrowser.ShowBrowserBar(var pvaClsid: OleVariant; var pvarShow: OleVariant);
  2197. begin
  2198.   DefaultInterface.ShowBrowserBar(pvaClsid, pvarShow, EmptyParam);
  2199. end;
  2200.  
  2201. procedure TWebBrowser.ShowBrowserBar(var pvaClsid: OleVariant; var pvarShow: OleVariant; 
  2202.                                      var pvarSize: OleVariant);
  2203. begin
  2204.   DefaultInterface.ShowBrowserBar(pvaClsid, pvarShow, pvarSize);
  2205. end;
  2206.  
  2207. class function CoInternetExplorer.Create: IWebBrowser2;
  2208. begin
  2209.   Result := CreateComObject(CLASS_InternetExplorer) as IWebBrowser2;
  2210. end;
  2211.  
  2212. class function CoInternetExplorer.CreateRemote(const MachineName: string): IWebBrowser2;
  2213. begin
  2214.   Result := CreateRemoteComObject(MachineName, CLASS_InternetExplorer) as IWebBrowser2;
  2215. end;
  2216.  
  2217. procedure TInternetExplorer.InitServerData;
  2218. const
  2219.   CServerData: TServerData = (
  2220.     ClassID:   '{0002DF01-0000-0000-C000-000000000046}';
  2221.     IntfIID:   '{D30C1661-CDAF-11D0-8A3E-00C04FC9E26E}';
  2222.     EventIID:  '{34A715A0-6587-11D0-924A-0020AFC7AC4D}';
  2223.     LicenseKey: nil;
  2224.     Version: 500);
  2225. begin
  2226.   ServerData := @CServerData;
  2227. end;
  2228.  
  2229. procedure TInternetExplorer.Connect;
  2230. var
  2231.   punk: IUnknown;
  2232. begin
  2233.   if FIntf = nil then
  2234.   begin
  2235.     punk := GetServer;
  2236.     ConnectEvents(punk);
  2237.     Fintf:= punk as IWebBrowser2;
  2238.   end;
  2239. end;
  2240.  
  2241. procedure TInternetExplorer.ConnectTo(svrIntf: IWebBrowser2);
  2242. begin
  2243.   Disconnect;
  2244.   FIntf := svrIntf;
  2245.   ConnectEvents(FIntf);
  2246. end;
  2247.  
  2248. procedure TInternetExplorer.DisConnect;
  2249. begin
  2250.   if Fintf <> nil then
  2251.   begin
  2252.     DisconnectEvents(FIntf);
  2253.     FIntf := nil;
  2254.   end;
  2255. end;
  2256.  
  2257. function TInternetExplorer.GetDefaultInterface: IWebBrowser2;
  2258. begin
  2259.   if FIntf = nil then
  2260.     Connect;
  2261.   Assert(FIntf <> nil, 'DefaultInterface is NULL. Component is not connected to Server. You must call ''Connect'' or ''ConnectTo'' before this operation');
  2262.   Result := FIntf;
  2263. end;
  2264.  
  2265. constructor TInternetExplorer.Create(AOwner: TComponent);
  2266. begin
  2267.   inherited Create(AOwner);
  2268.  
  2269.  
  2270. end;
  2271.  
  2272. destructor TInternetExplorer.Destroy;
  2273. begin
  2274.  
  2275.  
  2276.   inherited Destroy;
  2277. end;
  2278.  
  2279.  
  2280.  
  2281.  
  2282.  
  2283.  
  2284.  
  2285. procedure TInternetExplorer.InvokeEvent(DispID: TDispID; var Params: TVariantArray);
  2286. begin
  2287.   case DispID of
  2288.     -1: Exit;  // DISPID_UNKNOWN
  2289.    102: if Assigned(FOnStatusTextChange) then
  2290.             FOnStatusTextChange(Self, Params[0] (*const WideString*));
  2291.    108: if Assigned(FOnProgressChange) then
  2292.             FOnProgressChange(Self, Params[0] (*Integer*), Params[1] (*Integer*));
  2293.    105: if Assigned(FOnCommandStateChange) then
  2294.             FOnCommandStateChange(Self, Params[0] (*Integer*), Params[1] (*WordBool*));
  2295.    106: if Assigned(FOnDownloadBegin) then
  2296.             FOnDownloadBegin(Self);
  2297.    104: if Assigned(FOnDownloadComplete) then
  2298.             FOnDownloadComplete(Self);
  2299.    113: if Assigned(FOnTitleChange) then
  2300.             FOnTitleChange(Self, Params[0] (*const WideString*));
  2301.    112: if Assigned(FOnPropertyChange) then
  2302.             FOnPropertyChange(Self, Params[0] (*const WideString*));
  2303.    250: if Assigned(FOnBeforeNavigate2) then
  2304.             FOnBeforeNavigate2(Self, Params[0] (*const IDispatch*), Params[1] (*var OleVariant*), Params[2] (*var OleVariant*), Params[3] (*var OleVariant*), Params[4] (*var OleVariant*), Params[5] (*var OleVariant*), Params[6] (*var WordBool*));
  2305.    251: if Assigned(FOnNewWindow2) then
  2306.             FOnNewWindow2(Self, Params[0] (*var IDispatch*), Params[1] (*var WordBool*));
  2307.    252: if Assigned(FOnNavigateComplete2) then
  2308.             FOnNavigateComplete2(Self, Params[0] (*const IDispatch*), Params[1] (*var OleVariant*));
  2309.    259: if Assigned(FOnDocumentComplete) then
  2310.             FOnDocumentComplete(Self, Params[0] (*const IDispatch*), Params[1] (*var OleVariant*));
  2311.    253: if Assigned(FOnQuit) then
  2312.             FOnQuit(Self);
  2313.    254: if Assigned(FOnVisible) then
  2314.             FOnVisible(Self, Params[0] (*WordBool*));
  2315.    255: if Assigned(FOnToolBar) then
  2316.             FOnToolBar(Self, Params[0] (*WordBool*));
  2317.    256: if Assigned(FOnMenuBar) then
  2318.             FOnMenuBar(Self, Params[0] (*WordBool*));
  2319.    257: if Assigned(FOnStatusBar) then
  2320.             FOnStatusBar(Self, Params[0] (*WordBool*));
  2321.    258: if Assigned(FOnFullScreen) then
  2322.             FOnFullScreen(Self, Params[0] (*WordBool*));
  2323.    260: if Assigned(FOnTheaterMode) then
  2324.             FOnTheaterMode(Self, Params[0] (*WordBool*));
  2325.   end; {case DispID}
  2326. end;
  2327.  
  2328. function  TInternetExplorer.Get_Application: IDispatch;
  2329. begin
  2330.   Result := DefaultInterface.Get_Application;
  2331. end;
  2332.  
  2333. function  TInternetExplorer.Get_Parent: IDispatch;
  2334. begin
  2335.   Result := DefaultInterface.Get_Parent;
  2336. end;
  2337.  
  2338. function  TInternetExplorer.Get_Container: IDispatch;
  2339. begin
  2340.   Result := DefaultInterface.Get_Container;
  2341. end;
  2342.  
  2343. function  TInternetExplorer.Get_Document: IDispatch;
  2344. begin
  2345.   Result := DefaultInterface.Get_Document;
  2346. end;
  2347.  
  2348. function  TInternetExplorer.Get_TopLevelContainer: WordBool;
  2349. begin
  2350.   Result := DefaultInterface.Get_TopLevelContainer;
  2351. end;
  2352.  
  2353. function  TInternetExplorer.Get_Type_: WideString;
  2354. begin
  2355.   Result := DefaultInterface.Get_Type_;
  2356. end;
  2357.  
  2358. function  TInternetExplorer.Get_Left: Integer;
  2359. begin
  2360.   Result := DefaultInterface.Get_Left;
  2361. end;
  2362.  
  2363. procedure TInternetExplorer.Set_Left(pl: Integer);
  2364. begin
  2365.   DefaultInterface.Set_Left(pl);
  2366. end;
  2367.  
  2368. function  TInternetExplorer.Get_Top: Integer;
  2369. begin
  2370.   Result := DefaultInterface.Get_Top;
  2371. end;
  2372.  
  2373. procedure TInternetExplorer.Set_Top(pl: Integer);
  2374. begin
  2375.   DefaultInterface.Set_Top(pl);
  2376. end;
  2377.  
  2378. function  TInternetExplorer.Get_Width: Integer;
  2379. begin
  2380.   Result := DefaultInterface.Get_Width;
  2381. end;
  2382.  
  2383. procedure TInternetExplorer.Set_Width(pl: Integer);
  2384. begin
  2385.   DefaultInterface.Set_Width(pl);
  2386. end;
  2387.  
  2388. function  TInternetExplorer.Get_Height: Integer;
  2389. begin
  2390.   Result := DefaultInterface.Get_Height;
  2391. end;
  2392.  
  2393. procedure TInternetExplorer.Set_Height(pl: Integer);
  2394. begin
  2395.   DefaultInterface.Set_Height(pl);
  2396. end;
  2397.  
  2398. function  TInternetExplorer.Get_LocationName: WideString;
  2399. begin
  2400.   Result := DefaultInterface.Get_LocationName;
  2401. end;
  2402.  
  2403. function  TInternetExplorer.Get_LocationURL: WideString;
  2404. begin
  2405.   Result := DefaultInterface.Get_LocationURL;
  2406. end;
  2407.  
  2408. function  TInternetExplorer.Get_Busy: WordBool;
  2409. begin
  2410.   Result := DefaultInterface.Get_Busy;
  2411. end;
  2412.  
  2413. function  TInternetExplorer.Get_Name: WideString;
  2414. begin
  2415.   Result := DefaultInterface.Get_Name;
  2416. end;
  2417.  
  2418. function  TInternetExplorer.Get_HWND: Integer;
  2419. begin
  2420.   Result := DefaultInterface.Get_HWND;
  2421. end;
  2422.  
  2423. function  TInternetExplorer.Get_FullName: WideString;
  2424. begin
  2425.   Result := DefaultInterface.Get_FullName;
  2426. end;
  2427.  
  2428. function  TInternetExplorer.Get_Path: WideString;
  2429. begin
  2430.   Result := DefaultInterface.Get_Path;
  2431. end;
  2432.  
  2433. function  TInternetExplorer.Get_Visible: WordBool;
  2434. begin
  2435.   Result := DefaultInterface.Get_Visible;
  2436. end;
  2437.  
  2438. procedure TInternetExplorer.Set_Visible(pBool: WordBool);
  2439. begin
  2440.   DefaultInterface.Set_Visible(pBool);
  2441. end;
  2442.  
  2443. function  TInternetExplorer.Get_StatusBar: WordBool;
  2444. begin
  2445.   Result := DefaultInterface.Get_StatusBar;
  2446. end;
  2447.  
  2448. procedure TInternetExplorer.Set_StatusBar(pBool: WordBool);
  2449. begin
  2450.   DefaultInterface.Set_StatusBar(pBool);
  2451. end;
  2452.  
  2453. function  TInternetExplorer.Get_StatusText: WideString;
  2454. begin
  2455.   Result := DefaultInterface.Get_StatusText;
  2456. end;
  2457.  
  2458. procedure TInternetExplorer.Set_StatusText(const StatusText: WideString);
  2459. begin
  2460.   DefaultInterface.Set_StatusText(StatusText);
  2461. end;
  2462.  
  2463. function  TInternetExplorer.Get_ToolBar: SYSINT;
  2464. begin
  2465.   Result := DefaultInterface.Get_ToolBar;
  2466. end;
  2467.  
  2468. procedure TInternetExplorer.Set_ToolBar(Value: SYSINT);
  2469. begin
  2470.   DefaultInterface.Set_ToolBar(Value);
  2471. end;
  2472.  
  2473. function  TInternetExplorer.Get_MenuBar: WordBool;
  2474. begin
  2475.   Result := DefaultInterface.Get_MenuBar;
  2476. end;
  2477.  
  2478. procedure TInternetExplorer.Set_MenuBar(Value: WordBool);
  2479. begin
  2480.   DefaultInterface.Set_MenuBar(Value);
  2481. end;
  2482.  
  2483. function  TInternetExplorer.Get_FullScreen: WordBool;
  2484. begin
  2485.   Result := DefaultInterface.Get_FullScreen;
  2486. end;
  2487.  
  2488. procedure TInternetExplorer.Set_FullScreen(pbFullScreen: WordBool);
  2489. begin
  2490.   DefaultInterface.Set_FullScreen(pbFullScreen);
  2491. end;
  2492.  
  2493. function  TInternetExplorer.Get_ReadyState: tagREADYSTATE;
  2494. begin
  2495.   Result := DefaultInterface.Get_ReadyState;
  2496. end;
  2497.  
  2498. function  TInternetExplorer.Get_Offline: WordBool;
  2499. begin
  2500.   Result := DefaultInterface.Get_Offline;
  2501. end;
  2502.  
  2503. procedure TInternetExplorer.Set_Offline(pbOffline: WordBool);
  2504. begin
  2505.   DefaultInterface.Set_Offline(pbOffline);
  2506. end;
  2507.  
  2508. function  TInternetExplorer.Get_Silent: WordBool;
  2509. begin
  2510.   Result := DefaultInterface.Get_Silent;
  2511. end;
  2512.  
  2513. procedure TInternetExplorer.Set_Silent(pbSilent: WordBool);
  2514. begin
  2515.   DefaultInterface.Set_Silent(pbSilent);
  2516. end;
  2517.  
  2518. function  TInternetExplorer.Get_RegisterAsBrowser: WordBool;
  2519. begin
  2520.   Result := DefaultInterface.Get_RegisterAsBrowser;
  2521. end;
  2522.  
  2523. procedure TInternetExplorer.Set_RegisterAsBrowser(pbRegister: WordBool);
  2524. begin
  2525.   DefaultInterface.Set_RegisterAsBrowser(pbRegister);
  2526. end;
  2527.  
  2528. function  TInternetExplorer.Get_RegisterAsDropTarget: WordBool;
  2529. begin
  2530.   Result := DefaultInterface.Get_RegisterAsDropTarget;
  2531. end;
  2532.  
  2533. procedure TInternetExplorer.Set_RegisterAsDropTarget(pbRegister: WordBool);
  2534. begin
  2535.   DefaultInterface.Set_RegisterAsDropTarget(pbRegister);
  2536. end;
  2537.  
  2538. function  TInternetExplorer.Get_TheaterMode: WordBool;
  2539. begin
  2540.   Result := DefaultInterface.Get_TheaterMode;
  2541. end;
  2542.  
  2543. procedure TInternetExplorer.Set_TheaterMode(pbRegister: WordBool);
  2544. begin
  2545.   DefaultInterface.Set_TheaterMode(pbRegister);
  2546. end;
  2547.  
  2548. function  TInternetExplorer.Get_AddressBar: WordBool;
  2549. begin
  2550.   Result := DefaultInterface.Get_AddressBar;
  2551. end;
  2552.  
  2553. procedure TInternetExplorer.Set_AddressBar(Value: WordBool);
  2554. begin
  2555.   DefaultInterface.Set_AddressBar(Value);
  2556. end;
  2557.  
  2558. function  TInternetExplorer.Get_Resizable: WordBool;
  2559. begin
  2560.   Result := DefaultInterface.Get_Resizable;
  2561. end;
  2562.  
  2563. procedure TInternetExplorer.Set_Resizable(Value: WordBool);
  2564. begin
  2565.   DefaultInterface.Set_Resizable(Value);
  2566. end;
  2567.  
  2568. procedure TInternetExplorer.GoBack;
  2569. begin
  2570.   DefaultInterface.GoBack;
  2571. end;
  2572.  
  2573. procedure TInternetExplorer.GoForward;
  2574. begin
  2575.   DefaultInterface.GoForward;
  2576. end;
  2577.  
  2578. procedure TInternetExplorer.GoHome;
  2579. begin
  2580.   DefaultInterface.GoHome;
  2581. end;
  2582.  
  2583. procedure TInternetExplorer.GoSearch;
  2584. begin
  2585.   DefaultInterface.GoSearch;
  2586. end;
  2587.  
  2588. procedure TInternetExplorer.Navigate(const URL: WideString);
  2589. begin
  2590.   DefaultInterface.Navigate(URL, EmptyParam, EmptyParam, EmptyParam, EmptyParam);
  2591. end;
  2592.  
  2593. procedure TInternetExplorer.Navigate(const URL: WideString; var Flags: OleVariant);
  2594. begin
  2595.   DefaultInterface.Navigate(URL, Flags, EmptyParam, EmptyParam, EmptyParam);
  2596. end;
  2597.  
  2598. procedure TInternetExplorer.Navigate(const URL: WideString; var Flags: OleVariant; 
  2599.                                      var TargetFrameName: OleVariant);
  2600. begin
  2601.   DefaultInterface.Navigate(URL, Flags, TargetFrameName, EmptyParam, EmptyParam);
  2602. end;
  2603.  
  2604. procedure TInternetExplorer.Navigate(const URL: WideString; var Flags: OleVariant; 
  2605.                                      var TargetFrameName: OleVariant; var PostData: OleVariant);
  2606. begin
  2607.   DefaultInterface.Navigate(URL, Flags, TargetFrameName, PostData, EmptyParam);
  2608. end;
  2609.  
  2610. procedure TInternetExplorer.Navigate(const URL: WideString; var Flags: OleVariant; 
  2611.                                      var TargetFrameName: OleVariant; var PostData: OleVariant; 
  2612.                                      var Headers: OleVariant);
  2613. begin
  2614.   DefaultInterface.Navigate(URL, Flags, TargetFrameName, PostData, Headers);
  2615. end;
  2616.  
  2617. procedure TInternetExplorer.Refresh;
  2618. begin
  2619.   DefaultInterface.Refresh;
  2620. end;
  2621.  
  2622. procedure TInternetExplorer.Refresh2;
  2623. begin
  2624.   DefaultInterface.Refresh2(EmptyParam);
  2625. end;
  2626.  
  2627. procedure TInternetExplorer.Refresh2(var Level: OleVariant);
  2628. begin
  2629.   DefaultInterface.Refresh2(Level);
  2630. end;
  2631.  
  2632. procedure TInternetExplorer.Stop;
  2633. begin
  2634.   DefaultInterface.Stop;
  2635. end;
  2636.  
  2637. procedure TInternetExplorer.Quit;
  2638. begin
  2639.   DefaultInterface.Quit;
  2640. end;
  2641.  
  2642. procedure TInternetExplorer.ClientToWindow(var pcx: SYSINT; var pcy: SYSINT);
  2643. begin
  2644.   DefaultInterface.ClientToWindow(pcx, pcy);
  2645. end;
  2646.  
  2647. procedure TInternetExplorer.PutProperty(const Property_: WideString; vtValue: OleVariant);
  2648. begin
  2649.   DefaultInterface.PutProperty(Property_, vtValue);
  2650. end;
  2651.  
  2652. function  TInternetExplorer.GetProperty(const Property_: WideString): OleVariant;
  2653. begin
  2654.   Result := DefaultInterface.GetProperty(Property_);
  2655. end;
  2656.  
  2657. procedure TInternetExplorer.Navigate2(var URL: OleVariant);
  2658. begin
  2659.   DefaultInterface.Navigate2(URL, EmptyParam, EmptyParam, EmptyParam, EmptyParam);
  2660. end;
  2661.  
  2662. procedure TInternetExplorer.Navigate2(var URL: OleVariant; var Flags: OleVariant);
  2663. begin
  2664.   DefaultInterface.Navigate2(URL, Flags, EmptyParam, EmptyParam, EmptyParam);
  2665. end;
  2666.  
  2667. procedure TInternetExplorer.Navigate2(var URL: OleVariant; var Flags: OleVariant; 
  2668.                                       var TargetFrameName: OleVariant);
  2669. begin
  2670.   DefaultInterface.Navigate2(URL, Flags, TargetFrameName, EmptyParam, EmptyParam);
  2671. end;
  2672.  
  2673. procedure TInternetExplorer.Navigate2(var URL: OleVariant; var Flags: OleVariant; 
  2674.                                       var TargetFrameName: OleVariant; var PostData: OleVariant);
  2675. begin
  2676.   DefaultInterface.Navigate2(URL, Flags, TargetFrameName, PostData, EmptyParam);
  2677. end;
  2678.  
  2679. procedure TInternetExplorer.Navigate2(var URL: OleVariant; var Flags: OleVariant; 
  2680.                                       var TargetFrameName: OleVariant; var PostData: OleVariant; 
  2681.                                       var Headers: OleVariant);
  2682. begin
  2683.   DefaultInterface.Navigate2(URL, Flags, TargetFrameName, PostData, Headers);
  2684. end;
  2685.  
  2686. function  TInternetExplorer.QueryStatusWB(cmdID: OLECMDID): OLECMDF;
  2687. begin
  2688.   Result := DefaultInterface.QueryStatusWB(cmdID);
  2689. end;
  2690.  
  2691. procedure TInternetExplorer.ExecWB(cmdID: OLECMDID; cmdexecopt: OLECMDEXECOPT);
  2692. begin
  2693.   DefaultInterface.ExecWB(cmdID, cmdexecopt, EmptyParam, EmptyParam);
  2694. end;
  2695.  
  2696. procedure TInternetExplorer.ExecWB(cmdID: OLECMDID; cmdexecopt: OLECMDEXECOPT; var pvaIn: OleVariant);
  2697. begin
  2698.   DefaultInterface.ExecWB(cmdID, cmdexecopt, pvaIn, EmptyParam);
  2699. end;
  2700.  
  2701. procedure TInternetExplorer.ExecWB(cmdID: OLECMDID; cmdexecopt: OLECMDEXECOPT; 
  2702.                                    var pvaIn: OleVariant; var pvaOut: OleVariant);
  2703. begin
  2704.   DefaultInterface.ExecWB(cmdID, cmdexecopt, pvaIn, pvaOut);
  2705. end;
  2706.  
  2707. procedure TInternetExplorer.ShowBrowserBar(var pvaClsid: OleVariant);
  2708. begin
  2709.   DefaultInterface.ShowBrowserBar(pvaClsid, EmptyParam, EmptyParam);
  2710. end;
  2711.  
  2712. procedure TInternetExplorer.ShowBrowserBar(var pvaClsid: OleVariant; var pvarShow: OleVariant);
  2713. begin
  2714.   DefaultInterface.ShowBrowserBar(pvaClsid, pvarShow, EmptyParam);
  2715. end;
  2716.  
  2717. procedure TInternetExplorer.ShowBrowserBar(var pvaClsid: OleVariant; var pvarShow: OleVariant; 
  2718.                                            var pvarSize: OleVariant);
  2719. begin
  2720.   DefaultInterface.ShowBrowserBar(pvaClsid, pvarShow, pvarSize);
  2721. end;
  2722.  
  2723.  
  2724.  
  2725.  
  2726.  
  2727.  
  2728.  
  2729.  
  2730.  
  2731.  
  2732.  
  2733.  
  2734.  
  2735.  
  2736.  
  2737.  
  2738.  
  2739.  
  2740.  
  2741.  
  2742.  
  2743.  
  2744.  
  2745.  
  2746.  
  2747.  
  2748.  
  2749.  
  2750.  
  2751.  
  2752.  
  2753.  
  2754.  
  2755.  
  2756.  
  2757.  
  2758.  
  2759.  
  2760.  
  2761.  
  2762.  
  2763.  
  2764.  
  2765.  
  2766.  
  2767.  
  2768.  
  2769.  
  2770.  
  2771.  
  2772.  
  2773.  
  2774.  
  2775.  
  2776.  
  2777.  
  2778.  
  2779.  
  2780.  
  2781.  
  2782.  
  2783.  
  2784.  
  2785.  
  2786.  
  2787.  
  2788.  
  2789.  
  2790.  
  2791.  
  2792.  
  2793.  
  2794.  
  2795.  
  2796.  
  2797.  
  2798.  
  2799.  
  2800.  
  2801.  
  2802.  
  2803.  
  2804.  
  2805.  
  2806.  
  2807.  
  2808.  
  2809.  
  2810.  
  2811.  
  2812.  
  2813.  
  2814.  
  2815.  
  2816.  
  2817.  
  2818.  
  2819.  
  2820.  
  2821.  
  2822.  
  2823.  
  2824.  
  2825.  
  2826.  
  2827.  
  2828.  
  2829.  
  2830.  
  2831.  
  2832.  
  2833.  
  2834.  
  2835.  
  2836.  
  2837.  
  2838.  
  2839.  
  2840.  
  2841.  
  2842.  
  2843.  
  2844.  
  2845.  
  2846.  
  2847.  
  2848.  
  2849.  
  2850.  
  2851.  
  2852.  
  2853.  
  2854.  
  2855.  
  2856.  
  2857.  
  2858.  
  2859.  
  2860.  
  2861.  
  2862.  
  2863.  
  2864.  
  2865.  
  2866.  
  2867.  
  2868.  
  2869.  
  2870.  
  2871.  
  2872.  
  2873.  
  2874.  
  2875.  
  2876.  
  2877.  
  2878.  
  2879.  
  2880.  
  2881.  
  2882.  
  2883.  
  2884.  
  2885.  
  2886.  
  2887.  
  2888.  
  2889.  
  2890.  
  2891.  
  2892.  
  2893.  
  2894.  
  2895.  
  2896.  
  2897.  
  2898.  
  2899.  
  2900.  
  2901.  
  2902.  
  2903.  
  2904.  
  2905.  
  2906.  
  2907.  
  2908.  
  2909.  
  2910.  
  2911.  
  2912.  
  2913.  
  2914.  
  2915.  
  2916.  
  2917.  
  2918.  
  2919.  
  2920.  
  2921.  
  2922.  
  2923.  
  2924.  
  2925.  
  2926.  
  2927.  
  2928.  
  2929.  
  2930.  
  2931.  
  2932.  
  2933.  
  2934.  
  2935.  
  2936.  
  2937.  
  2938.  
  2939.  
  2940.  
  2941.  
  2942.  
  2943.  
  2944.  
  2945.  
  2946.  
  2947.  
  2948.  
  2949.  
  2950.  
  2951.  
  2952.  
  2953.  
  2954.  
  2955.  
  2956.  
  2957.  
  2958.  
  2959.  
  2960.  
  2961.  
  2962.  
  2963.  
  2964.  
  2965.  
  2966.  
  2967.  
  2968.  
  2969.  
  2970.  
  2971.  
  2972.  
  2973.  
  2974.  
  2975.  
  2976. class function CoShellBrowserWindow.Create: IWebBrowser2;
  2977. begin
  2978.   Result := CreateComObject(CLASS_ShellBrowserWindow) as IWebBrowser2;
  2979. end;
  2980.  
  2981. class function CoShellBrowserWindow.CreateRemote(const MachineName: string): IWebBrowser2;
  2982. begin
  2983.   Result := CreateRemoteComObject(MachineName, CLASS_ShellBrowserWindow) as IWebBrowser2;
  2984. end;
  2985.  
  2986. class function CoShellWindows.Create: IShellWindows;
  2987. begin
  2988.   Result := CreateComObject(CLASS_ShellWindows) as IShellWindows;
  2989. end;
  2990.  
  2991. class function CoShellWindows.CreateRemote(const MachineName: string): IShellWindows;
  2992. begin
  2993.   Result := CreateRemoteComObject(MachineName, CLASS_ShellWindows) as IShellWindows;
  2994. end;
  2995.  
  2996. procedure TShellWindows.InitServerData;
  2997. const
  2998.   CServerData: TServerData = (
  2999.     ClassID:   '{9BA05972-F6A8-11CF-A442-00A0C90A8F39}';
  3000.     IntfIID:   '{85CB6900-4D95-11CF-960C-0080C7F4EE85}';
  3001.     EventIID:  '{FE4106E0-399A-11D0-A48C-00A0C90A8F39}';
  3002.     LicenseKey: nil;
  3003.     Version: 500);
  3004. begin
  3005.   ServerData := @CServerData;
  3006. end;
  3007.  
  3008. procedure TShellWindows.Connect;
  3009. var
  3010.   punk: IUnknown;
  3011. begin
  3012.   if FIntf = nil then
  3013.   begin
  3014.     punk := GetServer;
  3015.     ConnectEvents(punk);
  3016.     Fintf:= punk as IShellWindows;
  3017.   end;
  3018. end;
  3019.  
  3020. procedure TShellWindows.ConnectTo(svrIntf: IShellWindows);
  3021. begin
  3022.   Disconnect;
  3023.   FIntf := svrIntf;
  3024.   ConnectEvents(FIntf);
  3025. end;
  3026.  
  3027. procedure TShellWindows.DisConnect;
  3028. begin
  3029.   if Fintf <> nil then
  3030.   begin
  3031.     DisconnectEvents(FIntf);
  3032.     FIntf := nil;
  3033.   end;
  3034. end;
  3035.  
  3036. function TShellWindows.GetDefaultInterface: IShellWindows;
  3037. begin
  3038.   if FIntf = nil then
  3039.     Connect;
  3040.   Assert(FIntf <> nil, 'DefaultInterface is NULL. Component is not connected to Server. You must call ''Connect'' or ''ConnectTo'' before this operation');
  3041.   Result := FIntf;
  3042. end;
  3043.  
  3044. constructor TShellWindows.Create(AOwner: TComponent);
  3045. begin
  3046.   inherited Create(AOwner);
  3047.  
  3048.  
  3049. end;
  3050.  
  3051. destructor TShellWindows.Destroy;
  3052. begin
  3053.  
  3054.  
  3055.   inherited Destroy;
  3056. end;
  3057.  
  3058.  
  3059.  
  3060.  
  3061.  
  3062.  
  3063.  
  3064. procedure TShellWindows.InvokeEvent(DispID: TDispID; var Params: TVariantArray);
  3065. begin
  3066.   case DispID of
  3067.     -1: Exit;  // DISPID_UNKNOWN
  3068.    200: if Assigned(FOnWindowRegistered) then
  3069.             FOnWindowRegistered(Self, Params[0] (*Integer*));
  3070.    201: if Assigned(FOnWindowRevoked) then
  3071.             FOnWindowRevoked(Self, Params[0] (*Integer*));
  3072.   end; {case DispID}
  3073. end;
  3074.  
  3075. function  TShellWindows.Get_Count: Integer;
  3076. begin
  3077.   Result := DefaultInterface.Get_Count;
  3078. end;
  3079.  
  3080. function  TShellWindows.Item: IDispatch;
  3081. begin
  3082.   Result := DefaultInterface.Item(EmptyParam);
  3083. end;
  3084.  
  3085. function  TShellWindows.Item(index: OleVariant): IDispatch;
  3086. begin
  3087.   Result := DefaultInterface.Item(index);
  3088. end;
  3089.  
  3090. function  TShellWindows._NewEnum: IUnknown;
  3091. begin
  3092.   Result := DefaultInterface._NewEnum;
  3093. end;
  3094.  
  3095. procedure TShellWindows.Register(const pid: IDispatch; HWND: Integer; swClass: SYSINT; 
  3096.                                  out plCookie: Integer);
  3097. begin
  3098.   DefaultInterface.Register(pid, HWND, swClass, plCookie);
  3099. end;
  3100.  
  3101. procedure TShellWindows.RegisterPending(lThreadId: Integer; var pvarloc: OleVariant; 
  3102.                                         var pvarlocRoot: OleVariant; swClass: SYSINT; 
  3103.                                         out plCookie: Integer);
  3104. begin
  3105.   DefaultInterface.RegisterPending(lThreadId, pvarloc, pvarlocRoot, swClass, plCookie);
  3106. end;
  3107.  
  3108. procedure TShellWindows.Revoke(lCookie: Integer);
  3109. begin
  3110.   DefaultInterface.Revoke(lCookie);
  3111. end;
  3112.  
  3113. procedure TShellWindows.OnNavigate(lCookie: Integer; var pvarloc: OleVariant);
  3114. begin
  3115.   DefaultInterface.OnNavigate(lCookie, pvarloc);
  3116. end;
  3117.  
  3118. procedure TShellWindows.OnActivated(lCookie: Integer; fActive: WordBool);
  3119. begin
  3120.   DefaultInterface.OnActivated(lCookie, fActive);
  3121. end;
  3122.  
  3123. function  TShellWindows.FindWindow(var pvarloc: OleVariant; var pvarlocRoot: OleVariant; 
  3124.                                    swClass: SYSINT; out pHWND: Integer; swfwOptions: SYSINT): IDispatch;
  3125. begin
  3126.   Result := DefaultInterface.FindWindow(pvarloc, pvarlocRoot, swClass, pHWND, swfwOptions);
  3127. end;
  3128.  
  3129. procedure TShellWindows.OnCreated(lCookie: Integer; const punk: IUnknown);
  3130. begin
  3131.   DefaultInterface.OnCreated(lCookie, punk);
  3132. end;
  3133.  
  3134. procedure TShellWindows.ProcessAttachDetach(fAttach: WordBool);
  3135. begin
  3136.   DefaultInterface.ProcessAttachDetach(fAttach);
  3137. end;
  3138.  
  3139.  
  3140.  
  3141.  
  3142.  
  3143.  
  3144.  
  3145.  
  3146.  
  3147.  
  3148.  
  3149.  
  3150.  
  3151.  
  3152.  
  3153.  
  3154.  
  3155.  
  3156.  
  3157. class function CoShellUIHelper.Create: IShellUIHelper;
  3158. begin
  3159.   Result := CreateComObject(CLASS_ShellUIHelper) as IShellUIHelper;
  3160. end;
  3161.  
  3162. class function CoShellUIHelper.CreateRemote(const MachineName: string): IShellUIHelper;
  3163. begin
  3164.   Result := CreateRemoteComObject(MachineName, CLASS_ShellUIHelper) as IShellUIHelper;
  3165. end;
  3166.  
  3167. procedure TShellUIHelper.InitServerData;
  3168. const
  3169.   CServerData: TServerData = (
  3170.     ClassID:   '{64AB4BB7-111E-11D1-8F79-00C04FC2FBE1}';
  3171.     IntfIID:   '{729FE2F8-1EA8-11D1-8F85-00C04FC2FBE1}';
  3172.     EventIID:  '';
  3173.     LicenseKey: nil;
  3174.     Version: 500);
  3175. begin
  3176.   ServerData := @CServerData;
  3177. end;
  3178.  
  3179. procedure TShellUIHelper.Connect;
  3180. var
  3181.   punk: IUnknown;
  3182. begin
  3183.   if FIntf = nil then
  3184.   begin
  3185.     punk := GetServer;
  3186.     Fintf:= punk as IShellUIHelper;
  3187.   end;
  3188. end;
  3189.  
  3190. procedure TShellUIHelper.ConnectTo(svrIntf: IShellUIHelper);
  3191. begin
  3192.   Disconnect;
  3193.   FIntf := svrIntf;
  3194. end;
  3195.  
  3196. procedure TShellUIHelper.DisConnect;
  3197. begin
  3198.   if Fintf <> nil then
  3199.   begin
  3200.     FIntf := nil;
  3201.   end;
  3202. end;
  3203.  
  3204. function TShellUIHelper.GetDefaultInterface: IShellUIHelper;
  3205. begin
  3206.   if FIntf = nil then
  3207.     Connect;
  3208.   Assert(FIntf <> nil, 'DefaultInterface is NULL. Component is not connected to Server. You must call ''Connect'' or ''ConnectTo'' before this operation');
  3209.   Result := FIntf;
  3210. end;
  3211.  
  3212. constructor TShellUIHelper.Create(AOwner: TComponent);
  3213. begin
  3214.   inherited Create(AOwner);
  3215.  
  3216.  
  3217. end;
  3218.  
  3219. destructor TShellUIHelper.Destroy;
  3220. begin
  3221.  
  3222.  
  3223.   inherited Destroy;
  3224. end;
  3225.  
  3226.  
  3227.  
  3228.  
  3229.  
  3230.  
  3231.  
  3232. procedure TShellUIHelper.ResetFirstBootMode;
  3233. begin
  3234.   DefaultInterface.ResetFirstBootMode;
  3235. end;
  3236.  
  3237. procedure TShellUIHelper.ResetSafeMode;
  3238. begin
  3239.   DefaultInterface.ResetSafeMode;
  3240. end;
  3241.  
  3242. procedure TShellUIHelper.RefreshOfflineDesktop;
  3243. begin
  3244.   DefaultInterface.RefreshOfflineDesktop;
  3245. end;
  3246.  
  3247. procedure TShellUIHelper.AddFavorite(const URL: WideString);
  3248. begin
  3249.   DefaultInterface.AddFavorite(URL, EmptyParam);
  3250. end;
  3251.  
  3252. procedure TShellUIHelper.AddFavorite(const URL: WideString; var Title: OleVariant);
  3253. begin
  3254.   DefaultInterface.AddFavorite(URL, Title);
  3255. end;
  3256.  
  3257. procedure TShellUIHelper.AddChannel(const URL: WideString);
  3258. begin
  3259.   DefaultInterface.AddChannel(URL);
  3260. end;
  3261.  
  3262. procedure TShellUIHelper.AddDesktopComponent(const URL: WideString; const Type_: WideString);
  3263. begin
  3264.   DefaultInterface.AddDesktopComponent(URL, Type_, EmptyParam, EmptyParam, EmptyParam, EmptyParam);
  3265. end;
  3266.  
  3267. procedure TShellUIHelper.AddDesktopComponent(const URL: WideString; const Type_: WideString; 
  3268.                                              var Left: OleVariant);
  3269. begin
  3270.   DefaultInterface.AddDesktopComponent(URL, Type_, Left, EmptyParam, EmptyParam, EmptyParam);
  3271. end;
  3272.  
  3273. procedure TShellUIHelper.AddDesktopComponent(const URL: WideString; const Type_: WideString; 
  3274.                                              var Left: OleVariant; var Top: OleVariant);
  3275. begin
  3276.   DefaultInterface.AddDesktopComponent(URL, Type_, Left, Top, EmptyParam, EmptyParam);
  3277. end;
  3278.  
  3279. procedure TShellUIHelper.AddDesktopComponent(const URL: WideString; const Type_: WideString; 
  3280.                                              var Left: OleVariant; var Top: OleVariant; 
  3281.                                              var Width: OleVariant);
  3282. begin
  3283.   DefaultInterface.AddDesktopComponent(URL, Type_, Left, Top, Width, EmptyParam);
  3284. end;
  3285.  
  3286. procedure TShellUIHelper.AddDesktopComponent(const URL: WideString; const Type_: WideString; 
  3287.                                              var Left: OleVariant; var Top: OleVariant; 
  3288.                                              var Width: OleVariant; var Height: OleVariant);
  3289. begin
  3290.   DefaultInterface.AddDesktopComponent(URL, Type_, Left, Top, Width, Height);
  3291. end;
  3292.  
  3293. function  TShellUIHelper.IsSubscribed(const URL: WideString): WordBool;
  3294. begin
  3295.   Result := DefaultInterface.IsSubscribed(URL);
  3296. end;
  3297.  
  3298. procedure TShellUIHelper.NavigateAndFind(const URL: WideString; const strQuery: WideString; 
  3299.                                          var varTargetFrame: OleVariant);
  3300. begin
  3301.   DefaultInterface.NavigateAndFind(URL, strQuery, varTargetFrame);
  3302. end;
  3303.  
  3304. procedure TShellUIHelper.ImportExportFavorites(fImport: WordBool; const strImpExpPath: WideString);
  3305. begin
  3306.   DefaultInterface.ImportExportFavorites(fImport, strImpExpPath);
  3307. end;
  3308.  
  3309. procedure TShellUIHelper.AutoCompleteSaveForm;
  3310. begin
  3311.   DefaultInterface.AutoCompleteSaveForm(EmptyParam);
  3312. end;
  3313.  
  3314. procedure TShellUIHelper.AutoCompleteSaveForm(var Form: OleVariant);
  3315. begin
  3316.   DefaultInterface.AutoCompleteSaveForm(Form);
  3317. end;
  3318.  
  3319. procedure TShellUIHelper.AutoScan(const strSearch: WideString; const strFailureUrl: WideString);
  3320. begin
  3321.   DefaultInterface.AutoScan(strSearch, strFailureUrl, EmptyParam);
  3322. end;
  3323.  
  3324. procedure TShellUIHelper.AutoScan(const strSearch: WideString; const strFailureUrl: WideString; 
  3325.                                   var pvarTargetFrame: OleVariant);
  3326. begin
  3327.   DefaultInterface.AutoScan(strSearch, strFailureUrl, pvarTargetFrame);
  3328. end;
  3329.  
  3330. procedure TShellUIHelper.AutoCompleteAttach;
  3331. begin
  3332.   DefaultInterface.AutoCompleteAttach(EmptyParam);
  3333. end;
  3334.  
  3335. procedure TShellUIHelper.AutoCompleteAttach(var Reserved: OleVariant);
  3336. begin
  3337.   DefaultInterface.AutoCompleteAttach(Reserved);
  3338. end;
  3339.  
  3340. function  TShellUIHelper.ShowBrowserUI(const bstrName: WideString; var pvarIn: OleVariant): OleVariant;
  3341. begin
  3342.   Result := DefaultInterface.ShowBrowserUI(bstrName, pvarIn);
  3343. end;
  3344.  
  3345.  
  3346.  
  3347.  
  3348.  
  3349.  
  3350.  
  3351.  
  3352.  
  3353.  
  3354.  
  3355.  
  3356.  
  3357.  
  3358. class function CoShellFavoritesNameSpace.Create: IShellFavoritesNameSpace;
  3359. begin
  3360.   Result := CreateComObject(CLASS_ShellFavoritesNameSpace) as IShellFavoritesNameSpace;
  3361. end;
  3362.  
  3363. class function CoShellFavoritesNameSpace.CreateRemote(const MachineName: string): IShellFavoritesNameSpace;
  3364. begin
  3365.   Result := CreateRemoteComObject(MachineName, CLASS_ShellFavoritesNameSpace) as IShellFavoritesNameSpace;
  3366. end;
  3367.  
  3368. procedure TShellFavoritesNameSpace.InitServerData;
  3369. const
  3370.   CServerData: TServerData = (
  3371.     ClassID:   '{55136805-B2DE-11D1-B9F2-00A0C98BC547}';
  3372.     IntfIID:   '{55136804-B2DE-11D1-B9F2-00A0C98BC547}';
  3373.     EventIID:  '{55136806-B2DE-11D1-B9F2-00A0C98BC547}';
  3374.     LicenseKey: nil;
  3375.     Version: 500);
  3376. begin
  3377.   ServerData := @CServerData;
  3378. end;
  3379.  
  3380. procedure TShellFavoritesNameSpace.Connect;
  3381. var
  3382.   punk: IUnknown;
  3383. begin
  3384.   if FIntf = nil then
  3385.   begin
  3386.     punk := GetServer;
  3387.     ConnectEvents(punk);
  3388.     Fintf:= punk as IShellFavoritesNameSpace;
  3389.   end;
  3390. end;
  3391.  
  3392. procedure TShellFavoritesNameSpace.ConnectTo(svrIntf: IShellFavoritesNameSpace);
  3393. begin
  3394.   Disconnect;
  3395.   FIntf := svrIntf;
  3396.   ConnectEvents(FIntf);
  3397. end;
  3398.  
  3399. procedure TShellFavoritesNameSpace.DisConnect;
  3400. begin
  3401.   if Fintf <> nil then
  3402.   begin
  3403.     DisconnectEvents(FIntf);
  3404.     FIntf := nil;
  3405.   end;
  3406. end;
  3407.  
  3408. function TShellFavoritesNameSpace.GetDefaultInterface: IShellFavoritesNameSpace;
  3409. begin
  3410.   if FIntf = nil then
  3411.     Connect;
  3412.   Assert(FIntf <> nil, 'DefaultInterface is NULL. Component is not connected to Server. You must call ''Connect'' or ''ConnectTo'' before this operation');
  3413.   Result := FIntf;
  3414. end;
  3415.  
  3416. constructor TShellFavoritesNameSpace.Create(AOwner: TComponent);
  3417. begin
  3418.   inherited Create(AOwner);
  3419.  
  3420.  
  3421. end;
  3422.  
  3423. destructor TShellFavoritesNameSpace.Destroy;
  3424. begin
  3425.  
  3426.  
  3427.   inherited Destroy;
  3428. end;
  3429.  
  3430.  
  3431.  
  3432.  
  3433.  
  3434.  
  3435.  
  3436. procedure TShellFavoritesNameSpace.InvokeEvent(DispID: TDispID; var Params: TVariantArray);
  3437. begin
  3438.   case DispID of
  3439.     -1: Exit;  // DISPID_UNKNOWN
  3440.    1: if Assigned(FOnFavoritesSelectionChange) then
  3441.             FOnFavoritesSelectionChange(Self, Params[0] (*Integer*), Params[1] (*Integer*), Params[2] (*const WideString*), Params[3] (*const WideString*), Params[4] (*Integer*), Params[5] (*const WideString*), Params[6] (*Integer*));
  3442.   end; {case DispID}
  3443. end;
  3444.  
  3445. function  TShellFavoritesNameSpace.Get_FOfflinePackInstalled: WordBool;
  3446. begin
  3447.   Result := DefaultInterface.Get_FOfflinePackInstalled;
  3448. end;
  3449.  
  3450. procedure TShellFavoritesNameSpace.MoveSelectionUp;
  3451. begin
  3452.   DefaultInterface.MoveSelectionUp;
  3453. end;
  3454.  
  3455. procedure TShellFavoritesNameSpace.MoveSelectionDown;
  3456. begin
  3457.   DefaultInterface.MoveSelectionDown;
  3458. end;
  3459.  
  3460. procedure TShellFavoritesNameSpace.ResetSort;
  3461. begin
  3462.   DefaultInterface.ResetSort;
  3463. end;
  3464.  
  3465. procedure TShellFavoritesNameSpace.NewFolder;
  3466. begin
  3467.   DefaultInterface.NewFolder;
  3468. end;
  3469.  
  3470. procedure TShellFavoritesNameSpace.Synchronize;
  3471. begin
  3472.   DefaultInterface.Synchronize;
  3473. end;
  3474.  
  3475. procedure TShellFavoritesNameSpace.Import;
  3476. begin
  3477.   DefaultInterface.Import;
  3478. end;
  3479.  
  3480. procedure TShellFavoritesNameSpace.Export;
  3481. begin
  3482.   DefaultInterface.Export;
  3483. end;
  3484.  
  3485. procedure TShellFavoritesNameSpace.InvokeContextMenuCommand(const strCommand: WideString);
  3486. begin
  3487.   DefaultInterface.InvokeContextMenuCommand(strCommand);
  3488. end;
  3489.  
  3490. procedure TShellFavoritesNameSpace.MoveSelectionTo;
  3491. begin
  3492.   DefaultInterface.MoveSelectionTo;
  3493. end;
  3494.  
  3495. function  TShellFavoritesNameSpace.CreateSubscriptionForSelection: WordBool;
  3496. begin
  3497.   Result := DefaultInterface.CreateSubscriptionForSelection;
  3498. end;
  3499.  
  3500. function  TShellFavoritesNameSpace.DeleteSubscriptionForSelection: WordBool;
  3501. begin
  3502.   Result := DefaultInterface.DeleteSubscriptionForSelection;
  3503. end;
  3504.  
  3505. procedure TShellFavoritesNameSpace.SetRoot(const bstrFullPath: WideString);
  3506. begin
  3507.   DefaultInterface.SetRoot(bstrFullPath);
  3508. end;
  3509.  
  3510.  
  3511.  
  3512.  
  3513.  
  3514.  
  3515.  
  3516.  
  3517.  
  3518.  
  3519.  
  3520.  
  3521.  
  3522.  
  3523.  
  3524.  
  3525.  
  3526.  
  3527.  
  3528. class function CoCScriptErrorList.Create: IScriptErrorList;
  3529. begin
  3530.   Result := CreateComObject(CLASS_CScriptErrorList) as IScriptErrorList;
  3531. end;
  3532.  
  3533. class function CoCScriptErrorList.CreateRemote(const MachineName: string): IScriptErrorList;
  3534. begin
  3535.   Result := CreateRemoteComObject(MachineName, CLASS_CScriptErrorList) as IScriptErrorList;
  3536. end;
  3537.  
  3538. class function CoSearchAssistantOC.Create: ISearchAssistantOC;
  3539. begin
  3540.   Result := CreateComObject(CLASS_SearchAssistantOC) as ISearchAssistantOC;
  3541. end;
  3542.  
  3543. class function CoSearchAssistantOC.CreateRemote(const MachineName: string): ISearchAssistantOC;
  3544. begin
  3545.   Result := CreateRemoteComObject(MachineName, CLASS_SearchAssistantOC) as ISearchAssistantOC;
  3546. end;
  3547.  
  3548. end.
  3549.