Closed sjclayton closed 1 month ago
Hi,
Unfortunately, I can't really follow it here. Since yesterday the feature your describing has already been added to the plugin.
For clarity I've added a video with the current implementation, is this what you are requesting? When no argument is passed to :MusicLoop
it will default to the default player (if configured by the user), and use Track
as loop mode.
https://github.com/user-attachments/assets/4237a714-746d-41bf-84ac-1fff9f37884c
Code responsible for this feature:
or potentially toggling through all available loop modes
This feature might be useful, feel free to take a look. If you'd rather not implement it, I'm more than happy to implement it myself.
Yeah :MusicLoop
enables (track mode) fine with no arguments, but it should behave like a switch, if I call the command again with no args a second time, looping should be turned off... this is the behaviour I was mentioning above.
Hopefully that is a little bit clearer. ๐
After some thought, I partially agree with you on adding this feature.
In my opinion, :MusicLoop
should remain unchanged, but we could introduce a new command, such as :MusicLoopToggle
, which would toggle between Track
and None
.
The reason is that changing the behavior of :MusicLoop
could disrupt workflows for other users, including mine, who rely on enabling Track
mode by passing no arguments. This is already clearly defined as the default behavior in both the README and Vim help documentation.
Feel free to open a PR and implement this new command. If you don't have time, I can handle it as wellโI believe it's a fairly straightforward change. ๐
I implemented a MusicLoopToggle
command in commit: b135d65b37ac042389d9df3d178b39de5381cb4f. I am closing this issue for now, if the solution is not what you were looking for, feel free to reopen it.
Thanks so much for adding this!! I have been super busy lately and didn't get around to it.
Describe the solution you'd like
:MusicLoop
should handle being passed no arguments, and use the default player (if one is set) while toggling either the default mode or potentially toggling through all available loop modes.I may work on this myself, but don't really have time at the moment. ๐