Mercurial > public > ostc4
comparison Discovery/Src/tMenu.c @ 507:5e3b830b955f
Added new menu tab into call structure
author | Ideenmodellierer |
---|---|
date | Sun, 30 Aug 2020 17:20:16 +0200 |
parents | 0dbf550dc743 |
children | e221cf762f45 |
comparison
equal
deleted
inserted
replaced
506:998529b3e142 | 507:5e3b830b955f |
---|---|
39 #include "tMenuEditHardware.h" | 39 #include "tMenuEditHardware.h" |
40 #include "tMenuEditPlanner.h" | 40 #include "tMenuEditPlanner.h" |
41 #include "tMenuEditSetpoint.h" | 41 #include "tMenuEditSetpoint.h" |
42 #include "tMenuEditSystem.h" | 42 #include "tMenuEditSystem.h" |
43 #include "tMenuEditXtra.h" | 43 #include "tMenuEditXtra.h" |
44 #include "tMenuEditCustom.h" | |
44 #include "tMenuGas.h" | 45 #include "tMenuGas.h" |
45 #include "tMenuHardware.h" | 46 #include "tMenuHardware.h" |
46 #include "tMenuPlanner.h" | 47 #include "tMenuPlanner.h" |
47 #include "tMenuSetpoint.h" | 48 #include "tMenuSetpoint.h" |
48 #include "tMenuSystem.h" | 49 #include "tMenuSystem.h" |
49 #include "tMenuXtra.h" | 50 #include "tMenuXtra.h" |
51 #include "tMenuCustom.h" | |
50 | 52 |
51 /* Private types -------------------------------------------------------------*/ | 53 /* Private types -------------------------------------------------------------*/ |
52 #define MAXPAGES 10 | 54 #define MAXPAGES 10 |
53 #define CURSOR_HIGH 25 | 55 #define CURSOR_HIGH 25 |
54 #define TAB_HEADER_HIGH 25 | 56 #define TAB_HEADER_HIGH 25 |
490 tM_add(StMSYS); //now in both modes | 492 tM_add(StMSYS); //now in both modes |
491 if(actual_menu_content == MENU_SURFACE) | 493 if(actual_menu_content == MENU_SURFACE) |
492 { | 494 { |
493 tM_add(StMDECO); | 495 tM_add(StMDECO); |
494 tM_add(StMHARD); | 496 tM_add(StMHARD); |
497 tM_add(StMCustom); | |
495 // tM_add(StMSYS); now in both modes | 498 // tM_add(StMSYS); now in both modes |
496 } | 499 } |
497 else | 500 else |
498 { | 501 { |
499 tM_add(StMXTRA); | 502 tM_add(StMXTRA); |
539 | 542 |
540 id = tMHardware_refresh(0, text, &tabPosition, subtext); | 543 id = tMHardware_refresh(0, text, &tabPosition, subtext); |
541 tM_build_page(id, text, tabPosition, subtext); | 544 tM_build_page(id, text, tabPosition, subtext); |
542 | 545 |
543 id = tMSystem_refresh(0, text, &tabPosition, subtext); | 546 id = tMSystem_refresh(0, text, &tabPosition, subtext); |
547 tM_build_page(id, text, tabPosition, subtext); | |
548 | |
549 id = tMCustom_refresh(0, text, &tabPosition, subtext); | |
544 tM_build_page(id, text, tabPosition, subtext); | 550 tM_build_page(id, text, tabPosition, subtext); |
545 } | 551 } |
546 | 552 |
547 | 553 |
548 void tM_refresh_live_content(void) | 554 void tM_refresh_live_content(void) |
696 tMSystem_refresh(line, text, &tabPosition, subtext); | 702 tMSystem_refresh(line, text, &tabPosition, subtext); |
697 clean_line_actual_page(); | 703 clean_line_actual_page(); |
698 update_content_actual_page(text, tabPosition, subtext); | 704 update_content_actual_page(text, tabPosition, subtext); |
699 } | 705 } |
700 break; | 706 break; |
707 case StMCustom: | |
708 tMCustom_refresh(line, text, &tabPosition, subtext); | |
709 clean_line_actual_page(); | |
710 update_content_actual_page(text, tabPosition, subtext); | |
711 break; | |
701 default: | 712 default: |
702 break; | 713 break; |
703 } | 714 } |
704 } | 715 } |
705 | 716 |
934 openEdit_Hardware(line); | 945 openEdit_Hardware(line); |
935 break; | 946 break; |
936 case StMSYS: | 947 case StMSYS: |
937 openEdit_System(line); | 948 openEdit_System(line); |
938 break; | 949 break; |
950 case StMCustom: | |
951 openEdit_Custom(line); | |
952 break; | |
939 default: | 953 default: |
940 break; | 954 break; |
941 } | 955 } |
942 } | 956 } |
943 | 957 |
1137 "DATA", | 1151 "DATA", |
1138 "DECO", | 1152 "DECO", |
1139 "", | 1153 "", |
1140 "SYS", | 1154 "SYS", |
1141 "", | 1155 "", |
1142 "SIM", | 1156 "", |
1143 "" | 1157 "SIM" |
1144 }; | 1158 }; |
1145 | 1159 |
1146 const _Bool spacing[MAXPAGES+1] = | 1160 const _Bool spacing[MAXPAGES+1] = |
1147 { 0, | 1161 { 0, |
1148 0, // behind OC | 1162 0, // behind OC |
1150 1, // behind SP | 1164 1, // behind SP |
1151 1, // behind DATA | 1165 1, // behind DATA |
1152 0, // behind DECO1 | 1166 0, // behind DECO1 |
1153 1, // behind DECO2 | 1167 1, // behind DECO2 |
1154 0, // behind SYS1 | 1168 0, // behind SYS1 |
1155 1, // behind SYS2 | 1169 0, // behind SYS2 |
1170 1, // behind SYS3 | |
1156 1, // behind SIM | 1171 1, // behind SIM |
1157 0 | 1172 0 |
1158 }; | 1173 }; |
1159 | 1174 |
1160 pBackup = tMscreen.FBStartAdress; | 1175 pBackup = tMscreen.FBStartAdress; |