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
6b7a5ae2
Kaydet (Commit)
6b7a5ae2
authored
Nis 03, 2013
tarafından
Roger Serwy
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
#14254: IDLE now handles readline correctly across shell restarts.
üst
0d28a61d
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
2 deletions
+14
-2
PyShell.py
Lib/idlelib/PyShell.py
+12
-2
NEWS
Misc/NEWS
+2
-0
No files found.
Lib/idlelib/PyShell.py
Dosyayı görüntüle @
6b7a5ae2
...
@@ -458,6 +458,7 @@ class ModifiedInterpreter(InteractiveInterpreter):
...
@@ -458,6 +458,7 @@ class ModifiedInterpreter(InteractiveInterpreter):
self
.
display_no_subprocess_error
()
self
.
display_no_subprocess_error
()
return
None
return
None
self
.
transfer_path
(
with_cwd
=
with_cwd
)
self
.
transfer_path
(
with_cwd
=
with_cwd
)
console
.
stop_readline
()
# annotate restart in shell window and mark it
# annotate restart in shell window and mark it
console
.
text
.
delete
(
"iomark"
,
"end-1c"
)
console
.
text
.
delete
(
"iomark"
,
"end-1c"
)
if
was_executing
:
if
was_executing
:
...
@@ -896,6 +897,7 @@ class PyShell(OutputWindow):
...
@@ -896,6 +897,7 @@ class PyShell(OutputWindow):
canceled
=
False
canceled
=
False
endoffile
=
False
endoffile
=
False
closing
=
False
closing
=
False
_stop_readline_flag
=
False
def
set_warning_stream
(
self
,
stream
):
def
set_warning_stream
(
self
,
stream
):
global
warning_stream
global
warning_stream
...
@@ -971,8 +973,7 @@ class PyShell(OutputWindow):
...
@@ -971,8 +973,7 @@ class PyShell(OutputWindow):
parent
=
self
.
text
)
parent
=
self
.
text
)
if
response
is
False
:
if
response
is
False
:
return
"cancel"
return
"cancel"
if
self
.
reading
:
self
.
stop_readline
()
self
.
top
.
quit
()
self
.
canceled
=
True
self
.
canceled
=
True
self
.
closing
=
True
self
.
closing
=
True
# Wait for poll_subprocess() rescheduling to stop
# Wait for poll_subprocess() rescheduling to stop
...
@@ -1027,6 +1028,12 @@ class PyShell(OutputWindow):
...
@@ -1027,6 +1028,12 @@ class PyShell(OutputWindow):
tkinter
.
_default_root
=
None
# 03Jan04 KBK What's this?
tkinter
.
_default_root
=
None
# 03Jan04 KBK What's this?
return
True
return
True
def
stop_readline
(
self
):
if
not
self
.
reading
:
# no nested mainloop to exit.
return
self
.
_stop_readline_flag
=
True
self
.
top
.
quit
()
def
readline
(
self
):
def
readline
(
self
):
save
=
self
.
reading
save
=
self
.
reading
try
:
try
:
...
@@ -1034,6 +1041,9 @@ class PyShell(OutputWindow):
...
@@ -1034,6 +1041,9 @@ class PyShell(OutputWindow):
self
.
top
.
mainloop
()
# nested mainloop()
self
.
top
.
mainloop
()
# nested mainloop()
finally
:
finally
:
self
.
reading
=
save
self
.
reading
=
save
if
self
.
_stop_readline_flag
:
self
.
_stop_readline_flag
=
False
return
""
line
=
self
.
text
.
get
(
"iomark"
,
"end-1c"
)
line
=
self
.
text
.
get
(
"iomark"
,
"end-1c"
)
if
len
(
line
)
==
0
:
# may be EOF if we quit our mainloop with Ctrl-C
if
len
(
line
)
==
0
:
# may be EOF if we quit our mainloop with Ctrl-C
line
=
"
\n
"
line
=
"
\n
"
...
...
Misc/NEWS
Dosyayı görüntüle @
6b7a5ae2
...
@@ -19,6 +19,8 @@ Core and Builtins
...
@@ -19,6 +19,8 @@ Core and Builtins
Library
Library
-------
-------
-
Issue
#
14254
:
IDLE
now
handles
readline
correctly
across
shell
restarts
.
-
Issue
#
17614
:
IDLE
no
longer
raises
exception
when
quickly
closing
a
file
.
-
Issue
#
17614
:
IDLE
no
longer
raises
exception
when
quickly
closing
a
file
.
-
Issue
#
6698
:
IDLE
now
opens
just
an
editor
window
when
configured
to
do
so
.
-
Issue
#
6698
:
IDLE
now
opens
just
an
editor
window
when
configured
to
do
so
.
...
...
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