html: give avatars a white background when they exist, so the default icon doesn't shine through

This commit is contained in:
Hylke Bons 2011-06-26 23:24:15 +01:00
parent 0c63053efd
commit 40ce10410a
2 changed files with 11 additions and 1 deletions

View file

@ -417,10 +417,14 @@ namespace SparkleShare {
comments += "</table>";
}
string avatar_email = "";
if (File.Exists (GetAvatar (change_set.UserEmail, 36)))
avatar_email = change_set.UserEmail;
event_entry += "</dl>";
event_entries += event_entry_html.Replace ("<!-- $event-entry-content -->", event_entry)
.Replace ("<!-- $event-user-name -->", change_set.UserName)
.Replace ("<!-- $event-avatar-url -->", "file://" + GetAvatar (change_set.UserEmail, 36))
.Replace ("<!-- $event-avatar-url -->", "file://" + GetAvatar (avatar_email, 36))
.Replace ("<!-- $event-time -->", change_set.Timestamp.ToString ("H:mm"))
.Replace ("<!-- $event-folder -->", change_set.Folder)
.Replace ("<!-- $event-revision -->", change_set.Revision)

View file

@ -13,6 +13,12 @@
}
});
$('.buddy-icon').each (function () {
if ($(this).css('backgroundImage').indexOf ('@') != -1) {
$(this).css ('backgroundColor', '#fff');
}
});
$('.comments-section').click(function () {
$(this).find ('.comments-wrapper').show ();
$(this).find ('.comments-wrapper').css ('cursor', 'default');