home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 10 Tools
/
10-Tools.zip
/
odtlktv4.zip
/
ODTLKT
/
TOOLKIT
/
BETA
/
SAMPLES
/
OPENDOC
/
PARTS
/
PUBLIC
/
CNNOTEBK.XH
< prev
next >
Wrap
Text File
|
1995-12-14
|
5KB
|
190 lines
/*
* This file was generated by the SOM Compiler.
* FileName: E:\opendoc\rel\os2c\include\os2\cnnotebk.xh.
* Generated using:
* SOM Precompiler somipc: 2.29.1.14
* SOM Emitter emitxh: 2.43
*/
/*
* Theory of Operation
*
*
* CNNotebk is implemented as a subclass of ODNotebk. The AddNotebookPages
* method is overridden to allow the part to add only the background page. The
* InsertBackgroundPage is added to provide the new page.
*
* Classes defined in this interface
*
*/
#ifndef SOM_CNNotebook_xh
#define SOM_CNNotebook_xh
class CNNotebook;
#define CNNotebook_MajorVersion 0
#define CNNotebook_MinorVersion 0
/* C++ SOM defs */
#include <somcls.xh>
#include <somcm.xh>
/* C++ parent defs */
#ifndef SOM_ODSettingsExtension_xh
#include <Settings.xh>
#endif
#ifndef CNNotebook_API
#define CNNotebook_API
/*
* -- The Class API
*/
/*
* Start of bindings for IDL types
*/
class SOMClass;
class SOMObject;
class ODFrame;
class ODFacet;
class ODPlatformCanvas;
class ODObject;
class ODExtension;
class ODRefCntObject;
class ODSettingsExtension;
class ODPart;
class ODTypeList;
class EditorSet;
class ODNameSpaceManager;
class CNNotebook;
/*
* End of bindings for IDL types.
*/
/* A procedure to create the CNNotebook Class */
SOMEXTERN SOMClass * SOMLINK CNNotebookNewClass(
integer4 majorVersion,
integer4 minorVersion);
/* The API to the CNNotebook class object, and the methods it introduces. */
SOMEXTERN struct CNNotebookClassDataStructure {
SOMClass *classObject;
somMToken InsertBackgroundPage;
} SOMDLINK CNNotebookClassData;
#define _CNNotebook CNNotebookClassData.classObject
/* The API to parentMtabs for CNNotebook, and the instance data it introduces. */
SOMEXTERN struct CNNotebookCClassDataStructure {
somMethodTabs parentMtab;
somDToken instanceDataToken;
} SOMDLINK CNNotebookCClassData;
/*
* -- Typedefs for CNNotebook Method Procedures
*/
SOMEXTERN {
typedef ODULong SOMLINK somTP_CNNotebook_InsertBackgroundPage(CNNotebook *somSelf, Environment *ev,
HWND hwndNotebook);
typedef somTP_CNNotebook_InsertBackgroundPage *somTD_CNNotebook_InsertBackgroundPage;
}
#endif /* CNNotebook_API */
/*
* -- This emitter treats Method Tokens as Thunks by default.
* -- Use the sc modifier "nothunks" to change this default
*/
#undef somresolve_
#define somresolve_(obj,mToken) ((somMethodProc*)((void)obj, mToken))
/*
* -- The C++ Wrapper Class for CNNotebook
*/
class CNNotebook : public ODSettingsExtension
{
public:
// CNNotebook::new creates the class object if necessary, and then uses somNewNoInit
// to allocate memory and create the object. Initialization is in ctors.
void *operator new(size_t)
{
if (!_CNNotebook) CNNotebookNewClass(CNNotebook_MajorVersion,CNNotebook_MinorVersion);
return (void*)
SOM_Resolve(_CNNotebook,SOMClass,somNewNoInit)
((SOMClass *)((void*)_CNNotebook));
}
// CNNotebook::delete uses somDestruct.
void operator delete(void * obj)
{
if (obj && *(void**)obj) {
SOM_Resolve(obj,SOMObject,somDestruct)
((SOMObject*)obj, 1, 0);
}
}
CNNotebook& operator=(CNNotebook& fromObj)
{
this->somDefaultAssign(0,(SOMObject*)((void*)&fromObj));
return *this;
}
CNNotebook()
{
if (*(void**)this !=
((somParentMtabStructPtr)
(CNNotebookCClassData.parentMtab))->mtab)
return;
((SOMObject*)((void*)this))->somDefaultInit(0);
}
CNNotebook(CNNotebook* fromObj)
{
if (*(void**)this !=
((somParentMtabStructPtr)
(CNNotebookCClassData.parentMtab))->mtab)
return;
((SOMObject*)((void*)this))->somDefaultCopyInit(0,((SOMObject*)((void*)fromObj)));
}
CNNotebook(const CNNotebook* fromObj)
{
if (*(void**)this !=
((somParentMtabStructPtr)
(CNNotebookCClassData.parentMtab))->mtab)
return;
((SOMObject*)((void*)this))->somDefaultConstCopyInit(0,((SOMObject*)((void*)fromObj)));
}
/* method: InsertBackgroundPage */
ODULong InsertBackgroundPage(Environment *ev,
HWND hwndNotebook)
{
#ifdef SOMCHKEXCEPT
ODULong __somResult =
SOM_ResolveD(this,CNNotebook,CNNotebook,InsertBackgroundPage)
(this, ev,hwndNotebook);
if ( ev->_major != NO_EXCEPTION )
SOMCHKEXCEPT;
return __somResult;
#else
return SOM_ResolveD(this,CNNotebook,CNNotebook,InsertBackgroundPage)
(this, ev,hwndNotebook);
#endif
}
}; /* CNNotebook */
#endif /* SOM_CNNotebook_xh */