Class FocusedWindowWidget
Interaction logic for FocusedWindowWidget.xaml
[WinRTRuntimeClassName("Microsoft.UI.Xaml.IUIElementOverrides")]
[WinRTExposedType(typeof(Whim_Bar_BatteryWidgetWinRTTypeDetails))]
public class FocusedWindowWidget : UserControl, IEquatable<DependencyObject>, IAnimationObject, IVisualElement, IVisualElement2, IEquatable<UIElement>, IEquatable<FrameworkElement>, IEquatable<Control>, IWinRTObject, IUnmanagedVirtualMethodTableProvider, IDynamicInterfaceCastable, IEquatable<UserControl>
- Inheritance
-
FocusedWindowWidget
- Implements
-
IWinRTObject
- Inherited Members
Methods
CreateComponent(Func<IWindow, string>?)
Create the focused window widget bar component.
public static BarComponent CreateComponent(Func<IWindow, string>? getTitle = null)
Parameters
getTitle
Func<IWindow, string>- The function to get the title of the window. Defaults to GetTitle(IWindow).
Returns
GetProcessName(IWindow)
Returns the process name of the window - e.g.,
SnippingTool
.public static string? GetProcessName(IWindow window)
Parameters
window
IWindow
Returns
GetShortTitle(IWindow)
Tries to split the title of the window and return the last part.
public static string GetShortTitle(IWindow window)
Parameters
window
IWindow
Returns
GetTitle(IWindow)
Gets the full title of the window.
public static string GetTitle(IWindow window)
Parameters
window
IWindow
Returns
InitializeComponent()
InitializeComponent()
public void InitializeComponent()