| OLD | NEW |
| 1 /* | 1 /* |
| 2 IMPORTANT: This Apple software is supplied to you by Apple Computer, Inc. ("Ap
ple") in | 2 IMPORTANT: This Apple software is supplied to you by Apple Computer, Inc. ("Ap
ple") in |
| 3 consideration of your agreement to the following terms, and your use, installat
ion, | 3 consideration of your agreement to the following terms, and your use, installat
ion, |
| 4 modification or redistribution of this Apple software constitutes acceptance of
these | 4 modification or redistribution of this Apple software constitutes acceptance of
these |
| 5 terms. If you do not agree with these terms, please do not use, install, modif
y or | 5 terms. If you do not agree with these terms, please do not use, install, modif
y or |
| 6 redistribute this Apple software. | 6 redistribute this Apple software. |
| 7 | 7 |
| 8 In consideration of your agreement to abide by the following terms, and subject
to these | 8 In consideration of your agreement to abide by the following terms, and subject
to these |
| 9 terms, Apple grants you a personal, non-exclusive license, under Apple's copyri
ghts in | 9 terms, Apple grants you a personal, non-exclusive license, under Apple's copyri
ghts in |
| 10 this original Apple software (the "Apple Software"), to use, reproduce, modify
and | 10 this original Apple software (the "Apple Software"), to use, reproduce, modify
and |
| (...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 101 | 101 |
| 102 // For compatibility with CFM browsers. | 102 // For compatibility with CFM browsers. |
| 103 int main(NPNetscapeFuncs *browserFuncs, NPPluginFuncs *pluginFuncs, NPP_Shutdown
ProcPtr *shutdown) | 103 int main(NPNetscapeFuncs *browserFuncs, NPPluginFuncs *pluginFuncs, NPP_Shutdown
ProcPtr *shutdown) |
| 104 { | 104 { |
| 105 browser = malloc(sizeof(NPNetscapeFuncs)); | 105 browser = malloc(sizeof(NPNetscapeFuncs)); |
| 106 bzero(browser, sizeof(NPNetscapeFuncs)); | 106 bzero(browser, sizeof(NPNetscapeFuncs)); |
| 107 | 107 |
| 108 browser->size = browserFuncs->size; | 108 browser->size = browserFuncs->size; |
| 109 browser->version = browserFuncs->version; | 109 browser->version = browserFuncs->version; |
| 110 | 110 |
| 111 // Since this is a mach-o plug-in and the browser is CFM because it is calli
ng main, translate | 111 // Since this is a mach-o plugin and the browser is CFM because it is callin
g main, translate |
| 112 // our function points into TVectors so the browser can call them. | 112 // our function points into TVectors so the browser can call them. |
| 113 browser->geturl = (NPN_GetURLProcPtr)functionPointerForTVector((TransitionVe
ctor)browserFuncs->geturl); | 113 browser->geturl = (NPN_GetURLProcPtr)functionPointerForTVector((TransitionVe
ctor)browserFuncs->geturl); |
| 114 browser->posturl = (NPN_PostURLProcPtr)functionPointerForTVector((Transition
Vector)browserFuncs->posturl); | 114 browser->posturl = (NPN_PostURLProcPtr)functionPointerForTVector((Transition
Vector)browserFuncs->posturl); |
| 115 browser->requestread = (NPN_RequestReadProcPtr)functionPointerForTVector((Tr
ansitionVector)browserFuncs->requestread); | 115 browser->requestread = (NPN_RequestReadProcPtr)functionPointerForTVector((Tr
ansitionVector)browserFuncs->requestread); |
| 116 browser->newstream = (NPN_NewStreamProcPtr)functionPointerForTVector((Transi
tionVector)browserFuncs->newstream); | 116 browser->newstream = (NPN_NewStreamProcPtr)functionPointerForTVector((Transi
tionVector)browserFuncs->newstream); |
| 117 browser->write = (NPN_WriteProcPtr)functionPointerForTVector((TransitionVect
or)browserFuncs->write); | 117 browser->write = (NPN_WriteProcPtr)functionPointerForTVector((TransitionVect
or)browserFuncs->write); |
| 118 browser->destroystream = (NPN_DestroyStreamProcPtr)functionPointerForTVector
((TransitionVector)browserFuncs->destroystream); | 118 browser->destroystream = (NPN_DestroyStreamProcPtr)functionPointerForTVector
((TransitionVector)browserFuncs->destroystream); |
| 119 browser->status = (NPN_StatusProcPtr)functionPointerForTVector((TransitionVe
ctor)browserFuncs->status); | 119 browser->status = (NPN_StatusProcPtr)functionPointerForTVector((TransitionVe
ctor)browserFuncs->status); |
| 120 browser->uagent = (NPN_UserAgentProcPtr)functionPointerForTVector((Transitio
nVector)browserFuncs->uagent); | 120 browser->uagent = (NPN_UserAgentProcPtr)functionPointerForTVector((Transitio
nVector)browserFuncs->uagent); |
| 121 browser->memalloc = (NPN_MemAllocProcPtr)functionPointerForTVector((Transiti
onVector)browserFuncs->memalloc); | 121 browser->memalloc = (NPN_MemAllocProcPtr)functionPointerForTVector((Transiti
onVector)browserFuncs->memalloc); |
| (...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 256 FunctionPointer *newGlue = NULL; | 256 FunctionPointer *newGlue = NULL; |
| 257 if (fp != NULL) { | 257 if (fp != NULL) { |
| 258 newGlue = (FunctionPointer *)malloc(2 * sizeof(FunctionPointer)); | 258 newGlue = (FunctionPointer *)malloc(2 * sizeof(FunctionPointer)); |
| 259 if (newGlue != NULL) { | 259 if (newGlue != NULL) { |
| 260 newGlue[0] = fp; | 260 newGlue[0] = fp; |
| 261 newGlue[1] = NULL; | 261 newGlue[1] = NULL; |
| 262 } | 262 } |
| 263 } | 263 } |
| 264 return (TransitionVector)newGlue; | 264 return (TransitionVector)newGlue; |
| 265 } | 265 } |
| OLD | NEW |