home *** CD-ROM | disk | FTP | other *** search
Text File | 1996-12-14 | 1.6 KB | 64 lines | [TEXT/CWIE] |
- // =================================================================================
- //
- // CPPActiveX.h ©1996 Microsoft Corporation All rights reserved.
- //
- // =================================================================================
-
- #ifndef _H_CPPActiveX
- #define _H_CPPActiveX
- #pragma once
-
- #include "CBaseControl.h"
- #include <LGrafPortView.h>
-
- #define CControl CPPActiveX
-
- class CPPActiveX;
-
- class CPPContextInfo : public CBaseContextInfo
- {
- public:
- CPPContextInfo(CPPActiveX* inControlP, Uint32 ContextID);
- virtual ~CPPContextInfo(void);
-
- virtual ErrorCode Activate(Boolean8 Acquired);
- virtual ErrorCode Deactivate(Boolean8 Acquired);
- };
-
- class CPPActiveX : public CBaseControl,
- public LGrafPortView
- {
- friend CPPContextInfo;
- public:
-
- static void InitModule();
-
- CPPActiveX(void);
- virtual ~CPPActiveX(void);
-
- // *** IObjectWithSite methods ***
- STDMETHOD (SetSite)(THIS_ IUnknown* inUnkSite);
-
- // *** IControl methods ***
- STDMETHOD (Draw) (THIS_ DrawContext* inContext);
- STDMETHOD (SetFocus)(THIS_ FocusCommand inCommand, FocusSet inFocus);
- STDMETHOD (DoMouse)(THIS_ MouseEventType inMouseET, PlatformEvent* inEvent);
- STDMETHOD (DoKey)(THIS_ KeyEventType inKeyET, Char8 inChar, PlatformEvent* inEvent);
- STDMETHOD (DoIdle)(THIS_ Uint32 IdleRefCon);
-
- // *** LCommander methods ***
- virtual void PutOnDuty();
- virtual void TakeOffDuty();
-
- virtual void RealignSelf(DrawContext*);
- virtual LView* CreateMainView();
- virtual void DrawSelf();
- virtual CBaseContextInfo* NewContext(Uint32 inContextID);
-
- private:
- LView* mMainView;
- FocusSet mOwnedFoci;
- };
-
- #endif
-