[baobab/reroot-view] Improve the scanning progress label
- From: Stefano Facchini <sfacchini src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [baobab/reroot-view] Improve the scanning progress label
- Date: Mon, 22 Jun 2020 15:25:45 +0000 (UTC)
commit f3c650d2e0097bfe67a4b2bc8409a529f04ab3ba
Author: Stefano Facchini <stefano facchini gmail com>
Date: Mon Jun 22 16:29:00 2020 +0200
Improve the scanning progress label
data/baobab.css | 4 ++++
data/ui/baobab-main-window.ui | 18 +++++++++++++++---
src/baobab-scanner.vala | 1 +
3 files changed, 20 insertions(+), 3 deletions(-)
---
diff --git a/data/baobab.css b/data/baobab.css
index 4070df6..44edd4a 100644
--- a/data/baobab.css
+++ b/data/baobab.css
@@ -63,6 +63,10 @@ window.background stack treeview:hover:not(:selected) {
background: @theme_bg_color;
}
+.scanning-label {
+ font-size: 150%;
+}
+
pathbar button {
transition: 0;
margin: 0;
diff --git a/data/ui/baobab-main-window.ui b/data/ui/baobab-main-window.ui
index a5a1e18..b1d6b3f 100644
--- a/data/ui/baobab-main-window.ui
+++ b/data/ui/baobab-main-window.ui
@@ -222,18 +222,30 @@
<child>
<object class="GtkGrid" id="scanning_page">
<property name="visible">True</property>
- <property name="orientation">vertical</property>
<property name="halign">center</property>
<property name="valign">center</property>
+ <style>
+ <class name="scanning-label"/>
+ <class name="dim-label"/>
+ </style>
<child>
- <object class="GtkLabel" id="scanning_label">
+ <object class="GtkLabel" id="scanning_label_front">
<property name="visible">True</property>
- <property name="label">Scanning…</property>
+ <property name="label" translatable="yes">In progress,</property>
</object>
</child>
<child>
<object class="GtkLabel" id="scanning_progress_label">
<property name="visible">True</property>
+ <property name="width_chars">8</property>
+ <property name="halign">end</property>
+ <property name="xalign">1.0</property>
+ </object>
+ </child>
+ <child>
+ <object class="GtkLabel" id="scanning_label_back">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes"> scanned so far</property>
</object>
</child>
</object>
diff --git a/src/baobab-scanner.vala b/src/baobab-scanner.vala
index 69d1fd9..1c3d07c 100644
--- a/src/baobab-scanner.vala
+++ b/src/baobab-scanner.vala
@@ -53,6 +53,7 @@ namespace Baobab {
public bool show_allocated_size { get; private set; }
+ // Used for progress reporting, should be updated whenever a new Results object is created
public uint64 total_size { get; private set; }
public int max_depth { get; protected set; }
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]