Package limn.backend.spi
Record Class TrayState
java.lang.Object
java.lang.Record
limn.backend.spi.TrayState
- Record Components:
title- the icon's name, which a panel and a screen reader say; never emptytooltip- the tooltip; empty for nonepicture- the icon shown as it is, ornullwhen the application set nonemonochrome- the icon that takes the panel's colour, ornull; a backend whose system colours one prefers it, and one that cannot know the panel's colour preferspictureattention- whether the icon asks for attention; both pictures then already carry what shows itactivates- whether a click that means "this application" is the application's; whenfalseevery click opens the menurightToLeft- whether the menu is laid out right to left
public record TrayState(String title, String tooltip, @Nullable TrayPicture picture, @Nullable TrayPicture monochrome, boolean attention, boolean activates, boolean rightToLeft)
extends Record
What a tray shows, whole: a backend is handed a new one whenever any part changes and shows the
difference.
-
Constructor Summary
ConstructorsConstructorDescriptionTrayState(String title, String tooltip, @Nullable TrayPicture picture, @Nullable TrayPicture monochrome, boolean attention, boolean activates, boolean rightToLeft) Checks the two texts. -
Method Summary
Modifier and TypeMethodDescriptionbooleanReturns the value of theactivatesrecord component.booleanReturns the value of theattentionrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.@Nullable TrayPictureReturns the value of themonochromerecord component.@Nullable TrayPicturepicture()Returns the value of thepicturerecord component.booleanReturns the value of therightToLeftrecord component.title()Returns the value of thetitlerecord component.tooltip()Returns the value of thetooltiprecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
TrayState
public TrayState(String title, String tooltip, @Nullable TrayPicture picture, @Nullable TrayPicture monochrome, boolean attention, boolean activates, boolean rightToLeft) Checks the two texts.
-
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
title
Returns the value of thetitlerecord component.- Returns:
- the value of the
titlerecord component
-
tooltip
Returns the value of thetooltiprecord component.- Returns:
- the value of the
tooltiprecord component
-
picture
Returns the value of thepicturerecord component.- Returns:
- the value of the
picturerecord component
-
monochrome
Returns the value of themonochromerecord component.- Returns:
- the value of the
monochromerecord component
-
attention
public boolean attention()Returns the value of theattentionrecord component.- Returns:
- the value of the
attentionrecord component
-
activates
public boolean activates()Returns the value of theactivatesrecord component.- Returns:
- the value of the
activatesrecord component
-
rightToLeft
public boolean rightToLeft()Returns the value of therightToLeftrecord component.- Returns:
- the value of the
rightToLeftrecord component
-