home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / wpentk.zip / WBPENTK2.DSK / OEM.IH < prev    next >
Text File  |  1994-10-07  |  12KB  |  427 lines

  1.  
  2. /*
  3.  * This file was generated by the SOM Compiler.
  4.  * FileName: oem.ih.
  5.  * Generated using:
  6.  *     SOM Precompiler somopc: 2.7
  7.  *     SOM Emitter emitih: 2.22
  8.  */
  9.  
  10. /*
  11.  * 
  12.  * 
  13.  *   File Name   : OEM.CSC
  14.  * 
  15.  *   Description : Sample sublcass
  16.  * 
  17.  *   Function:  This is a sample of a subclass of PenLocatorPen
  18.  * 
  19.  *   Copyright (C) 1993 IBM Corporation
  20.  * 
  21.  *       DISCLAIMER OF WARRANTIES.  The following [enclosed] code is
  22.  *       sample code created by IBM Corporation. This sample code is not
  23.  *       part of any standard or IBM product and is provided to you solely
  24.  *       for  the purpose of assisting you in the development of your
  25.  *       applications.  The code is provided "AS IS", without
  26.  *       warranty of any kind.  IBM shall not be liable for any damages
  27.  *       arising out of your use of the sample code, even if they have been
  28.  *       advised of the possibility of such damages.
  29.  * 
  30.  */
  31.  
  32.  
  33. #ifndef SOM_oem_ih
  34. #define SOM_oem_ih
  35.  
  36. #pragma checkout(suspend)
  37.  
  38. #include <oem.h>
  39.  
  40. /*
  41.  * Set the scope of methods functions
  42.  */
  43. #ifndef SOM_Scope
  44. #define SOM_Scope static
  45. #endif  /* SOM_Scope */
  46.  
  47. #ifndef SOM_CurrentClass
  48.     #define SOM_CurrentClass oemCClassData.parentMtab
  49. #endif  /* SOM_CurrentClass */
  50.  
  51. #define oem_MaxNoMethods 1
  52.  
  53. /*
  54.  * Instance data
  55.  */
  56. typedef void oemData;
  57.  
  58. /*
  59.  * Begin stuff that only goes in the primary file
  60.  */
  61. #if (defined(oem_Class_Source) || defined(SOM_Module_oem_Source))
  62.  
  63. /*
  64.  * Trace/Debug macro
  65.  */
  66. #ifndef oemMethodDebug
  67.    #define oemMethodDebug(c,m) SOMMethodDebug(c,m)
  68. #endif  /* oemMethodDebug */
  69.  
  70. /*
  71.  * Current class macros for Instance and Meta classes.
  72.  */
  73. #undef SOMMeta
  74. #define SOMMeta M_oemCClassData.parentMtab
  75. #undef SOMInstance
  76. #define SOMInstance oemCClassData.parentMtab
  77.  
  78. #ifndef M_oem_Class_Source
  79.    #define M_oem_Class_Source
  80. #endif    /* M_oem_Class_Source */
  81.  
  82. /*
  83.  * Generate the Apply Stubs.
  84.  */
  85. #pragma linkage(somAP_AddUserTypePage, system)
  86. static void SOMLINK somAP_AddUserTypePage(oem *somSelf,
  87.         ULONG *__retVal,
  88.         somMethodProc *__methodPtr,
  89.         va_list __ap)
  90. {
  91.     void *__somSelf = va_arg(__ap, void*);
  92.     HWND hwndOem = va_arg(__ap, HWND);
  93.  
  94.     *__retVal = ((somTD_oem_AddUserTypePage) __methodPtr) (somSelf, hwndOem);
  95. }
  96.  
  97.  
  98. /*
  99.  * Overridden method: wpAddSettingsPages
  100.  */
  101. #pragma linkage(wpAddSettingsPages, system)
  102. SOM_Scope BOOL   SOMLINK wpAddSettingsPages(oem *somSelf,
  103.         HWND hwndNotebook);
  104. #ifndef somMN_wpAddSettingsPages_defined
  105. #define somMN_wpAddSettingsPages_defined
  106.    static char *somMN_wpAddSettingsPages = "wpAddSettingsPages";
  107.    static somId somId_wpAddSettingsPages = &somMN_wpAddSettingsPages;
  108. #endif  /* somMN_wpAddSettingsPages_defined */
  109. #define oem_parent_PenLocatorPen_wpAddSettingsPages(somSelf,hwndNotebook) \
  110.     ((SOM_ParentNumResolve(WPObject, 1, oemCClassData.parentMtab, wpAddSettingsPages)) \
  111.      (somSelf,hwndNotebook))
  112. #ifndef SOMGD_pmc_PenLocatorPen_wpAddSettingsPages
  113.   #ifdef parent_PenLocatorPen_wpAddSettingsPages
  114.      #undef parent_PenLocatorPen_wpAddSettingsPages
  115.      #define SOMGD_pmc_PenLocatorPen_wpAddSettingsPages 1
  116.   #else
  117.      #define parent_PenLocatorPen_wpAddSettingsPages oem_parent_PenLocatorPen_wpAddSettingsPages
  118.   #endif /* parent_PenLocatorPen_wpAddSettingsPages */
  119. #endif /* SOMGD_pmc_PenLocatorPen_wpAddSettingsPages */
  120. #ifndef parent_wpAddSettingsPages
  121.    #define parent_wpAddSettingsPages(somSelf,hwndNotebook) \
  122.     ((SOM_ParentNumResolve(WPObject, 1, SOM_CurrentClass, wpAddSettingsPages)) \
  123.      (somSelf,hwndNotebook))
  124. #endif  /* parent_wpAddSettingsPages */
  125. #define oem_parents_wpAddSettingsPages(arg0,arg1) \
  126.   (void) oem_parent_PenLocatorPen_wpAddSettingsPages(arg0,arg1);
  127.  
  128. /*
  129.  * Initialize the class data structure
  130.  */
  131. struct oemClassDataStructure oemClassData = {(SOMAny *) NULL};
  132.  
  133. /*
  134.  * Define the C class data structure
  135.  */
  136. struct oemCClassDataStructure oemCClassData = {(somMethodTabs) NULL};
  137.  
  138. /*
  139.  * New Method: AddUserTypePage
  140.  */
  141. #pragma linkage(AddUserTypePage, system)
  142. SOM_Scope ULONG   SOMLINK AddUserTypePage(oem *somSelf,
  143.         HWND hwndOem);
  144. #ifndef somMN_AddUserTypePage_defined
  145. #define somMN_AddUserTypePage_defined
  146. static char *somMN_AddUserTypePage = "AddUserTypePage";
  147. static somId somId_AddUserTypePage = &somMN_AddUserTypePage;
  148. #endif  /* somMN_AddUserTypePage_defined */
  149. #ifndef somDS_AddUserTypePage_defined
  150. #define somDS_AddUserTypePage_defined
  151. static char *somDS_AddUserTypePage = somMD_oem_AddUserTypePage;
  152. static somId somDI_AddUserTypePage = &somDS_AddUserTypePage;
  153. #endif  /* somDS_AddUserTypePage_defined */
  154. #pragma linkage(somRD_AddUserTypePage, system)
  155. static ULONG   SOMLINK somRD_AddUserTypePage(oem *somSelf,
  156.         HWND hwndOem)
  157. {
  158.     ULONG __retVal;
  159.  
  160.     va_somDispatch(somSelf, (void **)&__retVal, somId_AddUserTypePage, somSelf 
  161.         ,hwndOem);
  162.     return __retVal;
  163. }
  164.  
  165. /*
  166.  * Routines and Structures to create the class object
  167.  */
  168.  
  169. /*
  170.  * Declare the Static Methods table.
  171.  */
  172. static somStaticMethod_t oemSM[] = {
  173.     {    &oemClassData.AddUserTypePage,
  174.          &somId_AddUserTypePage,
  175.          &somDI_AddUserTypePage,
  176.          (somMethodProc *) AddUserTypePage,
  177.          (somMethodProc *) somRD_AddUserTypePage,
  178.          (somMethodProc *) somAP_AddUserTypePage    },
  179. };
  180.  
  181.  
  182. /*
  183.  * Declare the Override Methods table.
  184.  */
  185. static somOverrideMethod_t oemOM[] = {
  186.     {    &somId_wpAddSettingsPages,
  187.          (somMethodProc *) wpAddSettingsPages    },
  188. };
  189.  
  190.  
  191. /*
  192.  *  Initializers for class Ids
  193.  */
  194. static char * somCN_oem = "oem";
  195. #ifndef somEMC_M_oem_defined
  196. #define somEMC_M_oem_defined
  197. static char * somEMC_M_oem = "M_oem";
  198. #endif
  199. static char * somPCN_oem_PenLocatorPen = "PenLocatorPen";
  200.  
  201. static somId somPCoem[] = {
  202.     &somPCN_oem_PenLocatorPen,
  203. };
  204.  
  205. static somStaticClassInfo oemSCI = {
  206.     3, 1, 1, 0, 0, 0,
  207.     oem_MajorVersion, oem_MinorVersion,
  208.     0, oem_MaxNoMethods, 1,
  209.     &somCN_oem,
  210.     &somEMC_M_oem, 0,
  211.     somPCoem,
  212.     (somClassDataStructure *) &oemClassData,
  213.     (somCClassDataStructure *) &oemCClassData,
  214.     oemSM, oemOM,
  215.     (char *) NULL,
  216.     (somNonInternalData_t *) NULL,  (somProcMethods_t *) NULL,
  217.     (somVarargsFuncs_t *) NULL,
  218.     (somTP_somClassInitFunc *) NULL,
  219.     0,
  220.     0,  /* old style class, zero directinitclasses */
  221.     0, /* no directinitclasses */
  222.     0, /* number of methods */
  223.     0, /* methods of the class */
  224.     0, /* dataOffset1 */
  225.     0, /* dataOffset2 */
  226.     0, /* number of SelectInheritedMethods */
  227.     0, /* SelectInheritedMethods */
  228.     0, /* number of releaseorder entries */
  229.     0, /* ReleaseOrder */
  230.     0, /* number of migrated methods */
  231.     0, /* migrated method implementations */
  232.     0, /* number of initializers */
  233.     0, /* initializers */
  234.     0, /* used to identify a DTS class */
  235.     0, /* used to register dynamically computed info */
  236. };
  237.  
  238.  
  239. oem * SOMLINK oemNewClass (integer4 somtmajorVersion,
  240.         integer4 somtminorVersion)
  241. {
  242.     PenLocatorPenNewClass(PenLocatorPen_MajorVersion,PenLocatorPen_MinorVersion);    /* static reference */
  243.     /* Explicit metaclass, so get it */ 
  244.     M_oemNewClass(M_oem_MajorVersion,M_oem_MinorVersion);    /* static reference */
  245.     return (somBuildClass(1,&oemSCI, somtmajorVersion, somtminorVersion));
  246. }
  247.  
  248. /*
  249.  * Functions for attributes.
  250.  */
  251.  
  252. #endif                   /* oem_Class_Source */
  253. #pragma checkout(resume)
  254.  
  255. #endif       /* SOM_oem_ih */
  256.  
  257. #ifndef SOM_M_M_oem_mih
  258. #define SOM_M_M_oem_mih
  259.  
  260. #pragma checkout(suspend)
  261.  
  262. /*
  263.  * Set the scope of methods functions
  264.  */
  265. #ifndef SOM_Scope
  266. #define SOM_Scope static
  267. #endif  /* SOM_Scope */
  268.  
  269. #ifndef SOM_CurrentClass
  270.     #define SOM_CurrentClass M_oemCClassData.parentMtab
  271. #endif  /* SOM_CurrentClass */
  272.  
  273. #define M_oem_MaxNoMethods 0
  274.  
  275. /*
  276.  * Instance data
  277.  */
  278. typedef void M_oemData;
  279.  
  280. /*
  281.  * Begin stuff that only goes in the primary file
  282.  */
  283. #if (defined(M_oem_Class_Source) || defined(SOM_Module_oem_Source))
  284.  
  285. /*
  286.  * Trace/Debug macro
  287.  */
  288. #ifndef M_oemMethodDebug
  289.    #define M_oemMethodDebug(c,m) SOMMethodDebug(c,m)
  290. #endif  /* M_oemMethodDebug */
  291.  
  292. /*
  293.  * Current class macros for Instance and Meta classes.
  294.  */
  295.  
  296. /*
  297.  * Generate the Apply Stubs.
  298.  */
  299.  
  300. /*
  301.  * Overridden method: wpclsQueryTitle
  302.  */
  303. #pragma linkage(oemM_wpclsQueryTitle, system)
  304. SOM_Scope PSZ   SOMLINK oemM_wpclsQueryTitle(M_oem *somSelf);
  305. #ifndef somMN_wpclsQueryTitle_defined
  306. #define somMN_wpclsQueryTitle_defined
  307.    static char *somMN_wpclsQueryTitle = "wpclsQueryTitle";
  308.    static somId somId_wpclsQueryTitle = &somMN_wpclsQueryTitle;
  309. #endif  /* somMN_wpclsQueryTitle_defined */
  310. #define parent_oemM_wpclsQueryTitle(somSelf) \
  311.     ((SOM_ParentNumResolve(M_WPObject, 1, M_oemCClassData.parentMtab, wpclsQueryTitle)) \
  312.      (somSelf))
  313. #ifndef parent_wpclsQueryTitle
  314.    #define parent_wpclsQueryTitle(somSelf) \
  315.     ((SOM_ParentNumResolve(M_WPObject, 1, SOM_CurrentClass, wpclsQueryTitle)) \
  316.      (somSelf))
  317. #endif  /* parent_wpclsQueryTitle */
  318. #define M_oem_parents_oemM_wpclsQueryTitle(arg0) \
  319.    (void) parent_oemM_wpclsQueryTitle(arg0);
  320.  
  321. /*
  322.  * Overridden method: wpclsQueryIconData
  323.  */
  324. #pragma linkage(oemM_wpclsQueryIconData, system)
  325. SOM_Scope ULONG   SOMLINK oemM_wpclsQueryIconData(M_oem *somSelf,
  326.         PICONINFO pIconInfo);
  327. #ifndef somMN_wpclsQueryIconData_defined
  328. #define somMN_wpclsQueryIconData_defined
  329.    static char *somMN_wpclsQueryIconData = "wpclsQueryIconData";
  330.    static somId somId_wpclsQueryIconData = &somMN_wpclsQueryIconData;
  331. #endif  /* somMN_wpclsQueryIconData_defined */
  332. #define parent_oemM_wpclsQueryIconData(somSelf,pIconInfo) \
  333.     ((SOM_ParentNumResolve(M_WPObject, 1, M_oemCClassData.parentMtab, wpclsQueryIconData)) \
  334.      (somSelf,pIconInfo))
  335. #ifndef parent_wpclsQueryIconData
  336.    #define parent_wpclsQueryIconData(somSelf,pIconInfo) \
  337.     ((SOM_ParentNumResolve(M_WPObject, 1, SOM_CurrentClass, wpclsQueryIconData)) \
  338.      (somSelf,pIconInfo))
  339. #endif  /* parent_wpclsQueryIconData */
  340. #define M_oem_parents_oemM_wpclsQueryIconData(arg0,arg1) \
  341.    (void) parent_oemM_wpclsQueryIconData(arg0,arg1);
  342.  
  343. /*
  344.  * Initialize the class data structure
  345.  */
  346. struct M_oemClassDataStructure M_oemClassData = {(SOMAny *) NULL};
  347.  
  348. /*
  349.  * Define the C class data structure
  350.  */
  351. struct M_oemCClassDataStructure M_oemCClassData = {(somMethodTabs) NULL};
  352.  
  353. /*
  354.  * Routines and Structures to create the class object
  355.  */
  356.  
  357. /*
  358.  * Declare the Override Methods table.
  359.  */
  360. static somOverrideMethod_t M_oemOM[] = {
  361.     {    &somId_wpclsQueryTitle,
  362.          (somMethodProc *) oemM_wpclsQueryTitle    },
  363.     {    &somId_wpclsQueryIconData,
  364.          (somMethodProc *) oemM_wpclsQueryIconData    },
  365. };
  366.  
  367.  
  368. /*
  369.  *  Initializers for class Ids
  370.  */
  371. static char * somCN_M_oem = "M_oem";
  372. static char * somPCN_M_oem_M_PenLocatorPen = "M_PenLocatorPen";
  373.  
  374. static somId somPCM_oem[] = {
  375.     &somPCN_M_oem_M_PenLocatorPen,
  376. };
  377.  
  378. static somStaticClassInfo M_oemSCI = {
  379.     3, 0, 2, 0, 0, 0,
  380.     M_oem_MajorVersion, M_oem_MinorVersion,
  381.     0, M_oem_MaxNoMethods, 1,
  382.     &somCN_M_oem,
  383.     (somId) NULL, 1,
  384.     somPCM_oem,
  385.     (somClassDataStructure *) &M_oemClassData,
  386.     (somCClassDataStructure *) &M_oemCClassData,
  387.     (somStaticMethod_t *) NULL, M_oemOM,
  388.     (char *) NULL,
  389.     (somNonInternalData_t *) NULL,  (somProcMethods_t *) NULL,
  390.     (somVarargsFuncs_t *) NULL,
  391.     (somTP_somClassInitFunc *) NULL,
  392.     0,
  393.     0,  /* old style class, zero directinitclasses */
  394.     0, /* no directinitclasses */
  395.     0, /* number of methods */
  396.     0, /* methods of the class */
  397.     0, /* dataOffset1 */
  398.     0, /* dataOffset2 */
  399.     0, /* number of SelectInheritedMethods */
  400.     0, /* SelectInheritedMethods */
  401.     0, /* number of releaseorder entries */
  402.     0, /* ReleaseOrder */
  403.     0, /* number of migrated methods */
  404.     0, /* migrated method implementations */
  405.     0, /* number of initializers */
  406.     0, /* initializers */
  407.     0, /* used to identify a DTS class */
  408.     0, /* used to register dynamically computed info */
  409. };
  410.  
  411.  
  412. M_oem * SOMLINK M_oemNewClass (integer4 somtmajorVersion,
  413.         integer4 somtminorVersion)
  414. {
  415.     M_PenLocatorPenNewClass(M_PenLocatorPen_MajorVersion,M_PenLocatorPen_MinorVersion);    /* static reference */
  416.     return (somBuildClass(1,&M_oemSCI, somtmajorVersion, somtminorVersion));
  417. }
  418.  
  419. /*
  420.  * Functions for attributes.
  421.  */
  422.  
  423. #endif                   /* M_oem_Class_Source */
  424. #pragma checkout(resume)
  425.  
  426. #endif       /* SOM_M_M_oem_mih */
  427.