mirror of
https://gitee.com/spark-store-project/spark-store
synced 2025-09-19 09:32:20 +08:00
git-subtree-dir: src/spark-update-tool git-subtree-mainline: 8e40670f553a36c895b55d26053129260689cc11 git-subtree-split: a54c8970ee51e2a5881a68703e92aa2ec6c1f477
37 lines
799 B
C++
37 lines
799 B
C++
#ifndef MAINWINDOW_H
|
|
#define MAINWINDOW_H
|
|
|
|
#include <QMainWindow>
|
|
#include "aptssupdater.h"
|
|
#include "applistmodel.h"
|
|
#include "appdelegate.h"
|
|
#include <QListView>
|
|
#include <QJsonArray> // 添加头文件
|
|
|
|
QT_BEGIN_NAMESPACE
|
|
namespace Ui {
|
|
class MainWindow;
|
|
}
|
|
QT_END_NAMESPACE
|
|
|
|
class MainWindow : public QMainWindow
|
|
{
|
|
Q_OBJECT
|
|
|
|
public:
|
|
MainWindow(QWidget *parent = nullptr);
|
|
~MainWindow();
|
|
|
|
private:
|
|
Ui::MainWindow *ui;
|
|
void checkUpdates();
|
|
void initStyle();
|
|
void runAptssUpgrade();
|
|
AppListModel *m_model;
|
|
AppDelegate *m_delegate;
|
|
QListView *listView; // 声明 QListView 指针
|
|
QJsonArray m_allApps; // 新增:保存所有应用数据
|
|
void filterAppsByKeyword(const QString &keyword); // 新增:搜索过滤函数声明
|
|
};
|
|
#endif // MAINWINDOW_H
|