From 8f7f9b3a9142eeea50054b83e9bce12056bae6c9 Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Thu, 23 Jun 2022 11:05:39 -0600 Subject: Remove ui_register_input_event_handler This patch removes ui_register_input_event_handler and ui_unregister_input_event_handler, replacing them with methods on 'ui'. It also changes gdb to use these methods everywhere, rather than sometimes reaching in to the ui to manage the file descriptor directly. --- gdb/utils.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'gdb/utils.c') diff --git a/gdb/utils.c b/gdb/utils.c index 413a4f4..5503acf 100644 --- a/gdb/utils.c +++ b/gdb/utils.c @@ -799,7 +799,7 @@ public: m_ui (NULL) { target_terminal::ours (); - ui_register_input_event_handler (current_ui); + current_ui->register_file_handler (); if (current_ui->prompt_state == PROMPT_BLOCKED) m_ui = current_ui; } @@ -807,7 +807,7 @@ public: ~scoped_input_handler () { if (m_ui != NULL) - ui_unregister_input_event_handler (m_ui); + m_ui->unregister_file_handler (); } DISABLE_COPY_AND_ASSIGN (scoped_input_handler); -- cgit v1.1