After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 638172 - Get rid of gconf in GnomeDesktopThumbnailFactory
Get rid of gconf in GnomeDesktopThumbnailFactory
Status: RESOLVED FIXED
Product: gnome-desktop
Classification: Core
Component: libgnome-desktop
unspecified
Other Linux
: Normal normal
: ---
Assigned To: Desktop Maintainers
Desktop Maintainers
Depends on: 638331
Blocks: 638343 638346
 
 
Reported: 2010-12-28 10:48 UTC by Carlos Garcia Campos
Modified: 2011-01-08 09:59 UTC
See Also:
GNOME target: 3.0
GNOME version: ---


Attachments
Don't use GConf to handle external thumbnailers (21.75 KB, patch)
2010-12-30 11:57 UTC, Carlos Garcia Campos
reviewed Details | Review
Updated patch (21.91 KB, patch)
2011-01-04 18:12 UTC, Carlos Garcia Campos
none Details | Review

Description Carlos Garcia Campos 2010-12-28 10:48:15 UTC
I'm already working on this, I was talking to Vincent and the idea is to use GKey files, similar to normal desktop files, instead of using gsettings. Thumbnailers will install a key file with information about what mime-types it supports and the command to run the thumbnailer.
Comment 1 Carlos Garcia Campos 2010-12-30 11:57:20 UTC
Created attachment 177251 [details] [review]
Don't use GConf to handle external thumbnailers

With this patch libgnome-desktop doesn't depend on GConf anymore. Note that this patch depends on bug #638331, since it uses the new gsettings schema for thumbnailers.
Comment 2 Bastien Nocera 2010-12-30 15:01:28 UTC
Review of attachment 177251 [details] [review]:

Coding style problems. Other than that looks alright to me.
Comment 3 Carlos Garcia Campos 2010-12-30 16:38:46 UTC
(In reply to comment #2)
> Review of attachment 177251 [details] [review]:
> 
> Coding style problems. 

where? I tried to follow the coding style of the file, please tell me where the problems are to fix them.

> Other than that looks alright to me.

Thanks for the review.
Comment 4 Kjartan Maraas 2011-01-03 07:56:48 UTC
I think Bastien must have meant that you're placing braces on the next line instead of the same line as the statement/conditional.
Comment 5 Carlos Garcia Campos 2011-01-03 09:53:02 UTC
It seems there are several coding styles in that file already, see:

http://git.gnome.org/browse/gnome-desktop/tree/libgnome-desktop/gnome-desktop-thumbnail.c#n100
http://git.gnome.org/browse/gnome-desktop/tree/libgnome-desktop/gnome-desktop-thumbnail.c#n265
....

I haven't noticed actually, I saw the gtk+ coding style somewhere in the file and I thought it was the only one and followed it.
Comment 6 Vincent Untz 2011-01-03 10:00:08 UTC
Review of attachment 177251 [details] [review]:

I had a very quick look, and it looks okay to me. I'll let Bastien clarify the coding style problems, but after that, it's probably okay to push it. Thanks!

::: libgnome-desktop/gnome-desktop-thumbnail.c
@@ +240,3 @@
+  thumbs_dirs[length] = NULL;
+
+  return thumbs_dirs;

We should also support the user data dir here, I guess.
Comment 7 Carlos Garcia Campos 2011-01-04 09:21:14 UTC
(In reply to comment #6)
> Review of attachment 177251 [details] [review]:
> 
> I had a very quick look, and it looks okay to me. I'll let Bastien clarify the
> coding style problems, but after that, it's probably okay to push it. Thanks!
> 
> ::: libgnome-desktop/gnome-desktop-thumbnail.c
> @@ +240,3 @@
> +  thumbs_dirs[length] = NULL;
> +
> +  return thumbs_dirs;
> 
> We should also support the user data dir here, I guess.

Do we really want users to install .thumbnailer files in their home dir?
Comment 8 Vincent Untz 2011-01-04 09:28:40 UTC
Yes, I think it makes sense. It can be used to override something, to quickly test something, or whatever. We do this for apps too. And for nearly everything using the XDG directories.
Comment 9 Carlos Garcia Campos 2011-01-04 10:36:15 UTC
Ok, I'll update the patch then.
Comment 10 Carlos Garcia Campos 2011-01-04 18:12:40 UTC
Created attachment 177504 [details] [review]
Updated patch

Updated patch:

 - It bumps gsettings schemas requirement to 0.1.4 since it uses new thumbnailer schemas
 - It adds the user data directory to the thumbnailer dir list
Comment 11 Carlos Garcia Campos 2011-01-08 09:59:58 UTC
I've fixed a memleak (I was leaking try_exec in thumbnailer_reload) and pushed to git master. I'll fix any coding style issues if needed.