Skip to content

Commit

Permalink
Fixed typo in the function pointer declaration
Browse files Browse the repository at this point in the history
  • Loading branch information
Wohlstand committed Oct 26, 2022
1 parent 75608c7 commit 5c83bca
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions include/adlmidi.h
Original file line number Diff line number Diff line change
Expand Up @@ -1309,7 +1309,7 @@ typedef void (*ADL_DebugMessageHook)(void *userdata, const char *fmt, ...);
* @brief Loop start/end point reach hook
* @param userdata Pointer to user data (usually, context of someting)
*/
typedef void (*ASL_LoopPointHook)(void *userdata);
typedef void (*ADL_LoopPointHook)(void *userdata);

/**
* @brief Set raw MIDI event hook
Expand Down Expand Up @@ -1361,7 +1361,7 @@ extern ADLMIDI_DECLSPEC void adl_setDebugMessageHook(struct ADL_MIDIPlayer *devi
* @param loopStartHook Pointer to the callback function which will be called on every loop start point passing
* @param userData Pointer to user data which will be passed through the callback.
*/
extern ADLMIDI_DECLSPEC void adl_setLoopStartHook(struct ADL_MIDIPlayer *device, ASL_LoopPointHook loopStartHook, void *userData);
extern ADLMIDI_DECLSPEC void adl_setLoopStartHook(struct ADL_MIDIPlayer *device, ADL_LoopPointHook loopStartHook, void *userData);

/**
* @brief Set the look start point hook
Expand All @@ -1377,7 +1377,7 @@ extern ADLMIDI_DECLSPEC void adl_setLoopStartHook(struct ADL_MIDIPlayer *device,
* @param loopStartHook Pointer to the callback function which will be called on every loop start point passing
* @param userData Pointer to user data which will be passed through the callback.
*/
extern ADLMIDI_DECLSPEC void adl_setLoopEndHook(struct ADL_MIDIPlayer *device, ASL_LoopPointHook loopEndHook, void *userData);
extern ADLMIDI_DECLSPEC void adl_setLoopEndHook(struct ADL_MIDIPlayer *device, ADL_LoopPointHook loopEndHook, void *userData);

/**
* @brief Get a textual description of the channel state. For display only.
Expand Down
4 changes: 2 additions & 2 deletions src/adlmidi.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1182,7 +1182,7 @@ ADLMIDI_EXPORT void adl_setDebugMessageHook(struct ADL_MIDIPlayer *device, ADL_D
}

/* Set loop start hook */
ADLMIDI_EXPORT void adl_setLoopStartHook(struct ADL_MIDIPlayer *device, ASL_LoopPointHook loopStartHook, void *userData)
ADLMIDI_EXPORT void adl_setLoopStartHook(struct ADL_MIDIPlayer *device, ADL_LoopPointHook loopStartHook, void *userData)
{
if(!device)
return;
Expand All @@ -1197,7 +1197,7 @@ ADLMIDI_EXPORT void adl_setLoopStartHook(struct ADL_MIDIPlayer *device, ASL_Loop
}

/* Set loop end hook */
ADLMIDI_EXPORT void adl_setLoopEndHook(struct ADL_MIDIPlayer *device, ASL_LoopPointHook loopEndHook, void *userData)
ADLMIDI_EXPORT void adl_setLoopEndHook(struct ADL_MIDIPlayer *device, ADL_LoopPointHook loopEndHook, void *userData)
{
if(!device)
return;
Expand Down
4 changes: 2 additions & 2 deletions src/adlmidi_midiplay.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,9 @@ struct MIDIEventHooks
void *onNote_userData;

// Loop start/end hooks
ASL_LoopPointHook onLoopStart;
ADL_LoopPointHook onLoopStart;
void *onLoopStart_userData;
ASL_LoopPointHook onLoopEnd;
ADL_LoopPointHook onLoopEnd;
void *onLoopEnd_userData;


Expand Down

0 comments on commit 5c83bca

Please sign in to comment.