|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.havi.ui.HScreenConfigTemplate
org.havi.ui.HBackgroundConfigTemplate
The HBackgroundConfigTemplate
class is used to obtain a valid HBackgroundConfiguration
. An
application instantiates one of these objects and then sets all
non-default attributes as desired. The HBackgroundDevice.getBestConfiguration(org.havi.ui.HBackgroundConfigTemplate)
method found in the HBackgroundDevice
class is then
called with this HBackgroundConfigTemplate
. A valid HBackgroundConfiguration
is
returned that meets or exceeds what was requested in the HBackgroundConfigTemplate
.
This class may be subclassed to support additional properties of background configurations which may be requested by applications.
The HScreenConfigTemplate.ZERO_VIDEO_IMPACT
property may be used in instances of this class
to discover whether displaying background stills will have any
impact on already running video. Implementations supporting the
STILL_IMAGE
preference shall return an HStillImageBackgroundConfiguration
when requested except as
described below.
STILL_IMAGE
interrupts video transiently while the image is decoded then a
configuration shall not be returned if the HScreenConfigTemplate.ZERO_VIDEO_IMPACT
property is present with the priority HScreenConfigTemplate.REQUIRED
.
STILL_IMAGE
interrupts video while the image is decoded and for the entire
period while the image is displayed then a configuration shall not
be returned if the HScreenConfigTemplate.ZERO_VIDEO_IMPACT
property is present with either the priorities
HScreenConfigTemplate.REQUIRED
or
HScreenConfigTemplate.PREFERRED
.
Parameter | Description | Default value | Set method | Get method |
---|---|---|---|---|
None. |
Description | Default value | Set method | Get method |
---|---|---|---|
None. |
HScreenConfigTemplate
,
HGraphicsConfigTemplate
,
HVideoConfigTemplate
Field Summary | |
static int |
CHANGEABLE_SINGLE_COLOR
A value for use in the preference field of the setPreference
and getPreferencePriority methods in the HBackgroundConfigTemplate that indicates that a single color
background is requested where that single color can be changed
by applications. |
static int |
STILL_IMAGE
A value for use in the preference field of the setPreference
and getPreferencePriority methods in the HBackgroundConfigTemplate that indicates that a background
which can support still images is requested. |
Fields inherited from class org.havi.ui.HScreenConfigTemplate |
DONT_CARE, FLICKER_FILTERING, INTERLACED_DISPLAY, PIXEL_ASPECT_RATIO, PIXEL_RESOLUTION, PREFERRED, PREFERRED_NOT, REQUIRED, REQUIRED_NOT, SCREEN_RECTANGLE, VIDEO_GRAPHICS_PIXEL_ALIGNED, ZERO_BACKGROUND_IMPACT, ZERO_GRAPHICS_IMPACT, ZERO_VIDEO_IMPACT |
Constructor Summary | |
HBackgroundConfigTemplate()
Creates an HBackgroundConfigTemplate
object. |
Method Summary | |
int |
getPreferencePriority(int preference)
Return the priority for the specified preference. |
boolean |
isConfigSupported(HBackgroundConfiguration hbc)
Returns a boolean indicating whether or not the specified HBackgroundConfiguration
can be used to create a background
plane that supports the features set in this template. |
void |
setPreference(int preference,
int priority)
Set the indicated preference to have the specified priority. |
Methods inherited from class org.havi.ui.HScreenConfigTemplate |
getPreferenceObject, setPreference |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int CHANGEABLE_SINGLE_COLOR
setPreference
and getPreferencePriority
methods in the HBackgroundConfigTemplate
that indicates that a single color
background is requested where that single color can be changed
by applications.
public static final int STILL_IMAGE
setPreference
and getPreferencePriority
methods in the HBackgroundConfigTemplate
that indicates that a background
which can support still images is requested. Where backgrounds
supporting this feature are returned, they are returned as
objects of the HStillImageBackgroundConfiguration
class.
Constructor Detail |
public HBackgroundConfigTemplate()
HBackgroundConfigTemplate
object. See the class description
for details of constructor parameters and default values.
Method Detail |
public boolean isConfigSupported(HBackgroundConfiguration hbc)
HBackgroundConfiguration
can be used to create a background
plane that supports the features set in this template.
hbc
- - the HBackgroundConfiguration
object to test against this template.
HBackgroundConfiguration
object can be used to create a background plane that supports
the features set in this template, false otherwise.public void setPreference(int preference, int priority)
Attributes that are not filled in in a template (through HScreenConfigTemplate.setPreference(int, int)
),
shall have the priority HScreenConfigTemplate.DONT_CARE
. Any
configuration always satisfies these attributes.
setPreference
in class HScreenConfigTemplate
preference
- the preference to be indicated. Valid values
for an HBackgroundConfigTemplate
are:
HScreenConfigTemplate.ZERO_BACKGROUND_IMPACT
,
HScreenConfigTemplate.ZERO_GRAPHICS_IMPACT
,
HScreenConfigTemplate.ZERO_VIDEO_IMPACT
,
HScreenConfigTemplate.INTERLACED_DISPLAY
,
HScreenConfigTemplate.FLICKER_FILTERING
,
HScreenConfigTemplate.VIDEO_GRAPHICS_PIXEL_ALIGNED
,
CHANGEABLE_SINGLE_COLOR
and
STILL_IMAGE
.
Subclasses may add further valid values. An
IllegalArgumentException shall be thrown if the preference is
not a valid value for this instance of HBackgroundConfigTemplate
priority
- the priority of the preference. Valid values are:
HScreenConfigTemplate.REQUIRED
,
HScreenConfigTemplate.PREFERRED
,
HScreenConfigTemplate.DONT_CARE
,
HScreenConfigTemplate.PREFERRED_NOT
and
HScreenConfigTemplate.REQUIRED_NOT
.
If priority
is not a valid priority as defined here a
java.lang.IllegalArgumentException will be thrown.
public int getPreferencePriority(int preference)
By default the preferences in a template returned from the
system will have a HScreenConfigTemplate.DONT_CARE
priority unless specified otherwise. Any configuration always
satisfies these attributes.
getPreferencePriority
in class HScreenConfigTemplate
preference
- the preference to be indicated. Valid values
for an HBackgroundConfigTemplate
are:
HScreenConfigTemplate.ZERO_BACKGROUND_IMPACT
,
HScreenConfigTemplate.ZERO_GRAPHICS_IMPACT
,
HScreenConfigTemplate.ZERO_VIDEO_IMPACT
,
HScreenConfigTemplate.INTERLACED_DISPLAY
,
HScreenConfigTemplate.FLICKER_FILTERING
,
HScreenConfigTemplate.VIDEO_GRAPHICS_PIXEL_ALIGNED
,
HScreenConfigTemplate.PIXEL_ASPECT_RATIO
,
HScreenConfigTemplate.PIXEL_RESOLUTION
,
HScreenConfigTemplate.SCREEN_RECTANGLE
,
CHANGEABLE_SINGLE_COLOR
and
STILL_IMAGE
.
Subclasses may add further valid values. An
IllegalArgumentException shall be thrown if the preference is
not a valid value for this instance of HBackgroundConfigTemplate
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |