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
1bbf6ff0
Commit
1bbf6ff0
authored
Jan 29, 2001
by
Jack Jansen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make balloon code dependent on existence of Help module
parent
a3e2dcad
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
3 deletions
+10
-3
Mac/scripts/EditPythonPrefs.py
Mac/scripts/EditPythonPrefs.py
+10
-3
No files found.
Mac/scripts/EditPythonPrefs.py
View file @
1bbf6ff0
...
...
@@ -16,7 +16,10 @@ import sys
import
Res
# For Res.Error
import
pythonprefs
import
EasyDialogs
import
Help
try
:
import
Help
except
ImportError
:
Help
=
None
# resource IDs in our own resources (dialogs, etc)
MESSAGE_ID
=
256
...
...
@@ -76,6 +79,8 @@ def optinteract(options):
SetDialogItemText
(
htext
,
options
[
'type'
])
d
.
SetDialogDefaultItem
(
OD_OK_ITEM
)
d
.
SetDialogCancelItem
(
OD_CANCEL_ITEM
)
if
not
Help
:
d
.
HideDialogItem
(
OD_HELP_ITEM
)
while
1
:
for
name
in
opt_dialog_dict
.
keys
():
num
=
opt_dialog_dict
[
name
]
...
...
@@ -113,7 +118,7 @@ def optinteract(options):
options
[
'keep_console'
]
=
2
;
elif
n
==
OD_KEEPNEVER_ITEM
:
options
[
'keep_console'
]
=
0
;
elif
n
==
OD_HELP_ITEM
:
elif
n
==
OD_HELP_ITEM
and
Help
:
onoff
=
Help
.
HMGetBalloons
()
Help
.
HMSetBalloons
(
not
onoff
)
elif
1
<=
n
<=
len
(
opt_dialog_map
):
...
...
@@ -138,6 +143,8 @@ def interact(options, title):
d
.
SelectDialogItemText
(
TEXT_ITEM
,
0
,
0
)
## d.SetDialogDefaultItem(OK_ITEM)
d
.
SetDialogCancelItem
(
CANCEL_ITEM
)
if
not
Help
:
d
.
HideDialogItem
(
HELP_ITEM
)
d
.
GetDialogWindow
().
ShowWindow
()
d
.
DrawDialog
()
while
1
:
...
...
@@ -152,7 +159,7 @@ def interact(options, title):
fss
,
ok
=
macfs
.
GetDirectory
(
'Select python home folder:'
)
if
ok
:
options
[
'dir'
]
=
fss
elif
n
==
HELP_ITEM
:
elif
n
==
HELP_ITEM
and
Help
:
onoff
=
Help
.
HMGetBalloons
()
Help
.
HMSetBalloons
(
not
onoff
)
if
n
==
OPTIONS_ITEM
:
...
...
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