Codebase list xapp / f9f97dd
Update upstream source from tag 'upstream/2.2.10' Update to upstream version '2.2.10' with Debian dir 68a39c34560ca9ffe5090730eefd1a9cebde7f39 Fabio Fantoni 1 year, 10 months ago
5 changed file(s) with 87 addition(s) and 17 deletion(s). Raw diff Collapse all Expand all
3737 fi
3838
3939 jobs:
40 "mint20":
40 "mint":
4141 <<: *shared
4242 docker:
43 - image: linuxmintd/mint20-amd64
43 - image: linuxmintd/mint21-amd64
4444
45 "lmde4":
45 "lmde":
4646 <<: *shared
4747 docker:
48 - image: linuxmintd/lmde4-amd64
48 - image: linuxmintd/lmde5-amd64
4949
5050 workflows:
5151 version: 2
5252 build:
5353 jobs:
54 - "mint20"
55 - "lmde4"
54 - "mint"
55 - "lmde"
18361836 else
18371837 {
18381838 g_free (priv->current_text);
1839 priv->current_text = g_strdup (search_text);
1839 priv->current_text = g_utf8_strdown (search_text, -1);
18401840
18411841 gtk_widget_show (priv->loading_bar);
18421842
18461846 {
18471847 if (priv->allow_paths)
18481848 {
1849 search_path (dialog, search_text, priv->search_icon_store);
1849 search_path (dialog, priv->current_text, priv->search_icon_store);
18501850 }
18511851 }
18521852 else
18531853 {
1854 search_icon_name (dialog, search_text, priv->search_icon_store);
1854 search_icon_name (dialog, priv->current_text, priv->search_icon_store);
18551855 }
18561856 }
18571857 }
638638 return GDK_EVENT_PROPAGATE;
639639 }
640640
641 static void
641 static gboolean
642642 on_gtk_status_icon_button_release (GtkStatusIcon *status_icon,
643643 GdkEvent *event,
644644 gpointer user_data)
685685 button,
686686 _time,
687687 orientation);
688
689 return GDK_EVENT_PROPAGATE;
690 }
691
692 static gboolean
693 on_gtk_status_icon_scroll (GtkStatusIcon *status_icon,
694 GdkEvent *event,
695 gpointer user_data)
696 {
697 XAppStatusIcon *icon = user_data;
698 guint _time;
699
700 _time = event->scroll.time;
701 GdkScrollDirection direction;
702
703
704 if (gdk_event_get_scroll_direction (event, &direction))
705 {
706 XAppScrollDirection x_dir = XAPP_SCROLL_UP;
707 gint delta = 0;
708
709 if (direction != GDK_SCROLL_SMOOTH) {
710 if (direction == GDK_SCROLL_UP)
711 {
712 x_dir = XAPP_SCROLL_UP;
713 delta = -1;
714 }
715 else if (direction == GDK_SCROLL_DOWN)
716 {
717 x_dir = XAPP_SCROLL_DOWN;
718 delta = 1;
719 }
720 else if (direction == GDK_SCROLL_LEFT)
721 {
722 x_dir = XAPP_SCROLL_LEFT;
723 delta = -1;
724 }
725 else if (direction == GDK_SCROLL_RIGHT)
726 {
727 x_dir = XAPP_SCROLL_RIGHT;
728 delta = 1;
729 }
730 }
731
732 DEBUG ("Received Scroll from GtkStatusIcon %s: "
733 "delta: %d , direction: %s , time: %u",
734 gtk_status_icon_get_title (status_icon),
735 delta, direction_to_str (direction), _time);
736
737 g_signal_emit(icon, signals[SCROLL], 0,
738 delta,
739 x_dir,
740 _time);
741 }
742
743 return GDK_EVENT_PROPAGATE;
688744 }
689745
690746 static void
9681024 g_signal_connect (priv->gtk_status_icon,
9691025 "button-release-event",
9701026 G_CALLBACK (on_gtk_status_icon_button_release),
1027 self);
1028 g_signal_connect (priv->gtk_status_icon,
1029 "scroll-event",
1030 G_CALLBACK (on_gtk_status_icon_scroll),
9711031 self);
9721032 g_signal_connect (priv->gtk_status_icon,
9731033 "notify::embedded",
00 project('xapp',
11 'c',
2 version : '2.2.8',
2 version : '2.2.10',
33 default_options : [ 'buildtype=debugoptimized' ],
44 )
55
5353 gboolean update_tooltip;
5454 gboolean update_menu;
5555 gboolean update_icon;
56 gboolean update_id;
5657 } SnItemPropertiesResult;
5758
5859 struct _SnItem
889890 new_props->update_icon = TRUE;
890891 }
891892 }
893 if (g_strcmp0 (name, "Id") == 0)
894 {
895 new_props->id = null_or_string_from_variant (value);
896 new_props->update_id = TRUE;
897 }
892898 }
893899
894900 g_variant_iter_free (iter);
912918 if (new_props->update_icon || new_props->update_status)
913919 {
914920 update_icon (item, new_props);
921 }
922
923 if (new_props->update_id || new_props->update_status)
924 {
925 assign_sortable_name (item, new_props->id);
915926 }
916927
917928 props_free (item->current_props);
970981 }
971982
972983 if (g_strcmp0 (signal_name, "NewIcon") == 0 ||
984 g_strcmp0 (signal_name, "Id") == 0 ||
973985 g_strcmp0 (signal_name, "NewAttentionIcon") == 0 ||
974986 g_strcmp0 (signal_name, "NewOverlayIcon") == 0 ||
975987 g_strcmp0 (signal_name, "NewToolTip") == 0 ||
10771089
10781090 static void
10791091 assign_sortable_name (SnItem *item,
1080 const gchar *title)
1092 const gchar *id)
10811093 {
10821094 gchar *init_name, *normalized;
10831095 gchar *sortable_name, *old_sortable_name;
10841096
1085 init_name = sn_item_interface_dup_id (SN_ITEM_INTERFACE (item->sn_item_proxy));
1086
1087 if (init_name == NULL && title != NULL)
1088 {
1089 init_name = g_strdup (title);
1097 if (id != NULL)
1098 {
1099 init_name = g_strdup (id);
10901100 }
10911101 else
10921102 {