diff options
author | Vivien Kraus <vivien@planete-kraus.eu> | 2021-10-05 11:25:18 +0200 |
---|---|---|
committer | Vivien Kraus <vivien@planete-kraus.eu> | 2021-10-07 12:34:19 +0200 |
commit | 381a7d0399434aa277aa86a30e742ee215f2576a (patch) | |
tree | 561589e60e93420aa831eb180c378f0e0ec4170b /src/scm/webid-oidc/client/gui.scm | |
parent | dd18ea62055a95733db6c7bc507e01783e526858 (diff) |
gui: use the application API
Diffstat (limited to 'src/scm/webid-oidc/client/gui.scm')
-rw-r--r-- | src/scm/webid-oidc/client/gui.scm | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/src/scm/webid-oidc/client/gui.scm b/src/scm/webid-oidc/client/gui.scm index 29bf556..3fbd291 100644 --- a/src/scm/webid-oidc/client/gui.scm +++ b/src/scm/webid-oidc/client/gui.scm @@ -37,6 +37,7 @@ #:use-module (webid-oidc client accounts) #:use-module ((webid-oidc client gui settings) #:prefix settings:) #:use-module ((webid-oidc client gui application) #:prefix app:) + #:use-module (webid-oidc client gui application-hooks) #:use-module ((webid-oidc cache) #:prefix cache:) #:use-module ((webid-oidc catalog) #:prefix catalog:) #:use-module (web uri) @@ -58,15 +59,9 @@ (use-typelibs (("Gio" "2.0") #:renamer (protect 'application:new)) ("Gtk" "3.0")) -(add-hook! settings:client-changed-hook - (lambda (client) - (format #t (G_ "The client changed: it is now ~a.\n") client) - ((@ (webid-oidc client) client) client))) - -(add-hook! settings:accounts-changed-hook - (lambda (main other) - (format #t (G_ "The accounts changed: the main account is ~a, and the others are ~a.\n") - main other))) +(add-hook! application-state-changed-hook + (lambda (state) + (format #t (G_ "The application state changed: it is now ~a.\n") state))) (define (main) (parameterize ((p:anonymous-http-request (@ (web client) http-request))) |