| 1560 | } |
| 1561 | |
| 1562 | void MainWindow::consoleStr() { |
| 1563 | if (int available = emu.read.available()) { |
| 1564 | int remaining = CONSOLE_BUFFER_SIZE - emu.readPos; |
| 1565 | emu.read.acquire(available); |
| 1566 | |
| 1567 | console(emu.type, emu.buffer + emu.readPos, available < remaining ? available : remaining); |
| 1568 | if (available < remaining) { |
| 1569 | emu.readPos += available; |
| 1570 | } else if (available == remaining) { |
| 1571 | emu.readPos = 0; |
| 1572 | } else { |
| 1573 | emu.readPos = available - remaining; |
| 1574 | console(emu.type, emu.buffer, emu.readPos); |
| 1575 | } |
| 1576 | |
| 1577 | emu.write.release(available); |
| 1578 | } |
| 1579 | } |
| 1580 | |
| 1581 | void MainWindow::showAsicRevInfo(const QList<int>& supportedRevs, int loadedRev, int defaultRev, bool python) { |
| 1582 | QString defaultRevStr = ui->comboBoxAsicRev->itemText(defaultRev); |