Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions reader/widgets/EncryptionPage.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// Copyright (C) 2019 - 2026 Uniontech Software Technology Co.,Ltd.
// SPDX-FileCopyrightText: 2023 UnionTech Software Technology Co., Ltd.
// SPDX-FileCopyrightText: 2023-2026 UnionTech Software Technology Co., Ltd.
//
// SPDX-License-Identifier: GPL-3.0-or-later

Expand All @@ -12,8 +12,9 @@
#include <DFontSizeManager>
#include <DApplication>

#include <QBoxLayout>

Check warning on line 15 in reader/widgets/EncryptionPage.cpp

View workflow job for this annotation

GitHub Actions / cppcheck

Include file: <QBoxLayout> not found. Please note: Cppcheck does not need standard library headers to get proper results.
#include <DGuiApplicationHelper>

Check warning on line 16 in reader/widgets/EncryptionPage.cpp

View workflow job for this annotation

GitHub Actions / cppcheck

Include file: <DGuiApplicationHelper> not found. Please note: Cppcheck does not need standard library headers to get proper results.
#include <DSuggestButton>

Check warning on line 17 in reader/widgets/EncryptionPage.cpp

View workflow job for this annotation

GitHub Actions / cppcheck

Include file: <DSuggestButton> not found. Please note: Cppcheck does not need standard library headers to get proper results.

EncryptionPage::EncryptionPage(QWidget *parent)
: DWidget(parent)
Expand Down Expand Up @@ -48,7 +49,7 @@
edit->setObjectName("passwdEdit");
edit->setPlaceholderText(tr("Password"));

m_nextbutton = new DPushButton(this);
m_nextbutton = new DSuggestButton(this);
m_nextbutton->setObjectName("ensureBtn");
m_nextbutton->setAccessibleName("Nextbutton");
m_nextbutton->setFixedSize(360, 36);
Expand All @@ -73,6 +74,7 @@
mainlayout->addStretch();

setAutoFillBackground(true);
setMinimumHeight(305);

onUpdateTheme();
m_password->lineEdit()->setAttribute(Qt::WA_InputMethodEnabled, false);
Expand All @@ -84,7 +86,7 @@
{
qCDebug(appLog) << "Setting up encryption page signal connections";
connect(m_password, &DPasswordEdit::textChanged, this, &EncryptionPage::onPasswordChanged);
connect(m_nextbutton, &DPushButton::clicked, this, &EncryptionPage::nextbuttonClicked);
connect(m_nextbutton, &DSuggestButton::clicked, this, &EncryptionPage::nextbuttonClicked);

connect(dApp, SIGNAL(sigSetPasswdFocus()), this, SLOT(onSetPasswdFocus()));
}
Expand Down
5 changes: 3 additions & 2 deletions reader/widgets/EncryptionPage.h
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
// Copyright (C) 2019 ~ 2020 Uniontech Software Technology Co.,Ltd.
// SPDX-FileCopyrightText: 2023 UnionTech Software Technology Co., Ltd.
// SPDX-FileCopyrightText: 2023-2026 UnionTech Software Technology Co., Ltd.
//
// SPDX-License-Identifier: GPL-3.0-or-later

#ifndef ENCRYPTIONPAGE_H
#define ENCRYPTIONPAGE_H

#include <DWidget>

Check warning on line 9 in reader/widgets/EncryptionPage.h

View workflow job for this annotation

GitHub Actions / cppcheck

Include file: <DWidget> not found. Please note: Cppcheck does not need standard library headers to get proper results.
#include <DPushButton>

Check warning on line 10 in reader/widgets/EncryptionPage.h

View workflow job for this annotation

GitHub Actions / cppcheck

Include file: <DPushButton> not found. Please note: Cppcheck does not need standard library headers to get proper results.
#include <DSuggestButton>

Check warning on line 11 in reader/widgets/EncryptionPage.h

View workflow job for this annotation

GitHub Actions / cppcheck

Include file: <DSuggestButton> not found. Please note: Cppcheck does not need standard library headers to get proper results.
#include <DLabel>

Check warning on line 12 in reader/widgets/EncryptionPage.h

View workflow job for this annotation

GitHub Actions / cppcheck

Include file: <DLabel> not found. Please note: Cppcheck does not need standard library headers to get proper results.
#include <DPasswordEdit>

Check warning on line 13 in reader/widgets/EncryptionPage.h

View workflow job for this annotation

GitHub Actions / cppcheck

Include file: <DPasswordEdit> not found. Please note: Cppcheck does not need standard library headers to get proper results.

DWIDGET_USE_NAMESPACE

Expand Down Expand Up @@ -77,7 +78,7 @@
void onUpdateTheme();

private:
DPushButton *m_nextbutton = nullptr;
DSuggestButton *m_nextbutton = nullptr;
DPushButton *m_echoBtn = nullptr;
DPasswordEdit *m_password = nullptr;
};
Expand Down
Loading