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
476736ee
Commit
476736ee
authored
May 09, 2003
by
Just van Rossum
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
more dead code removal
parent
5ef0e7cc
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
32 deletions
+2
-32
Mac/Tools/IDE/PyEdit.py
Mac/Tools/IDE/PyEdit.py
+2
-32
No files found.
Mac/Tools/IDE/PyEdit.py
View file @
476736ee
...
...
@@ -108,8 +108,6 @@ class Editor(W.Window):
self
.
run_as_main
=
self
.
settings
.
get
(
"run_as_main"
,
0
)
self
.
run_with_interpreter
=
self
.
settings
.
get
(
"run_with_interpreter"
,
0
)
self
.
run_with_cl_interpreter
=
self
.
settings
.
get
(
"run_with_cl_interpreter"
,
0
)
self
.
_threadstate
=
(
0
,
0
)
self
.
_thread
=
None
def
readwindowsettings
(
self
):
try
:
...
...
@@ -506,15 +504,7 @@ class Editor(W.Window):
self
.
runselbutton
.
push
()
def
run
(
self
):
if
self
.
_threadstate
==
(
0
,
0
):
self
.
_run
()
else
:
lock
=
Wthreading
.
Lock
()
lock
.
acquire
()
self
.
_thread
.
postException
(
KeyboardInterrupt
)
if
self
.
_thread
.
isBlocked
():
self
.
_thread
.
start
()
lock
.
release
()
self
.
_run
()
def
_run
(
self
):
if
self
.
run_with_interpreter
:
...
...
@@ -565,14 +555,7 @@ class Editor(W.Window):
t
.
do_script
(
with_command
=
cmd
)
def
runselection
(
self
):
if
self
.
_threadstate
==
(
0
,
0
):
self
.
_runselection
()
elif
self
.
_threadstate
==
(
1
,
1
):
self
.
_thread
.
block
()
self
.
setthreadstate
((
1
,
2
))
elif
self
.
_threadstate
==
(
1
,
2
):
self
.
_thread
.
start
()
self
.
setthreadstate
((
1
,
1
))
self
.
_runselection
()
def
_runselection
(
self
):
if
self
.
run_with_interpreter
or
self
.
run_with_cl_interpreter
:
...
...
@@ -625,19 +608,6 @@ class Editor(W.Window):
klass
.
__dict__
.
update
(
globals
[
classname
].
__dict__
)
globals
[
classname
]
=
klass
def
setthreadstate
(
self
,
state
):
oldstate
=
self
.
_threadstate
if
oldstate
[
0
]
<>
state
[
0
]:
self
.
runbutton
.
settitle
(
runButtonLabels
[
state
[
0
]])
if
oldstate
[
1
]
<>
state
[
1
]:
self
.
runselbutton
.
settitle
(
runSelButtonLabels
[
state
[
1
]])
self
.
_threadstate
=
state
def
_exec_threadwrapper
(
self
,
*
args
,
**
kwargs
):
apply
(
execstring
,
args
,
kwargs
)
self
.
setthreadstate
((
0
,
0
))
self
.
_thread
=
None
def
execstring
(
self
,
pytext
,
globals
,
locals
,
file
,
modname
):
tracebackwindow
.
hide
()
# update windows
...
...
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