Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: 修复 Debug 模式下仍出现启动动画的问题 (#168 引入) #176

Merged
merged 1 commit into from
May 16, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
fix: 修复 Debug 模式下仍出现启动动画的问题 (#168 引入)
yixy-only committed May 15, 2024
commit 80bfd4b71dcade49915ee6be57f355fd51092958
11 changes: 10 additions & 1 deletion include/ege.h
Original file line number Diff line number Diff line change
@@ -815,7 +815,16 @@ bool EGEAPI getunicodecharmessage();
void EGEAPI setinitmode(int mode, int x = CW_USEDEFAULT, int y = CW_USEDEFAULT);
int EGEAPI getinitmode();
void EGEAPI initgraph(int width, int height, int mode);
void EGEAPI initgraph(int width, int height);

inline void EGEAPI initgraph(int width, int height)
{
#if !defined(NDEBUG) || defined(DEBUG) || defined(_DEBUG)
initgraph(width, height, getinitmode());
#else
initgraph(width, height, getinitmode() | INIT_WITHLOGO);
#endif
}

void EGEAPI initgraph(int* gdriver, int* gmode, const char* path);
void EGEAPI closegraph();
bool EGEAPI is_run();
9 changes: 0 additions & 9 deletions src/graphics.cpp
Original file line number Diff line number Diff line change
@@ -874,15 +874,6 @@ void initgraph(int width, int height, int mode)
initgraph(&g, &m, "");
}

void EGEAPI initgraph(int width, int height)
{
#if !defined(NDEBUG) || defined(DEBUG) || defined(_DEBUG)
initgraph(width, height, getinitmode());
#else
initgraph(width, height, getinitmode() | INIT_WITHLOGO);
#endif
}

void detectgraph(int* gdriver, int* gmode)
{
*gdriver = VGA;