Use common code formatting style.
This commit is contained in:
@@ -14,19 +14,25 @@
|
||||
|
||||
using namespace std;
|
||||
|
||||
PopupDelete::PopupDelete(WWidget * anchorWidget, TransientMessageWidget * txtMessage, const WLength& width)
|
||||
: WPopupWidget(cpp14::make_unique<WContainerWidget>()) {
|
||||
m_tmwMessage = txtMessage; m_cwMain = NULL; m_cbConfirm = NULL;
|
||||
m_cbReConfirm = NULL; m_btnDelete = NULL;
|
||||
PopupDelete::PopupDelete(WWidget * anchorWidget, TransientMessageWidget * txtMessage, const WLength& width)
|
||||
: WPopupWidget(cpp14::make_unique<WContainerWidget>())
|
||||
{
|
||||
m_tmwMessage = txtMessage;
|
||||
m_cwMain = NULL;
|
||||
m_cbConfirm = NULL;
|
||||
m_cbReConfirm = NULL;
|
||||
m_btnDelete = NULL;
|
||||
setTransient(true);
|
||||
setAnchorWidget(anchorWidget);
|
||||
setWidth(width);
|
||||
}
|
||||
|
||||
PopupDelete::~PopupDelete() {
|
||||
PopupDelete::~PopupDelete()
|
||||
{
|
||||
}
|
||||
|
||||
void PopupDelete::Create() {
|
||||
void PopupDelete::Create()
|
||||
{
|
||||
m_cwMain = static_cast<WContainerWidget*> (implementation());
|
||||
// White in css file, like default background color.
|
||||
m_cwMain->setStyleClass("popup");
|
||||
@@ -45,7 +51,8 @@ void PopupDelete::Create() {
|
||||
this->hidden().connect(this, &PopupDelete::Reset);
|
||||
}
|
||||
|
||||
void PopupDelete::Reset() {
|
||||
void PopupDelete::Reset()
|
||||
{
|
||||
m_btnDelete->hide();
|
||||
m_cbReConfirm->setUnChecked();
|
||||
m_cbReConfirm->hide();
|
||||
@@ -53,12 +60,14 @@ void PopupDelete::Reset() {
|
||||
m_cbConfirm->show();
|
||||
}
|
||||
|
||||
void PopupDelete::OnCbConfirm() {
|
||||
void PopupDelete::OnCbConfirm()
|
||||
{
|
||||
m_cbReConfirm->setHidden(m_cbConfirm->checkState() != CheckState::Checked);
|
||||
m_cbReConfirm->setUnChecked();
|
||||
m_btnDelete->setHidden(m_cbReConfirm->checkState() != CheckState::Checked);
|
||||
}
|
||||
|
||||
void PopupDelete::OnCbReConfirm() {
|
||||
void PopupDelete::OnCbReConfirm()
|
||||
{
|
||||
m_btnDelete->setHidden(m_cbReConfirm->checkState() != CheckState::Checked);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user