Class FolderItem
java.lang.Object
de.rcblum.stream.deck.items.AbstractStreamItem
de.rcblum.stream.deck.items.FolderItem
- All Implemented Interfaces:
StreamKeyListener, StreamItem
- Direct Known Subclasses:
PagedFolderItem, PagedFolderItem.PageItem, ProxyItem
Simple Stream Item that can contain other stream items.
- Author:
- Roland von Werden
-
Field Summary
Fields inherited from class AbstractStreamItem
animation, buttonCount, img, parent, rawImg, rowCount, text, textPosFields inherited from interface StreamItem
TEXT_POS_BOTTOM, TEXT_POS_CENTER, TEXT_POS_TOP -
Constructor Summary
ConstructorsConstructorDescriptionFolderItem(String folderName, StreamItem parent, StreamItem[] children) FolderItem(String folderName, StreamItem parent, StreamItem[] children, int textPosition) -
Method Summary
Modifier and TypeMethodDescriptiongetChild(int i) intintgetChildId(StreamItem item) Returns the Index of the childReturns an array with the children of this item.getIcon()Returns the icon to be displayed on the stream deck.voidonKeyEvent(KeyEvent event) Whenever a key event is triggered this method will be calledvoidsetFolderName(String folderName) Methods inherited from class AbstractStreamItem
addIconUpdateListener, fireIconUpdate, getAnimation, getButtonCount, getColumnCount, getDialListeners, getParent, getRowCount, getText, getTouchScreenImage, getTouchScreenListeners, hasAnimation, hasDialListeners, hasTouchScreenImage, hasTouchScreenListeners, removeIconUpdateListener, setAnimation, setButtonCount, setIcon, setIconPackage, setParent, setRowCount, setText, setText, setTextPositionMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface StreamItem
isLeaf
-
Constructor Details
-
FolderItem
-
FolderItem
-
-
Method Details
-
onKeyEvent
Description copied from interface:StreamKeyListenerWhenever a key event is triggered this method will be called- Parameters:
event-
-
setFolderName
-
getIcon
Description copied from interface:StreamItemReturns the icon to be displayed on the stream deck.- Specified by:
getIconin interfaceStreamItem- Overrides:
getIconin classAbstractStreamItem- Returns:
- Returns the icon object of the Item
-
getChildren
Description copied from interface:StreamItemReturns an array with the children of this item. If the item has a parent, the parent must be the 5th item (StreamItem.getChildren()[4] ) in the array.- Returns:
- Children of this item, or null, if not a folder
-
getChild
-
getChildCount
public int getChildCount()- Specified by:
getChildCountin interfaceStreamItem- Overrides:
getChildCountin classAbstractStreamItem
-
getChildId
Description copied from interface:StreamItemReturns the Index of the child- Parameters:
item- Child to be identified- Returns:
- Index of the child or -1 if its not a child.
-