def get_translated_storefile(store, pootle_path=None):
 storeclass = store.syncer.file_class
 filestore = store.syncer.convert(storeclass)
 for unit in filestore.units:
  if (not unit.istranslated()):
   unit.target = ('Translation of %s' % unit.source)
 path = (pootle_path if (pootle_path is not None) else store.pootle_path)
 filestore.updateheader(add=True, X_Pootle_Path=path)
 filestore.updateheader(add=True, X_Pootle_Revision=store.get_max_unit_revision())
 return filestore

def get_translated_storefile ( store , pootle_path = None ) : storeclass = store . syncer . file_class filestore = store . syncer . convert ( storeclass ) for unit in filestore . units : if ( not unit . istranslated ( ) ) : unit . target = ( 'Translation of %s' % unit . source ) path = ( pootle_path if ( pootle_path is not None ) else store . pootle_path ) filestore . updateheader ( add = True , X_Pootle_Path = path ) filestore . updateheader ( add = True , X_Pootle_Revision = store . get_max_unit_revision ( ) ) return filestore
returns file store with added translations for untranslated units .