smplayer-dev / smplayer

Free Media Player for Windows, Linux and Mac OS with YouTube support.
https://smplayer.info
GNU General Public License v2.0
685 stars 94 forks source link

Some keyboard shortcuts stop to work when playing music (or a file without video) when using "Mpc GUI" or "Mini Gui" interface #1001

Open Jpokul opened 4 months ago

Jpokul commented 4 months ago

Describe the bug When playing music, or any file without visual output, the use of some shortcuts on keyboard and mouse both becomes unusable. resizing window won't help.

The keys that stop working are jump forward/backward X seconds, frame step forward/back, space to pause, M to mute, P to show/hide playlist. There probably are more. Those functions will work when used from the menu.

To Reproduce

  1. Change Options->Preferences->Interface->Gui to MPC Gui or Mini Gui
  2. Launch any file without visual output, like music,
  3. Try using shortcuts with keyboard.

Sometimes the keys will work. What I did to make them not work again:

  1. Create a playlist, add 2 files - 1 with video and 1 without,
  2. Start playing video file (keys do work),
  3. Double click on the music file in the playlist to start listening to it
  4. Keys will not work, clicking on title bar, progress bar, double clicking will not make the keyboard keys work.
  5. Even if keyboard shortcuts do work, the shortcuts bound to mouse buttons will not (like mouse 3,4 that are sometimes on the side of mice that often work as load previous next page in browsers). I bound them to perform jump forward/backward 5 seconds in SMPlayer settings (they do work on files with visual output).

Your Enviroment

EDIT: As one might have expected, the moment I wrote this, the keys started working. I guess that they do work when the window is active but making it active itself won't always be possible when clicking on the window.

I modified the reproduction steps to account for that.

smplayer-dev commented 4 months ago

I can't reproduce this problem in my computer, with Ubuntu.

Jpokul commented 4 months ago

I'll be keeping an eye if I can make out any pattern. It seems that sometimes when I launch the player from files manager that plays music it will work, then if I click on empty space in playlist it will stop working. Or if I move the window with control bars and then I can't reenable it, but only if there is no visual.

With video files, the control will be disabled if I click an empty space on playlist but it will be reenabled if I select the window with controls, they will start working again. But maybe it is something on my side. I'll try to see if I can pinpoint the problem.

Jpokul commented 4 months ago

Note that some music can have some visuals, like album icon.

The problem will appear if I try to play a file without anything visual - like something downloaded with yt-dlp and converted to not have visuals (-x, --extract-audio Convert video files to audio-only files (requires ffmpeg and ffprobe))

With a command "yt-dlp -x Http_link".

Jpokul commented 4 months ago

Ok, I think I found out what causes it, it seems to only happen when using the "mpc GUI" interface or "Mini GUI". When Using the default GUI it works as it should.

I checked, and the same happens on Windows, with a freshly downloaded SMPlayer but only when using those interfaces.

0x7633 commented 2 months ago

I can't reproduce this problem

Try this:

  1. Turn on: Options -> Preferences -> Interface -> Hide video window when playing audio files.
  2. Play any mp3 file that doesn't have a cover.
  3. Switch to another program window, for example, a file manager.
  4. Switch back to smplayer.

On X11, smplayer stops responding to keyboard keys. A month ago, on another version of my Linux distribution, if I pressed alt, smplayer would start responding to keyboard key presses again. Now - no.