[gnome-builder/gnome-builder-43] libide/lsp: fix search result property



commit 93f7ff46bfffc153540af88444ba8d37192f1cad
Author: Christian Hergert <chergert redhat com>
Date:   Sat Sep 24 15:43:49 2022 -0700

    libide/lsp: fix search result property
    
    Fixes #1803

 src/libide/lsp/ide-lsp-search-result.c | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)
---
diff --git a/src/libide/lsp/ide-lsp-search-result.c b/src/libide/lsp/ide-lsp-search-result.c
index ddf22a552..2b951926b 100644
--- a/src/libide/lsp/ide-lsp-search-result.c
+++ b/src/libide/lsp/ide-lsp-search-result.c
@@ -49,12 +49,16 @@ ide_lsp_search_result_new (const gchar *title,
                            IdeLocation *location,
                            const gchar *icon_name)
 {
+  g_autoptr(GIcon) gicon = NULL;
+
+  if (icon_name != NULL)
+    gicon = g_themed_icon_new (icon_name);
+
   return g_object_new (IDE_TYPE_LSP_SEARCH_RESULT,
                        "title", title,
                        "subtitle", subtitle,
                        "location", location,
-                       "icon-name", icon_name,
-                       // place search results before the other search providers
+                       "gicon", gicon,
                        "priority", -1,
                        NULL);
 }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]