src/eric7/Tasks/TaskViewer.py

branch
eric7
changeset 9517
d73c3a1e432b
parent 9514
2b104ad132a4
child 9653
e67609152c5e
equal deleted inserted replaced
9516:0f023e61a9b5 9517:d73c3a1e432b
445 """ 445 """
446 self.addTask( 446 self.addTask(
447 summary, 447 summary,
448 filename=filename, 448 filename=filename,
449 lineno=lineno, 449 lineno=lineno,
450 isProjectTask=(self.project and self.project.isProjectSource(filename)), 450 isProjectTask=(
451 self.project and self.project.isProjectCategory(filename, "SOURCES")
452 ),
451 taskType=TaskType(taskType), 453 taskType=TaskType(taskType),
452 description=description, 454 description=description,
453 ) 455 )
454 456
455 def getProjectTasks(self): 457 def getProjectTasks(self):
507 @param filename name of the file (string) 509 @param filename name of the file (string)
508 @param conditionally flag indicating to clear the tasks of the file 510 @param conditionally flag indicating to clear the tasks of the file
509 checking some conditions (boolean) 511 checking some conditions (boolean)
510 """ 512 """
511 if conditionally: 513 if conditionally:
512 if self.project and self.project.isProjectSource(filename): 514 if self.project and self.project.isProjectCategory(filename, "SOURCES"):
513 # project related tasks will not be cleared 515 # project related tasks will not be cleared
514 return 516 return
515 if not Preferences.getTasks("ClearOnFileClose"): 517 if not Preferences.getTasks("ClearOnFileClose"):
516 return 518 return
517 for task in self.tasks[:]: 519 for task in self.tasks[:]:

eric ide

mercurial