Main Page | Modules | Alphabetical List | Data Structures | File List | Data Fields | Globals | Related Pages

Device state


Data Structures

struct  osso_hw_state_t

Typedefs

typedef void( osso_hw_cb_f )(osso_hw_state_t *state, gpointer data)

Functions

osso_return_t osso_display_state_on (osso_context_t *osso)
osso_return_t osso_display_blanking_pause (osso_context_t *osso)
osso_return_t osso_hw_set_event_cb (osso_context_t *osso, osso_hw_state_t *state, osso_hw_cb_f *cb, gpointer data)
osso_return_t osso_hw_unset_event_cb (osso_context_t *osso, osso_hw_state_t *state)

Detailed Description

Functions in this group offer a convenient way to receive device status information.

Typedef Documentation

typedef void( osso_hw_cb_f)(osso_hw_state_t *state, gpointer data)
 

This is the type for the device event handler.

Parameters:
state ste current state of the device.
data The data that was set with the osso_hw_set_event_cb function.


Function Documentation

osso_return_t osso_display_blanking_pause osso_context_t osso  ) 
 

Request not to blank display, must be repeated in 60 seconds to renew request.. Used for example by the video player during video playback. Also prevents suspending.

Returns:
OSSO_OK if all goes well, OSSO_ERROR if an error occured.

osso_return_t osso_display_state_on osso_context_t osso  ) 
 

Request to turn on the display as if the user had pressed the keys or touchscreen. This can be used after completing a long operation such as downloading a webpage or fetching emails.

Returns:
OSSO_OK if all goes well, OSSO_ERROR if an error occured.

osso_return_t osso_hw_set_event_cb osso_context_t osso,
osso_hw_state_t state,
osso_hw_cb_f cb,
gpointer  data
 

This function sets an event handler callback that is called whenever the state of the device changes. The first call to this function will also check the state files for the state of the device, and if the state is set, the corresponding callback function will be called immediately.

Parameters:
osso The library context as returned by osso_initialize.
state The states we are interested in. NULL can be passed here to indicate that all signals are of interest.
cb The callback function.
data Program specific data.
Returns:
OSSO_OK if all goes well, OSSO_ERROR if an error occurred or OSSO_INVALID if some parameter is invalid.

osso_return_t osso_hw_unset_event_cb osso_context_t osso,
osso_hw_state_t state
 

This function unsets an event handler callback.

Parameters:
osso The library context as returned by osso_initialize. § *
state The states we are interested in. NULL can be passed here to indicate that all signals are of interest.
Returns:
OSSO_OK if all goes well, OSSO_ERROR if an error occurred or OSSO_INVALID if some parameter is invalid.


Generated on Mon May 23 03:17:49 2005 for LibOSSO by doxygen 1.3.7