<br><br><div class="gmail_quote">On Fri, Mar 1, 2013 at 5:35 PM, Daniele E. Domenichelli <span dir="ltr"><<a href="mailto:daniele.domenichelli@gmail.com" target="_blank">daniele.domenichelli@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im">On 01/03/13 12:21, Martin Klapetek wrote:<br>
> What you could do is to put it inside KTp::Contact and then reimplement<br>
> avatar() and check if the contact is offline and if so, return the<br>
> greyed avatar. Makes things simpler and you don't have to change any<br>
> other code.<br>
<br>
</div>It looks like the right place to me, but I don't remember a<br>
{Tp/KTp}::Contact::avatar() method to reimplement, I think that we have<br>
just a "QString Tp::Contact::avatarToken()" that returns just a string.<br>
We could add a KTp::contact::avatar() that does the magic though, but<br>
I'm not sure if we want it grayed wherever it is used, so I'd suggest to<br>
add a "bool KTp::Contact::avatar(grayIfUnavailable = false)".<br></blockquote><div><br>It might be better to use an enum instead of a boolean value. It's easier to figure out what the code is doing that way -<br>
<br> avatar = contact.avatar( Greyed ); <br>instead of<br> avatar = contact.avatar( true );<br><br><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
<br>
Cheers,<br>
Daniele<br>
<br>
_______________________________________________<br>
KDE-Telepathy mailing list<br>
<a href="mailto:KDE-Telepathy@kde.org">KDE-Telepathy@kde.org</a><br>
<a href="https://mail.kde.org/mailman/listinfo/kde-telepathy" target="_blank">https://mail.kde.org/mailman/listinfo/kde-telepathy</a><br>
</blockquote></div><br><br clear="all"><br>-- <br><span style="color:rgb(192,192,192)">Vishesh Handa</span><br>