Skip to content

Commit

Permalink
Fix loss of mouse focus for external automap again
Browse files Browse the repository at this point in the history
Plus a couple other tweaks.
  • Loading branch information
bradharding committed Mar 13, 2022
1 parent cd0f6ea commit ec9cf4d
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 7 deletions.
2 changes: 0 additions & 2 deletions src/c_autocomplete.c
Original file line number Diff line number Diff line change
Expand Up @@ -7780,11 +7780,9 @@ autocomplete_t autocompletelist[] =
{ "name friendly archvile ", DOOM2ONLY },
{ "name friendly baronofhell ", DOOM1AND2 },
{ "name friendly cacodemon ", DOOM1AND2 },
{ "name friendly cacodemon Hissy", DOOM1AND2 },
{ "name friendly chaingunner ", DOOM2ONLY },
{ "name friendly cyberdemon ", DOOM1AND2 },
{ "name friendly dog ", DOOM1AND2 },
{ "name friendly dog Sascha", DOOM1AND2 },
{ "name friendly hellknight ", DOOM2ONLY },
{ "name friendly imp ", DOOM1AND2 },
{ "name friendly lostsoul ", DOOM1AND2 },
Expand Down
4 changes: 2 additions & 2 deletions src/c_cmds.c
Original file line number Diff line number Diff line change
Expand Up @@ -4588,8 +4588,8 @@ static void name_cmd_func2(char *cmd, char *parms)
{
M_StripQuotes(namecmdnew);

C_PlayerMessage("The %s%s nearest to %s has been %s " BOLD("%s") ".",
(namecmdfriendly ? "friendly " : ""), namecmdold, playername, (*bestmobj->name ? "renamed" : "named"), namecmdnew);
C_PlayerMessage("The nearest %s%s has been %s " BOLD("%s") ".",
(namecmdfriendly ? "friendly " : ""), namecmdold, (*bestmobj->name ? "renamed" : "named"), namecmdnew);

M_StringCopy(bestmobj->name, namecmdnew, sizeof(bestmobj->name));
}
Expand Down
3 changes: 3 additions & 0 deletions src/i_video.c
Original file line number Diff line number Diff line change
Expand Up @@ -2032,6 +2032,9 @@ void I_InitGraphics(void)
I_SDLError(SDL_SetHintWithPriority);
#endif

if (!(SDL_SetHintWithPriority(SDL_HINT_MOUSE_RELATIVE_MODE_WARP, "1", SDL_HINT_OVERRIDE)))
I_SDLError(SDL_SetHintWithPriority);

SetVideoMode(true, true);

if (vid_fullscreen)
Expand Down
8 changes: 5 additions & 3 deletions src/midifile.c
Original file line number Diff line number Diff line change
Expand Up @@ -433,9 +433,11 @@ midi_track_iter_t *MIDI_IterateTrack(midi_file_t *file, unsigned int track)

assert(track < file->num_tracks);

iter = malloc(sizeof(*iter));
iter->track = &file->tracks[track];
iter->position = 0;
if ((iter = malloc(sizeof(*iter))))
{
iter->track = &file->tracks[track];
iter->position = 0;
}

return iter;
}
Expand Down

0 comments on commit ec9cf4d

Please sign in to comment.