Ignore:
Timestamp:
07/19/10 12:13:20 (4 years ago)
Author:
xkolman2 <xkolman2@…>
Branches:
master
Children:
d707c31
Parents:
0f17f26
git-author:
xkolman2 <xkolman2@…> (07/19/10 12:13:20)
git-committer:
xkolman2 <xkolman2@…> (07/19/10 12:13:20)
Message:

cathegories for tracklogs can now be set

git-svn-id: https://nlp.fi.muni.cz/svn/gps_navigace/trunk@148 0858a4d0-ffff-46e5-938e-62b5ecb34222

File:
1 edited

Legend:

Unmodified
Added
Removed
  • modules/mod_loadTracklogs.py

    recf53e5 rbdd8b77  
    130130#    return tracklog 
    131131 
     132  def getIndexForPath(self,path): 
     133    """get index for the tracklog with corresponding path 
     134       from the main tracklog lists""" 
     135        
     136    return self.tracklogPathList.index(path) 
     137 
     138 
    132139  def getActiveTracklogPath(self): 
    133140    index = int(self.get('activeTracklog', 0)) 
     
    138145    catData = self.get('tracklogPathCathegory', {}) 
    139146    catData[path] = cathegory 
     147    # update the persistent list 
    140148    self.set('tracklogPathCathegory', catData) 
     149 
     150    index = self.getIndexForPath(path) 
     151    # update the current in memmory list 
     152    self.tracklogList[index]['cat'] = cathegory 
    141153 
    142154  def listAvailableTracklogs(self): 
Note: See TracChangeset for help on using the changeset viewer.