Skip to content

Commit

Permalink
all: Allow to build with CLANG in cl mode
Browse files Browse the repository at this point in the history
  • Loading branch information
dimhotepus committed Jun 27, 2024
1 parent 57327c7 commit d640714
Show file tree
Hide file tree
Showing 12 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions bink_media_player/main.cc
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ bool MoveToMainDisplayCenter(_In_ HWND window,
*/
void ToggleFullscreenWindow(_In_ HWND window, _In_ DWORD default_window_style) {
static WINDOWPLACEMENT previous_window_placement{
sizeof(previous_window_placement), 0U, 0U};
sizeof(previous_window_placement), 0U, 0U, {}, {}, {}};

BINK_DCHECK(!!window);

Expand Down Expand Up @@ -249,7 +249,7 @@ LRESULT WINAPI WindowProc(HWND window, UINT message, WPARAM wParam,
*/
[[nodiscard]] HWND CreateBinkWindow(_In_ HINSTANCE instance,
_In_z_ LPCSTR cmd_line) noexcept {
WNDCLASS wc = {0};
WNDCLASS wc = {};
// Handle resizes in WM_PAINT.
wc.style = CS_OWNDC | CS_VREDRAW | CS_HREDRAW;
wc.lpfnWndProc = WindowProc;
Expand Down Expand Up @@ -341,7 +341,7 @@ int WINAPI WinMain(_In_ HINSTANCE instance, _In_opt_ HINSTANCE,
std::optional{std::move(*bink_media_player_result)};
bink_media_player_host.swap(maybe_bink_media_player);

bink::BinkMediaInfo media_info = {0};
bink::BinkMediaInfo media_info = {};
if (!bink_media_player_host->GetMediaInfo(media_info)) {
::MessageBoxA(window, "Unable to get media info.",
"Bink Media Player - Media Open Error", MB_OK | MB_ICONSTOP);
Expand Down
2 changes: 1 addition & 1 deletion bink_media_player/scoped_timer_resolution.h
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ class ScopedTimerResolution {
unsigned error_code_;

#ifdef _WIN64
std::byte pad_[sizeof(char *) - sizeof(error_code_)]; //-V730_NOINIT
[[maybe_unused]] std::byte pad_[sizeof(char *) - sizeof(error_code_)]; //-V730_NOINIT
#endif

/**
Expand Down
2 changes: 1 addition & 1 deletion binkmp/bink_media_player.h
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ class BinkMediaPlayer : public IBinkMediaPlayer {
* @param height New height.
* @return true on success, false on failure.
*/
bool SetWindowScale(unsigned width, unsigned height) const noexcept {
bool SetWindowScale(unsigned width, unsigned height) const noexcept override {
const auto [new_width, new_height] = FindClosestScale(width, height);
return bink_buffer_.SetWindowScale(new_width, new_height);
}
Expand Down
2 changes: 1 addition & 1 deletion binkmp/ibink_media_player.cc
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@

namespace bink {

IBinkMediaPlayer::~IBinkMediaPlayer() {}
IBinkMediaPlayer::~IBinkMediaPlayer() noexcept {}

} // namespace bink
Binary file modified binkw/binkw.cc
Binary file not shown.
Binary file modified binkw/dllmain.cc
Binary file not shown.
Binary file modified binkw/stdafx.cc
Binary file not shown.
Binary file modified binkw/stdafx.h
Binary file not shown.
Binary file modified binkw/targetver.h
Binary file not shown.
Binary file modified mss/dllmain.cc
Binary file not shown.
Binary file modified mss/mss.cc
Binary file not shown.
Binary file modified mss/targetver.h
Binary file not shown.

0 comments on commit d640714

Please sign in to comment.