mirror of
https://github.com/python/cpython.git
synced 2025-09-26 18:29:57 +00:00
IDLE: make filetypes a tuple constant. (#3847)
Save a bit of code, plus non-tuples get converted anyway to tuples by tkinter for the tk call.
This commit is contained in:
parent
2102c78903
commit
5961e7c156
1 changed files with 2 additions and 2 deletions
|
@ -487,11 +487,11 @@ class IOBinding:
|
||||||
opendialog = None
|
opendialog = None
|
||||||
savedialog = None
|
savedialog = None
|
||||||
|
|
||||||
filetypes = [
|
filetypes = (
|
||||||
("Python files", "*.py *.pyw", "TEXT"),
|
("Python files", "*.py *.pyw", "TEXT"),
|
||||||
("Text files", "*.txt", "TEXT"),
|
("Text files", "*.txt", "TEXT"),
|
||||||
("All files", "*"),
|
("All files", "*"),
|
||||||
]
|
)
|
||||||
|
|
||||||
defaultextension = '.py' if sys.platform == 'darwin' else ''
|
defaultextension = '.py' if sys.platform == 'darwin' else ''
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue