source: branches/classes/c/c_image/cwpcx.c

Last change on this file was 2, checked in by stevenhl, 8 years ago

Import sources from cwmm-full.zip dated 2005-03-21

File size: 3.0 KB
Line 
1/*
2 * This file was generated by the SOM Compiler and Emitter Framework.
3 * Generated using:
4 * SOM Emitter emitctm: 2.42
5 */
6
7#ifndef SOM_Module_cwpcx_Source
8#define SOM_Module_cwpcx_Source
9#endif
10#define CWPCX_Class_Source
11#define M_CWPCX_Class_Source
12
13#include <os2.h>
14#include "helpid.h"
15#include "cwpcx.ih"
16
17extern char chrHelpLibrary[CCHMAXPATH];
18
19HMODULE queryResModuleHandle(void);
20HMODULE queryModuleHandle(void);
21BOOL getMessage(char* text,ULONG ulID, LONG lSizeText, HMODULE hResource,HWND hwnd);
22
23/*
24 * The prototype for cwpcxM_wpclsQueryInstanceType was replaced by the following prototype:
25 */
26SOM_Scope PSZ SOMLINK cwpcxM_wpclsQueryInstanceType(M_MMPCX *somSelf)
27{
28 /* M_CWPCXData *somThis = M_CWPCXGetData(somSelf); */
29 M_MMPCXMethodDebug("M_MMPCX","cwpcxM_wpclsQueryInstanceType");
30
31 return "PCX";
32}
33
34/*
35 * The prototype for cwpcxM_wpclsQueryInstanceFilter was replaced by the following prototype:
36 */
37SOM_Scope PSZ SOMLINK cwpcxM_wpclsQueryInstanceFilter(M_MMPCX *somSelf)
38{
39 /* M_CWPCXData *somThis = M_CWPCXGetData(somSelf); */
40 M_MMPCXMethodDebug("M_MMPCX","cwpcxM_wpclsQueryInstanceFilter");
41
42 return "*.PCX";
43}
44
45
46/*
47 * The prototype for cwpcxM_wpclsQueryDefaultHelp was replaced by the following prototype:
48 */
49SOM_Scope BOOL SOMLINK cwpcxM_wpclsQueryDefaultHelp(M_MMPCX *somSelf,
50 PULONG pHelpPanelId,
51 PSZ pszHelpLibrary)
52{
53 /* M_CWPCXData *somThis = M_CWPCXGetData(somSelf); */
54 M_MMPCXMethodDebug("M_MMPCX","cwpcxM_wpclsQueryDefaultHelp");
55
56 if(pHelpPanelId)
57 *pHelpPanelId=PCXFILE_HELP_PANEL;
58 if(pszHelpLibrary)
59 strncpy(pszHelpLibrary, chrHelpLibrary, CCHMAXPATH);
60 return TRUE;
61}
62
63/*
64 * The prototype for cwpcxM_wpclsQueryTitle was replaced by the following prototype:
65 */
66SOM_Scope PSZ SOMLINK cwpcxM_wpclsQueryTitle(M_MMPCX *somSelf)
67{
68 static char chrTitle[20]={0};
69 /* M_CWPCXData *somThis = M_CWPCXGetData(somSelf); */
70 M_MMPCXMethodDebug("M_MMPCX","cwpcxM_wpclsQueryTitle");
71
72 if(chrTitle[0]==0)
73 if(!getMessage(chrTitle, IDSTR_PCXTITLE, sizeof(chrTitle), queryResModuleHandle(), HWND_DESKTOP))
74 strcpy(chrTitle,"PCXImage.PCX");
75
76 return chrTitle;
77}
78
79/*
80 * The prototype for cwpcxM_wpclsQueryIconData was replaced by the following prototype:
81 */
82SOM_Scope ULONG SOMLINK cwpcxM_wpclsQueryIconData(M_MMPCX *somSelf,
83 PICONINFO pIconInfo)
84{
85 HMODULE hmod;
86 /* M_CWPCXData *somThis = M_CWPCXGetData(somSelf); */
87 M_MMPCXMethodDebug("M_MMPCX","cwpcxM_wpclsQueryIconData");
88
89 hmod=queryModuleHandle();
90 if(!hmod)
91 return M_MMPCX_parent_M_MMImage_wpclsQueryIconData(somSelf, pIconInfo);
92
93 if (pIconInfo) {
94 pIconInfo->fFormat = ICON_RESOURCE;
95 pIconInfo->hmod = hmod;
96 pIconInfo->resid = ID_ICONPCXFILE;
97 } /* endif */
98
99 return ( sizeof(ICONINFO) );
100
101}
102
Note: See TracBrowser for help on using the repository browser.