Commit 807f103e authored by Guillaume Carmel-Archambault's avatar Guillaume Carmel-Archambault
Browse files

GTK Tooltips on main buttons

parent f16bf674
......@@ -284,12 +284,14 @@ create_toolbar (){
image = gtk_image_new_from_file( ICONS_DIR "/call.svg");
callButton = gtk_tool_button_new (image, "Place a Call");
gtk_widget_set_tooltip_text(GTK_WIDGET(callButton), "Place a call");
g_signal_connect (G_OBJECT (callButton), "clicked",
G_CALLBACK (call_button), NULL);
gtk_toolbar_insert(GTK_TOOLBAR(ret), GTK_TOOL_ITEM(callButton), -1);
gtk_toolbar_insert(GTK_TOOLBAR(ret), GTK_TOOL_ITEM(callButton), -1);
image = gtk_image_new_from_file( ICONS_DIR "/accept.svg");
pickupButton = gtk_tool_button_new(image, "Pick up");
gtk_widget_set_tooltip_text(GTK_WIDGET(pickupButton), "Pick up");
gtk_widget_set_state( GTK_WIDGET(pickupButton), GTK_STATE_INSENSITIVE);
g_signal_connect(G_OBJECT (pickupButton), "clicked",
G_CALLBACK (call_button), NULL);
......@@ -297,6 +299,7 @@ create_toolbar (){
image = gtk_image_new_from_file( ICONS_DIR "/hang_up.svg");
hangupButton = gtk_tool_button_new (image, "Hang up");
gtk_widget_set_tooltip_text(GTK_WIDGET(hangupButton), "Hang up");
gtk_widget_set_state( GTK_WIDGET(hangupButton), GTK_STATE_INSENSITIVE);
g_signal_connect (G_OBJECT (hangupButton), "clicked",
G_CALLBACK (hang_up), NULL);
......@@ -304,6 +307,7 @@ create_toolbar (){
image = gtk_image_new_from_file( ICONS_DIR "/unhold.svg");
unholdButton = gtk_tool_button_new (image, "Off Hold");
gtk_widget_set_tooltip_text(GTK_WIDGET(unholdButton), "Off Hold");
gtk_widget_set_state( GTK_WIDGET(unholdButton), GTK_STATE_INSENSITIVE);
g_signal_connect (G_OBJECT (unholdButton), "clicked",
G_CALLBACK (unhold), NULL);
......@@ -311,14 +315,16 @@ create_toolbar (){
image = gtk_image_new_from_file( ICONS_DIR "/hold.svg");
holdButton = gtk_tool_button_new (image, "On Hold");
gtk_widget_set_tooltip_text(GTK_WIDGET(holdButton), "On Hold");
gtk_widget_set_state( GTK_WIDGET(holdButton), GTK_STATE_INSENSITIVE);
g_signal_connect (G_OBJECT (holdButton), "clicked",
G_CALLBACK (hold), NULL);
gtk_toolbar_insert(GTK_TOOLBAR(ret), GTK_TOOL_ITEM(holdButton), -1);
gtk_toolbar_insert(GTK_TOOLBAR(ret), GTK_TOOL_ITEM(holdButton), -1);
image = gtk_image_new_from_file( ICONS_DIR "/transfert.svg");
transfertButton = gtk_toggle_tool_button_new ();
gtk_tool_button_set_icon_widget(GTK_TOOL_BUTTON(transfertButton), image);
gtk_widget_set_tooltip_text(GTK_WIDGET(transfertButton), "Transfer");
gtk_tool_button_set_label(GTK_TOOL_BUTTON(transfertButton), "Transfer");
gtk_widget_set_state( GTK_WIDGET(transfertButton), GTK_STATE_INSENSITIVE);
transfertButtonConnId = g_signal_connect (G_OBJECT (transfertButton), "toggled",
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment