From: Ricardo Markiewicz Date: Mon, 17 Nov 2003 04:08:07 +0000 (+0000) Subject: Se agrega el body al handler del msg desde el servidor. X-Git-Tag: svn_import~283 X-Git-Url: https://git.llucax.com/z.facultad/75.42/plaqui.git/commitdiff_plain/1e454706fe6a1edf98043888def20b2a84e83ff2?ds=inline Se agrega el body al handler del msg desde el servidor. --- diff --git a/Client/include/principal.h b/Client/include/principal.h index 3aa1ada..f93adbe 100644 --- a/Client/include/principal.h +++ b/Client/include/principal.h @@ -56,7 +56,7 @@ protected: // Callbacks para las conexiones void on_conexion_connected(); void on_conexion_finished(); - void on_conexion_ok(); + void on_conexion_ok(const std::string &body); void on_conexion_error(unsigned code); }; diff --git a/Client/src/principal.cpp b/Client/src/principal.cpp index c6a4760..45d4a44 100644 --- a/Client/src/principal.cpp +++ b/Client/src/principal.cpp @@ -148,9 +148,12 @@ void Principal::on_conexion_finished() conexion = NULL; } -void Principal::on_conexion_ok() +void Principal::on_conexion_ok(const std::string &body) { - txt_view->get_buffer()->insert_at_cursor("El server dice que ta' todo ok!\n"); + std::cout << body << std::endl; + txt_view->get_buffer()->insert_at_cursor("\n"); + txt_view->get_buffer()->insert_at_cursor(Glib::locale_to_utf8(body)); + txt_view->get_buffer()->insert_at_cursor("\n"); } void Principal::on_conexion_error(unsigned code)