Commit da66ace7 authored by Ghislain MARY's avatar Ghislain MARY
Browse files

Replace a lot of stock icons by our own ones.

parent af28361f
......@@ -242,7 +242,7 @@ void linphone_gtk_call_log_clear_missed_call(){
GtkNotebook *notebook=GTK_NOTEBOOK(linphone_gtk_get_widget(mw,"viewswitch"));
GtkWidget *page=gtk_notebook_get_nth_page(notebook,0);
GtkWidget *box=gtk_hbox_new(FALSE,0);
GtkWidget *image=gtk_image_new_from_stock(GTK_STOCK_REFRESH,GTK_ICON_SIZE_MENU);
GtkWidget *image=gtk_image_new_from_icon_name("linphone-history",GTK_ICON_SIZE_MENU);
GtkWidget *l;
const gchar*text=gtk_label_get_text(GTK_LABEL(linphone_gtk_get_widget(mw,"label3")));
......@@ -268,7 +268,7 @@ void linphone_gtk_call_log_display_missed_call(int nb){
GtkWidget *page=gtk_notebook_get_nth_page(notebook,0);
GtkWidget *ebox=gtk_event_box_new();
GtkWidget *box=gtk_hbox_new(FALSE,0);
GtkWidget *image=gtk_image_new_from_stock(GTK_STOCK_REFRESH,GTK_ICON_SIZE_MENU);
GtkWidget *image=gtk_image_new_from_icon_name("linphone-history",GTK_ICON_SIZE_MENU);
GtkWidget *l;
gchar *buf;
......
......@@ -43,11 +43,10 @@
<property name="can_focus">False</property>
<child>
<object class="GtkToggleButton" id="conf_record_button">
<property name="label">gtk-media-record</property>
<property name="label" translatable="yes">Record</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="use_stock">True</property>
<signal name="toggled" handler="linphone_gtk_record_call_toggled" swapped="no"/>
</object>
<packing>
......
......@@ -34,7 +34,7 @@
static GtkWidget *create_conference_label(void){
GtkWidget *box=gtk_hbox_new(FALSE,0);
gtk_box_pack_start(GTK_BOX(box),gtk_image_new_from_stock(GTK_STOCK_ADD,GTK_ICON_SIZE_MENU),FALSE,FALSE,0);
gtk_box_pack_start(GTK_BOX(box),gtk_image_new_from_icon_name("linphone-conference-start",GTK_ICON_SIZE_MENU),FALSE,FALSE,0);
gtk_box_pack_end(GTK_BOX(box),gtk_label_new(_("Conference")),TRUE,FALSE,0);
gtk_widget_show_all(box);
return box;
......@@ -88,7 +88,9 @@ static GtkWidget * create_conference_panel(void){
GtkWidget *box;
GtkWidget *viewswitch=linphone_gtk_get_widget(mw,"viewswitch");
GtkWidget *participant;
GtkWidget *record = linphone_gtk_get_widget(conf_frame, "conf_record_button");
gtk_button_set_image(GTK_BUTTON(record), gtk_image_new_from_icon_name("linphone-record", GTK_ICON_SIZE_BUTTON));
gtk_button_set_image(GTK_BUTTON(button_conf),image);
g_signal_connect_swapped(G_OBJECT(button_conf),"clicked",(GCallback)linphone_gtk_terminate_call,NULL);
g_object_set_data(G_OBJECT(mw),"conf_frame",(gpointer)conf_frame);
......
......@@ -453,11 +453,12 @@ static void icon_press_handler(GtkEntry *entry){
}
static void update_star(GtkEntry *entry, gboolean is_known){
gtk_entry_set_icon_from_icon_name(entry,GTK_ENTRY_ICON_SECONDARY,"linphone-contact-add");
if (is_known){
gtk_entry_set_icon_from_icon_name(entry,GTK_ENTRY_ICON_SECONDARY,"linphone-contact-bookmarked");
gtk_entry_set_icon_sensitive(GTK_ENTRY(entry),GTK_ENTRY_ICON_SECONDARY,FALSE);
gtk_entry_set_icon_tooltip_text(GTK_ENTRY(entry),GTK_ENTRY_ICON_SECONDARY,NULL);
}else{
gtk_entry_set_icon_from_icon_name(entry,GTK_ENTRY_ICON_SECONDARY,"linphone-contact-not-bookmarked");
gtk_entry_set_icon_sensitive(GTK_ENTRY(entry),GTK_ENTRY_ICON_SECONDARY,TRUE);
gtk_entry_set_icon_tooltip_text(GTK_ENTRY(entry),GTK_ENTRY_ICON_SECONDARY,_("Add to addressbook"));
}
}
......@@ -607,15 +608,6 @@ void linphone_gtk_friend_list_on_presence_column_clicked(GtkTreeModel *model){
}
#endif
void create_button(){
GtkWidget *main_window = linphone_gtk_get_main_window ();
GtkWidget *button_add = linphone_gtk_get_widget(main_window,"add_button");
GtkWidget *image;
image=gtk_image_new_from_stock(GTK_STOCK_ADD,GTK_ICON_SIZE_MENU);
gtk_container_add (GTK_CONTAINER (button_add), image);
}
static void linphone_gtk_friend_list_init(GtkWidget *friendlist){
GtkTreeModel *store = gtk_tree_view_get_model(GTK_TREE_VIEW(friendlist));
GtkTreeSelection *select = gtk_tree_view_get_selection (GTK_TREE_VIEW (friendlist));
......
......@@ -46,29 +46,16 @@
<child>
<object class="GtkHBox" id="encryption_box">
<property name="can_focus">False</property>
<child>
<object class="GtkImage" id="dialog_authenticator_image">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="stock">gtk-dialog-authentication</property>
<property name="icon-size">1</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkImage" id="encryption_status_icon">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="stock">gtk-apply</property>
<property name="icon_name">linphone-security-pending</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
<property name="position">1</property>
<property name="position">0</property>
</packing>
</child>
<child>
......@@ -80,7 +67,7 @@
<property name="expand">True</property>
<property name="fill">True</property>
<property name="padding">2</property>
<property name="position">2</property>
<property name="position">1</property>
</packing>
</child>
<child>
......@@ -94,7 +81,7 @@
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
<property name="position">3</property>
<property name="position">2</property>
</packing>
</child>
</object>
......@@ -245,12 +232,11 @@
<property name="can_focus">False</property>
<child>
<object class="GtkToggleButton" id="record_button">
<property name="label">gtk-media-record</property>
<property name="label" translatable="yes">Record</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="tooltip_text" translatable="yes">Record this call to an audio file</property>
<property name="use_stock">True</property>
<signal name="toggled" handler="linphone_gtk_record_call_toggled" swapped="no"/>
</object>
<packing>
......
......@@ -79,7 +79,7 @@ void linphone_gtk_call_update_tab_header(LinphoneCall *call,gboolean pause){
gchar *text;
if(pause){
i=gtk_image_new_from_stock(GTK_STOCK_MEDIA_PAUSE,GTK_ICON_SIZE_BUTTON);
i=gtk_image_new_from_icon_name("linphone-hold-off",GTK_ICON_SIZE_BUTTON);
} else {
i=gtk_image_new_from_icon_name("linphone-start-call", GTK_ICON_SIZE_BUTTON);
}
......@@ -410,6 +410,7 @@ void linphone_gtk_create_in_call_view(LinphoneCall *call){
GtkWidget *audio_bar = linphone_gtk_get_widget(call_view, "incall_audioview");
static int call_index=1;
int idx;
GtkWidget *record;
GtkWidget *transfer;
GtkWidget *conf;
GtkWidget *button;
......@@ -434,14 +435,16 @@ void linphone_gtk_create_in_call_view(LinphoneCall *call){
linphone_gtk_enable_mute_button(
GTK_BUTTON(linphone_gtk_get_widget(call_view,"incall_mute")),FALSE);
record = linphone_gtk_get_widget(call_view, "record_button");
gtk_button_set_image(GTK_BUTTON(record), gtk_image_new_from_icon_name("linphone-record", GTK_ICON_SIZE_BUTTON));
gtk_widget_hide(record);
transfer = linphone_gtk_get_widget(call_view,"transfer_button");
gtk_button_set_image(GTK_BUTTON(transfer),gtk_image_new_from_stock
(GTK_STOCK_GO_FORWARD,GTK_ICON_SIZE_BUTTON));
gtk_button_set_image(GTK_BUTTON(transfer),gtk_image_new_from_icon_name("linphone-call-transfer",GTK_ICON_SIZE_BUTTON));
g_signal_connect(G_OBJECT(transfer),"clicked",(GCallback)transfer_button_clicked,call);
gtk_widget_hide(transfer);
conf = linphone_gtk_get_widget(call_view,"conference_button");
gtk_button_set_image(GTK_BUTTON(conf),gtk_image_new_from_stock (GTK_STOCK_ADD,GTK_ICON_SIZE_BUTTON));
gtk_button_set_image(GTK_BUTTON(conf),gtk_image_new_from_icon_name("linphone-conference-start",GTK_ICON_SIZE_BUTTON));
g_signal_connect(G_OBJECT(conf),"clicked",(GCallback)conference_button_clicked,call);
gtk_widget_hide(conf);
......@@ -480,7 +483,7 @@ void linphone_gtk_update_video_button(LinphoneCall *call){
button=linphone_gtk_get_widget(call_view,"video_button");
gtk_button_set_image(GTK_BUTTON(button),
gtk_image_new_from_stock(has_video ? GTK_STOCK_REMOVE : GTK_STOCK_ADD,GTK_ICON_SIZE_BUTTON));
gtk_image_new_from_icon_name(has_video ? "linphone-camera-disabled" : "linphone-camera-enabled",GTK_ICON_SIZE_BUTTON));
g_object_set_data(G_OBJECT(button),"adding_video",GINT_TO_POINTER(!has_video));
if (!linphone_core_video_supported(linphone_call_get_core(call))){
gtk_widget_set_sensitive(button,FALSE);
......@@ -726,13 +729,13 @@ void linphone_gtk_in_call_view_show_encryption(LinphoneCall *call){
case LinphoneMediaEncryptionSRTP:
gtk_widget_show_all(encryption_box);
gtk_label_set_markup(GTK_LABEL(label),_("Secured by SRTP"));
gtk_widget_hide(status_icon);
gtk_image_set_from_icon_name(GTK_IMAGE(status_icon), "linphone-security-ok", GTK_ICON_SIZE_MENU);
gtk_widget_hide(verify_button);
break;
case LinphoneMediaEncryptionDTLS:
gtk_widget_show_all(encryption_box);
gtk_label_set_markup(GTK_LABEL(label),_("Secured by DTLS"));
gtk_widget_hide(status_icon);
gtk_image_set_from_icon_name(GTK_IMAGE(status_icon), "linphone-security-ok", GTK_ICON_SIZE_MENU);
gtk_widget_hide(verify_button);
break;
case LinphoneMediaEncryptionZRTP:
......@@ -740,8 +743,8 @@ void linphone_gtk_in_call_view_show_encryption(LinphoneCall *call){
gchar *text=g_strdup_printf(_("Secured by ZRTP - [auth token: %s]"),linphone_call_get_authentication_token(call));
gtk_label_set_markup(GTK_LABEL(label),text);
g_free(text);
gtk_image_set_from_stock(GTK_IMAGE(status_icon),
verified ? GTK_STOCK_APPLY : GTK_STOCK_DIALOG_WARNING,GTK_ICON_SIZE_MENU);
gtk_image_set_from_icon_name(GTK_IMAGE(status_icon),
verified ? "linphone-security-ok" : "linphone-security-pending", GTK_ICON_SIZE_MENU);
gtk_button_set_label(GTK_BUTTON(verify_button),
verified ? _("Set unverified") : _("Set verified"));
gtk_widget_show_all(encryption_box);
......
......@@ -1400,7 +1400,7 @@ static void update_registration_status(LinphoneProxyConfig *cfg, LinphoneRegistr
GtkTreeModel *model=gtk_combo_box_get_model(box);
GtkTreeIter iter;
gboolean found=FALSE;
const char *stock_id=NULL;
const char *icon_name=NULL;
if (gtk_tree_model_get_iter_first(model,&iter)){
gpointer p;
......@@ -1418,21 +1418,21 @@ static void update_registration_status(LinphoneProxyConfig *cfg, LinphoneRegistr
}
switch (rs){
case LinphoneRegistrationOk:
stock_id=GTK_STOCK_YES;
icon_name="linphone-ok";
break;
case LinphoneRegistrationProgress:
stock_id=GTK_STOCK_REFRESH;
icon_name="linphone-inprogress";
break;
case LinphoneRegistrationCleared:
stock_id=NULL;
icon_name=NULL;
break;
case LinphoneRegistrationFailed:
stock_id=GTK_STOCK_DIALOG_WARNING;
icon_name="linphone-failed";
break;
default:
break;
}
gtk_list_store_set(GTK_LIST_STORE(model),&iter,1,stock_id,-1);
gtk_list_store_set(GTK_LIST_STORE(model),&iter,1,icon_name,-1);
}
static void linphone_gtk_registration_state_changed(LinphoneCore *lc, LinphoneProxyConfig *cfg,
......@@ -1588,7 +1588,7 @@ static void init_identity_combo(GtkComboBox *box){
gtk_cell_layout_pack_start(GTK_CELL_LAYOUT(box),(r1=gtk_cell_renderer_text_new()),TRUE);
gtk_cell_layout_pack_end(GTK_CELL_LAYOUT(box),(r2=gtk_cell_renderer_pixbuf_new()),FALSE);
gtk_cell_layout_add_attribute(GTK_CELL_LAYOUT(box),r1,"text",0);
gtk_cell_layout_add_attribute(GTK_CELL_LAYOUT(box),r2,"stock-id",1);
gtk_cell_layout_add_attribute(GTK_CELL_LAYOUT(box),r2,"icon-name",1);
g_object_set(G_OBJECT(r1),"ellipsize",PANGO_ELLIPSIZE_END,NULL);
gtk_combo_box_set_model(box,GTK_TREE_MODEL(store));
}
......@@ -1620,7 +1620,7 @@ void linphone_gtk_load_identities(void){
LinphoneProxyConfig *cfg=(LinphoneProxyConfig*)elem->data;
gtk_list_store_append(store,&iter);
gtk_list_store_set(store,&iter,0,linphone_proxy_config_get_identity(cfg),1,
linphone_proxy_config_is_registered(cfg) ? GTK_STOCK_YES : NULL,
linphone_proxy_config_is_registered(cfg) ? "linphone-ok" : NULL,
2,cfg,-1);
if (cfg==def) {
def_index=i;
......
......@@ -362,11 +362,11 @@
<property name="can_focus">True</property>
<property name="invisible_char"></property>
<property name="invisible_char_set">True</property>
<property name="secondary_icon_name">linphone-contact-not-bookmarked</property>
<property name="secondary_icon_name">linphone-contact-add</property>
<property name="primary_icon_activatable">False</property>
<property name="secondary_icon_activatable">True</property>
<property name="primary_icon_sensitive">True</property>
<property name="secondary_icon_sensitive">True</property>
<property name="secondary_icon_sensitive">False</property>
<signal name="activate" handler="linphone_gtk_uri_bar_activate" swapped="no"/>
</object>
<packing>
......
[Dolphin]
PreviewsShown=true
Timestamp=2015,10,21,11,22,45
Version=3
......@@ -43,6 +43,13 @@ install(FILES
svg/linphone-chat-new-message.svg
svg/linphone-chat-nothing.svg
svg/linphone-chat-writing.svg
svg/linphone-ok.svg
svg/linphone-inprogress.svg
svg/linphone-failed.svg
svg/linphone-camera-enabled.svg
svg/linphone-camera-disabled.svg
svg/linphone-security-ok.svg
svg/linphone-security-pending.svg
DESTINATION ${ICONS_INSTALL_DIR}/scalable/status
PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ
)
......@@ -58,6 +65,9 @@ install(FILES
svg/linphone-edit.svg
svg/linphone-delete.svg
svg/linphone-contact-add.svg
svg/linphone-conference-start.svg
svg/linphone-call-transfer.svg
svg/linphone-record.svg
DESTINATION ${ICONS_INSTALL_DIR}/scalable/actions
PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ
)
......@@ -78,8 +88,13 @@ install(FILES
linphone-call-status-incoming.png
linphone-call-status-outgoing.png
linphone-call-status-missed.png
linphone-contact-bookmarked.png
linphone-contact-not-bookmarked.png
linphone-ok.png
linphone-inprogress.png
linphone-failed.png
linphone-camera-enabled.png
linphone-camera-disabled.png
linphone-security-ok.png
linphone-security-pending.png
DESTINATION ${ICONS_INSTALL_DIR}/48x48/status
PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ
)
......@@ -96,6 +111,9 @@ install(FILES
linphone-edit.png
linphone-delete.png
linphone-contact-add.png
linphone-conference-start.png
linphone-call-transfer.png
linphone-record.png
DESTINATION ${ICONS_INSTALL_DIR}/48x48/actions
PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ
)
......
......@@ -28,8 +28,13 @@ dist_status48icons_DATA= \
linphone-call-status-incoming.png \
linphone-call-status-outgoing.png \
linphone-call-status-missed.png \
linphone-contact-bookmarked.png \
linphone-contact-not-bookmarked.png
linphone-ok.png \
linphone-inprogress.png \
linphone-failed.png \
linphone-camera-enabled.png \
linphone-camera-disabled.png \
linphone-security-ok.png \
linphone-security-pending.png
statussvgiconsdir=$(iconsdir)/scalable/status
dist_statussvgicons_DATA= \
......@@ -47,7 +52,14 @@ dist_statussvgicons_DATA= \
svg/linphone-chat-new-message-and-writing.svg \
svg/linphone-chat-new-message.svg \
svg/linphone-chat-nothing.svg \
svg/linphone-chat-writing.svg
svg/linphone-chat-writing.svg \
svg/linphone-ok.svg \
svg/linphone-inprogress.svg \
svg/linphone-failed.svg \
svg/linphone-camera-enabled.svg \
svg/linphone-camera-disabled.svg \
svg/linphone-security-ok.svg \
svg/linphone-security-pending.svg
actions48iconsdir=$(iconsdir)/48x48/actions
dist_actions48icons_DATA= \
......@@ -61,7 +73,10 @@ dist_actions48icons_DATA= \
linphone-history.png \
linphone-edit.png \
linphone-delete.png \
linphone-contact-add.png
linphone-contact-add.png \
linphone-conference-start.png \
linphone-call-transfer.png \
linphone-record.png
actionssvgiconsdir=$(iconsdir)/scalable/actions
dist_actionssvgicons_DATA= \
......@@ -74,4 +89,7 @@ dist_actionssvgicons_DATA= \
svg/linphone-history.svg \
svg/linphone-edit.svg \
svg/linphone-delete.svg \
svg/linphone-contact-add.svg
svg/linphone-contact-add.svg \
svg/linphone-conference-start.svg \
svg/linphone-call-transfer.svg \
svg/linphone-record.svg
Markdown is supported
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