System.Gadget.visible property

[The Windows Gadget Platform/Sidebar is available for use in the operating systems specified in the Requirements section. It may be altered or unavailable in subsequent versions. ]

Gets the visibility state of the gadget.

This property is read-only.

Syntax

bvisible = System.Gadget.visible

Property value

A Boolean that receives the visibility state of the gadget.

(TRUE)

Gadget is visible.

(FALSE)

Gadget is not visible.

Remarks

This property is updated by the visibilityChanged event.

Examples

The following example demonstrates how to use the visibilityChanged event to suspend or resume a timer based on the gadget visibility.

// Delegate for the gadget visibility changed event.
System.Gadget.visibilityChanged = checkVisibility;

// --------------------------------------------------------------------
// Handle the gadget visiblity changed event.
// event = Event argument.
// --------------------------------------------------------------------
function VisibilityChanged(event)
{
    if (!System.Gadget.visible)
    {
        // Stop the timer;
    }
    else
    {
        // Start the timer;
    }
}

Requirements

Minimum supported client
Windows Vista [desktop apps only]
Minimum supported server
Windows Server 2008 [desktop apps only]
End of client support
Windows 7
End of server support
Windows Server 2008
IDL
Sidebar.idl
DLL
Sidebar.Exe (version 1.00 or later)

See also

Reference

System.Gadget

visibilityChanged