summaryrefslogtreecommitdiff
path: root/src/gui/button.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/button.c')
-rw-r--r--src/gui/button.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/gui/button.c b/src/gui/button.c
index 35ac2ed..1ed5965 100644
--- a/src/gui/button.c
+++ b/src/gui/button.c
@@ -1,12 +1,11 @@
1#include "gui/button.h"
1#include <stdlib.h> 2#include <stdlib.h>
2#include <stdbool.h> 3#include <stdbool.h>
3#include <assert.h> 4#include <assert.h>
4#include <string.h> 5#include <string.h>
5#include "gui/button.h" 6#include <MLV/MLV_all.h>
6#include "MLV/MLV_all.h"
7#include "common/mem.h" 7#include "common/mem.h"
8 8
9
10static bool button_is_selected(int x, int y, Button *button) { 9static bool button_is_selected(int x, int y, Button *button) {
11 assert(button != NULL); 10 assert(button != NULL);
12 int x1 = button->component.x_pos; 11 int x1 = button->component.x_pos;
@@ -104,8 +103,8 @@ Button *button_create(const char *text, int sizeInterligne, int x_pos, int y_pos
104 return button; 103 return button;
105} 104}
106 105
107void button_destroy(Button *button){ 106void button_destroy(Button *button) {
108 assert(button != NULL); 107 assert(button != NULL);
109 free(button->label); 108 free(button->label);
110 free(button); 109 free(button);
111} \ No newline at end of file 110}