Page 1 of 1

hotkey delete file playing?

Posted: 03 Nov 2021 15:16
by otreux
Hi :)
Is it possible to assign a hotkey that deletes the video I am playing and that the next video in the folder is automatically played? Thanks

Re: hotkey delete file playing?

Posted: 04 Nov 2021 10:11
by Lotesdelere
Not that I know.
I may add, fortunately.

Re: hotkey delete file playing?

Posted: 04 Nov 2021 12:49
by otreux
nobody forces you to use a feature you don't like. This is instead a very useful function for many people who have to watch (and delete) a lot of videos

Re: hotkey delete file playing?

Posted: 04 Nov 2021 16:36
by Hitchhiker
As far as the Delete function is concerned you could use this script: https://gist.github.com/crmaxx/45fc0b22 ... 921449d5ba

Theoretically, you could subsequently use the 'N' and 'P' shortcut keys to go to the next video / previous video in your playlist, but I haven't tried the script myself and can't guarantee it will work.

Re: hotkey delete file playing?

Posted: 04 Nov 2021 20:47
by otreux
Thanks Hitchhiker
Can you tell me how I must use this script?
Or is there any easy guide on how to use this script? I looked on the forum but I did not understand anything, also because my English is bad :(

I am familiar with the 'N' and 'P' hotkeys and it seems genius idea (ironic) that these hotkeys only work when the videos are in the playlist. It was obviously too easy to get them to work in normal view

Re: hotkey delete file playing?

Posted: 05 Nov 2021 12:13
by Hitchhiker
I found an easier solution which is this one: https://github.com/surrim/vlc-delete/

To use go to https://github.com/surrim/vlc-delete/bl ... delete.lua and copy all 116 lines of code. The easiest way to do that is to click the first dash (nothing will appear on screen) and then scroll down to the bottom of the code, hold down SHIFT and click after the last letter from the word "end". That will highlight everything in between. Right click anywhere in the highlighted text and click Copy.

Next, open Windows Notepad, right click and click Paste.

For clarity here's the full URL

Code: Select all

https://github.com/surrim/vlc-delete/blob/master/vlc-delete.lua

To create the file:
  1. Click File ---> Save As and where it reads "File name" type: vlc-delete.luac
  2. Directly below that in the field called "Save As Type" change it to All Files via the dropdown menu and then click Save.
  3. Place the file in this location: C:\Program Files\VideoLAN\VLC\lua\extensions

To use, play a video you want to delete and on the top toolbar click View ---> VLC Delete.

Re: hotkey delete file playing?

Posted: 05 Nov 2021 14:59
by otreux
thank you so much for the help but i thought it was possible to assign a hotkey :(
At this point I first open explorer and delete the video from there. But really thanks for the help!

Re: hotkey delete file playing?

Posted: 05 Nov 2021 18:09
by Hitchhiker
I just tried the script myself and note that it adds a description of the action performed rather than the name "VLC Delete". Here's a pix of it.

Image
(click to enlarge)

It's no big deal to change it to something else though merely by amending the sentence in the shortdesc line. Here's a pix of where that can be found.

Image
(click to enlarge)

But no hotkey I'm afraid.

I'll look into that aspect further and will post again if I find a solution.

EDIT: forgot to mention that according to the script author deleting the video using that option will play the next video automatically. So no need to hit "N'.

Re: hotkey delete file playing?

Posted: 06 Nov 2021 12:58
by otreux
Thanks really for your help! We hope that the authors of VLC decide to insert this option for speed delete video.

As well as hotkeys that also work in normal view (I speak about N 'and' P 'shortcut). I don't understand why I have to put videos in the playlist in order to have working hotkeys. A normal person opens a folder, clicks on a video, watches it and must be able to scroll to the previous / next easily without having to insert the videos into the playlist. I find it really absurd

Anyway...I tried the script, it doesn't work with VLC portable

Re: hotkey delete file playing?

Posted: 10 Nov 2021 08:41
by sean_incali
I found an easier solution which is this one: https://github.com/surrim/vlc-delete/

To use go to https://github.com/surrim/vlc-delete/bl ... delete.lua and copy all 116 lines of code. The easiest way to do that is to click the first dash (nothing will appear on screen) and then scroll down to the bottom of the code, hold down SHIFT and click after the last letter from the word "end". That will highlight everything in between. Right click anywhere in the highlighted text and click Copy.

Next, open Windows Notepad, right click and click Paste.

For clarity here's the full URL

Code: Select all

https://github.com/surrim/vlc-delete/blob/master/vlc-delete.lua

To create the file:
  1. Click File ---> Save As and where it reads "File name" type: vlc-delete.luac
  2. Directly below that in the field called "Save As Type" change it to All Files via the dropdown menu and then click Save.
  3. Place the file in this location: C:\Program Files\VideoLAN\VLC\lua\extensions

To use, play a video you want to delete and on the top toolbar click View ---> VLC Delete.
I too have the same needs as the Op and this plugin works as expected. now if there is a way to bind a hotkey to the menu item added by the plugin, then the problem will be resolved.

But based on what i'm reading it's not possible currently. correct?

Re: hotkey delete file playing?

Posted: 10 Nov 2021 09:40
by Hitchhiker

I too have the same needs as the Op and this plugin works as expected. now if there is a way to bind a hotkey to the menu item added by the plugin, then the problem will be resolved.

But based on what i'm reading it's not possible currently. correct?

I doubt it somehow since it would have been implemented by now if it was. A search through the latest 3.0.x documentation yields zero results.

I also sent the guy who wrote the script an email last Thursday, but haven't received a reply yet. You can have a go yourself if you wish: contact details here: https://spirit.surrim.org/contact

Re: hotkey delete file playing?

Posted: 10 Nov 2021 10:20
by sean_incali
ok. thank you. it will be a nice addition for people who want to clean up their video folders. hopefully some day.

Re: hotkey delete file playing?

Posted: 10 Nov 2021 15:43
by Hitchhiker
This thread might be of interest to you all: https://forum.videolan.org/viewtopic.ph ... 01#p520201

According to one of the developers you can bind certain keys to a mouse button which can then be used to perform a specific function. Since the standard keyboard Delete key isn't assigned to a key already on vlc it might be possible to use the third party tool one of the mods on here (mederi) recommended to achieve that goal: https://www.highrez.co.uk/downloads/XMo ... ontrol.htm

Re: hotkey delete file playing?

Posted: 12 Nov 2021 17:14
by RĂ©mi Denis-Courmont
The delete key removes an entry from playlist or media library. It would confusing if it started deleting the underlying file as well...

As a developer, I simply do not want to have to deal with complaints about personal files accidentally deleted via VLC. Some users already found ways to accidentally delete their files with VLC (or to believe that they did so), so it is not hard to imagine how much worse that would get. Call that idiot proofing perhaps, but that's that.

Re: hotkey delete file playing?

Posted: 26 Nov 2021 07:06
by sean_incali
The delete key removes an entry from playlist or media library. It would confusing if it started deleting the underlying file as well...

As a developer, I simply do not want to have to deal with complaints about personal files accidentally deleted via VLC. Some users already found ways to accidentally delete their files with VLC (or to believe that they did so), so it is not hard to imagine how much worse that would get. Call that idiot proofing perhaps, but that's that.
you could probably add customizable hot key to the delete.lua plug in that shows up under the
view menu?

that way only people who know what they're doing will be able to bind a shot key to deleting a file from the disk.

Because as of now, there is no way to add a custom hotkey/menu combo under the configure hotkey settings.