source: branches/classes/c/c_image/cwavc.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: 4.0 KB
Line 
1/*
2 * (C) Chris Wohlgemuth 2002-2004
3 *
4 */
5/*
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2, or (at your option)
9 * any later version.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License
17 * along with this program; see the file COPYING. If not, write to
18 * the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
19 */
20/*
21 * If you need another license for your project/product (commercial,
22 * noncommercial, whatever) contact me at
23 *
24 * http://www.os2world.com/cdwriting
25 * http://www.geocities.com/SiliconValley/Sector/5785/
26 *
27 */
28
29/*
30 * This file was generated by the SOM Compiler and Emitter Framework.
31 * Generated using:
32 * SOM Emitter emitctm: 2.42
33 */
34
35#ifndef SOM_Module_cwavc_Source
36#define SOM_Module_cwavc_Source
37#endif
38#define CWAVC_Class_Source
39#define M_CWAVC_Class_Source
40
41#include <os2.h>
42#include "helpid.h"
43#include "cwavc.ih"
44
45extern char chrHelpLibrary[CCHMAXPATH];
46
47HMODULE queryResModuleHandle(void);
48HMODULE queryModuleHandle(void);
49BOOL getMessage(char* text,ULONG ulID, LONG lSizeText, HMODULE hResource,HWND hwnd);
50
51/*
52 * The prototype for cwavcM_wpclsQueryInstanceType was replaced by the following prototype:
53 */
54SOM_Scope PSZ SOMLINK cwavcM_wpclsQueryInstanceType(M_MMAVC *somSelf)
55{
56 /* M_CWAVCData *somThis = M_CWAVCGetData(somSelf); */
57 M_MMAVCMethodDebug("M_MMAVC","cwavcM_wpclsQueryInstanceType");
58
59 return "AVC Image";
60}
61
62/*
63 * The prototype for cwavcM_wpclsQueryInstanceFilter was replaced by the following prototype:
64 */
65SOM_Scope PSZ SOMLINK cwavcM_wpclsQueryInstanceFilter(M_MMAVC *somSelf)
66{
67 /* M_CWAVCData *somThis = M_CWAVCGetData(somSelf); */
68 M_MMAVCMethodDebug("M_MMAVC","cwavcM_wpclsQueryInstanceFilter");
69
70 return "*._IM";
71}
72
73/*
74 * The prototype for cwavcM_wpclsQueryDefaultHelp was replaced by the following prototype:
75 */
76SOM_Scope BOOL SOMLINK cwavcM_wpclsQueryDefaultHelp(M_MMAVC *somSelf,
77 PULONG pHelpPanelId,
78 PSZ pszHelpLibrary)
79{
80 /* M_CWAVCData *somThis = M_CWAVCGetData(somSelf); */
81 M_MMAVCMethodDebug("M_MMAVC","cwavcM_wpclsQueryDefaultHelp");
82
83 if(pHelpPanelId)
84 *pHelpPanelId=AVCFILE_HELP_PANEL;
85 if(pszHelpLibrary)
86 strncpy(pszHelpLibrary, chrHelpLibrary, CCHMAXPATH);
87 return TRUE;
88}
89
90
91/*
92 * The prototype for cwavcM_wpclsQueryTitle was replaced by the following prototype:
93 */
94SOM_Scope PSZ SOMLINK cwavcM_wpclsQueryTitle(M_MMAVC *somSelf)
95{
96 static char chrTitle[20]={0};
97 /* M_CWAVCData *somThis = M_CWAVCGetData(somSelf); */
98 M_MMAVCMethodDebug("M_MMAVC","cwavcM_wpclsQueryTitle");
99
100 if(chrTitle[0]==0)
101 if(!getMessage(chrTitle, IDSTR_AVCTITLE, sizeof(chrTitle), queryResModuleHandle(), HWND_DESKTOP))
102 strcpy(chrTitle,"AVCImage.AVC");
103
104 return chrTitle;
105}
106
107/*
108 * The prototype for cwavcM_wpclsQueryIconData was replaced by the following prototype:
109 */
110SOM_Scope ULONG SOMLINK cwavcM_wpclsQueryIconData(M_MMAVC *somSelf,
111 PICONINFO pIconInfo)
112{
113 HMODULE hmod;
114
115 /* M_CWAVCData *somThis = M_CWAVCGetData(somSelf); */
116 M_MMAVCMethodDebug("M_MMAVC","cwavcM_wpclsQueryIconData");
117
118 hmod=queryModuleHandle();
119 if(!hmod)
120 return M_MMAVC_parent_M_MMImage_wpclsQueryIconData(somSelf, pIconInfo);
121
122 if (pIconInfo) {
123 pIconInfo->fFormat = ICON_RESOURCE;
124 pIconInfo->hmod = hmod;
125 pIconInfo->resid = ID_ICONAVCFILE;
126 } /* endif */
127
128 return ( sizeof(ICONINFO) );
129}
130
131
132
Note: See TracBrowser for help on using the repository browser.