summaryrefslogtreecommitdiff
path: root/plugins/Libs/KOLDEF.inc
blob: cc7a004604b9d44087f00197ba572f75369515ce (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
{$IFDEF VER90}
              {$DEFINE _D2}
              {$DEFINE _D2orD3}
              {$DEFINE _D2orD3orD4}
{$ENDIF}

{$IFDEF VER100}
              {$DEFINE _D3}
              {$DEFINE _D3orHigher}
              {$DEFINE _D2orD3}
              {$DEFINE _D2orD3orD4}
              {$DEFINE _D3orD4}
{$ENDIF}

{$IFDEF VER120}
              {$DEFINE _D3orHigher}
              {$DEFINE _D3orD4}
              {$DEFINE _D4}
              {$DEFINE _D4orHigher}
              {$DEFINE _D2orD3orD4}
                  {$IFnDEF KOL_MCK}
                           {$DEFINE INPACKAGE}
                  {$ENDIF}
{$ENDIF}

{$IFDEF VER130}
              {$DEFINE _D3orHigher}
              {$DEFINE _D4orHigher}
              {$DEFINE _D5}
              {$DEFINE _D5orHigher}
{$ENDIF}

{$IFDEF VER140}
              {$DEFINE _D3orHigher}
              {$DEFINE _D4orHigher}
              {$DEFINE _D5orHigher}
              {$DEFINE _D6}
              {$DEFINE _D6orHigher}
{$ENDIF}

{$IFDEF VER150}
              {$DEFINE _D3orHigher}
              {$DEFINE _D4orHigher}
              {$DEFINE _D5orHigher}
              {$DEFINE _D6orHigher}
              {$DEFINE _D7}
              {$DEFINE _D7orHigher}
{$WARN UNIT_DEPRECATED OFF}
{$WARN SYMBOL_PLATFORM OFF}
{$WARN UNSAFE_TYPE OFF}
{$WARN UNSAFE_CAST OFF}
{$WARN UNSAFE_CODE OFF}
{$ENDIF}

{$IFDEF VER160} // Delphi 8
Delphi version 8 not supported! (delphi 8 is .net only)
{$ENDIF}

{$IFDEF VER170} // Delphi 2005
             {$DEFINE _D3orHigher}
             {$DEFINE _D4orHigher}
             {$DEFINE _D5orHigher}
             {$DEFINE _D6orHigher}
             {$DEFINE _D7orHigher}
             {$DEFINE _D8}
             {$DEFINE _D8orHigher}
             {$DEFINE _D2005}
             {$DEFINE _D2005orHigher}
{$WARN UNIT_DEPRECATED OFF}
{$WARN SYMBOL_PLATFORM OFF}
{$WARN UNSAFE_TYPE OFF}
{$WARN UNSAFE_CAST OFF}
{$WARN UNSAFE_CODE OFF}
{$ENDIF}

{$IFDEF VER180} // Delphi 2006
             {$DEFINE _D3orHigher}
             {$DEFINE _D4orHigher}
             {$DEFINE _D5orHigher}
             {$DEFINE _D6orHigher}
             {$DEFINE _D7orHigher}
             {$DEFINE _D8orHigher}
             {$DEFINE _D2005}
             {$DEFINE _D2005orHigher}
             {$DEFINE _D2006orHigher}
{$WARN UNIT_DEPRECATED OFF}
{$WARN SYMBOL_PLATFORM OFF}
{$WARN UNSAFE_TYPE OFF}
{$WARN UNSAFE_CAST OFF}
{$WARN UNSAFE_CODE OFF}
{$ENDIF}

{$IFDEF _D2005orHigher}

  // by Thaddy de Koning:
  {$IFDEF VER185} // Delphi 2007 ( and Highlander )
               {$DEFINE _D3orHigher}
               {$DEFINE _D4orHigher}
               {$DEFINE _D5orHigher}
               {$DEFINE _D6orHigher}
               {$DEFINE _D7orHigher}
               {$DEFINE _D2005orHigher}
               {$DEFINE _D2006orHigher}
               {$DEFINE _D2007}
               {$DEFINE _D2007orHigher}
  {$WARN UNIT_DEPRECATED OFF}
  {$WARN SYMBOL_PLATFORM OFF}
  {$WARN UNSAFE_TYPE OFF}
  {$WARN UNSAFE_CAST OFF}
  {$WARN UNSAFE_CODE OFF}
  {$ENDIF}

{$INLINE OFF}
{$ENDIF}

{$IFDEF VER200} // Delphi 2009
             {$DEFINE _D3orHigher}
             {$DEFINE _D4orHigher}
             {$DEFINE _D5orHigher}
             {$DEFINE _D6orHigher}
             {$DEFINE _D7orHigher}
             {$DEFINE _D2005orHigher}
             {$DEFINE _D2006orHigher}
             {$DEFINE _D2007orHigher}
             {$DEFINE _D2009}
             {$DEFINE _D2009orHigher}
{$WARN UNIT_DEPRECATED OFF}
{$WARN SYMBOL_PLATFORM OFF}
{$WARN UNSAFE_TYPE OFF}
{$WARN UNSAFE_CAST OFF}
{$WARN UNSAFE_CODE OFF}
{$ENDIF}

{$IFDEF VER210} // Delphi 2010
	{$DEFINE _D3orHigher}
	{$DEFINE _D4orHigher}
	{$DEFINE _D5orHigher}
	{$DEFINE _D6orHigher}
	{$DEFINE _D7orHigher}
	{$DEFINE _D2005orHigher}
	{$DEFINE _D2006orHigher}
	{$DEFINE _D2007orHigher}
	{$DEFINE _D2009orHigher}
	{$DEFINE _D2010}
	{$DEFINE _D2010orHigher}
	{$WARN UNIT_DEPRECATED OFF}
	{$WARN SYMBOL_PLATFORM OFF}
	{$WARN UNSAFE_TYPE OFF}
	{$WARN UNSAFE_CAST OFF}
	{$WARN UNSAFE_CODE OFF}
{$ENDIF}

{$IFDEF VER220} // Delphi XE
	{$DEFINE _D3orHigher}
	{$DEFINE _D4orHigher}
	{$DEFINE _D5orHigher}
	{$DEFINE _D6orHigher}
	{$DEFINE _D7orHigher}
	{$DEFINE _D2005orHigher}
	{$DEFINE _D2006orHigher}
	{$DEFINE _D2007orHigher}
	{$DEFINE _D2009orHigher}
	{$DEFINE _D2010orHigher}
	{$DEFINE _DXE}
	{$DEFINE _DXEorHigher}
    {$WARN UNIT_DEPRECATED OFF}
	{$WARN SYMBOL_PLATFORM OFF}
	{$WARN UNSAFE_TYPE OFF}
	{$WARN UNSAFE_CAST OFF}
	{$WARN UNSAFE_CODE OFF}
{$ENDIF}

{$IFDEF VER230} // Delphi XE2
	{$DEFINE _D3orHigher}
	{$DEFINE _D4orHigher}
	{$DEFINE _D5orHigher}
	{$DEFINE _D6orHigher}
	{$DEFINE _D7orHigher}
	{$DEFINE _D2005orHigher}
	{$DEFINE _D2006orHigher}
	{$DEFINE _D2007orHigher}
	{$DEFINE _D2009orHigher}
	{$DEFINE _D2010orHigher}
	{$DEFINE _DXE}
	{$DEFINE _DXEorHigher}
	{$DEFINE _DXE2}
	{$DEFINE _DXE2orHigher}
	{$DEFINE PAS_VERSION}
  {$WARN UNIT_DEPRECATED OFF}
	{$WARN SYMBOL_PLATFORM OFF}
	{$WARN UNSAFE_TYPE OFF}
	{$WARN UNSAFE_CAST OFF}
	{$WARN UNSAFE_CODE OFF}
{$ENDIF}

(*
// TODO: check DLL project
{$IFNDEF NO_STRIP_RELOC}
  // by Thaddy de Koning:
  {$IFDEF _D2006orHigher}
  // strips relocs, like stripreloc.exe does
  {$SetPEFlags 1}
//	{$SETPEFlAGS IMAGE_FILE_RELOCS_STRIPPED or IMAGE_FILE_DEBUG_STRIPPED or IMAGE_FILE_LINE_NUMS_STRIPPED or IMAGE_FILE_LOCAL_SYMS_STRIPPED or IMAGE_FILE_REMOVABLE_RUN_FROM_SWAP or IMAGE_FILE_NET_RUN_FROM_SWAP}
  {$ENDIF}
{$ENDIF}
*)
{$IFDEF FPC}
{------------------------------------
by Thaddy de Koning:

FPC version 2.1.1 is very compatible with Delphi and kol now.
You can simply use the $(DELPHI)\source\rtl\win\*.pas files from Delphi 4/5 instead of the prepared files that were needed for 
FPC1.X
 
That is all to have full compatibility.
------------------------------------}
  {$DEFINE PAS_VERSION}
  {$IFDEF VER2}
   {$DEFINE _D3orHigher}
   {$DEFINE _D4orHigher}
   {$DEFINE _D5orHigher}
   {$DEFINE _D6orHigher}
   {$DEFINE _D7}
   {$DEFINE _D7orHigher}
  {$ENDIF}
{$ENDIF FPC}

{$IFNDEF _NOT_KOLCtrlWrapper_}
 {$DEFINE _KOLCtrlWrapper_}
{$ENDIF}

{$IFNDEF _NOT_KOLCtrlWrapper_}
  {$DEFINE _KOLCtrlWrapper_}
{$ENDIF}

//// from delphidef.inc ////

{$IFDEF WIN64}
  {$DEFINE x64}
  {$DEFINE PAS_VERSION}
{$ENDIF}

//{$DEFINE _FPC}
{$DEFINE ASM_VERSION} // Comment this line to produce Pascal code.
                      // Or, just add PAS_VERSION to conditionals
                      // of your project (must be rebuilt).

{$IFDEF ASM_VERSION}
  {$IFDEF PAS_VERSION}
    {$UNDEF ASM_VERSION}
    // To compile a project with ASM_VERSION option turned off,
    // define a symbol PAS_VERSION in project options.
  {$ENDIF}
{$ENDIF}

//{$DEFINE USE_CONSTRUCTORS}
// Comment this line to produce smaller code if constructors are not used.
// When uncommented, this definition allows to create descendant controls
// and objects overriding constructors, which are actually members of objects.
// Otherwise, global functions (usually named New<ObjectName>) are used to
// create and initialize object instances. This gives smaller code, but
// prevents from using OOP inheritance.
// Note: creating descendant objects derived from TObj does not require using
// of this option. It is actually needed only for deriving new controls on
// base of TControl. See also option USE_CUSTOMEXTENSIONS below.

//{$DEFINE USE_CUSTOMEXTENSIONS}
// Uncomment this option or add it to your project conditional defines,
// if You wish to extend existing TControl object from
// the inner of those. When this option is turned on, include directive at the
// tail of TControl declaration is enabled, causing a compiler to include your
// portion of source directly into the TControl body. See comments near this
// directive there. (Search the word: USE_CUSTOMEXTENSIONS).
// Please note, that this option is not fully supported now.

//{$IFNDEF NOT_UNLOAD_RICHEDITLIB}
//  {$DEFINE UNLOAD_RICHEDITLIB}
//{$ENDIF}
// You can freely comment this directive. 1st, if the application does not
// use richedit control. 2nd, even if it does, freeing the library handle
// actually is not needed.
// Another way to turn this option off is to define symbol NOT_UNLOAD_RICHEDITLIB
// in your project options.

//{$DEFINE TEST_VERSION}
{$IFNDEF _D6orHigher}
 {$DEFINE PARANOIA} //seems not needed from D6 !!! Inprise fixed this, finally...
{$ENDIF}


{$IFNDEF USE_OLD_FLAGS}
         {$DEFINE USE_FLAGS}
{$ELSE}  {$UNDEF  USE_FLAGS}
{$ENDIF}

{$IFnDEF EVENTS_STATIC}
         {$DEFINE EVENTS_DYNAMIC}
{$ENDIF}
{$IFnDEF CMDACTIONS_RECORD}
         {$DEFINE COMMANDACTIONS_OBJ}
         {$DEFINE PACK_COMMANDACTIONS}
         {$IFDEF  NOT_PACK_COMMANDACTIONS}
                  {$UNDEF PACK_COMMANDACTIONS}
         {$ENDIF}
{$ENDIF}

{$DEFINE KOL3XX}
{$DEFINE DIBPixels32bitWithAlpha}