Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
5674e4ec
Commit
5674e4ec
authored
Aug 01, 1996
by
Jack Jansen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
NumVersion stuff has changed
parent
d1f06313
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
47 deletions
+8
-47
Mac/Modules/snd/Sndmodule.c
Mac/Modules/snd/Sndmodule.c
+8
-28
Mac/Modules/snd/sndsupport.py
Mac/Modules/snd/sndsupport.py
+0
-19
No files found.
Mac/Modules/snd/Sndmodule.c
View file @
5674e4ec
...
...
@@ -40,9 +40,6 @@ extern int GrafObj_Convert(PyObject *, GrafPtr *);
extern
PyObject
*
BMObj_New
(
BitMapPtr
);
extern
int
BMObj_Convert
(
PyObject
*
,
BitMapPtr
*
);
extern
PyObject
*
PMObj_New
(
PixMapHandle
);
extern
int
PMObj_Convert
(
PyObject
*
,
PixMapHandle
*
);
extern
PyObject
*
WinObj_WhichWindow
(
WindowPtr
);
#include <Sound.h>
...
...
@@ -78,23 +75,6 @@ SndCmd_Convert(PyObject *v, SndCommand *pc)
return
PyArg_Parse
(
v
,
"h"
,
&
pc
->
cmd
);
}
/* Create a NumVersion object (a quintuple of integers) */
static
PyObject
*
NumVer_New
(
NumVersion
nv
)
{
return
Py_BuildValue
(
"iiiii"
,
nv
.
majorRev
,
#ifdef THINK_C
nv
.
minorRev
,
nv
.
bugFixRev
,
#else
(
nv
.
minorAndBugRev
>>
4
)
&
0xf
,
nv
.
minorAndBugRev
&
0xf
,
#endif
nv
.
stage
,
nv
.
nonRelRev
);
}
static
pascal
void
SndCh_UserRoutine
(
SndChannelPtr
chan
,
SndCommand
*
cmd
);
/* Forward */
static
PyObject
*
Snd_Error
;
...
...
@@ -426,12 +406,12 @@ static PyObject *Snd_SndSoundManagerVersion(_self, _args)
PyObject
*
_args
;
{
PyObject
*
_res
=
NULL
;
long
_rv
;
NumVersion
_rv
;
if
(
!
PyArg_ParseTuple
(
_args
,
""
))
return
NULL
;
_rv
=
SndSoundManagerVersion
();
_res
=
Py_BuildValue
(
"
l
"
,
_rv
);
_res
=
Py_BuildValue
(
"
O&
"
,
PyMac_BuildNumVersion
,
_rv
);
return
_res
;
}
...
...
@@ -491,12 +471,12 @@ static PyObject *Snd_MACEVersion(_self, _args)
PyObject
*
_args
;
{
PyObject
*
_res
=
NULL
;
long
_rv
;
NumVersion
_rv
;
if
(
!
PyArg_ParseTuple
(
_args
,
""
))
return
NULL
;
_rv
=
MACEVersion
();
_res
=
Py_BuildValue
(
"
l
"
,
_rv
);
_res
=
Py_BuildValue
(
"
O&
"
,
PyMac_BuildNumVersion
,
_rv
);
return
_res
;
}
...
...
@@ -771,7 +751,7 @@ static PyMethodDef Snd_methods[] = {
{
"SndControl"
,
(
PyCFunction
)
Snd_SndControl
,
1
,
"(short id) -> (SndCommand cmd)"
},
{
"SndSoundManagerVersion"
,
(
PyCFunction
)
Snd_SndSoundManagerVersion
,
1
,
"() -> (
long
_rv)"
},
"() -> (
NumVersion
_rv)"
},
{
"SndManagerStatus"
,
(
PyCFunction
)
Snd_SndManagerStatus
,
1
,
"(short theLength) -> (SMStatus theStatus)"
},
{
"SndGetSysBeepState"
,
(
PyCFunction
)
Snd_SndGetSysBeepState
,
1
,
...
...
@@ -779,7 +759,7 @@ static PyMethodDef Snd_methods[] = {
{
"SndSetSysBeepState"
,
(
PyCFunction
)
Snd_SndSetSysBeepState
,
1
,
"(short sysBeepState) -> None"
},
{
"MACEVersion"
,
(
PyCFunction
)
Snd_MACEVersion
,
1
,
"() -> (
long
_rv)"
},
"() -> (
NumVersion
_rv)"
},
{
"Comp3to1"
,
(
PyCFunction
)
Snd_Comp3to1
,
1
,
"(Buffer buffer, StateBlock state, unsigned long numChannels, unsigned long whichChannel) -> (Buffer buffer, StateBlock state)"
},
{
"Exp1to3"
,
(
PyCFunction
)
Snd_Exp1to3
,
1
,
...
...
Mac/Modules/snd/sndsupport.py
View file @
5674e4ec
...
...
@@ -79,8 +79,6 @@ SndCallBackUPP = SndCallBackProcPtr
SndCompletionProcPtr
=
FakeType
(
'(SndCompletionProcPtr)0'
)
# XXX
SndCompletionUPP
=
SndCompletionProcPtr
NumVersion
=
OpaqueByValueType
(
'NumVersion'
,
'NumVer'
)
##InOutBuf128 = FixedInputOutputBufferType(128)
StateBlock
=
StructInputOutputBufferType
(
'StateBlock'
)
...
...
@@ -119,23 +117,6 @@ SndCmd_Convert(PyObject *v, SndCommand *pc)
return PyArg_Parse(v, "h", &pc->cmd);
}
/* Create a NumVersion object (a quintuple of integers) */
static PyObject *
NumVer_New(NumVersion nv)
{
return Py_BuildValue("iiiii",
nv.majorRev,
#ifdef THINK_C
nv.minorRev,
nv.bugFixRev,
#else
(nv.minorAndBugRev>>4) & 0xf,
nv.minorAndBugRev & 0xf,
#endif
nv.stage,
nv.nonRelRev);
}
static pascal void SndCh_UserRoutine(SndChannelPtr chan, SndCommand *cmd); /* Forward */
"""
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment