Quantum Fog  0.9.3
CommonMach-OPrefix.h
1 // ===========================================================================
2 // CommonMach-OPrefix.h ©1999-2003 Metrowerks Corporation. All rights reserved.
3 // ===========================================================================
4 // Common options for a Mach-O Target
5 
6 // ---------------------------------------------------------------------------
7 // Mach-O Target
8 
9 #define PP_Target_Carbon 1
10 
11 #define PP_Target_Classic (!PP_Target_Carbon)
12 
13 #define TARGET_API_MAC_CARBON PP_Target_Carbon
14 #define TARGET_API_MAC_OS8 PP_Target_Classic
15 #define TARGET_API_MAC_OSX PP_Target_Carbon
16 
17 
18 // ---------------------------------------------------------------------------
19 // Options
20 
21 #define PP_Uses_PowerPlant_Namespace 0
22 #define PP_Supports_Pascal_Strings 1
23 #define PP_StdDialogs_Option PP_StdDialogs_NavServicesOnly
24 
25 #define PP_Uses_Old_Integer_Types 0
26 #define PP_Obsolete_AllowTargetSwitch 0
27 #define PP_Obsolete_ThrowExceptionCode 0
28 #define PP_Warn_Obsolete_Classes 1
29 
30 #define PP_Suppress_Notes_221 1
31 
32 #include <MSLCarbonPrefix.h>
33 
34 #include <cmath>//c language math
35 #include <fp.h> //must be after #include <cmath>, both necessary
36 #include <complex>
37 //FIXEDDECIMAL or FLOATDECIMAL are used
38 //as the second argument of LString::Assign ( double, char, SInt16 )
39 //Definition in fp.h but not loaded?
40 #ifndef FIXEDDECIMAL
41  #define FIXEDDECIMAL 1
42 #endif
43 
44 
45 //see MacTypes.h header, linker couldn't find memmove and bzero
46 #define NO_BLOCKMOVE_INLINE 1
47 
48 
49 //-----------------------------------------------------------------
50 //NONTRIVIAL EXCERPT FROM PP
51 //see DebugSample_PrefixCommon.h
52 
53 // _do_debug corresponds to __PP_SAMPLE_DEBUG__ in CDebugApp sample project
54 #ifndef _do_debug
55 #error "_do_debug is not yet #defined"
56 #endif
57 
58 #if !(_do_debug==0 || _do_debug==1)
59 #error "_do_debug is not zero or one"
60 #endif
61 
62 
63 // MacOS Macros
64 
65 #define OLDROUTINENAMES 0
66 #define OLDROUTINELOCATIONS 0
67 #define SystemSevenOrLater 1
68 
69 // use new PP API
70 
71 #define PP_Obsolete_Constants 0
72 #define PP_Obsolete_Stream_Creators 0
73 #define PP_Obsolete_Array_API 0
74 
75 // for MSL
76 
77 #if 0 // already defined in ansi_prefix.mach.h
78 #define __dest_os __mac_os
79 #endif
80 
81 #if _do_debug
82 
83  //for UDebugging and UException which give Throw_() and Signal_() capabilities:
84  #define Debug_Throw
85  #define Debug_Signal
86 
87  //these debugging macros must be #defined to desired value
88 
89  #define PP_DEBUG 1
90 // #define PP_USE_MOREFILES
91  #define PP_SPOTLIGHT_SUPPORT 1
92  #define PP_QC_SUPPORT 0
93  #define PP_DEBUGNEW_SUPPORT 0
94 
95  //set DebugNew to full strength
96  //could also be set to DEBUG_NEW_BASIC
97 
98 // #define DEBUG_NEW DEBUG_NEW_LEAKS
99 
100 #else
101 
102  // when not debugging, turn everything is off
103  // (only used for final builds)
104 
105  #define PP_DEBUG 0
106  // we don't need MoreFiles in the final build, but if we
107  // did, it would be safe to leave this #defined in.
108 // #define PP_USE_MOREFILES
109  #define PP_SPOTLIGHT_SUPPORT 0
110  #define PP_QC_SUPPORT 0
111  #define PP_DEBUGNEW_SUPPORT 0
112 
113  //since we're not supporting DebugNew, no need to define DEBUG_NEW
114  #define DEBUG_NEW DEBUG_NEW_OFF
115 
116 #endif
117 //After defining all the debugging macros,
118 //we are ready for this header
119 #include <PP_Debug.h>
120 
121 #if _do_debug
122 
123 
124  // A nifty DebugNew feature is the ability to generate a "leaks.log"
125  // file detailing the leaks that it found. The way it does this is
126  // through some preprocessor "magic" turning "new" into "NEW". This
127  // is a hack, basically, but it can generally work. However, DebugNew
128  // cannot work with array operator new (new[]). So if you use array
129  // operator new anywhere, this trick will NOT work for you (in fact
130  // it could cause trouble). About your only solution then is to
131  // manually replace "new" with "NEW" throughout your code.
132  //
133  // new[] doesn't work because the MW C/C++ compiler (up until CWP3)
134  // did not support overriding/overloading new[]. And DebugNew needs
135  // to be updated to suit this (at the time of this writing, it was
136  // not).
137  //
138  // Also, if you have your own operator new anywhere (or really any
139  // use of the word "new" that's in source and not in a comment), the
140  // preprocessor will replace "new" with "NEW". This could cause all
141  // sorts of havoc (e.g. try this with LThread or LReentrantMemoryPool
142  // (and it's LRMPObject class)).
143  //
144  // If you cannot utilize DebugNew's DEBUG_NEW_LEAKS functionality
145  // then your best bet would probably be to use DebugNew at the
146  // DEBUG_NEW_BASIC level and rely upon something like Spotlight
147  // for your C++ leak checking.
148 
149  #if PP_DEBUGNEW_SUPPORT && DEBUG_NEW == DEBUG_NEW_LEAKS
150  #include <new.h>
151  // NEW is only useful for leaks
152  #define new NEW
153  #endif
154 
155 #endif
156 //-----------------------------------------------------------------
157 
158 
159 //in addition to what is in PP_ClassHeaders.cp
160 #include <LTable.h>
161 #include <LTableView.h>
162 #include <LTableMultiSelector.h>
163 #include <LTableMultiGeometry.h>
164 #include <LTableMonoGeometry.h>
165 #include <LGroupBox.h>
166 #include <LIconPane.h>
167 #include <PP_DebugMacros.h>
168 
169 #include <LPopupButton.h>
170 #include <UNavServicesDialogs.h>
171 #include <UControlRegistry.h>
172 
173 
174 
175 #include "my_notation.h"
176 
177 #define _mac_gui_app
178 /*
179 The ansi application and the mac gui application each has parts that
180 are not in the other.
181 
182 The overlapping code will have no preprocessor
183 conditionals bracketing it.
184 
185 The parts that are in the ansi_app minus
186 the mac_gui_app will be bracketed by #ifdef _ansi_app.
187 
188 The parts that are in the mac_gui_app minus
189 the ansi_app will be bracketed by #ifdef _mac_gui_app.
190 
191 The ansi_app is non-graphical and ANSI compatible.
192 It can run on any platform.
193 
194 */
195 
196 
197 
198 
199 
200 
201