projects
/
rocksndiamonds.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
22d5ea0
)
prepared some functions for empty scores list
author
Holger Schemel
<info@artsoft.org>
Fri, 18 Feb 2022 17:28:59 +0000
(18:28 +0100)
committer
Holger Schemel
<info@artsoft.org>
Fri, 18 Feb 2022 17:28:59 +0000
(18:28 +0100)
src/screens.c
patch
|
blob
|
history
diff --git
a/src/screens.c
b/src/screens.c
index ba5b21c85ba888598e766c76538df146fedef136..68b8c08497c440eff6c9c17de81e124d4d2f409c 100644
(file)
--- a/
src/screens.c
+++ b/
src/screens.c
@@
-4816,7
+4816,7
@@
static void DrawChooseTree(TreeInfo **ti_ptr)
if (CheckFadeAll())
fade_mask = REDRAW_ALL;
if (CheckFadeAll())
fade_mask = REDRAW_ALL;
- if (strEqual((*ti_ptr)->subdir, STRING_TOP_DIRECTORY))
+ if (
*ti_ptr != NULL &&
strEqual((*ti_ptr)->subdir, STRING_TOP_DIRECTORY))
{
if (game_status == GAME_MODE_SETUP)
{
{
if (game_status == GAME_MODE_SETUP)
{
@@
-5080,7
+5080,7
@@
static void HandleChooseTree(int mx, int my, int dx, int dy, int button,
int sx1_edit_name = getChooseTreeEditXPos(POS_LEFT);
int sx2_edit_name = getChooseTreeEditXPos(POS_RIGHT);
int x = 0;
int sx1_edit_name = getChooseTreeEditXPos(POS_LEFT);
int sx2_edit_name = getChooseTreeEditXPos(POS_RIGHT);
int x = 0;
- int y =
ti->cl_cursor
;
+ int y =
(ti != NULL ? ti->cl_cursor : 0)
;
int step = (button == 1 ? 1 : button == 2 ? 5 : 10);
int num_entries = numTreeInfoInGroup(ti);
int num_page_entries = MIN(num_entries, NUM_MENU_ENTRIES_ON_SCREEN);
int step = (button == 1 ? 1 : button == 2 ? 5 : 10);
int num_entries = numTreeInfoInGroup(ti);
int num_page_entries = MIN(num_entries, NUM_MENU_ENTRIES_ON_SCREEN);