Skip to content
This repository has been archived by the owner on Feb 11, 2021. It is now read-only.

Commit

Permalink
Backed out changeset 3f487d7d2d1d
Browse files Browse the repository at this point in the history
This breaks applications.
  • Loading branch information
icculus committed Aug 8, 2013
1 parent eb8ec67 commit f79d823
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
7 changes: 7 additions & 0 deletions src/events/SDL_windowevents.c
Expand Up @@ -197,6 +197,13 @@ SDL_SendWindowEvent(SDL_Window * window, Uint8 windowevent, int data1,
posted = (SDL_PushEvent(&event) > 0);
}

if (windowevent == SDL_WINDOWEVENT_CLOSE) {
if ( !window->prev && !window->next ) {
/* This is the last window in the list so send the SDL_QUIT event */
SDL_SendQuit();
}
}

return (posted);
}

Expand Down
5 changes: 0 additions & 5 deletions src/video/SDL_video.c
Expand Up @@ -2210,11 +2210,6 @@ SDL_DestroyWindow(SDL_Window * window)
}

SDL_free(window);

if (_this->windows == NULL) {
/* This is the last window in the list so send the SDL_QUIT event */
SDL_SendQuit();
}
}

SDL_bool
Expand Down

0 comments on commit f79d823

Please sign in to comment.