-
Notifications
You must be signed in to change notification settings - Fork 0
/
view.c
44 lines (30 loc) · 825 Bytes
/
view.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
#include "view.h"
void erro(int codigoErro){
switch ( codigoErro ){
case 1: printf("Erro ao criar a tabela Chat");
break;
case 2: printf("Falha de conexao\n");
break;
case 3: printf("Erro ao enviar a mensagem");
break;
default: printf("Codigo Invalido.");
break;
}
}
void info(int codigoInfo){
switch ( codigoInfo ){
case 1: printf("Tabela Chat Criada ou ja Existe");
break;
case 2: printf("\nConexao ao banco realizada com sucesso!\n");
break;
case 3: printf("\nMensagem enviada com sucesso");
break;
default: erro(-1);
break;
}
}
void vMenuInicial(){
printf("1 - Criar uma Sala\n");
printf("2 - Mostrar Salas\n");
printf("3 - Conectar a uma Sala\n");
}