public static class Ability.WindowAttributeHelper extends Object
Intent to set window attributes for the current application.
This class encapsulates padding settings of a window in an Intent, and you do
not need to care about how the data is stored.
SystemCapability.Aafwk#ABILITY| 构造器 | 说明 |
|---|---|
WindowAttributeHelper(Intent intentAttribute) |
A parameterized constructor used to create a
WindowAttributeHelper instance. |
| 限定符和类型 | 方法 | 说明 |
|---|---|---|
Ability.WindowAttributeHelper |
setBottomPadding(int bottom) |
Sets the bottom padding of a window.
|
Ability.WindowAttributeHelper |
setLeftPadding(int left) |
Sets the left padding of a window.
|
Ability.WindowAttributeHelper |
setRightPadding(int right) |
Sets the right padding of a window.
|
Ability.WindowAttributeHelper |
setTopPadding(int top) |
Sets the top padding of a window.
|
public WindowAttributeHelper(Intent intentAttribute)
WindowAttributeHelper instance.
The Intent carried in the instance automatically stores the attribute
settings after a setting method provided by WindowAttributeHelper is called.
intentAttribute - Indicates the Intent used for storing window
attributes.public Ability.WindowAttributeHelper setLeftPadding(int left)
left - Indicates the left padding of a window to set, in pixelsWindowAttributeHelper object with the specified left padding.public Ability.WindowAttributeHelper setTopPadding(int top)
top - Indicates the top padding of a window to set, in pixelsWindowAttributeHelper object with the specified top padding.public Ability.WindowAttributeHelper setRightPadding(int right)
right - Indicates the right padding of a window to set, in pixelsWindowAttributeHelper object with the specified right padding.public Ability.WindowAttributeHelper setBottomPadding(int bottom)
bottom - Indicates the bottom padding of a window to set, in pixels.WindowAttributeHelper object with the specified bottom padding.