GNOME Bugzilla – Bug 657097
improved avatar chooser with icon preview
Last modified: 2018-05-22 15:01:18 UTC
Currently the Empathy avatar can be chosen from the open-file-dialog as an image from the disk or a camera capture (if a camera was detected). Improve Empathy's avatar chooser by presenting: - a grid of standard or previously used avatars - an option to get avatar from camera (if a camera was detected) - an option to select another image
Cool; do you have a branch/patches? Would be great to get this in for 3.2 (UI freeze is next week).
I need to tidy things up a bit. I just finished the work Nick requested on the video effects feature. Will post a branch later today or tomorrow. Is that ok?
sure.
Created attachment 194647 [details] [review] avatar-chooser: add new avatar chooser with icon preview
Review of attachment 194647 [details] [review]: Looks pretty cool! I didn't review the code yet so here a just general comments. Why did you record this commit with another name/email? Are the um-* files a bare copy from the control center? I'd add a comment in their header documenting the original projects of those files. You broke "make check", some files should be added to POTFILES.in. Those files should not be added to libempathy_gtk_handwritten_source (they are considered as imported, not written) so their coding style won't be checked. I hit this error when opening the "edit personnal info" dialog: Gtk-CRITICAL **: gtk_widget_get_state: assertion `GTK_IS_WIDGET (widget)' failed Program received signal SIGTRAP, Trace/breakpoint trap. 0x00007fffea8adc88 in g_logv (log_domain=0x7fffef239897 "Gtk", log_level=G_LOG_LEVEL_CRITICAL, format=0x7fffea936178 "%s: assertion `%s' failed", args1=0x7fffffffab80) at gmessages.c:570 570 G_BREAKPOINT (); (gdb) bt
+ Trace 228198
Review of attachment 194647 [details] [review]: ::: libempathy-gtk/empathy-avatar-chooser.c @@ -74,3 @@ -#define EMPATHY_AVATAR_CHOOSER_RESPONSE_NO_IMAGE GTK_RESPONSE_NO -#define EMPATHY_AVATAR_CHOOSER_RESPONSE_CANCEL GTK_RESPONSE_CANCEL - */ More stuffs are not used any more: AVATAR_SIZE_SAVE, DEFAULT_DIR, priv->chooser_dialog, gsettings_ui, etc. I guess that means we can remove the EMPATHY_PREFS_UI_AVATAR_DIRECTORY gsetting key. ::: libempathy-gtk/empathy-avatar-chooser.h @@ +69,3 @@ TpAccount *account); +void avatar_chooser_set_image_from_file (EmpathyAvatarChooser *self, exported methods should be prefixed with empathy_ ::: libempathy-gtk/um-photo-dialog.c @@ +38,3 @@ +#include "um-crop-area.h" +#include "um-utils.h" +#include "empathy-avatar-chooser.h" Ok, so this one has obvioulsy be modified to work with Empathy. It would be much cleaner and easier to maintain to keep um-* files as a bare copy from CC (so we can just sync this file when needed). Would it be possible to modify this object to fire signals that would be catched in EmpathyAvatarChooser?
Review of attachment 194647 [details] [review]: ::: libempathy-gtk/um-photo-dialog.c @@ +426,3 @@ + goto skip_faces; + + image = gtk_image_new_from_icon_name ("avatar-default", GTK_ICON_SIZE_DIALOG); It's not that clear that selecting this image will unset your avatar. I think we should be more explicit like, maybe a "Unset avatar" entry in the bottom menu? Btw, unsetting avatar doesn't seem to work.
I was working on my boyfriend's computer because on mine empathy was crashing (see bug #657271) and I forgot to configure git's user.email/user.name. Will fix. I stripped down um-utils.c|h because we didn't need most of the functions from there. um-crop-area.c|h are copy-pasted in libcheese too. I think these should go to a lower-level library (maybe gtk itself) but I don't know where it would be more suited. I removed from um-photo-dialog.c|h all stuff that was related to um-user (including a pointer to a UmUser from the UmPhotoDialog structure). UmPhotoDialog would need to be split into a low level UmPhotoDialog that would communicate with signals as you said earlier or call pointers to functions and classes that would work using this low-level UmPhotoDialog. I don't know if there's time to do that before the freeze in gnome-control-center/empathy.
Hi, I just got home with a dead laptop from my grandfather :(.I am trying to install on my home desktop all the stuff to make the changes. Is it still in time if I make the changes till tomorrow night?
Probably needs a freeze exception.
We should still ask for it though, since it shouldn't add to the translation and documentation load etc. as it's the same design that's used elsewhere.
Raluca-Elena: Do you plan to continue working on this patch, or is anybody free to pick up your work? :)
Yeap. I will look at it this week.If I can't find the time I will let you know.
-- GitLab Migration Automatic Message -- This bug has been migrated to GNOME's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/empathy/issues/421.