Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
SRB2
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
STJr
SRB2
Commits
cc026cf5
Commit
cc026cf5
authored
2 months ago
by
Alam Ed Arias
Browse files
Options
Downloads
Patches
Plain Diff
Emscripten: disable TERMIOS support
parent
538f1b69
Branches
Branches containing commit
No related tags found
1 merge request
!2658
WASM port
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/sdl/i_system.c
+11
-0
11 additions, 0 deletions
src/sdl/i_system.c
with
11 additions
and
0 deletions
src/sdl/i_system.c
+
11
−
0
View file @
cc026cf5
...
@@ -103,6 +103,10 @@ typedef LPVOID (WINAPI *p_MapViewOfFile) (HANDLE, DWORD, DWORD, DWORD, SIZE_T);
...
@@ -103,6 +103,10 @@ typedef LPVOID (WINAPI *p_MapViewOfFile) (HANDLE, DWORD, DWORD, DWORD, SIZE_T);
#endif
#endif
#endif
#endif
#ifdef __EMSCRIPTEN__
#undef HAVE_TERMIOS // do not read on /dev/tty, JavaScript alert() are blocking
#endif
#if defined(UNIXCOMMON)
#if defined(UNIXCOMMON)
#include
<poll.h>
#include
<poll.h>
#endif
#endif
...
@@ -799,6 +803,11 @@ static inline void I_StartupConsole(void)
...
@@ -799,6 +803,11 @@ static inline void I_StartupConsole(void)
framebuffer
=
M_CheckParm
(
"-framebuffer"
);
framebuffer
=
M_CheckParm
(
"-framebuffer"
);
#ifdef __EMSCRIPTEN__
framebuffer
=
SDL_FALSE
;
consolevent
=
SDL_TRUE
;
#endif
if
(
framebuffer
)
if
(
framebuffer
)
consolevent
=
SDL_FALSE
;
consolevent
=
SDL_FALSE
;
}
}
...
@@ -972,7 +981,9 @@ void I_OutputMsg(const char *fmt, ...)
...
@@ -972,7 +981,9 @@ void I_OutputMsg(const char *fmt, ...)
#endif
#endif
if
(
!
framebuffer
)
if
(
!
framebuffer
)
{
fprintf
(
stderr
,
"%s"
,
txt
);
fprintf
(
stderr
,
"%s"
,
txt
);
}
#ifdef HAVE_TERMIOS
#ifdef HAVE_TERMIOS
if
(
consolevent
&&
txt
[
len
-
1
]
==
'\n'
)
if
(
consolevent
&&
txt
[
len
-
1
]
==
'\n'
)
{
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment