diff options
Diffstat (limited to 'include/gui/component.h')
-rw-r--r-- | include/gui/component.h | 21 |
1 files changed, 14 insertions, 7 deletions
diff --git a/include/gui/component.h b/include/gui/component.h index 895e9ba..1a255e2 100644 --- a/include/gui/component.h +++ b/include/gui/component.h | |||
@@ -3,6 +3,7 @@ | |||
3 | 3 | ||
4 | /** | 4 | /** |
5 | * File: component.h | 5 | * File: component.h |
6 | * Components implementation. | ||
6 | * | 7 | * |
7 | * Author: | 8 | * Author: |
8 | * Adam NAILI | 9 | * Adam NAILI |
@@ -24,16 +25,22 @@ typedef enum { | |||
24 | WAITING_BUTTON_SHOW, WAITING_BUTTON_HIDE, INSERT_ORIGIN, INSERT_TARGET, PRINTING, EXITING, PRINTING_BUTTONS, RENDERING | 25 | WAITING_BUTTON_SHOW, WAITING_BUTTON_HIDE, INSERT_ORIGIN, INSERT_TARGET, PRINTING, EXITING, PRINTING_BUTTONS, RENDERING |
25 | } Mode; | 26 | } Mode; |
26 | 27 | ||
28 | /** | ||
29 | * Mode is used for application status rotation. It is shared between our components. In OOP, this could have been a | ||
30 | * static attribute of the class. | ||
31 | **/ | ||
27 | extern Mode mode; | 32 | extern Mode mode; |
28 | extern int frame; | 33 | |
29 | extern char labelFrame[20]; | ||
30 | /** | 34 | /** |
31 | * File: component.h | 35 | * Components have no access to exterior. They can access only to themselves due to the generic implementation. These |
32 | * Windows and components handling. | 36 | * variables are the easiest way to share memory between components. |
33 | * | 37 | * frame and labelFrame is used to frame management and printing this number of frame on one of the button. Button are |
34 | * See also: | 38 | * not designed to have a dynamic label, so this implementation is the fastest without breaking the code or creating |
35 | * The famous OS | 39 | * another type of components. |
36 | */ | 40 | */ |
41 | extern int frame; | ||
42 | extern char labelFrame[20]; | ||
43 | |||
37 | struct Component; | 44 | struct Component; |
38 | 45 | ||
39 | /** | 46 | /** |