Skip to content

Instantly share code, notes, and snippets.

@esmarr58
Last active March 20, 2025 14:35
Show Gist options
  • Save esmarr58/8496e59b13716fa580b6c45fa36cbfba to your computer and use it in GitHub Desktop.
Save esmarr58/8496e59b13716fa580b6c45fa36cbfba to your computer and use it in GitHub Desktop.
m_webSocket = new QWebSocket();
m_connected = false;
// Conectar WebSocket
connect(m_webSocket, &QWebSocket::connected, this, &MainWindow::onConnected);
connect(m_webSocket, &QWebSocket::disconnected, this, &MainWindow::onDisconnected);
connect(m_webSocket, &QWebSocket::textMessageReceived, this, &MainWindow::onTextMessageReceived);
connect(m_webSocket, &QWebSocket::errorOccurred, this, &MainWindow::onError);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment