~pythonregexp2.7/python/issue2636-12

« back to all changes in this revision

Viewing changes to Mac/Modules/win/_Winmodule.c

  • Committer: Jeffrey C. "The TimeHorse" Jacobs
  • Date: 2008-06-09 14:52:42 UTC
  • mfrom: (39033.1.3 Regexp-2.6)
  • Revision ID: darklord@timehorse.com-20080609145242-9m268zc6u87rp1vp
Merged in changes from the core Regexp branch.

Show diffs side-by-side

added added

removed removed

Lines of Context:
3
3
 
4
4
#include "Python.h"
5
5
 
6
 
 
 
6
#ifndef __LP64__
7
7
 
8
8
#include "pymactoolbox.h"
9
9
 
3147
3147
                             WinObj_WhichWindow, theWindow);
3148
3148
        return _res;
3149
3149
}
 
3150
#endif /* __LP64__ */
3150
3151
 
3151
3152
static PyMethodDef Win_methods[] = {
 
3153
#ifndef __LP64__
3152
3154
        {"GetNewCWindow", (PyCFunction)Win_GetNewCWindow, 1,
3153
3155
         PyDoc_STR("(short windowID, WindowPtr behind) -> (WindowPtr _rv)")},
3154
3156
        {"NewWindow", (PyCFunction)Win_NewWindow, 1,
3200
3202
        {"FindWindow", (PyCFunction)Win_FindWindow, 1,
3201
3203
         PyDoc_STR("(Point thePoint) -> (short _rv, WindowPtr theWindow)")},
3202
3204
        {NULL, NULL, 0}
 
3205
#endif /* __LP64__ */
3203
3206
};
3204
3207
 
3205
3208
 
3206
3209
 
 
3210
#ifndef __LP64__
3207
3211
/* Return the object corresponding to the window, or NULL */
3208
3212
 
3209
3213
PyObject *
3226
3230
        return it;
3227
3231
}
3228
3232
 
 
3233
#endif /* __LP64__ */
3229
3234
 
3230
3235
void init_Win(void)
3231
3236
{
3232
3237
        PyObject *m;
 
3238
#ifndef __LP64__
3233
3239
        PyObject *d;
3234
3240
 
3235
 
 
3236
 
 
3237
 
                PyMac_INIT_TOOLBOX_OBJECT_NEW(WindowPtr, WinObj_New);
3238
 
                PyMac_INIT_TOOLBOX_OBJECT_NEW(WindowPtr, WinObj_WhichWindow);
3239
 
                PyMac_INIT_TOOLBOX_OBJECT_CONVERT(WindowPtr, WinObj_Convert);
3240
 
 
 
3241
        PyMac_INIT_TOOLBOX_OBJECT_NEW(WindowPtr, WinObj_New);
 
3242
        PyMac_INIT_TOOLBOX_OBJECT_NEW(WindowPtr, WinObj_WhichWindow);
 
3243
        PyMac_INIT_TOOLBOX_OBJECT_CONVERT(WindowPtr, WinObj_Convert);
 
3244
 
 
3245
#endif /* __LP64__ */
3241
3246
 
3242
3247
        m = Py_InitModule("_Win", Win_methods);
 
3248
#ifndef __LP64__
3243
3249
        d = PyModule_GetDict(m);
3244
3250
        Win_Error = PyMac_GetOSErrException();
3245
3251
        if (Win_Error == NULL ||
3252
3258
        /* Backward-compatible name */
3253
3259
        Py_INCREF(&Window_Type);
3254
3260
        PyModule_AddObject(m, "WindowType", (PyObject *)&Window_Type);
 
3261
#endif /* __LP64__ */
3255
3262
}
3256
3263
 
3257
3264
/* ======================== End module _Win ========================= */