diff --git a/gtk/incall_view.c b/gtk/incall_view.c index 4eb8d76ef..ff2cda616 100644 --- a/gtk/incall_view.c +++ b/gtk/incall_view.c @@ -901,22 +901,13 @@ void linphone_gtk_enable_mute_button(GtkButton *button, gboolean sensitive){ } void linphone_gtk_draw_hold_button(GtkButton *button, gboolean active){ + const gchar *icon_name = active ? "linphone-hold-on" : "linphone-hold-off"; + const gchar *label = active ? _("Resume") : _("Pause"); + GtkWidget *image = gtk_image_new_from_icon_name(icon_name, GTK_ICON_SIZE_BUTTON); g_object_set_data(G_OBJECT(button),"active",GINT_TO_POINTER(active)); - if (active){ - GtkWidget *image=create_pixmap("hold_off.png"); - gtk_button_set_label(GTK_BUTTON(button),_("Resume")); - if (image!=NULL) { - gtk_button_set_image(GTK_BUTTON(button),image); - gtk_widget_show(image); - } - }else{ - GtkWidget *image=create_pixmap("hold_on.png"); - gtk_button_set_label(GTK_BUTTON(button),_("Pause")); - if (image!=NULL) { - gtk_button_set_image(GTK_BUTTON(button),image); - gtk_widget_show(image); - } - } + gtk_button_set_label(GTK_BUTTON(button),label); + gtk_button_set_image(GTK_BUTTON(button),image); + gtk_widget_show(image); } void linphone_gtk_hold_clicked(GtkButton *button){ diff --git a/pixmaps/CMakeLists.txt b/pixmaps/CMakeLists.txt index 2477afcd2..e470168a2 100644 --- a/pixmaps/CMakeLists.txt +++ b/pixmaps/CMakeLists.txt @@ -75,6 +75,8 @@ install(FILES linphone-add-call.png linphone-start-call.png linphone-start-chat.png + linphone-hold-on.png + linphone-hold-off.png DESTINATION ${ICONS_INSTALL_DIR}/48x48/actions PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ ) diff --git a/pixmaps/Makefile.am b/pixmaps/Makefile.am index 390e6168b..7dcbd5d78 100644 --- a/pixmaps/Makefile.am +++ b/pixmaps/Makefile.am @@ -49,5 +49,7 @@ dist_actions48icons_DATA= \ linphone-start-call2.png \ linphone-show-dialer.png \ linphone-add-call.png \ - linphone-start-call.png + linphone-start-call.png \ + linphone-hold-on \ + linphone-hold-off ) diff --git a/pixmaps/hold_off.png b/pixmaps/hold_off.png deleted file mode 100644 index 3ba6746fb..000000000 Binary files a/pixmaps/hold_off.png and /dev/null differ diff --git a/pixmaps/hold_on.png b/pixmaps/hold_on.png deleted file mode 100644 index 776d5ddd4..000000000 Binary files a/pixmaps/hold_on.png and /dev/null differ diff --git a/pixmaps/linphone-hold-off.png b/pixmaps/linphone-hold-off.png new file mode 100644 index 000000000..016115266 Binary files /dev/null and b/pixmaps/linphone-hold-off.png differ diff --git a/pixmaps/linphone-hold-on.png b/pixmaps/linphone-hold-on.png new file mode 100644 index 000000000..c287c8a32 Binary files /dev/null and b/pixmaps/linphone-hold-on.png differ