HaikuArchives / ffmpegGUI

GUI for FFmpeg

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Update command line when Start is pressed

humdingerb opened this issue · comments

As a consequence of how BTextControl works, there's no message send if the user changes the contents without changing focus from the text field, e.g. by pressing TAB or ENTER.

Now, if the user changes e.g. the bitrate from 1000 to 3000 and clicks "Start", the command line still says "1000k".

When "Start" is clicked, all parameters should be updated before ffmpeg is called to do its work.

As a consequence of how BTextControl works, there's no message send if the user changes the contents without changing focus from the text field, e.g. by pressing TAB or ENTER.

Yep, it's very annoying that there is no way to send out a BMessage on every text change. I miss that feature quite often.

When "Start" is clicked, all parameters should be updated before ffmpeg is called to do its work.

The problem is, this would conflict with being able to edit the commandline by hand before starting the encoding. Which was specifically requested in #11 . Or is there a way to do both?

A fundamental problem is that any change in the options completely rewrite the command line. The user has to do any command line changes as a last step or they'll be overwritten.

I suspect that users might add parameters to the generated command line, but won't fiddle with the ones that are set with the GUI options.
If that's true, the command line could be made uneditable and a second "Additional parameters" BTextControl could be added to allow further manual additions.
Then the command line could be safely updated when "Start" is clicked (or - a bit hacky maybe - the text boxes could be polled every 0.5s if their text has changed).

This isn't an issue anymore, now that we use SetModificationMessages.