Skip to content

Commit

Permalink
applets: Fix runtime error messages
Browse files Browse the repository at this point in the history
  • Loading branch information
vkareh authored and raveit65 committed Jul 28, 2018
1 parent ae885fb commit 19bfc3d
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
2 changes: 1 addition & 1 deletion applets/notification_area/status-notifier/sn-item-v0.c
Expand Up @@ -256,7 +256,7 @@ update (SnItemV0 *v0)
if (!pixbuf){
/*try to find icons specified by path and filename*/
pixbuf = gdk_pixbuf_new_from_file(v0->icon_name, NULL);
if (pixbuf){
if (pixbuf && icon_size > 1) {
/*An icon specified by path and filename may be the wrong size for the tray */
pixbuf=gdk_pixbuf_scale_simple(pixbuf, icon_size-2, icon_size-2,GDK_INTERP_BILINEAR);
}
Expand Down
12 changes: 8 additions & 4 deletions applets/wncklet/workspace-switcher.c
Expand Up @@ -120,7 +120,8 @@ static void update_properties_for_wm(PagerData* pager)
gtk_widget_show(pager->workspace_names_scroll);
if (pager->display_workspaces_toggle)
gtk_widget_show(pager->display_workspaces_toggle);
g_object_set (pager->cell, "editable", TRUE, NULL);
if (pager->cell)
g_object_set (pager->cell, "editable", TRUE, NULL);
break;
case PAGER_WM_METACITY:
if (pager->workspaces_frame)
Expand All @@ -131,7 +132,8 @@ static void update_properties_for_wm(PagerData* pager)
gtk_widget_show(pager->workspace_names_scroll);
if (pager->display_workspaces_toggle)
gtk_widget_show(pager->display_workspaces_toggle);
g_object_set (pager->cell, "editable", TRUE, NULL);
if (pager->cell)
g_object_set (pager->cell, "editable", TRUE, NULL);
break;
case PAGER_WM_I3:
if (pager->workspaces_frame)
Expand All @@ -144,7 +146,8 @@ static void update_properties_for_wm(PagerData* pager)
gtk_widget_hide(pager->workspace_names_scroll);
if (pager->display_workspaces_toggle)
gtk_widget_show(pager->display_workspaces_toggle);
g_object_set (pager->cell, "editable", FALSE, NULL);
if (pager->cell)
g_object_set (pager->cell, "editable", FALSE, NULL);
break;
case PAGER_WM_COMPIZ:
if (pager->workspaces_frame)
Expand All @@ -155,7 +158,8 @@ static void update_properties_for_wm(PagerData* pager)
gtk_widget_hide(pager->workspace_names_scroll);
if (pager->display_workspaces_toggle)
gtk_widget_hide(pager->display_workspaces_toggle);
g_object_set (pager->cell, "editable", FALSE, NULL);
if (pager->cell)
g_object_set (pager->cell, "editable", FALSE, NULL);
break;
case PAGER_WM_UNKNOWN:
if (pager->workspaces_frame)
Expand Down

0 comments on commit 19bfc3d

Please sign in to comment.