feat(ela): P3-b 项目列表弹窗 Ela 化 — 输入/下拉/按钮→Ela*

nameEdit_→ElaLineEdit, typeCombo_→ElaComboBox, 搜索/重置/上一页/下一页→ElaPushButton;
表格(QTableWidget)保留并靠 P2 暗色 QSS 联动
This commit is contained in:
gaozheng 2026-06-10 07:51:12 +08:00
parent c8812aa8a6
commit ef278ac335
1 changed files with 10 additions and 6 deletions

View File

@ -16,6 +16,10 @@
#include "Theme.hpp"
#include <ElaComboBox.h>
#include <ElaLineEdit.h>
#include <ElaPushButton.h>
namespace geopro::app {
namespace {
QString statusText(int s) {
@ -45,18 +49,18 @@ ProjectListDialog::ProjectListDialog(data::IProjectRepository& repo, QWidget* pa
auto* filter = new QHBoxLayout();
filter->addWidget(new QLabel(QStringLiteral("项目名称"), this));
nameEdit_ = new QLineEdit(this);
nameEdit_ = new ElaLineEdit(this);
nameEdit_->setPlaceholderText(QStringLiteral("输入项目名称"));
nameEdit_->setFixedWidth(200);
filter->addWidget(nameEdit_);
filter->addSpacing(8);
filter->addWidget(new QLabel(QStringLiteral("项目类型"), this));
typeCombo_ = new QComboBox(this);
typeCombo_ = new ElaComboBox(this);
typeCombo_->setFixedWidth(160);
filter->addWidget(typeCombo_);
filter->addSpacing(8);
auto* searchBtn = new QPushButton(QStringLiteral("搜索"), this);
auto* resetBtn = new QPushButton(QStringLiteral("重置"), this);
auto* searchBtn = new ElaPushButton(QStringLiteral("搜索"), this);
auto* resetBtn = new ElaPushButton(QStringLiteral("重置"), this);
filter->addWidget(searchBtn);
filter->addWidget(resetBtn);
filter->addStretch();
@ -81,8 +85,8 @@ ProjectListDialog::ProjectListDialog(data::IProjectRepository& repo, QWidget* pa
pageLabel_ = new QLabel(this);
bottom->addWidget(pageLabel_);
bottom->addStretch();
prevBtn_ = new QPushButton(QStringLiteral("上一页"), this);
nextBtn_ = new QPushButton(QStringLiteral("下一页"), this);
prevBtn_ = new ElaPushButton(QStringLiteral("上一页"), this);
nextBtn_ = new ElaPushButton(QStringLiteral("下一页"), this);
bottom->addWidget(prevBtn_);
bottom->addWidget(nextBtn_);
root->addLayout(bottom);