summaryrefslogtreecommitdiffstats
path: root/Lib/stdwin
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/stdwin')
-rwxr-xr-xLib/stdwin/filewin.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/Lib/stdwin/filewin.py b/Lib/stdwin/filewin.py
index 6a224e7..a03c3f7 100755
--- a/Lib/stdwin/filewin.py
+++ b/Lib/stdwin/filewin.py
@@ -2,17 +2,19 @@
# File windows, a subclass of textwin (which is a subclass of gwin)
import textwin
-from util import readfile
+import builtin
# FILE WINDOW
def open_readonly(fn): # Open a file window
- w = textwin.open_readonly(fn, readfile(fn))
+ fp = builtin.open(fn, 'r')
+ w = textwin.open_readonly(fn, fp.read())
w.fn = fn
return w
def open(fn): # Open a file window
- w = textwin.open(fn, readfile(fn))
+ fp = builtin.open(fn, 'r')
+ w = textwin.open(fn, fp.read())
w.fn = fn
return w