comparison src/gui.c @ 31:9401d767d989

wtf??
author Paper <37962225+mrpapersonic@users.noreply.github.com>
date Fri, 08 Apr 2022 00:07:35 -0400
parents fa7bd08be944
children cc498a5feaaf
comparison
equal deleted inserted replaced
30:fa7bd08be944 31:9401d767d989
35 HWND hWndListBox, hWndComboBox; 35 HWND hWndListBox, hWndComboBox;
36 int16_t version = 13; 36 int16_t version = 13;
37 enum types { 37 enum types {
38 vf, 38 vf,
39 veg 39 veg
40 }; 40 } type;
41 enum types type;
42 char* file_name = " "; 41 char* file_name = " ";
43 42
44 void set_data(unsigned char magic[], uint16_t version, FILE* target) { 43 void set_data(unsigned char magic[], uint16_t version, FILE* target) {
45 int i; 44 int i;
46 fseek(target, 0x46, SEEK_SET); 45 fseek(target, 0x46, SEEK_SET);
214 case WM_COMMAND: 213 case WM_COMMAND:
215 if(HIWORD(wParam) == CBN_SELCHANGE) { 214 if(HIWORD(wParam) == CBN_SELCHANGE) {
216 if (LOWORD(wParam) == COMBOBOX) 215 if (LOWORD(wParam) == COMBOBOX)
217 version = (int16_t)(8+SendMessage((HWND) lParam, (UINT) CB_GETCURSEL, (WPARAM) 0, (LPARAM) 0)); 216 version = (int16_t)(8+SendMessage((HWND) lParam, (UINT) CB_GETCURSEL, (WPARAM) 0, (LPARAM) 0));
218 if (LOWORD(wParam) == LISTBOX) 217 if (LOWORD(wParam) == LISTBOX)
219 type = (types)SendMessage((HWND) lParam, (UINT) LB_GETCURSEL, (WPARAM) 0, (LPARAM) 0); 218 type = (type)SendMessage((HWND) lParam, (UINT) LB_GETCURSEL, (WPARAM) 0, (LPARAM) 0);
220 } 219 }
221 switch(wParam) { 220 switch(wParam) {
222 case OPEN_FILE_BUTTON: 221 case OPEN_FILE_BUTTON:
223 file_name = open_file(hWnd); 222 file_name = open_file(hWnd);
224 break; 223 break;