Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FreeRDP/Remmina.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormyheroyuki <myheroyuki@outlook.com>2022-10-29 14:57:05 +0300
committermyheroyuki <myheroyuki@outlook.com>2022-10-29 14:57:05 +0300
commit332ac1618ccc03514b1e711b521afb7858f7a715 (patch)
tree8f8903bf94f1c043f4006e57f5cf633cf242461a /src
parent15148bfef09542d3f85980c6b83670dceb718b74 (diff)
[Rem-2782] Display protocol name in tooltip for connections in the ... menu when in an existing connection's window
Diffstat (limited to 'src')
-rw-r--r--src/remmina_applet_menu_item.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/remmina_applet_menu_item.c b/src/remmina_applet_menu_item.c
index f7f87d153..2c49f0789 100644
--- a/src/remmina_applet_menu_item.c
+++ b/src/remmina_applet_menu_item.c
@@ -135,8 +135,17 @@ GtkWidget* remmina_applet_menu_item_new(RemminaAppletMenuItemType item_type, ...
gtk_widget_set_halign(widget, GTK_ALIGN_START);
gtk_container_add(GTK_CONTAINER(item), widget);
+ /* Add server and protocol to tooltip text */
if (item->server) {
- gtk_widget_set_tooltip_text(GTK_WIDGET(item), item->server);
+ if (item->protocol){
+ gchar buff[200];
+ g_snprintf(buff, 200, "%s (%s)", item->server, item->protocol);
+ gtk_widget_set_tooltip_text(GTK_WIDGET(item), buff);
+ } else {
+ gtk_widget_set_tooltip_text(GTK_WIDGET(item), item->server);
+ }
+ } else if (item->protocol) {
+ gtk_widget_set_tooltip_text(GTK_WIDGET(item), item->protocol);
}
return GTK_WIDGET(item);