ukui-settings-daemon/ 0000775 0001750 0001750 00000000000 15174103014 013550 5 ustar feng feng ukui-settings-daemon/plugins/ 0000775 0001750 0001750 00000000000 15174102667 015246 5 ustar feng feng ukui-settings-daemon/plugins/housekeeping/ 0000775 0001750 0001750 00000000000 15174103014 017717 5 ustar feng feng ukui-settings-daemon/plugins/housekeeping/housekeeping.pro 0000664 0001750 0001750 00000002020 15174103014 023121 0 ustar feng feng QT += gui
QT += core widgets
TARGET = housekeeping
TEMPLATE = lib
DEFINES += HOUSEKEPPING_LIBRARY MODULE_NAME=\\\"housekeeping\\\"
CONFIG += c++20 no_keywords link_pkgconfig plugin
DEFINES += QT_DEPRECATED_WARNINGS
include($$PWD/../../common/common.pri)
PKGCONFIG += gtk+-3.0 glib-2.0 harfbuzz gmodule-2.0 \
libxklavier gobject-2.0 gio-2.0 gio-unix-2.0 \
cairo cairo-gobject
INCLUDEPATH += \
-I $$PWD/../.. \
-I ukui-settings-daemon/
SOURCES += \
housekeeping-manager.cpp \
housekeeping-plugin.cpp \
ldsm-trash-empty.cpp \
usd-disk-space.cpp \
usd-ldsm-dialog.cpp
HEADERS += \
housekeeping-manager.h \
housekeeping-plugin.h \
ldsm-trash-empty.h \
usd-disk-space.h \
usd-ldsm-dialog.h
housekeeping_lib.path = $${PLUGIN_INSTALL_DIRS}
housekeeping_lib.files = $$OUT_PWD/libhousekeeping.so
INSTALLS += housekeeping_lib
FORMS += \
ldsm-trash-empty.ui \
usd-ldsm-dialog.ui
RESOURCES += \
trash_empty.qrc
ukui-settings-daemon/plugins/housekeeping/usd-ldsm-dialog.h 0000664 0001750 0001750 00000005063 15174103014 023061 0 ustar feng feng /* -*- Mode: C++; indent-tabs-mode: nil; tab-width: 4 -*-
* -*- coding: utf-8 -*-
*
* Copyright (C) 2023 KylinSoft Co., Ltd.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*/
#ifndef USDLDSMDIALOG_H
#define USDLDSMDIALOG_H
#include
#include
#include
#include
#include
#include
#include "QGSettings/qgsettings.h"
#define SETTINGS_SCHEMA "org.ukui.SettingsDaemon.plugins.housekeeping"
#define SETTINGS_IGNORE_PATHS "ignore-paths"
#define LDSM_DIALOG_IGNORE 10
#define LDSM_DIALOG_RESPONSE_ANALYZE 30
#define LDSM_DIALOG_RESPONSE_EMPTY_TRASH 40
QT_BEGIN_NAMESPACE
namespace Ui { class LdsmDialog; }
QT_END_NAMESPACE
class LdsmDialog : public QDialog
{
Q_OBJECT
public:
LdsmDialog(QWidget *parent = nullptr);
LdsmDialog(bool other_usable_partitions,bool other_partitions,bool display_baobab,bool has_trash,
long space_remaining,QString partition_name,QString mount_path,
QWidget *parent = nullptr);
~LdsmDialog();
private:
Ui::LdsmDialog *ui;
QLabel* picture_label;
QLabel* primary_label;
QScrollArea *scroll_area;
QCheckBox* ignore_check_button;
QPushButton* trash_empty = nullptr;
QPushButton* ignore_button;
QPushButton* analyze_button;
QDialog* m_dialog;
QGSettings* m_fontSetting;
bool other_usable_partitions;
bool other_partitions;
bool has_trash;
long space_remaining;
/*char *partition_name;
char *mount_path;*/
QString partition_name;
QString mount_path;
public:
void checkButtonClicked(int);
void checkButtonIgnore ();
void checkButtonAnalyze ();
void checkButtonTrashEmpty();
public Q_SLOTS:
void updateText(QString key);
void resetFont(QWidget *pWid, QString str);
private:
void windowLayoutInit(bool display_baobab);
QString getPrimaryText();
QString getCheckButtonText();
void allConnectEvent(bool display_baobab);
};
#endif // USDLDSMDIALOG_H
ukui-settings-daemon/plugins/housekeeping/warning.png 0000664 0001750 0001750 00000000340 15174102667 022104 0 ustar feng feng PNG
IHDR g PLTEe-g tRNS @f IDATU
0P2ܙ%KQzD'SiQOeט =~(ؖ
-0i
((ZڑćȄ
14u(a}*Q8*3W