1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 14:57:35 +00:00

LibCore: Convert CTCPServer to ObjectPtr

Also get rid of the custom CNotifier::create() in favor of construct().
This commit is contained in:
Andreas Kling 2019-09-21 15:18:12 +02:00
parent bce58bbbca
commit 4ea229accd
12 changed files with 23 additions and 27 deletions

View file

@ -56,7 +56,7 @@ void IRCClient::set_server(const String& hostname, int port)
void IRCClient::on_socket_connected()
{
m_notifier = CNotifier::create(m_socket->fd(), CNotifier::Read);
m_notifier = CNotifier::construct(m_socket->fd(), CNotifier::Read);
m_notifier->on_ready_to_read = [this] { receive_from_server(); };
send_user();

View file

@ -22,7 +22,7 @@
TerminalWidget::TerminalWidget(int ptm_fd, RefPtr<CConfigFile> config)
: m_terminal(*this)
, m_ptm_fd(ptm_fd)
, m_notifier(CNotifier::create(ptm_fd, CNotifier::Read))
, m_notifier(CNotifier::construct(ptm_fd, CNotifier::Read))
, m_config(move(config))
{
m_cursor_blink_timer = CTimer::create();