fix bookmark

This commit is contained in:
chrys
2016-09-24 03:25:46 +02:00
parent 4500ca76aa
commit f9ff3eeed3
3 changed files with 5 additions and 3 deletions

View File

@ -17,7 +17,7 @@ class command():
return 'remove Bookmark ' + self.ID
def run(self):
currApp = self.environment['runtime']['applicationManager'].getCurrentApplication()
currApp = self.env['runtime']['applicationManager'].getCurrentApplication()
del self.env['commandBuffer']['bookMarks'][self.ID][currApp]

View File

@ -21,12 +21,14 @@ class command():
if not self.env['commandBuffer']['Marks']['1']:
self.env['runtime']['outputManager'].presentText("No Mark found", interrupt=True)
return
currApp = self.environment['runtime']['applicationManager'].getCurrentApplication()
currApp = self.env['runtime']['applicationManager'].getCurrentApplication()
self.env['commandBuffer']['bookMarks'][self.ID][currApp] = {}
self.env['commandBuffer']['bookMarks'][self.ID][currApp]['1'] = self.env['commandBuffer']['Marks']['1'].copy()
if self.env['commandBuffer']['Marks']['2']:
self.env['commandBuffer']['bookMarks'][self.ID][currApp]['2'] = self.env['commandBuffer']['Marks']['2'].copy()
else:
self.env['commandBuffer']['bookMarks'][self.ID][currApp]['2'] = None
self.env['runtime']['outputManager'].presentText('Bookmark ' + self.ID + " set for application " + currApp, interrupt=True)
self.env['commandBuffer']['Marks']['1'] = None
self.env['commandBuffer']['Marks']['2'] = None