Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
XNAT-Group
XNAT_Query_Client_XSA
Commits
52ab47ba
Commit
52ab47ba
authored
Mar 12, 2015
by
Franziska Koehn
Browse files
docu added to messagedialogs
parent
584d38ab
Changes
1
Hide whitespace changes
Inline
Side-by-side
xsagtk/message_dialogs.py
View file @
52ab47ba
import
gtk
def
create_error_message
(
message
):
"""Creates a message-dialog for errors, which contains a warning-sign and a ok-button
**Parameters**
:message: str: message, that will be displayed
"""
md
=
gtk
.
MessageDialog
(
type
=
gtk
.
MESSAGE_WARNING
,
buttons
=
gtk
.
BUTTONS_OK
,
message_format
=
str
(
message
)
...
...
@@ -9,6 +14,11 @@ def create_error_message(message):
md
.
destroy
()
def
create_confirmation_message
(
message
):
"""Creates a message-dialog with confirmation buttons (yes/no), that contains a warning-sign
**Parameters**
:message: str: message, that will be displayed
"""
md
=
gtk
.
MessageDialog
(
type
=
gtk
.
MESSAGE_WARNING
,
buttons
=
gtk
.
BUTTONS_YES_NO
,
message_format
=
message
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment