mirror of
https://github.com/ShareX/ShareX.git
synced 2024-09-30 01:07:21 +13:00
Allow overriding file extension in video converter tool
This commit is contained in:
parent
f9cab94ac3
commit
99791f7af4
2 changed files with 13 additions and 5 deletions
|
@ -39,14 +39,20 @@ public string OutputFilePath
|
|||
{
|
||||
get
|
||||
{
|
||||
if (string.IsNullOrEmpty(OutputFolderPath) || string.IsNullOrEmpty(OutputFileName))
|
||||
string path = "";
|
||||
|
||||
if (!string.IsNullOrEmpty(OutputFolderPath) && !string.IsNullOrEmpty(OutputFileName))
|
||||
{
|
||||
return "";
|
||||
path = Path.Combine(OutputFolderPath, OutputFileName);
|
||||
|
||||
if (!Path.HasExtension(OutputFileName))
|
||||
{
|
||||
string extension = GetFileExtension();
|
||||
path = Path.ChangeExtension(path, extension);
|
||||
}
|
||||
}
|
||||
|
||||
string path = Path.Combine(OutputFolderPath, OutputFileName);
|
||||
string extension = GetFileExtension();
|
||||
return Path.ChangeExtension(path, extension);
|
||||
return path;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -143,6 +143,8 @@ private PinToScreenForm(PinToScreenOptions options)
|
|||
ImageOpacity = Options.InitialOpacity;
|
||||
|
||||
InitializeComponent();
|
||||
// TODO: Add options form
|
||||
tsbOptions.Visible = false;
|
||||
ShareXResources.ApplyTheme(this);
|
||||
TopMost = Options.TopMost;
|
||||
SetStyle(ControlStyles.AllPaintingInWmPaint | ControlStyles.OptimizedDoubleBuffer | ControlStyles.UserPaint, true);
|
||||
|
|
Loading…
Reference in a new issue