Class WidgetBase

Definition

Namespace:
Tizen.Applications
Assembly:
Tizen.Applications.WidgetApplication.dll

The abstract class for widget instances.

C#
Copy
[Obsolete("Deprecated since API10. Will be removed in API12.")] public abstract class WidgetBase
Inheritance
object
WidgetBase

Constructors

View Source

WidgetBase()

Constructor.

Declaration
C#
Copy
[Obsolete("Deprecated since API10. Will be removed in API12.")] public WidgetBase()

Fields

View Source

Window

Window object for this widget instance. It will be created after OnCreate method is invoked.

Declaration
C#
Copy
[Obsolete("Deprecated since API10. Will be removed in API12.")] protected Window Window
Field Value
Type Description
Window

Properties

View Source

Id

ID for this widget instance. It will be created after OnCreate method is invoked.

Declaration
C#
Copy
[Obsolete("Deprecated since API10. Will be removed in API12.")] public string Id { get; }
Property Value
Type Description
string

Methods

View Source

Exit()

Finishes the context for the widget instance.

Declaration
C#
Copy
[Obsolete("Deprecated since API10. Will be removed in API12.")] public void Exit()
Exceptions
Type Condition
System.NotSupportedException

Thrown when the API is not supported in this device.

System.InvalidOperationException

Thrown in case of an unrecoverable error.

View Source

OnCreate(Bundle, int, int)

Overrides this method if want to handle the behavior when the widget instance is started.

Declaration
C#
Copy
[Obsolete("Deprecated since API10. Will be removed in API12.")] public virtual void OnCreate(Bundle content, int w, int h)
Parameters
Type Name Description
Bundle content

The data set for the previous status.

int w

The pixel value for the widget width.

int h

The pixel value for the widget height.

View Source

OnDestroy(WidgetDestroyType, Bundle)

Overrides this method if want to handle the behavior when the widget instance is destroyed.

Declaration
C#
Copy
[Obsolete("Deprecated since API10. Will be removed in API12.")] public virtual void OnDestroy(WidgetBase.WidgetDestroyType reason, Bundle content)
Parameters
Type Name Description
WidgetBase.WidgetDestroyType reason

The reason for destruction.

Bundle content

The data set to save.

View Source

OnPause()

Overrides this method if want to handle the behavior when the widget instance is paused.

Declaration
C#
Copy
[Obsolete("Deprecated since API10. Will be removed in API12.")] public virtual void OnPause()
View Source

OnResize(int, int)

Overrides this method if want to handle the behavior when the widget instance is resized.

Declaration
C#
Copy
[Obsolete("Deprecated since API10. Will be removed in API12.")] public virtual void OnResize(int w, int h)
Parameters
Type Name Description
int w

Widget width.

int h

Widget height.

View Source

OnResume()

Overrides this method if want to handle the behavior when the widget instance is resumed.

Declaration
C#
Copy
[Obsolete("Deprecated since API10. Will be removed in API12.")] public virtual void OnResume()
View Source

OnUpdate(Bundle, bool)

Overrides this method if want to handle the behavior when the widget instance is updated.

Declaration
C#
Copy
[Obsolete("Deprecated since API10. Will be removed in API12.")] public virtual void OnUpdate(Bundle content, bool isForce)
Parameters
Type Name Description
Bundle content

The data set for updating this widget will be provided by the requester.

bool isForce

Although the widget is paused, if it is true, the widget can be updated.

View Source

SetContent(Bundle)

Sets the content information to the widget.

Declaration
C#
Copy
[Obsolete("Deprecated since API10. Will be removed in API12.")] public void SetContent(Bundle info)
Parameters
Type Name Description
Bundle info

The data set to save.

Exceptions
Type Condition
System.ArgumentException

Thrown when failed because of an invalid argument.

System.NotSupportedException

Thrown when the API is not supported in this device.

System.InvalidOperationException

Thrown in case of an unrecoverable error.

View Source

SetTitle(string)

Sends the title to the widget.

Declaration
C#
Copy
[Obsolete("Deprecated since API10. Will be removed in API12.")] public void SetTitle(string title)
Parameters
Type Name Description
string title

When an accessibility mode is turned on, this string will be read.

Exceptions
Type Condition
System.ArgumentException

Thrown when failed because of an invalid argument.

System.NotSupportedException

Thrown when the API is not supported in this device.

System.InvalidOperationException

Thrown in case of an unrecoverable error.