Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added utilities to the base gui's API
- Loading branch information
Showing
7 changed files
with
90 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
|
||
class aMSNDialogWindow(object): | ||
""" | ||
This Interface represent a dialog window, used to ask the user | ||
about something to do. | ||
""" | ||
def __init__(self, message, actions): | ||
""" | ||
@type message: str | ||
@type actions: tuple | ||
@param actions: A tuple containing the options between | ||
which the user can choose. Every option is a tuple itself, of the form (name, callback), | ||
where callback is the function that will be called if the option is selected. | ||
This will eventually call the related show() method, so the window is | ||
displayed when created. | ||
""" | ||
raise NotImplementedError | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
|
||
class aMSNDPChooser(object): | ||
""" | ||
This Interface represent a window used to choose a display picture, | ||
should show a list of default dps and the possibility to catch a picture from a webcam. | ||
""" | ||
def __init__(self, default_dps, actions): | ||
""" | ||
@type default_dps: tuple | ||
@params default_dps: a tuple containing strings representing the paths of the default dps. | ||
@type actions: tuple | ||
@param actions: A tuple containing the options between | ||
which the user can choose. Every option is a tuple itself, of the form (name, callback), | ||
where callback is the function that will be called if the option is selected. | ||
This will eventually call the related show() method, so the window is | ||
displayed when created. | ||
""" | ||
raise NotImplementedError |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
|
||
class aMSNErrorWindow(object): | ||
""" This Interface represent an error window """ | ||
def __init__(self, error_text): | ||
""" | ||
@type error_text: str | ||
This will eventually call the related show() method, so the window is | ||
displayed when created. | ||
""" | ||
raise NotImplementedError | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
|
||
class aMSNFileChooserWindow(object): | ||
""" | ||
This Interface represent a window used to choose a file, | ||
which could be an image for the dp, a file to send, a theme file, etc. | ||
""" | ||
def __init__(self, filter, directory): | ||
""" | ||
@type filter: tuple | ||
@param filter: A tuple containing strings, that will represent the file | ||
formats to filter. | ||
@type directory: str | ||
@param directory: The path to start from. | ||
This will eventually call the related show() method, so the window is | ||
displayed when created. | ||
""" | ||
raise NotImplementedError | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
|
||
class aMSNNotificationWindow(object): | ||
""" | ||
This Interface represent a window used to display a notification message, | ||
generally when an operation has finished succesfully. | ||
""" | ||
def __init__(self, notification_text): | ||
""" | ||
@type notification_text: str | ||
This will eventually call the related show() method, so the window is | ||
displayed when created. | ||
""" | ||
raise NotImplementedError | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters