summaryrefslogtreecommitdiffstats
path: root/private/oleutest/balls/common/bscbnd.hxx
diff options
context:
space:
mode:
authorAdam <you@example.com>2020-05-17 05:51:50 +0200
committerAdam <you@example.com>2020-05-17 05:51:50 +0200
commite611b132f9b8abe35b362e5870b74bce94a1e58e (patch)
treea5781d2ec0e085eeca33cf350cf878f2efea6fe5 /private/oleutest/balls/common/bscbnd.hxx
downloadNT4.0-e611b132f9b8abe35b362e5870b74bce94a1e58e.tar
NT4.0-e611b132f9b8abe35b362e5870b74bce94a1e58e.tar.gz
NT4.0-e611b132f9b8abe35b362e5870b74bce94a1e58e.tar.bz2
NT4.0-e611b132f9b8abe35b362e5870b74bce94a1e58e.tar.lz
NT4.0-e611b132f9b8abe35b362e5870b74bce94a1e58e.tar.xz
NT4.0-e611b132f9b8abe35b362e5870b74bce94a1e58e.tar.zst
NT4.0-e611b132f9b8abe35b362e5870b74bce94a1e58e.zip
Diffstat (limited to 'private/oleutest/balls/common/bscbnd.hxx')
-rw-r--r--private/oleutest/balls/common/bscbnd.hxx208
1 files changed, 208 insertions, 0 deletions
diff --git a/private/oleutest/balls/common/bscbnd.hxx b/private/oleutest/balls/common/bscbnd.hxx
new file mode 100644
index 000000000..1822fcd36
--- /dev/null
+++ b/private/oleutest/balls/common/bscbnd.hxx
@@ -0,0 +1,208 @@
+//+-------------------------------------------------------------------
+//
+// File: bscbnd.hxx
+//
+// Contents: This file contins the DLL entry points
+// LibMain
+// DllGetClassObject (Bindings key func)
+// DllCanUnloadNow
+// CBasicBndCF (class factory)
+// History: 30-Mar-92 SarahJ Created
+//
+//---------------------------------------------------------------------
+
+#ifndef __BSCBND_H__
+#define __BSCBND_H__
+
+
+extern "C" const GUID CLSID_BasicBnd;
+extern "C" const GUID CLSID_TestEmbed;
+
+
+#define STGM_DFRALL (STGM_READWRITE | STGM_TRANSACTED | STGM_SHARE_DENY_WRITE)
+
+//
+// Define the interface we are going to use here - avoiding MIDL stuff
+//
+
+//+-------------------------------------------------------------------
+//
+// Class: CBasicBndCF
+//
+// Synopsis: Class Factory for CBasicBnd
+//
+// Methods: IUnknown - QueryInterface, AddRef, Release
+// IClassFactory - CreateInstance
+//
+// History: 21-Mar-92 SarahJ Created
+//
+//--------------------------------------------------------------------
+
+
+class FAR CBasicBndCF: public IClassFactory
+{
+public:
+
+ // Constructor/Destructor
+ CBasicBndCF();
+ ~CBasicBndCF();
+
+ // IUnknown
+ STDMETHODIMP QueryInterface(REFIID iid, void FAR * FAR * ppv);
+ STDMETHODIMP_(ULONG) AddRef(void);
+ STDMETHODIMP_(ULONG) Release(void);
+
+
+ // IClassFactory
+ STDMETHODIMP CreateInstance(IUnknown FAR* pUnkOuter,
+ REFIID iidInterface,
+ void FAR* FAR* ppv);
+
+ STDMETHODIMP LockServer(BOOL fLock);
+
+ BOOL ReleaseClass(void);
+
+private:
+
+ ULONG _cRefs;
+};
+
+
+
+//+-------------------------------------------------------------------
+//
+// Class: CBasicBnd
+//
+// Synopsis: Test class CBasicBnd
+//
+// Methods:
+//
+// History: 21-Mar-92 SarahJ Created
+//
+//--------------------------------------------------------------------
+
+
+class FAR CBasicBnd: public IPersistFile, public IOleClientSite,
+ public IOleObject, public IOleItemContainer
+{
+public:
+ // *** Constructor/Destructor
+ CBasicBnd(IUnknown *punk);
+ ~CBasicBnd();
+
+ // *** IUnknown
+ STDMETHODIMP QueryInterface(REFIID iid, void FAR * FAR * ppv);
+ STDMETHODIMP_(ULONG) AddRef(void);
+ STDMETHODIMP_(ULONG) Release(void);
+
+ // *** IPersist
+ STDMETHODIMP GetClassID(LPCLSID lpClassID);
+
+ // *** IPersitFile
+ STDMETHODIMP IsDirty();
+ STDMETHODIMP Load(LPCOLESTR lpszFileName, DWORD grfMode);
+ STDMETHODIMP Save(LPCOLESTR lpszFileName, BOOL fRemember);
+ STDMETHODIMP SaveCompleted(LPCOLESTR lpszFileName);
+ STDMETHODIMP GetCurFile(LPOLESTR FAR * lplpszFileName);
+
+ // *** IOleObject methods ***
+ STDMETHODIMP SetClientSite( LPOLECLIENTSITE pClientSite);
+ STDMETHODIMP GetClientSite( LPOLECLIENTSITE FAR* ppClientSite);
+ STDMETHODIMP SetHostNames( LPCOLESTR szContainerApp, LPCOLESTR szContainerObj);
+ STDMETHODIMP Close(DWORD dwSaveOption);
+ STDMETHODIMP SetMoniker( DWORD dwWhichMoniker, LPMONIKER pmk);
+ STDMETHODIMP GetMoniker( DWORD dwAssign, DWORD dwWhichMoniker,
+ LPMONIKER FAR* ppmk);
+ STDMETHODIMP InitFromData( LPDATAOBJECT pDataObject,
+ BOOL fCreation,
+ DWORD dwReserved);
+ STDMETHODIMP GetClipboardData( DWORD dwReserved,
+ LPDATAOBJECT FAR* ppDataObject);
+ STDMETHODIMP DoVerb( LONG iVerb,
+ LPMSG lpmsg,
+ LPOLECLIENTSITE pActiveSite,
+ LONG lindex,
+ HWND hwndParent,
+ LPCRECT lprcPosRect);
+ STDMETHODIMP EnumVerbs(LPENUMOLEVERB FAR* ppenumOleVerb);
+ STDMETHODIMP Update(void);
+ STDMETHODIMP IsUpToDate(void);
+ STDMETHODIMP GetUserClassID(CLSID FAR *pClsid);
+ STDMETHODIMP GetUserType(DWORD dwFormOfType, LPOLESTR FAR* pszUserType);
+ STDMETHODIMP SetExtent( DWORD dwDrawAspect, LPSIZEL lpsizel);
+ STDMETHODIMP GetExtent( DWORD dwDrawAspect, LPSIZEL lpsizel);
+
+ STDMETHODIMP Advise( LPADVISESINK pAdvSink, DWORD FAR* pdwConnection);
+ STDMETHODIMP Unadvise( DWORD dwConnection);
+ STDMETHODIMP EnumAdvise( LPENUMSTATDATA FAR* ppenumAdvise);
+ STDMETHODIMP GetMiscStatus(DWORD dwAspect, DWORD FAR* pdwStatus);
+ STDMETHODIMP SetColorScheme( LPLOGPALETTE lpLogpal);
+
+ // *** IParseDisplayName method ***
+ STDMETHODIMP ParseDisplayName(
+ LPBC pbc,
+ LPOLESTR lpszDisplayName,
+ ULONG FAR* pchEaten,
+ LPMONIKER FAR* ppmkOut) ;
+
+ // *** IOleContainer methods ***
+ STDMETHODIMP EnumObjects(DWORD grfFlags, LPENUMUNKNOWN FAR* ppenumUnknown);
+ STDMETHODIMP LockContainer(BOOL fLock);
+
+ // *** IOleItemContainer methods ***
+ STDMETHODIMP GetObject(
+ LPOLESTR lpszItem,
+ DWORD dwSpeedNeeded,
+ LPBINDCTX pbc,
+ REFIID riid,
+ LPVOID FAR* ppvObject);
+
+ STDMETHODIMP GetObjectStorage(
+ LPOLESTR lpszItem,
+ LPBINDCTX pbc,
+ REFIID riid,
+ LPVOID FAR* ppvStorage);
+
+ STDMETHODIMP IsRunning(LPOLESTR lpszItem) ;
+
+ // *** IOleClientSite
+ STDMETHODIMP SaveObject (void);
+ STDMETHODIMP GetContainer (LPOLECONTAINER FAR *ppContainer);
+ STDMETHODIMP ShowObject (void);
+ STDMETHODIMP OnShowWindow (BOOL fShow);
+ STDMETHODIMP RequestNewObjectLayout (void);
+
+private:
+
+ IUnknown * _punk;
+
+ IMoniker * _pmkContainer;
+
+ IStorage * _psStg1;
+
+ IStorage * _psStg2;
+};
+
+
+class CUnknownBasicBnd : public IUnknown
+{
+public:
+
+ CUnknownBasicBnd(IUnknown *punk);
+
+ ~CUnknownBasicBnd(void);
+
+ // *** IUnknown
+ STDMETHODIMP QueryInterface(REFIID iid, void FAR * FAR * ppv);
+ STDMETHODIMP_(ULONG) AddRef(void);
+ STDMETHODIMP_(ULONG) Release(void);
+
+private:
+
+ CBasicBnd * _pbasicbnd;
+
+ ULONG _cRefs;
+};
+
+
+#endif // __BSCBND_H__