Operating System Simulator Plugin  3.5.1
Unreal Engine plugin that simulates an Operating System Environment
Loading...
Searching...
No Matches
UOperatingSystemTaskbarButton Class Reference

Represents a taskbar button in the operating system. More...

#include "OperatingSystemTaskbarButton.h"

Inheritance diagram for UOperatingSystemTaskbarButton:
[legend]
Collaboration diagram for UOperatingSystemTaskbarButton:
[legend]

Public Member Functions

 UOperatingSystemTaskbarButton ()
 
bool ChangeTaskbarState (const EOperatingSystemProgramViewState NewState)
 Changes the state of the taskbar button to the specified state.
 
FORCEINLINE EOperatingSystemProgramViewState GetCurrentState () const
 Returns the current state of the taskbar button. This method returns the current state of the taskbar button.
 
- Public Member Functions inherited from UOperatingSystemWidgetBase
 UOperatingSystemWidgetBase ()
 
void SetOperatingSystem (UOperatingSystem *NewOS)
 
void DestroyOperatingSystemBaseWidget ()
 Destroys the operating system base widget.
 
void ThemeChanged (UOperatingSystemSettingModule_Theme *ThemePayload)
 Callback function for handling theme changes in the operating system widget.
 
- Public Member Functions inherited from IOperatingSystemThemeInterface
void K2_OnOperatingSystemThemeChanged (UOperatingSystemSettingModule_Theme *ThemePayload)
 Callback function for handling theme changes in the operating system widget.
 

Static Public Member Functions

static UOperatingSystemTaskbarButtonCreateTaskbarButton (UOperatingSystemBaseProgram *OwningProgram)
 Creates a taskbar button for the specified owning program.
 

Protected Member Functions

void ToggleState ()
 Toggles the state of the taskbar button. If the current state is Focused or NotFocused, it will minimize the parent program. If the current state is Minimized or MinimizedAndNotFocused, it will restore the minimized program.
 
void K2_OnCreated ()
 This method is called when the taskbar button is created.
 
- Protected Member Functions inherited from UOperatingSystemWidgetBase
virtual void NativeConstruct () override
 
virtual OPERATINGSYSTEMSIMULATOR_API void OnDestroyWidget ()
 
void K2_OnSetOperatingSystem ()
 Blueprint event called when the operating system is set.
 

Protected Attributes

EOperatingSystemProgramViewState CurrentState
 
TWeakObjectPtr< UOperatingSystemBaseProgramParentProgram
 Represents the parent program associated with the taskbar button. It is a weak reference to a UOperatingSystemBaseProgram object. The parent program is the program to which the taskbar button belongs.
 
- Protected Attributes inherited from UOperatingSystemWidgetBase
TObjectPtr< UOperatingSystemParentOS
 A pointer to the parent operating system of the operating system widget.
 

Detailed Description

Represents a taskbar button in the operating system.

UOperatingSystemTaskbarButton is an abstract class that represents a taskbar button in an operating system. It inherits from UOperatingSystemWidgetBase and provides functions and variables specific to the taskbar button.

Constructor & Destructor Documentation

◆ UOperatingSystemTaskbarButton()

UOperatingSystemTaskbarButton::UOperatingSystemTaskbarButton ( )

Member Function Documentation

◆ ChangeTaskbarState()

bool UOperatingSystemTaskbarButton::ChangeTaskbarState ( const EOperatingSystemProgramViewState NewState)

Changes the state of the taskbar button to the specified state.

This method changes the state of the taskbar button to the specified state. If the current state and the new state are not the same, the method updates the current state, triggers the OnProgramWindowStateChanged event on the parent program, and returns true. If the current state and the new state are the same, the method does nothing and returns false.

Parameters
NewStateThe new state of the taskbar button.
Returns
Returns true if the state was changed, false otherwise.
Here is the call graph for this function:

◆ CreateTaskbarButton()

UOperatingSystemTaskbarButton * UOperatingSystemTaskbarButton::CreateTaskbarButton ( UOperatingSystemBaseProgram * OwningProgram)
static

Creates a taskbar button for the specified owning program.

This method creates a taskbar button for the specified owning program. It returns a pointer to the created taskbar button.

Parameters
OwningProgramThe owning program for which the taskbar button will be created.
Returns
A pointer to the created taskbar button. If the owning program's taskbar button class is null, the method returns nullptr.
Note
The returned taskbar button should be managed by the caller, and it is the caller's responsibility to destroy the button when it is no longer needed.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetCurrentState()

FORCEINLINE EOperatingSystemProgramViewState UOperatingSystemTaskbarButton::GetCurrentState ( ) const
inline

Returns the current state of the taskbar button. This method returns the current state of the taskbar button.

Returns
The current state of the taskbar button as an EOperatingSystemProgramViewState enum value.
See also
EOperatingSystemProgramViewState

◆ K2_OnCreated()

void UOperatingSystemTaskbarButton::K2_OnCreated ( )
protected

This method is called when the taskbar button is created.

This method is an event that is called when the taskbar button is created. It is a BlueprintImplementableEvent, which means that it can be implemented in Blueprint subclasses of UOperatingSystemTaskbarButton to provide additional functionality. It is called after the taskbar button is created and initialized.

Note
This method does not have a default implementation in C++. It is intended to be implemented in Blueprint subclasses of UOperatingSystemTaskbarButton. If you wish to modify the behavior of this method, you should implement it in a Blueprint subclass of UOperatingSystemTaskbarButton.

◆ ToggleState()

void UOperatingSystemTaskbarButton::ToggleState ( )
protected

Toggles the state of the taskbar button. If the current state is Focused or NotFocused, it will minimize the parent program. If the current state is Minimized or MinimizedAndNotFocused, it will restore the minimized program.

Member Data Documentation

◆ CurrentState

EOperatingSystemProgramViewState UOperatingSystemTaskbarButton::CurrentState
protected

◆ ParentProgram

TWeakObjectPtr<UOperatingSystemBaseProgram> UOperatingSystemTaskbarButton::ParentProgram
protected

Represents the parent program associated with the taskbar button. It is a weak reference to a UOperatingSystemBaseProgram object. The parent program is the program to which the taskbar button belongs.

Note
The value of this variable can be accessed but should not be modified directly.

The documentation for this class was generated from the following files: