Skip to content

Commit

Permalink
Cleanup code after last changes
Browse files Browse the repository at this point in the history
  • Loading branch information
piotrmacha committed May 27, 2024
1 parent c495d00 commit 942f0de
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 24 deletions.
2 changes: 1 addition & 1 deletion src/NH/Bass/Channel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ namespace NH::Bass
{
log->Error("Trying to acquire a non-available channel. We will allow that to not crash the game but the music may be funky.");
}
m_Status = ChannelStatus::PLAYING;
m_Status = ChannelStatus::ACQUIRED;
}

void Channel::Release()
Expand Down
14 changes: 2 additions & 12 deletions src/NH/Bass/Channel.h
Original file line number Diff line number Diff line change
@@ -1,22 +1,15 @@
#pragma once

#include "NH/Bass/CommonTypes.h"
#include "EventManager.h"
#include "NH/Logger.h"
#include <NH/Bass/MusicTheme.h>
#include <NH/Bass/IChannel.h>

#include <functional>


namespace NH::Bass
{
enum class ChannelStatus
{
AVAILABLE,
PLAYING,
FADING_OUT
};
enum class ChannelStatus { AVAILABLE, ACQUIRED };

class Channel : public IChannel
{
Expand Down Expand Up @@ -45,10 +38,7 @@ namespace NH::Bass

void Acquire() override;
void Release() override;
bool IsAvailable() override
{
return m_Status == ChannelStatus::AVAILABLE;
};
bool IsAvailable() override { return m_Status == ChannelStatus::AVAILABLE; };

private:
static void CALLBACK OnSlideVolumeSyncCallFunction(HSYNC, DWORD channel, DWORD data, void* userData);
Expand Down
9 changes: 0 additions & 9 deletions src/NH/Bass/CommonTypes.h

This file was deleted.

2 changes: 1 addition & 1 deletion src/NH/Bass/Engine.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#pragma once

#include "CommonTypes.h"
#include <bass.h>
#include "EventManager.h"
#include "Channel.h"
#include "NH/Logger.h"
Expand Down
1 change: 0 additions & 1 deletion src/NH/Bass/EventManager.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
#pragma once

#include "NH/Bass/CommonTypes.h"
#include "NH/Logger.h"
#include <NH/HashString.h>

Expand Down

0 comments on commit 942f0de

Please sign in to comment.