2019-01-26 10:40:51 +01:00
|
|
|
from PyQt5.QtWidgets import QMessageBox
|
|
|
|
|
|
|
|
|
2019-01-19 16:24:18 +01:00
|
|
|
class BorgException(Exception):
|
|
|
|
pass
|
2019-01-26 10:40:51 +01:00
|
|
|
|
|
|
|
|
|
|
|
def show_error(e):
|
2019-01-27 14:49:31 +01:00
|
|
|
"""Helper function to show an error dialog."""
|
2019-01-26 10:40:51 +01:00
|
|
|
message = QMessageBox()
|
|
|
|
message.setIcon(QMessageBox.Warning)
|
|
|
|
message.setText("Error")
|
|
|
|
message.setWindowTitle("Borg-Qt Error")
|
|
|
|
message.setInformativeText(e.args[0])
|
|
|
|
message.exec_()
|