!111 feat: 清除QtWebCore的缓存

* Merge remote-tracking branch 'upstream/dev' into dev
* Merge branch 'dev' of gitee.com:uniartisan2018/spark-store into dev
* feat: 清除网页缓存
* 文案修改
* update src/widget.ui.
* feat: 星火应用商店检测更新
This commit is contained in:
2022-09-03 09:25:19 +00:00
committed by shenmo
parent af89e64478
commit 9e4df5c5c2
3 changed files with 45 additions and 27 deletions

View File

@@ -1148,6 +1148,16 @@ void Widget::on_pushButton_clear_clicked() // 清空临时缓存目录
}); });
} }
void Widget::on_pushButton_clearWebCache_clicked()
{
QtConcurrent::run([=]()
{
QString dataLocal = QStandardPaths::writableLocation(QStandardPaths::AppLocalDataLocation);
QDir cacheDir(dataLocal );
cacheDir.removeRecursively(); });
}
quint64 Widget::dirFileSize(const QString &path) quint64 Widget::dirFileSize(const QString &path)
{ {
QDir dir(path); QDir dir(path);

View File

@@ -91,6 +91,7 @@ private slots:
void on_pushButton_updateApt_clicked(); void on_pushButton_updateApt_clicked();
void on_pushButton_uninstall_clicked(); void on_pushButton_uninstall_clicked();
void on_pushButton_clear_clicked(); void on_pushButton_clear_clicked();
void on_pushButton_clearWebCache_clicked();
void on_pushButton_website_clicked(); void on_pushButton_website_clicked();
void on_pushButton_clicked(); void on_pushButton_clicked();
void on_btn_openDir_clicked(); void on_btn_openDir_clicked();

View File

@@ -345,7 +345,7 @@
<number>0</number> <number>0</number>
</property> </property>
<property name="currentIndex"> <property name="currentIndex">
<number>2</number> <number>3</number>
</property> </property>
<widget class="QWidget" name="page"> <widget class="QWidget" name="page">
<layout class="QVBoxLayout" name="verticalLayout_4"> <layout class="QVBoxLayout" name="verticalLayout_4">
@@ -489,7 +489,7 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>903</width> <width>889</width>
<height>849</height> <height>849</height>
</rect> </rect>
</property> </property>
@@ -993,8 +993,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>869</width> <width>851</width>
<height>325</height> <height>324</height>
</rect> </rect>
</property> </property>
<layout class="QHBoxLayout" name="horizontalLayout_4"> <layout class="QHBoxLayout" name="horizontalLayout_4">
@@ -1123,8 +1123,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>738</width> <width>889</width>
<height>886</height> <height>716</height>
</rect> </rect>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout_23"> <layout class="QVBoxLayout" name="verticalLayout_23">
@@ -1285,7 +1285,31 @@
<item> <item>
<widget class="QWidget" name="widget_10" native="true"> <widget class="QWidget" name="widget_10" native="true">
<layout class="QGridLayout" name="gridLayout_4"> <layout class="QGridLayout" name="gridLayout_4">
<item row="0" column="3"> <item row="2" column="0" colspan="5">
<widget class="QLabel" name="label_12">
<property name="styleSheet">
<string notr="true">color:#808080</string>
</property>
<property name="text">
<string>Since the dictionary is at /tmp,It would be cleaned automatically when system reboot.</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QLabel" name="tmp_size_ui">
<property name="text">
<string>0B</string>
</property>
</widget>
</item>
<item row="0" column="0" colspan="2">
<widget class="QLabel" name="label_11">
<property name="text">
<string>Location/tmp/spark-store</string>
</property>
</widget>
</item>
<item row="0" column="4">
<spacer name="horizontalSpacer_5"> <spacer name="horizontalSpacer_5">
<property name="orientation"> <property name="orientation">
<enum>Qt::Horizontal</enum> <enum>Qt::Horizontal</enum>
@@ -1305,16 +1329,6 @@
</property> </property>
</widget> </widget>
</item> </item>
<item row="2" column="0" colspan="4">
<widget class="QLabel" name="label_12">
<property name="styleSheet">
<string notr="true">color:#808080</string>
</property>
<property name="text">
<string>Since the dictionary is at /tmp,It would be cleaned automatically when system reboot.</string>
</property>
</widget>
</item>
<item row="1" column="0"> <item row="1" column="0">
<widget class="QLabel" name="label_13"> <widget class="QLabel" name="label_13">
<property name="maximumSize"> <property name="maximumSize">
@@ -1328,17 +1342,10 @@
</property> </property>
</widget> </widget>
</item> </item>
<item row="1" column="1"> <item row="0" column="3">
<widget class="QLabel" name="tmp_size_ui"> <widget class="QPushButton" name="pushButton_clearWebCache">
<property name="text"> <property name="text">
<string>0B</string> <string>Clear Web Cache</string>
</property>
</widget>
</item>
<item row="0" column="0" colspan="2">
<widget class="QLabel" name="label_11">
<property name="text">
<string>Location/tmp/spark-store</string>
</property> </property>
</widget> </widget>
</item> </item>