Changeset 1482

Show
Ignore:
Timestamp:
07/10/08 18:14:41 (2 months ago)
Author:
rob
Message:

Changed expandCommandLine to use relative path name
* changed getCommandLine to use buffer.getFilename instead of directly accessing the buffer.url

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/peppy/major.py

    r1481 r1482  
    997997            retval=dlg.ShowModal() 
    998998            return 
    999         script = str(self.buffer.url.path) 
     999        script = self.buffer.getFilename() 
    10001000        if bangpath: 
    10011001            if wx.Platform == '__WXMSW__': 
     
    10771077    def expandCommandLine(self, cmd): 
    10781078        """Expand the command line to include the filename of the buffer""" 
     1079        filename = self.buffer.url.path.get_name() 
    10791080        if '%' in cmd: 
    1080             cmd = cmd % self.buffer.getFilename() 
     1081            cmd = cmd % filename 
    10811082        else: 
    1082             cmd = "%s %s" % (cmd, self.buffer.getFilename()) 
     1083            cmd = "%s %s" % (cmd, filename) 
    10831084        return cmd 
    10841085