On Thursday, 2 May 2013 16:12:50 CEST, Sreepriya Chalakkal wrote:
I had made the changes accordingly.
Thanks. Any reason you haven't used the following?
if (edit->text().isEmpty() || parseRecipients(recipients, errorMessage)) {
edit->setPalette(QPalette());
} else {
QPalette p;
p.setColor(QPalette::Base, Gui::Util::tintColor(p.color(QPalette::Base),
QColor(0xff, 0, 0, 0x20)));
edit->setPalette(p);
}
I find this a bit cleaner -- it makes it clear that the coloring only happens when the mail is not
parsed properly instead of separating the "empty string" and "valid mail" into
unrelated branches. What do you think about this?
Also, please stick with qobject_cast when working with QObjects provided by Qt.
Finally, you forgot to change the author's and commiter's name. I cannot push
this into KDE's git.
Cheers,
Jan
--
Trojitá, a fast Qt IMAP e-mail client -- http://trojita.flaska.net/