[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
154/197: installer: Main page: Redisplay translatable strings upon refre
From: |
Danny Milosavljevic |
Subject: |
154/197: installer: Main page: Redisplay translatable strings upon refresh. |
Date: |
Mon, 3 Jul 2017 20:37:17 -0400 (EDT) |
dannym pushed a commit to branch wip-installer-2
in repository guix.
commit ddf5617aef028f1e233b8378f3b86c8413efc0f8
Author: John Darrington <address@hidden>
Date: Mon Jan 30 11:57:24 2017 +0100
installer: Main page: Redisplay translatable strings upon refresh.
* gnu/system/installer/guixsd-installer.scm (main-page-refresh): Add
display of translatable strings. (main-page-init): Remove display of
translatable strings.
---
gnu/system/installer/guixsd-installer.scm | 50 ++++++++++++++++++++-----------
1 file changed, 32 insertions(+), 18 deletions(-)
diff --git a/gnu/system/installer/guixsd-installer.scm
b/gnu/system/installer/guixsd-installer.scm
index 0aa5582..3674944 100644
--- a/gnu/system/installer/guixsd-installer.scm
+++ b/gnu/system/installer/guixsd-installer.scm
@@ -229,18 +229,38 @@ tail of the list."
(main-menu (make-menu main-options
#:disp-proc (lambda (datum row)
- (format #f "~a"
- (task-title (cdr
datum)))))))
+ (gettext (task-title (cdr
datum)))))))
- (addstr* text-window (format #f
- (gettext
- "To start the complete installation process, choose ~s. Alternatively,
you may run each step individually for a slower, more controlled experience.")
installation-menu-title))
(page-set-wwin! page frame)
(page-set-datum! page 'menu main-menu)
+ (page-set-datum! page 'text-window text-window)
+ (page-set-datum! page 'background background)
(menu-post main-menu win)
- (push-cursor (page-cursor-visibility page))
+ (push-cursor (page-cursor-visibility page))))
+
+
+(define (main-page-refresh page)
+ (when (not (page-initialised? page))
+ (main-page-init page)
+ (page-set-initialised! page #t))
+
+ (let ((text-window (page-datum page 'text-window))
+ (menu (page-datum page 'menu))
+ (background (page-datum page 'background)))
+
+ (clear background)
+
+ (addstr*
+ text-window
+ (format
+ #f
+ (gettext
+ "To start the complete installation process, choose ~s. Alternatively,
you may run each step individually for a slower, more controlled experience.")
+ (gettext installation-menu-title)))
+
+
;; Do the key action labels
(let ((ypos (1- (getmaxy background)))
(str0 (gettext "Get a Shell <F1>"))
@@ -252,19 +272,13 @@ tail of the list."
(truncate (/ (- (getmaxx background)
(string-length str1)) 2)))
(addstr background str2 #:y ypos #:x
- (- (getmaxx background) (string-length str2))))))
-
-
-(define (main-page-refresh page)
- (when (not (page-initialised? page))
- (main-page-init page)
- (page-set-initialised! page #t))
+ (- (getmaxx background) (string-length str2))))
- (touchwin (outer (page-wwin page)))
- (refresh* (outer (page-wwin page)))
- (refresh* (inner (page-wwin page)))
- (menu-redraw (page-datum page 'menu))
- (menu-refresh (page-datum page 'menu)))
+ (touchwin (outer (page-wwin page)))
+ (refresh* (outer (page-wwin page)))
+ (refresh* (inner (page-wwin page)))
+ (menu-redraw menu)
+ (menu-refresh menu)))
(define-public (guixsd-installer)
- 125/197: installer: Do not assume the root file system is of type "ext4"., (continued)
- 125/197: installer: Do not assume the root file system is of type "ext4"., Danny Milosavljevic, 2017/07/03
- 130/197: installer: Delete unused procedure "justify"., Danny Milosavljevic, 2017/07/03
- 134/197: installer: Tolerate an undefined system role in config generation., Danny Milosavljevic, 2017/07/03
- 137/197: installer: Prepare for new wireless network features., Danny Milosavljevic, 2017/07/03
- 140/197: installer: Fix the key map option., Danny Milosavljevic, 2017/07/03
- 132/197: installer: Add new procedure to check file system specifications., Danny Milosavljevic, 2017/07/03
- 145/197: gurses: Avoid yet another use of car and cdr., Danny Milosavljevic, 2017/07/03
- 129/197: installer: Emphasise that writing filesystems destroys existing data., Danny Milosavljevic, 2017/07/03
- 150/197: gurses: Reimplement pad-complex-string., Danny Milosavljevic, 2017/07/03
- 159/197: installer: Fix i18n in dialogs., Danny Milosavljevic, 2017/07/03
- 154/197: installer: Main page: Redisplay translatable strings upon refresh.,
Danny Milosavljevic <=
- 157/197: installer: Replace 'file-browser' with 'key-map'., Danny Milosavljevic, 2017/07/03
- 161/197: installer: Improve i18n in ping page., Danny Milosavljevic, 2017/07/03
- 162/197: gurses: Avoid one use of car/cdr., Danny Milosavljevic, 2017/07/03
- 166/197: installer: Provide verbose description of locale., Danny Milosavljevic, 2017/07/03
- 167/197: installer: Fix bug when changing languages., Danny Milosavljevic, 2017/07/03
- 156/197: installer: New page to select language., Danny Milosavljevic, 2017/07/03
- 168/197: installer: Fix the startup locale., Danny Milosavljevic, 2017/07/03
- 173/197: installer: Remove whitespace., Danny Milosavljevic, 2017/07/03
- 01/197: gnu: Add graphical installer, Danny Milosavljevic, 2017/07/03
- 174/197: installer: Provide the ability to add new users., Danny Milosavljevic, 2017/07/03