X-Git-Url: http://gitweb.hugovil.com/?a=blobdiff_plain;f=src%2Fmemwin.c;h=58ce1d2e6b7f87fae080c4fe57d1b2202a78c3d3;hb=c2ef73ab945d0c668e000aef58a1ad227d8910c1;hp=446f9d43f66b8dc32777a39d6efae1fc440ddd89;hpb=3edb6517f8ddd7e7d9b10a9f4cfe794cdf4981e6;p=emu8051.git diff --git a/src/memwin.c b/src/memwin.c index 446f9d4..58ce1d2 100644 --- a/src/memwin.c +++ b/src/memwin.c @@ -33,9 +33,11 @@ #include "regwin.h" #include "memwin.h" #include "emugtk.h" +#include "options.h" #include "app-config.h" extern struct app_config_t *cfg; +extern struct options_t options; static int COL_ASCII; static int N_COLUMNS; @@ -201,9 +203,9 @@ compute_data_rows(int memory_id) int data_rows; if (memory_id == INT_MEM_ID) { - data_rows = (INT_MEM_SIZE / cfg->bits_per_row); + data_rows = options.iram_size / cfg->bits_per_row; } else if (memory_id == EXT_MEM_ID) { - data_rows = 1024 / cfg->bits_per_row; + data_rows = options.xram_size / cfg->bits_per_row; } else { log_fail("Invalid memory type"); exit(1);