Update avatar size to be 48px, per recommendation

See #269
This commit is contained in:
Michael Gratton 2019-02-26 22:53:15 +11:00 committed by Michael James Gratton
parent d11a5088d3
commit d93e5fe879
2 changed files with 7 additions and 8 deletions

View file

@ -613,15 +613,14 @@ public class ConversationMessage : Gtk.Grid, Geary.BaseInterface {
throw new GLib.IOError.CANCELLED("Conversation load cancelled");
}
const int PIXEL_SIZE = 32;
// We occasionally get crashes calling as below
// Gtk.Image.get_pixel_size() when the image is null. There's
// perhaps some race going on there. So we need to hard-code
// the size here and keep it in sync with
// ui/conversation-message.ui. :(
const int PIXEL_SIZE = 48;
if (this.primary_originator != null) {
int window_scale = get_scale_factor();
// We occasionally get crashes calling as below
// Gtk.Image.get_pixel_size() when the image is
// null. There's perhaps some race going on there. So we
// need to hard-code the size and keep it in sync with
// ui/conversation-message.ui. :(
//
//int pixel_size = this.avatar.get_pixel_size() * window_scale;
int pixel_size = PIXEL_SIZE * window_scale;
Gdk.Pixbuf? avatar_buf = yield loader.load(

View file

@ -19,7 +19,7 @@
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="valign">start</property>
<property name="pixel_size">32</property>
<property name="pixel_size">48</property>
<property name="icon_name">avatar-default-symbolic</property>
</object>
<packing>