Overview
Comment: | Implement some mouse-based controls in level strings editor. |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA1: |
0cad5241861e734f5f7486cd5e79bad8 |
User & Date: | user on 2021-09-18 00:23:15 |
Other Links: | manifest | tags |
Context
2021-09-18
| ||
22:37 | Add 'am' editor command to make MRU item by SQL results check-in: 16400482c5 user: user tags: trunk | |
00:23 | Implement some mouse-based controls in level strings editor. check-in: 0cad524186 user: user tags: trunk | |
2021-09-12
| ||
04:37 | Add possibility to adjust replay speed at run time. check-in: 1d89b3ab66 user: user tags: trunk | |
Changes
Modified edit.c from [10af50702a] to [3dcbbc08e2].
︙ | ︙ | |||
1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 | if(!*cp) cp[1]=0; if(!o) memmove(cp+1,cp,(s+sz+1)-cp); *cp=i; if(i==10) r++,c=0; else c++; } break; } goto redraw; case SDL_VIDEOEXPOSE: goto redraw; } } erase: c=0; | > > > > > > > > | 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 | if(!*cp) cp[1]=0; if(!o) memmove(cp+1,cp,(s+sz+1)-cp); *cp=i; if(i==10) r++,c=0; else c++; } break; } goto redraw; case SDL_MOUSEBUTTONDOWN: if(ev.button.button==1 && ev.button.y>=24) { if(c=ev.button.x>>3) c--; i=(ev.button.y-24)>>3; r=0; while(r<63 && r<i && li[r+1]!=0xFFFF) r++; } goto redraw; case SDL_VIDEOEXPOSE: goto redraw; } } erase: c=0; |
︙ | ︙ | |||
1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 | } break; case SDLK_UP: case SDLK_KP_MINUS: n--; break; case SDLK_DOWN: case SDLK_KP_PLUS: n++; break; } if(n<=0) n=0; else if(n>=nlevelstrings) n=nlevelstrings-1; goto redraw; case SDL_VIDEOEXPOSE: goto redraw; case SDL_QUIT: exit(0); return -1; } } | > > > > > > | 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 | } break; case SDLK_UP: case SDLK_KP_MINUS: n--; break; case SDLK_DOWN: case SDLK_KP_PLUS: n++; break; } if(n<=0) n=0; else if(n>=nlevelstrings) n=nlevelstrings-1; goto redraw; case SDL_MOUSEBUTTONDOWN: i=ev.button.y/8-scroll-1; if(i<0 || i>=nlevelstrings) break; n=i; if(ev.button.button==3 && n<nlevelstrings) return n; goto redraw; case SDL_VIDEOEXPOSE: goto redraw; case SDL_QUIT: exit(0); return -1; } } |
︙ | ︙ |