Skip to content

Commit 4486f71

Browse files
committed
style fixes
1 parent 90940eb commit 4486f71

File tree

7 files changed

+227
-227
lines changed

7 files changed

+227
-227
lines changed

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,4 @@ x16emu.html
1414
x16emu.html.mem
1515
x16emu.js
1616
x16emu.wasm
17-
x16emu.worker.js
17+
x16emu.worker.js

debugger.c

Lines changed: 32 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -509,38 +509,38 @@ static void DEBUGRenderCmdLine(int x, int width, int height) {
509509

510510
static void DEBUGRenderZeroPageRegisters(int y) {
511511
#define LAST_R 15
512-
int reg = 0;
513-
int y_start = y;
514-
char lbl[6];
515-
while (reg < DBGMAX_ZERO_PAGE_REGISTERS) {
516-
if (((y-y_start) % 5) != 0) { // Break registers into groups of 5, easier to locate
517-
if (reg <= LAST_R)
518-
sprintf(lbl, "R%d", reg);
519-
else
520-
sprintf(lbl, "x%d", reg);
521-
522-
DEBUGString(dbgRenderer, DBG_ZP_REG, y, lbl, col_label);
523-
524-
int reg_addr = 2 + reg * 2;
525-
int n = real_read6502(reg_addr+1, true, currentBank)*256+real_read6502(reg_addr, true, currentBank);
526-
527-
DEBUGNumber(DBG_ZP_REG+5, y, n, 4, col_data);
528-
529-
if (oldRegChange[reg] != NULL)
530-
DEBUGString(dbgRenderer, DBG_ZP_REG+9, y, oldRegChange[reg], col_data);
531-
532-
if (oldRegisterTicks != clockticks6502) { // change detection only when the emulated CPU changes
533-
oldRegChange[reg] = n != oldRegisters[reg] ? "*" : " ";
534-
oldRegisters[reg]=n;
535-
}
536-
reg++;
537-
}
538-
y++;
539-
}
540-
541-
if (oldRegisterTicks != clockticks6502) {
542-
oldRegisterTicks = clockticks6502;
543-
}
512+
int reg = 0;
513+
int y_start = y;
514+
char lbl[6];
515+
while (reg < DBGMAX_ZERO_PAGE_REGISTERS) {
516+
if (((y-y_start) % 5) != 0) { // Break registers into groups of 5, easier to locate
517+
if (reg <= LAST_R)
518+
sprintf(lbl, "R%d", reg);
519+
else
520+
sprintf(lbl, "x%d", reg);
521+
522+
DEBUGString(dbgRenderer, DBG_ZP_REG, y, lbl, col_label);
523+
524+
int reg_addr = 2 + reg * 2;
525+
int n = real_read6502(reg_addr+1, true, currentBank)*256+real_read6502(reg_addr, true, currentBank);
526+
527+
DEBUGNumber(DBG_ZP_REG+5, y, n, 4, col_data);
528+
529+
if (oldRegChange[reg] != NULL)
530+
DEBUGString(dbgRenderer, DBG_ZP_REG+9, y, oldRegChange[reg], col_data);
531+
532+
if (oldRegisterTicks != clockticks6502) { // change detection only when the emulated CPU changes
533+
oldRegChange[reg] = n != oldRegisters[reg] ? "*" : " ";
534+
oldRegisters[reg]=n;
535+
}
536+
reg++;
537+
}
538+
y++;
539+
}
540+
541+
if (oldRegisterTicks != clockticks6502) {
542+
oldRegisterTicks = clockticks6502;
543+
}
544544
}
545545

546546
// *******************************************************************************************

disasm.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ int disasm(uint16_t pc, uint8_t *RAM, char *line, unsigned int max_line, bool de
3838

3939
if (isZprel) {
4040
snprintf(line, max_line, mnemonic, real_read6502(pc + 1, debugOn, bank), pc + 3 + (int8_t)real_read6502(pc + 2, debugOn, bank));
41-
length = 3;
41+
length = 3;
4242
} else {
4343
if (strstr(line, "%02x")) {
4444
length = 2;

icon.c

Lines changed: 188 additions & 188 deletions
Large diffs are not rendered by default.

main.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -449,7 +449,7 @@ usage()
449449
printf("\tcan be specified.\n");
450450
#endif
451451
printf("-version\n");
452-
printf("\tPrint additional version information the emulator and ROM.\n");
452+
printf("\tPrint additional version information the emulator and ROM.\n");
453453
printf("\n");
454454
exit(1);
455455
}
@@ -780,7 +780,7 @@ main(int argc, char **argv)
780780
printf("%s", VER_INFO);
781781
argc--;
782782
argv++;
783-
exit(0);
783+
exit(0);
784784
} else {
785785
usage();
786786
}

video.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -508,7 +508,7 @@ render_sprite_line(const uint16_t y)
508508
// 8bpp
509509
memcpy(unpacked_sprite_line, bitmap_data, props->sprite_width);
510510
}
511-
511+
512512
for (uint16_t sx = 0; sx < props->sprite_width; ++sx) {
513513
const uint16_t line_x = props->sprite_x + sx;
514514
if (line_x >= SCREEN_WIDTH) {
@@ -532,7 +532,7 @@ render_sprite_line(const uint16_t y)
532532
sprite_line_collisions |= sprite_line_mask[line_x] & props->sprite_collision_mask;
533533
sprite_line_mask[line_x] |= props->sprite_collision_mask;
534534

535-
if (props->sprite_zdepth > sprite_line_z[line_x]) {
535+
if (props->sprite_zdepth > sprite_line_z[line_x]) {
536536
sprite_line_col[line_x] = col_index + props->palette_offset;
537537
sprite_line_z[line_x] = props->sprite_zdepth;
538538
}

webassembly/x16emu-template.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,4 +85,4 @@ <h1>Commander X16 Emulator <a href="http://commanderx16.com" target="_blank">vis
8585

8686
</body>
8787

88-
</html>
88+
</html>

0 commit comments

Comments
 (0)