mirror of
https://github.com/xpipe-io/xpipe.git
synced 2024-11-21 23:20:23 +00:00
Fix status bar gc
This commit is contained in:
parent
0646aedaf9
commit
4df4a7572f
1 changed files with 3 additions and 2 deletions
|
@ -7,6 +7,7 @@ import io.xpipe.app.fxcomps.SimpleComp;
|
|||
import io.xpipe.app.fxcomps.SimpleCompStructure;
|
||||
import io.xpipe.app.fxcomps.augment.ContextMenuAugment;
|
||||
import io.xpipe.app.fxcomps.impl.LabelComp;
|
||||
import io.xpipe.app.fxcomps.util.BindingsHelper;
|
||||
import io.xpipe.app.fxcomps.util.PlatformThread;
|
||||
import io.xpipe.app.util.HumanReadableFormat;
|
||||
import javafx.beans.binding.Bindings;
|
||||
|
@ -55,7 +56,7 @@ public class BrowserStatusBarComp extends SimpleComp {
|
|||
model.getProgress().getValue().getTotal(), true);
|
||||
},
|
||||
model.getProgress()));
|
||||
var progressComp = new LabelComp(Bindings.createStringBinding(
|
||||
var progressComp = new LabelComp(BindingsHelper.persist(Bindings.createStringBinding(
|
||||
() -> {
|
||||
if (model.getProgress().getValue() == null
|
||||
|| model.getProgress().getValue().done()) {
|
||||
|
@ -69,7 +70,7 @@ public class BrowserStatusBarComp extends SimpleComp {
|
|||
},
|
||||
transferredCount,
|
||||
allCount,
|
||||
model.getProgress()));
|
||||
model.getProgress())));
|
||||
return progressComp;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue