summaryrefslogtreecommitdiff
path: root/save.pl
diff options
context:
space:
mode:
Diffstat (limited to 'save.pl')
-rw-r--r--save.pl11
1 files changed, 7 insertions, 4 deletions
diff --git a/save.pl b/save.pl
index a793e06..18c5b57 100644
--- a/save.pl
+++ b/save.pl
@@ -15,9 +15,7 @@ unlink(D) :->
:- pce_global(@editor, new(editor)).
:- pce_global(@browser, new(browser)).
:- pce_global(@save_button,
- new(button(save,
- message(@prolog, save),
- 'RET'))).
+ new(button(save, message(@prolog, save), 'RET'))).
main :-
pce_main_loop(main).
@@ -54,7 +52,12 @@ added(0) :-
refresh :-
send(@files, clear),
status(@files),
- send(@browser, members(@files)).
+ send(@browser, members(@files)),
+ get(@files, size, L),
+ ( L > 0
+ -> send(@save_button, status, active)
+ ; send(@save_button, sattus, inactive)
+ ).
status(C) :-
setup_call_cleanup(