Command palette shows commands without assigned menu item
This commit is contained in:
@@ -2,8 +2,9 @@
|
||||
5.4.8.8 Beta (2021-03-??)
|
||||
=========================
|
||||
|
||||
- The mpv window-scale property works now exactly like in mpv.
|
||||
- Implementation for the mpv title property.
|
||||
- Improved window scaling.
|
||||
- Title property implementation.
|
||||
- Command palette shows commands without assigned menu item.
|
||||
|
||||
|
||||
5.4.8.7 Beta (2021-03-09)
|
||||
|
||||
@@ -102,6 +102,7 @@ namespace mpvnet
|
||||
|
||||
public string Path { get; set; } = "";
|
||||
public string Command { get; set; } = "";
|
||||
public string Display { get { return string.IsNullOrEmpty(Path) ? Command : Path; } }
|
||||
|
||||
public CommandItem() { }
|
||||
|
||||
|
||||
@@ -141,8 +141,9 @@
|
||||
|
||||
Ctrl+t set ontop yes #menu: View > On Top > Enable
|
||||
Ctrl+T set ontop no #menu: View > On Top > Disable
|
||||
Alt++ script-message mpv.net scale-window 1.2 #menu: View > Window Size > Enlarge
|
||||
Alt+- script-message mpv.net scale-window 0.8 #menu: View > Window Size > Shrink
|
||||
Alt++ script-message mpv.net scale-window 1.2 #menu: View > Zoom > Enlarge
|
||||
Alt+- script-message mpv.net scale-window 0.8 #menu: View > Zoom > Shrink
|
||||
_ ignore #menu: View > Zoom > -
|
||||
Alt+0 set window-scale 0.5 #menu: View > Zoom > 50 %
|
||||
Alt+1 set window-scale 1.0 #menu: View > Zoom > 100 %
|
||||
Alt+2 set window-scale 2.0 #menu: View > Zoom > 200 %
|
||||
|
||||
@@ -45,8 +45,8 @@
|
||||
<ColumnDefinition />
|
||||
<ColumnDefinition />
|
||||
</Grid.ColumnDefinitions>
|
||||
|
||||
<TextBlock Text="{Binding Path}"></TextBlock>
|
||||
|
||||
<TextBlock Text="{Binding Display}"></TextBlock>
|
||||
|
||||
<TextBlock Grid.Column="1"
|
||||
Text="{Binding Input}"
|
||||
|
||||
@@ -26,7 +26,7 @@ namespace mpvnet
|
||||
|
||||
bool Filter(CommandItem item)
|
||||
{
|
||||
if (item.Command == "" || item.Path == "")
|
||||
if (item.Command == "")
|
||||
return false;
|
||||
|
||||
string filter = FilterTextBox.Text.ToLower();
|
||||
|
||||
@@ -146,9 +146,12 @@ namespace mpvnet
|
||||
}
|
||||
}
|
||||
|
||||
void ScaleWindow(float value)
|
||||
{
|
||||
BeginInvoke(new Action(() => SetFormPosAndSize(value)));
|
||||
void ScaleWindow(float value) {
|
||||
BeginInvoke(new Action(() => {
|
||||
if (value < 1 && (Width == MinimumSize.Width || Height == MinimumSize.Height))
|
||||
return;
|
||||
SetFormPosAndSize(value, false, false, false);
|
||||
}));
|
||||
}
|
||||
|
||||
void WindowScale(double scale)
|
||||
@@ -334,7 +337,10 @@ namespace mpvnet
|
||||
return null;
|
||||
}
|
||||
|
||||
void SetFormPosAndSize(double scale = 1, bool force = false)
|
||||
void SetFormPosAndSize(double scale = 1,
|
||||
bool force = false,
|
||||
bool checkAutofitSmaller = true,
|
||||
bool checkAutofitLarger = true)
|
||||
{
|
||||
if (!force)
|
||||
{
|
||||
@@ -375,7 +381,8 @@ namespace mpvnet
|
||||
}
|
||||
|
||||
height = Convert.ToInt32(height * scale);
|
||||
SetSize(new Size(height * videoSize.Width / videoSize.Height, height), videoSize, screen);
|
||||
SetSize(new Size(height * videoSize.Width / videoSize.Height, height),
|
||||
videoSize, screen, checkAutofitSmaller, checkAutofitLarger);
|
||||
}
|
||||
|
||||
void SetSize(Size size,
|
||||
@@ -842,6 +849,7 @@ namespace mpvnet
|
||||
WPF.WPF.Init();
|
||||
System.Windows.Application.Current.ShutdownMode = System.Windows.ShutdownMode.OnExplicitShutdown;
|
||||
Cursor.Position = new Point(Cursor.Position.X + 1, Cursor.Position.Y);
|
||||
MinimumSize = new Size(FontHeight * 9, FontHeight * 9);
|
||||
UpdateCheck.DailyCheck();
|
||||
core.LoadScripts();
|
||||
Task.Run(() => App.Extension = new Extension());
|
||||
|
||||
Reference in New Issue
Block a user