Skip to content

Commit e02759c

Browse files
committed
[1.0.0] Add help text for editing prefs
1 parent bdb076c commit e02759c

File tree

3 files changed

+34
-7
lines changed

3 files changed

+34
-7
lines changed

makefiles/custom-atari.mk

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,10 +54,10 @@ ALTIRRA ?= $(ALTIRRA_HOME)/Altirra64.exe \
5454
$(XS)/portable $(XS)/portablealt:altirra-debug.ini \
5555
$(XS)/debug \
5656
$(XS)/debugcmd: ".loadsym build\$(PROGRAM_TGT).lbl" \
57-
$(XS)/debugcmd: "bp kb_global" \
5857

58+
# $(XS)/debugcmd: "bp kb_global" \
5959
# $(XS)/debugcmd: "bp debug" \
60-
# $(XS)/debugcmd: "ba w mw_setting_up" \
60+
# $(XS)/debugcmd: "ba w mw_setting_up" \
6161
6262
ATARI800 ?= $(ATARI800_HOME)/atari800 \
6363
-xl -nobasic -ntsc -xl-rev custom -config atari800-debug.cfg -run

src/atari/full/modules/mod_info/mi_edit_preferences.s

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,22 @@
11
.export _mi_edit_preferences
22

33
.import _bar_setcolor
4+
.import _clr_help
45
.import _cng_prefs
56
.import _just_rts
67
.import _kb_get_c_ucase
78
.import _pmg_space_left
89
.import _pmg_space_right
10+
.import _put_help
911
.import _put_s
1012
.import _scr_highlight_line
1113
.import _write_prefs
1214
.import get_scrloc
1315
.import hexb
1416
.import mi_selected
1517
.import mi_set_pmg_widths
18+
.import mx_h1
19+
.import mx_pref_edit_help
1620
.import pusha
1721
.import temp_num
1822

@@ -38,7 +42,7 @@
3842
jsr display_pref
3943
jsr edit_start
4044

41-
; TODO: change the HELP to "up/down edit, return accept, esc exit"
45+
put_help #0, #mx_pref_edit_help
4246

4347
; now, start a mini keyboard routine that checks for 4 keys, and manipulates the current value
4448
; we can use _cng_prefs + mi_selected as the value we are editing, as the screen has same order as the structure.
@@ -123,6 +127,9 @@ not_up:
123127
jsr display_pref
124128
jsr enact_pref_change ; reset colours to previous values
125129
jsr mi_set_pmg_widths ; set the widths back to normal
130+
jsr reset_help
131+
lda _cng_prefs + CNG_PREFS_DATA::bar_conn
132+
sta bar_colour
126133
jmp change_bar_colour
127134

128135
not_esc:
@@ -143,6 +150,7 @@ not_esc:
143150
jsr _write_prefs ; save them
144151
jsr mi_set_pmg_widths ; set the widths back to normal
145152

153+
jsr reset_help
146154
lda _cng_prefs + CNG_PREFS_DATA::bar_conn
147155
sta bar_colour
148156
jmp change_bar_colour
@@ -162,6 +170,12 @@ copy_pref_to_temp:
162170
sta pref_copy
163171
rts
164172

173+
reset_help:
174+
jsr _clr_help
175+
pusha #0
176+
setax #mx_h1
177+
jmp _put_help
178+
165179
.endproc
166180

167181

src/atari/full/screen/mod_screen_data.s

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
.export mh_s1, mh_s2, mh_h1
22
.export md_s1, md_s2, md_h1
33
.export mw_s1, mw_s2, mw_h1, mw_h2, mw_help_setup, mw_help_password, mw_custom_msg, mw_help_custom
4-
.export mx_s1, mx_s2, mx_h1
4+
.export mx_s1, mx_s2, mx_h1, mx_pref_edit_help
55
.export mx_k_app_name, mx_v_app_name
66
.export mx_k_version, mx_v_version
77
.export mx_k_bank_cnt
@@ -37,7 +37,7 @@ mh_s2:
3737
NORMAL_CHARMAP
3838
.byte $81, $1e, $82
3939
INVERT_ATASCII
40-
.byte "Info Drive Slots"
40+
.byte "Prefs Drive Slots"
4141
NORMAL_CHARMAP
4242
.byte $81, $1f, $82, 0
4343

@@ -91,7 +91,7 @@ mw_s2:
9191
NORMAL_CHARMAP
9292
.byte $81, $1e, $82
9393
INVERT_ATASCII
94-
.byte "Drive Slots Info"
94+
.byte "Drive Slots Prefs"
9595
NORMAL_CHARMAP
9696
.byte $81, $1f, $82, 0
9797

@@ -155,7 +155,7 @@ mw_custom_msg:
155155
.byte "<Custom SSID>", 0
156156

157157
; ------------------------------------------------------------------
158-
; Mod DONE data
158+
; Mod INFO data
159159
; ------------------------------------------------------------------
160160
mx_s1:
161161
INVERT_ATASCII
@@ -184,6 +184,19 @@ mx_h1:
184184
.byte "Edit ", 0
185185
NORMAL_CHARMAP
186186

187+
mx_pref_edit_help:
188+
NORMAL_CHARMAP
189+
.byte $81, $1c, $1d, $82 ; endL up down endR
190+
INVERT_ATASCII
191+
.byte "Inc/Dec"
192+
NORMAL_CHARMAP
193+
.byte $81, "Ret", $82
194+
INVERT_ATASCII
195+
.byte "Select"
196+
NORMAL_CHARMAP
197+
.byte $81, "ESC", $82
198+
INVERT_ATASCII
199+
.byte "Exit", 0
187200

188201

189202
NORMAL_CHARMAP

0 commit comments

Comments
 (0)