Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
e7134aa0
Kaydet (Commit)
e7134aa0
authored
Şub 26, 1995
tarafından
Guido van Rossum
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
return old value of PyMac_DoYieldEnabled; -1 means do not even check for interrupts
üst
83c434b1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
6 deletions
+15
-6
macosmodule.c
Mac/Modules/macosmodule.c
+6
-5
macglue.c
Mac/Python/macglue.c
+9
-1
No files found.
Mac/Modules/macosmodule.c
Dosyayı görüntüle @
e7134aa0
...
...
@@ -197,13 +197,13 @@ MacOS_SetScheduleTimes(PyObject *self, PyObject *args)
static
PyObject
*
MacOS_EnableAppswitch
(
PyObject
*
self
,
PyObject
*
args
)
{
int
enable
;
int
old
,
new
;
if
(
!
PyArg_ParseTuple
(
args
,
"i"
,
&
enable
))
if
(
!
PyArg_ParseTuple
(
args
,
"i"
,
&
new
))
return
NULL
;
PyMac_DoYieldEnabled
=
enable
;
Py
_INCREF
(
Py_None
)
;
return
Py_
None
;
old
=
PyMac_DoYieldEnabled
;
Py
Mac_DoYieldEnabled
=
new
;
return
Py_
BuildValue
(
"i"
,
old
)
;
}
...
...
@@ -246,3 +246,4 @@ MacOS_Init()
if
(
MacOS_Error
==
NULL
||
PyDict_SetItemString
(
d
,
"Error"
,
MacOS_Error
)
!=
0
)
Py_FatalError
(
"can't define MacOS.Error"
);
}
Mac/Python/macglue.c
Dosyayı görüntüle @
e7134aa0
...
...
@@ -115,7 +115,12 @@ static long yield_bg = 12;
static
long
lastyield
;
static
int
in_foreground
;
int
PyMac_DoYieldEnabled
=
1
;
/* Don't do eventloop when false */
/*
** When > 0, do full scanning for events (program is not event aware)
** when == 0, only scan for Command-period
** when < 0, don't do any event scanning
*/
int
PyMac_DoYieldEnabled
=
1
;
/* Convert C to Pascal string. Returns pointer to static buffer. */
unsigned
char
*
...
...
@@ -238,6 +243,8 @@ scan_event_queue(flush)
int
PyOS_InterruptOccurred
()
{
if
(
PyMac_DoYieldEnabled
<
0
)
return
0
;
#ifdef THINK_C
scan_event_queue
(
1
);
#endif
...
...
@@ -882,3 +889,4 @@ PyMac_InitApplication()
}
Py_Main
(
argc
,
argv
);
}
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