Class WidgetComponent
Definition
- Namespace:
- Tizen.Applications.ComponentBased.Common
- Assembly:
- Tizen.Applications.ComponentBased.dll
Represents a base class for widget components in the component-based application model. This class provides methods for handling the lifecycle and state of widget components.
C#Copypublic abstract class WidgetComponent : BaseComponent
- Inheritance
Methods
CreateWindowInfo(int, int)
Called to create the window for the widget. This method will be called before the OnCreate(int, int) method.
Declaration
C#Copypublic abstract IWindowProxy CreateWindowInfo(int width, int height)
Parameters
| Type | Name | Description |
|---|---|---|
| int | width | The width of the widget window. |
| int | height | The height of the widget window. |
Returns
| Type | Description |
|---|---|
| IWindowProxy | An IWindowProxy object representing the window to use. |
OnCreate(int, int)
Called when the widget component is created. Override this method to implement custom creation behavior.
Declaration
C#Copypublic abstract bool OnCreate(int width, int height)
Parameters
| Type | Name | Description |
|---|---|---|
| int | width | The width of the widget component instance. |
| int | height | The height of the widget component instance. |
Returns
| Type | Description |
|---|---|
| bool |
|
OnDestroy(bool)
Called when the widget component is destroyed. Override this method to handle destruction behavior.
Declaration
C#Copypublic virtual void OnDestroy(bool permanent)
Parameters
| Type | Name | Description |
|---|---|---|
| bool | permanent |
|
OnPause()
Called when the widget component is paused. Override this method to handle pause behavior.
Declaration
C#Copypublic virtual void OnPause()
OnResume()
Called when the widget component is resumed. Override this method to handle resume behavior.
Declaration
C#Copypublic virtual void OnResume()
OnStart(bool)
Called when the widget component is started. Override this method to handle start behavior.
Declaration
C#Copypublic virtual void OnStart(bool restarted)
Parameters
| Type | Name | Description |
|---|---|---|
| bool | restarted |
|
OnStop()
Called when the widget component is stopped. Override this method to handle stop behavior.
Declaration
C#Copypublic virtual void OnStop()