src/eric7/Debugger/DebugUI.py

branch
eric7
changeset 10928
46651e194fbe
parent 10806
2f6df822e3b9
child 10988
729202700a5a
equal deleted inserted replaced
10927:ce599998be7d 10928:46651e194fbe
1337 if not quiet: 1337 if not quiet:
1338 if not program: 1338 if not program:
1339 program = self.ui.currentProg 1339 program = self.ui.currentProg
1340 1340
1341 if message: 1341 if message:
1342 info = self.tr("Message: {0}").format(Utilities.html_uencode(message)) 1342 info = self.tr("Message: {0}").format(
1343 EricUtilities.html_uencode(message)
1344 )
1343 else: 1345 else:
1344 info = "" 1346 info = ""
1345 if program is None: 1347 if program is None:
1346 msg = self.tr( 1348 msg = self.tr(
1347 "<p>The program has terminated with an exit status of" 1349 "<p>The program has terminated with an exit status of"
1496 ' <b>{0}</b><br>"<b>{1}</b>"<br>' 1498 ' <b>{0}</b><br>"<b>{1}</b>"<br>'
1497 "File: <b>{2}</b>, Line: <b>{3}</b></p>" 1499 "File: <b>{2}</b>, Line: <b>{3}</b></p>"
1498 "<p>Break here?</p>" 1500 "<p>Break here?</p>"
1499 ).format( 1501 ).format(
1500 exceptionType, 1502 exceptionType,
1501 Utilities.html_encode(exceptionMessage), 1503 EricUtilities.html_encode(exceptionMessage),
1502 stackTrace[0][0], 1504 stackTrace[0][0],
1503 stackTrace[0][1], 1505 stackTrace[0][1],
1504 ), 1506 ),
1505 buttons, 1507 buttons,
1506 EricMessageBox.No, 1508 EricMessageBox.No,
1511 Program, 1513 Program,
1512 self.tr( 1514 self.tr(
1513 "<p>The debugged program raised the exception" 1515 "<p>The debugged program raised the exception"
1514 ' <b>{0}</b><br>"<b>{1}</b>"</p>' 1516 ' <b>{0}</b><br>"<b>{1}</b>"</p>'
1515 ).format( 1517 ).format(
1516 exceptionType, Utilities.html_encode(exceptionMessage) 1518 exceptionType,
1519 EricUtilities.html_encode(exceptionMessage),
1517 ), 1520 ),
1518 ) 1521 )
1519 if res == EricMessageBox.Yes: 1522 if res == EricMessageBox.Yes:
1520 self.debugServer.setDebugging(True) 1523 self.debugServer.setDebugging(True)
1521 self.exceptionInterrupt.emit() 1524 self.exceptionInterrupt.emit()
1781 if duplicate: 1784 if duplicate:
1782 if not special: 1785 if not special:
1783 msg = self.tr( 1786 msg = self.tr(
1784 """<p>A watch expression '<b>{0}</b>'""" 1787 """<p>A watch expression '<b>{0}</b>'"""
1785 """ already exists.</p>""" 1788 """ already exists.</p>"""
1786 ).format(Utilities.html_encode(cond)) 1789 ).format(EricUtilities.html_encode(cond))
1787 else: 1790 else:
1788 msg = self.tr( 1791 msg = self.tr(
1789 """<p>A watch expression '<b>{0}</b>'""" 1792 """<p>A watch expression '<b>{0}</b>'"""
1790 """ for the variable <b>{1}</b> already""" 1793 """ for the variable <b>{1}</b> already"""
1791 """ exists.</p>""" 1794 """ exists.</p>"""
1792 ).format(special, Utilities.html_encode(cond)) 1795 ).format(special, EricUtilities.html_encode(cond))
1793 EricMessageBox.warning( 1796 EricMessageBox.warning(
1794 self.ui, self.tr("Watch expression already exists"), msg 1797 self.ui, self.tr("Watch expression already exists"), msg
1795 ) 1798 )
1796 model.deleteWatchPointByIndex(index) 1799 model.deleteWatchPointByIndex(index)
1797 else: 1800 else:

eric ide

mercurial