strcpy(buffer, "---"); ::SetWindowText(GetDlgItem(IDC_PALETTE_NUM), buffer);
buffer = "---"; GetDlgItem(IDC_PALETTE_NUM)->SetWindowText(buffer);
LRESULT MapView::OnMapInfo(WPARAM wParam, LPARAM lParam){  u8 *colors = (u8 *)lParam;  mapViewZoom.setColors(colors);  int x = wParam & 0xffff;  int y = (wParam >> 16);    char buffer[16];  sprintf(buffer, "(%d,%d)", x, y);  ::SetWindowText(GetDlgItem(IDC_XY), buffer);  u32 address = GetClickAddress(x,y);  sprintf(buffer, "0x%08X", address);  ::SetWindowText(GetDlgItem(IDC_ADDRESS), buffer);  int mode = DISPCNT & 7;    if(mode < 3) {    u16 value = *((u16 *)&vram[address - 0x6000000]);    int tile = value & 1023;    sprintf(buffer, "%d", tile);    ::SetWindowText(GetDlgItem(IDC_TILE_NUM), buffer);    buffer[0] = value & 1024 ? 'H' : '-';    buffer[1] = value & 2048 ? 'V' : '-';    buffer[2] = 0;    ::SetWindowText(GetDlgItem(IDC_FLIP), buffer);    if(!(control & 0x80)) {      sprintf(buffer, "%d", (value >> 12) & 15);    } else      strcpy(buffer, "---");    ::SetWindowText(GetDlgItem(IDC_PALETTE_NUM), buffer);  } else {    ::SetWindowText(GetDlgItem(IDC_TILE_NUM), "---");    ::SetWindowText(GetDlgItem(IDC_FLIP), "--");    ::SetWindowText(GetDlgItem(IDC_PALETTE_NUM), "---");  }    return TRUE;}