diff options
author | Peter D'Hoye <peter.dhoye@gmail.com> | 2009-05-24 21:28:16 +0000 |
---|---|---|
committer | Peter D'Hoye <peter.dhoye@gmail.com> | 2009-05-24 21:28:16 +0000 |
commit | 526b5580dabbfed7cfe5439dc3a90ec727f563c2 (patch) | |
tree | 22b1af92348785daad16714ee5e2b633017e0e48 /apps/plugins/pdbox/PDa/src/t_main.c | |
parent | 4f2dfcc01b260d946044ef2b6af5fe36cb772c8d (diff) | |
download | rockbox-526b5580dabbfed7cfe5439dc3a90ec727f563c2.tar.gz rockbox-526b5580dabbfed7cfe5439dc3a90ec727f563c2.zip |
Cut the files in half and it might work better (note to self: check your tree is really clean before patching)
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21070 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/plugins/pdbox/PDa/src/t_main.c')
-rw-r--r-- | apps/plugins/pdbox/PDa/src/t_main.c | 119 |
1 files changed, 0 insertions, 119 deletions
diff --git a/apps/plugins/pdbox/PDa/src/t_main.c b/apps/plugins/pdbox/PDa/src/t_main.c index 7b80cb0dd6..d68579e745 100644 --- a/apps/plugins/pdbox/PDa/src/t_main.c +++ b/apps/plugins/pdbox/PDa/src/t_main.c | |||
@@ -118,123 +118,4 @@ Tcl_AppInit(interp) | |||
118 | } | 118 | } |
119 | 119 | ||
120 | #endif /* MACOSX */ | 120 | #endif /* MACOSX */ |
121 | /* Copyright (c) 1997-1999 Miller Puckette. | ||
122 | * For information on usage and redistribution, and for a DISCLAIMER OF ALL | ||
123 | * WARRANTIES, see the file, "LICENSE.txt," in this distribution. */ | ||
124 | |||
125 | /* This file should be compared with the corresponding thing in the TK | ||
126 | * distribution whenever updating to newer versions of TCL/TK. */ | ||
127 | |||
128 | /* | ||
129 | * Copyright (c) 1993 The Regents of the University of California. | ||
130 | * Copyright (c) 1994 Sun Microsystems, Inc. | ||
131 | * | ||
132 | * See the file "license.terms" for information on usage and redistribution | ||
133 | * of this file, and for a DISCLAIMER OF ALL WARRANTIES. | ||
134 | */ | ||
135 | |||
136 | |||
137 | #ifndef MACOSX /* linux and IRIX only; in MACOSX we don't link this in */ | ||
138 | #include "tk.h" | ||
139 | #include <stdlib.h> | ||
140 | |||
141 | /* | ||
142 | * The following variable is a special hack that is needed in order for | ||
143 | * Sun shared libraries to be used for Tcl. | ||
144 | */ | ||
145 | |||
146 | extern int matherr(void); | ||
147 | int *tclDummyMathPtr = (int *) matherr; | ||
148 | |||
149 | /* | ||
150 | *---------------------------------------------------------------------- | ||
151 | * | ||
152 | * main -- | ||
153 | * | ||
154 | * This is the main program for the application. | ||
155 | * | ||
156 | * Results: | ||
157 | * None: Tk_Main never returns here, so this procedure never | ||
158 | * returns either. | ||
159 | * | ||
160 | * Side effects: | ||
161 | * Whatever the application does. | ||
162 | * | ||
163 | *---------------------------------------------------------------------- | ||
164 | */ | ||
165 | |||
166 | void pdgui_startup(Tcl_Interp *interp); | ||
167 | void pdgui_setname(char *name); | ||
168 | void pdgui_setsock(int port); | ||
169 | void pdgui_sethost(char *name); | ||
170 | 121 | ||
171 | int | ||
172 | main(int argc, char **argv) | ||
173 | { | ||
174 | pdgui_setname(argv[0]); | ||
175 | if (argc >= 2) | ||
176 | { | ||
177 | pdgui_setsock(atoi(argv[1])); | ||
178 | argc--; argv++; | ||
179 | argv[0] = "Pd"; | ||
180 | } | ||
181 | if (argc >= 2) | ||
182 | { | ||
183 | pdgui_sethost(argv[1]); | ||
184 | argc--; argv++; | ||
185 | argv[0] = "Pd"; | ||
186 | } | ||
187 | Tk_Main(argc, argv, Tcl_AppInit); | ||
188 | return 0; /* Needed only to prevent compiler warning. */ | ||
189 | } | ||
190 | |||
191 | |||
192 | /* | ||
193 | *---------------------------------------------------------------------- | ||
194 | * | ||
195 | * Tcl_AppInit -- | ||
196 | * | ||
197 | * This procedure performs application-specific initialization. | ||
198 | * Most applications, especially those that incorporate additional | ||
199 | * packages, will have their own version of this procedure. | ||
200 | * Results: | ||
201 | * Returns a standard Tcl completion code, and leaves an error | ||
202 | * message in interp->result if an error occurs. | ||
203 | * | ||
204 | * Side effects: | ||
205 | * Depends on the startup script. | ||
206 | * | ||
207 | *---------------------------------------------------------------------- | ||
208 | */ | ||
209 | |||
210 | int | ||
211 | Tcl_AppInit(interp) | ||
212 | Tcl_Interp *interp; /* Interpreter for application. */ | ||
213 | { | ||
214 | |||
215 | if (Tcl_Init(interp) == TCL_ERROR) { | ||
216 | return TCL_ERROR; | ||
217 | } | ||
218 | if (Tk_Init(interp) == TCL_ERROR) { | ||
219 | return TCL_ERROR; | ||
220 | } | ||
221 | |||
222 | /* setup specific to pd-gui: */ | ||
223 | |||
224 | pdgui_startup(interp); | ||
225 | |||
226 | /* | ||
227 | * Specify a user-specific startup file to invoke if the application | ||
228 | * is run interactively. Typically the startup file is "~/.apprc" | ||
229 | * where "app" is the name of the application. If this line is deleted | ||
230 | * then no user-specific startup file will be run under any conditions. | ||
231 | */ | ||
232 | |||
233 | #if 0 | ||
234 | tcl_RcFileName = "~/.pdrc"; | ||
235 | #endif | ||
236 | |||
237 | return TCL_OK; | ||
238 | } | ||
239 | |||
240 | #endif /* MACOSX */ | ||