mirror of
https://git.tartarus.org/simon/putty.git
synced 2025-06-30 19:12:48 -05:00
Remove TermWin's is_utf8 method.
All implementations of it work by checking the line_codepage field in the ucsdata structure that the terminal itself already has a pointer to. Therefore, it's a totally unnecessary query function: the terminal can check the same thing directly by inspecting that structure! (In fact, it already _does_ do that, for the purpose of actually deciding how to decode terminal output data. It only uses this query function at all for the auxiliary purpose of inventing useful tty modes to pass to the backend.)
This commit is contained in:
@ -254,7 +254,6 @@ static void wintw_palette_reset(TermWin *);
|
||||
static void wintw_get_pos(TermWin *, int *x, int *y);
|
||||
static void wintw_get_pixels(TermWin *, int *x, int *y);
|
||||
static const char *wintw_get_title(TermWin *, bool icon);
|
||||
static bool wintw_is_utf8(TermWin *);
|
||||
|
||||
static const TermWinVtable windows_termwin_vt = {
|
||||
.setup_draw_ctx = wintw_setup_draw_ctx,
|
||||
@ -284,7 +283,6 @@ static const TermWinVtable windows_termwin_vt = {
|
||||
.get_pos = wintw_get_pos,
|
||||
.get_pixels = wintw_get_pixels,
|
||||
.get_title = wintw_get_title,
|
||||
.is_utf8 = wintw_is_utf8,
|
||||
};
|
||||
|
||||
static TermWin wintw[1];
|
||||
@ -300,11 +298,6 @@ static bool is_utf8(void)
|
||||
return ucsdata.line_codepage == CP_UTF8;
|
||||
}
|
||||
|
||||
static bool wintw_is_utf8(TermWin *tw)
|
||||
{
|
||||
return is_utf8();
|
||||
}
|
||||
|
||||
static bool win_seat_is_utf8(Seat *seat)
|
||||
{
|
||||
return is_utf8();
|
||||
|
Reference in New Issue
Block a user