Update of /cvsroot/pythoncard/PythonCard
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10707
Modified Files:
model.py
Removed Files:
fixdc.py
Log Message:
added clean exit code to model.py
removed fixdc.py since wxPython 2.5.2 is the minimum required version
Index: model.py
===================================================================
RCS file: /cvsroot/pythoncard/PythonCard/model.py,v
retrieving revision 1.178
retrieving revision 1.179
diff -C2 -d -r1.178 -r1.179
*** model.py 17 Jul 2004 17:20:10 -0000 1.178
--- model.py 9 Aug 2004 17:22:44 -0000 1.179
***************
*** 6,22 ****
import os, sys
- # some things might work with lesser
- # versions, but this is a reasonable base
- assert sys.version_info >= (2, 3)
- # sys.modules relative path fix
- sys.path[0] = os.path.abspath(sys.path[0])
- #sys.path = [os.path.abspath(p) for p in sys.path]
! import wx
! assert wx.VERSION >= (2, 5)
- # KEA 2004-05-01
- # temporary fix for wxPython 2.5.1.5
- import fixdc
import configuration
--- 6,40 ----
import os, sys
! # KEA 2004-08-09
! # assert some minimum requirements and attempt to exit cleanly
! # if they aren't met
!
! try:
! # some things might work with lesser
! # versions, but this is a reasonable base
! assert sys.version_info >= (2, 3)
! # sys.modules relative path fix
! sys.path[0] = os.path.abspath(sys.path[0])
! #sys.path = [os.path.abspath(p) for p in sys.path]
!
! import wx
! assert wx.VERSION >= (2, 5, 2)
! except:
! from wxPython.wx import wxPySimpleApp, wxFrame, wxMessageDialog, wxICON_EXCLAMATION, wxOK, wxVERSION_STRING
! app = wxPySimpleApp()
! frame = wxFrame(None, -1, "Minimum Requirements Not Met")
! #frame.Show(1)
! message = "PythonCard minimum requirements:\nPython 2.3 and wxPython 2.5.2\n\n" + \
! "You are using Python %s\nand wxPython %s.\n\nClick OK to exit." % (sys.version, wxVERSION_STRING)
! dialog = wxMessageDialog(frame, message,
! "Minimum Requirements Not Met",
! wxICON_EXCLAMATION | wxOK)
! dialog.ShowModal()
! dialog.Destroy()
! #app.MainLoop()
! sys.exit(0)
!
import configuration
--- fixdc.py DELETED ---
|