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 778424 - can't set custom image for user
can't set custom image for user
Status: RESOLVED FIXED
Product: gnome-control-center
Classification: Core
Component: User Accounts
git master
Other Linux
: Normal normal
: ---
Assigned To: Control-Center Maintainers
Control-Center Maintainers
Depends on:
Blocks:
 
 
Reported: 2017-02-10 02:02 UTC by Mohammed Sadiq
Modified: 2017-02-24 11:04 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
user-accounts: Don't depend on the thumbnailer for selecting photo (1.57 KB, patch)
2017-02-10 13:25 UTC, Felipe Borges
rejected Details | Review

Description Mohammed Sadiq 2017-02-10 02:02:54 UTC
No image can be selected from the File chooser in users panel.

How to reproduce:
1. In the new users panel -> Click on the image tile
2. Click on 'Browse for more Pictures'
3. Try to select some image

Result:
No image can be selected.

I believe that the bug 767065 is fixed, and it is OK to test and file bugs against the new User Accounts panel. Please let me know if otherwise.

Thanks.
Comment 1 Felipe Borges 2017-02-10 13:25:49 UTC
Created attachment 345454 [details] [review]
user-accounts: Don't depend on the thumbnailer for selecting photo

The UmPhotoDialog file chooser sets its "Open" button sensitivity
based on whether gnome_desktop_thumbnail_factory_generate_thumbnail
returns a valid pixbuf.

Due to the recent changes in GdkPixbuf and the gnome-desktop
thumbnailer, gnome_desktop_thumbnail_factory_generate_thumbnail is
no longer generating pixbufs for our use case.

This commit should be reverted as soon as the problems are fixed
in the necessary API.
Comment 2 Felipe Borges 2017-02-10 13:30:48 UTC
The attached patch is a workaround the issue, not a final solution. It should be reverted asap.

I opened Bug 778451 to understand/track down the issue.
Comment 3 Bastien Nocera 2017-02-12 19:11:14 UTC
Review of attachment 345454 [details] [review]:

No, the bug is in the code that worked as if by magic.
Comment 4 Bastien Nocera 2017-02-12 19:13:03 UTC
commit 5c5d608730ca5cd1276c5caf178865e7c6ae6bf5
Author: Bastien Nocera <hadess@hadess.net>
Date:   Sun Feb 12 20:09:44 2017 +0100

    user-accounts: Fix button sensitivity in photo dialogue
    
    g_file_info_get_content_type() returns an internal string, and we were
    freeing the file_info we got it from in the next line, so it's a miracle
    that the mime_type was ever not garbage.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=778424
Comment 5 Bastien Nocera 2017-02-24 11:04:41 UTC
*** Bug 779155 has been marked as a duplicate of this bug. ***