2013-06-23 01:32:48 +00:00
|
|
|
ownerclass = 'HSErrorReportWindow'
|
|
|
|
ownerimport = 'HSErrorReportWindow.h'
|
|
|
|
|
2014-03-30 14:07:01 +00:00
|
|
|
result = Window(524, 470, "Error Report")
|
2013-06-23 01:32:48 +00:00
|
|
|
result.canClose = False
|
|
|
|
result.canResize = False
|
|
|
|
result.canMinimize = False
|
2014-03-30 14:07:01 +00:00
|
|
|
label1 = Label(result, "Something went wrong. How about reporting the error?")
|
2013-06-23 01:32:48 +00:00
|
|
|
errorTextView = TextView(result)
|
2014-03-30 14:07:01 +00:00
|
|
|
label2 = Label(result,
|
|
|
|
"Error reports should be reported as Github issues. You can copy the error traceback "
|
|
|
|
"above and paste it in a new issue (bonus point if you run a search to make sure the "
|
|
|
|
"issue doesn't already exist). What usually really helps is if you add a description "
|
|
|
|
"of how you got the error. Thanks!"
|
|
|
|
"\n\n"
|
|
|
|
"Although the application should continue to run after this error, it may be in an "
|
|
|
|
"unstable state, so it is recommended that you restart the application."
|
|
|
|
)
|
|
|
|
sendButton = Button(result, "Go to Github")
|
|
|
|
dontSendButton = Button(result, "Close")
|
2013-06-23 01:32:48 +00:00
|
|
|
|
|
|
|
owner.contentTextView = errorTextView
|
2014-03-30 14:07:01 +00:00
|
|
|
sendButton.action = Action(owner, 'goToGithub')
|
2013-06-23 01:32:48 +00:00
|
|
|
sendButton.keyEquivalent = "\\r"
|
2014-03-30 14:07:01 +00:00
|
|
|
dontSendButton.action = Action(owner, 'close')
|
2013-06-23 01:32:48 +00:00
|
|
|
dontSendButton.keyEquivalent = "\\E"
|
|
|
|
|
|
|
|
label1.height = 34
|
|
|
|
errorTextView.height = 221
|
2014-03-30 14:07:01 +00:00
|
|
|
label2.height = 130
|
2013-06-23 01:32:48 +00:00
|
|
|
sendButton.width = 100
|
|
|
|
dontSendButton.width = 100
|
|
|
|
|
2014-03-30 14:07:01 +00:00
|
|
|
label1.moveTo(Pack.UpperLeft)
|
2013-06-23 01:32:48 +00:00
|
|
|
label1.fill(Pack.Right)
|
2014-03-30 14:07:01 +00:00
|
|
|
errorTextView.moveNextTo(label1, Pack.Below, Pack.Left)
|
2013-06-23 01:32:48 +00:00
|
|
|
errorTextView.fill(Pack.Right)
|
2014-03-30 14:07:01 +00:00
|
|
|
label2.moveNextTo(errorTextView, Pack.Below, Pack.Left)
|
2013-06-23 01:32:48 +00:00
|
|
|
label2.fill(Pack.Right)
|
2014-03-30 14:07:01 +00:00
|
|
|
sendButton.moveNextTo(label2, Pack.Below, Pack.Right)
|
|
|
|
dontSendButton.moveNextTo(sendButton, Pack.Left, Pack.Middle)
|