[Bug 532635] Review Request: rurple - A Python Learning Environment
bugzilla at redhat.com
bugzilla at redhat.com
Tue Nov 3 17:47:37 UTC 2009
Please do not reply directly to this email. All additional
comments should be made in the comments box of this bug.
https://bugzilla.redhat.com/show_bug.cgi?id=532635
--- Comment #5 from Paulo Roma Cavalcanti <promac at gmail.com> 2009-11-03 12:47:36 EDT ---
Generally, people want to save in the same directory where the file has been
read from. If I patch to save in /home, it will always save there, even if the
file has been read from a user directory.
I can check if it is the first time, that is, the user has just typed a program
(has not read it from anywhere):
The same thing would have to be done for saving the world.
The file /usr/bin/rur_start.py would have a test like the one below,
which uses a new variable init_dir. What do you think?
def SaveProgramFile(self, dummy):
if self.isRunning:
return
global code
code = self.ProgramEditor.GetText()
no_error, mesg = parser.ParseProgram(code)
if no_error:
wildcard = _("Program files (*.rur)|*.rur| All files (*.*)|*.*")
fname = os.path.basename(self.filename)
if ( self.filename == "" ):
init_dir = os.environ.get('HOME')
else:
init_dir = misc.PRGM_DIR
dlg = wx.FileDialog(self, _("Save new program as"), init_dir,
fname, wildcard, wx.SAVE| wx.CHANGE_DIR )
--
Configure bugmail: https://bugzilla.redhat.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
More information about the Fedora-package-review
mailing list