[haiku-commits] haiku: hrev54824 - src/apps/bootmanager

  • From: Adrien Destugues <pulkomandy@xxxxxxxxx>
  • To: haiku-commits@xxxxxxxxxxxxx
  • Date: Wed, 30 Dec 2020 08:36:06 -0500 (EST)

hrev54824 adds 1 changeset to branch 'master'
old head: a7375336a643c9a698f32b13c3ca3ed33d4ce801
new head: 786f0456666788716ad1198843c28f5dae2cb8c8
overview: 
https://git.haiku-os.org/haiku/log/?qt=range&q=786f04566667+%5Ea7375336a643

----------------------------------------------------------------------------

786f04566667: BootManager: add support for page down/up/home/end keys
  
  * Page down is the same as the end key, and just selects the last entry
    in the boot menu.
  * Likewise, page up is the same as the home key.
  
  Change-Id: Ibaf8559b0f68462834395aaec8fb22554d7a90f6
  Reviewed-on: https://review.haiku-os.org/c/haiku/+/3555
  Reviewed-by: John Scipione <jscipione@xxxxxxxxx>
  Reviewed-by: Jérôme Duval <jerome.duval@xxxxxxxxx>

                                   [ Axel Dörfler <axeld@xxxxxxxxxxxxxxxx> ]

----------------------------------------------------------------------------

Revision:    hrev54824
Commit:      786f0456666788716ad1198843c28f5dae2cb8c8
URL:         https://git.haiku-os.org/haiku/commit/?id=786f04566667
Author:      Axel Dörfler <axeld@xxxxxxxxxxxxxxxx>
Date:        Tue Dec 29 17:31:30 2020 UTC
Committer:   Adrien Destugues <pulkomandy@xxxxxxxxx>
Commit-Date: Wed Dec 30 13:36:01 2020 UTC

----------------------------------------------------------------------------

1 file changed, 25 insertions(+)
src/apps/bootmanager/bootman.S | 25 +++++++++++++++++++++++++

----------------------------------------------------------------------------

diff --git a/src/apps/bootmanager/bootman.S b/src/apps/bootmanager/bootman.S
index b296035844..b586d1fc51 100644
--- a/src/apps/bootmanager/bootman.S
+++ b/src/apps/bootmanager/bootman.S
@@ -134,6 +134,10 @@
 ; Key codes
 %assign KEY_DOWN                                               0x50
 %assign KEY_UP                                                 0x48
+%assign KEY_PAGE_DOWN                                  0x51
+%assign KEY_PAGE_UP                                            0x49
+%assign KEY_HOME                                               0x47
+%assign KEY_END                                                        0x4f
 %assign KEY_RETURN                                             0x1C
 
 ; Modifier key bitmasks
@@ -431,9 +435,19 @@ inputLoop:
        cmp             ah, KEY_DOWN
        je              selectNextPartition
 
+       cmp             ah, KEY_PAGE_DOWN
+       je              selectLastPartition
+       cmp             ah, KEY_END
+       je              selectLastPartition
+
        cmp             ah, KEY_UP
        je              selectPreviousPartition
 
+       cmp             ah, KEY_PAGE_UP
+       je              selectFirstPartition
+       cmp             ah, KEY_HOME
+       je              selectFirstPartition
+
        cmp             ah, KEY_RETURN
        jne             inputLoop
        jmp             bootSelectedPartition
@@ -448,6 +462,12 @@ selectNextPartition:
        mov             [bp + selection], ax
        jmp             mainLoop
 
+selectLastPartition:
+       mov             ax, [listItemCount]
+       dec             ax
+       mov             [bp + selection], ax
+       jmp             mainLoop
+
 selectPreviousPartition:
        mov             ax, [bp + selection]
        or              ax, ax
@@ -458,6 +478,11 @@ selectPreviousPartition:
        mov             [bp + selection], ax
        jmp             mainLoop
 
+selectFirstPartition:
+       xor             ax, ax
+       mov             [bp + selection], ax
+       jmp             mainLoop
+
 
 ; ======================= Print the OS list ============================
 printMenu:


Other related posts:

  • » [haiku-commits] haiku: hrev54824 - src/apps/bootmanager - Adrien Destugues