src/eric7/Debugger/BreakPointModel.py

branch
eric7
changeset 11046
478b4ce023dd
parent 11037
adfda913834a
child 11066
d71eab9be477
equal deleted inserted replaced
11045:72202235e0bb 11046:478b4ce023dd
286 @param breakpoints list of breakpoints with file name, line number, 286 @param breakpoints list of breakpoints with file name, line number,
287 condition, temporary flag, enabled flag and ignore count each 287 condition, temporary flag, enabled flag and ignore count each
288 @type list of (str, int, str, bool, bool, int) 288 @type list of (str, int, str, bool, bool, int)
289 """ 289 """
290 # eliminate redundant break points 290 # eliminate redundant break points
291 newBreakpoints = [b for b in set(breakpoints) if b not in self.breakpoints] 291 newBreakpoints = []
292 for breakpoint in breakpoints:
293 if breakpoint not in self.breakpoints and breakpoint not in newBreakpoints:
294 newBreakpoints.append(breakpoint)
292 295
293 if newBreakpoints: 296 if newBreakpoints:
294 cnt = len(self.breakpoints) 297 cnt = len(self.breakpoints)
295 self.beginInsertRows(QModelIndex(), cnt, cnt + len(newBreakpoints) - 1) 298 self.beginInsertRows(QModelIndex(), cnt, cnt + len(newBreakpoints) - 1)
296 self.breakpoints += newBreakpoints 299 self.breakpoints += newBreakpoints

eric ide

mercurial