Libksieve

vacationmaillineedit.cpp
1 /*
2  SPDX-FileCopyrightText: 2018-2021 Laurent Montel <[email protected]>
3 
4  SPDX-License-Identifier: LGPL-2.0-or-later
5 */
6 
7 #include "vacationmaillineedit.h"
8 #include <KColorScheme>
9 
10 using namespace KSieveUi;
11 VacationMailLineEdit::VacationMailLineEdit(QWidget *parent)
12  : QLineEdit(parent)
13 {
14 }
15 
16 void VacationMailLineEdit::setInvalidEmail(bool state)
17 {
18  if (state) {
20  setStyleSheet(QStringLiteral("QLineEdit{ background-color:%1 }").arg(bgBrush.brush(this).color().name()));
21  } else {
22  setStyleSheet(QString());
23  }
24 }
This file is part of the KDE documentation.
Documentation copyright © 1996-2021 The KDE developers.
Generated on Sat Apr 17 2021 23:09:34 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.