* Deinitialize terminal */
| 1747 | * Deinitialize terminal |
| 1748 | */ |
| 1749 | public void |
| 1750 | deinit(VOID_PARAM) |
| 1751 | { |
| 1752 | if (!init_done) |
| 1753 | return; |
| 1754 | #if !MSDOS_COMPILER |
| 1755 | if (!(quit_if_one_screen && one_screen)) |
| 1756 | { |
| 1757 | if (mousecap) |
| 1758 | deinit_mouse(); |
| 1759 | if (!no_keypad) |
| 1760 | ltputs(sc_e_keypad, sc_height, putchr); |
| 1761 | if (!no_init) |
| 1762 | ltputs(sc_deinit, sc_height, putchr); |
| 1763 | } |
| 1764 | #else |
| 1765 | /* Restore system colors. */ |
| 1766 | SETCOLORS(sy_fg_color, sy_bg_color); |
| 1767 | #if MSDOS_COMPILER==WIN32C |
| 1768 | win32_deinit_vt_term(); |
| 1769 | if (!(quit_if_one_screen && one_screen)) |
| 1770 | { |
| 1771 | if (mousecap) |
| 1772 | deinit_mouse(); |
| 1773 | if (!no_init) |
| 1774 | win32_deinit_term(); |
| 1775 | } |
| 1776 | #else |
| 1777 | /* Need clreol to make SETCOLORS take effect. */ |
| 1778 | clreol(); |
| 1779 | #endif |
| 1780 | #endif |
| 1781 | init_done = 0; |
| 1782 | } |
| 1783 | |
| 1784 | /* |
| 1785 | * Are we interactive (ie. writing to an initialized tty)? |
no test coverage detected
searching dependent graphs…