public class

Folder

extends Shortcut
java.lang.Object
   ↳ net.pierrox.lightning_launcher.script.api.Item
     ↳ net.pierrox.lightning_launcher.script.api.Shortcut
       ↳ net.pierrox.lightning_launcher.script.api.Folder

Class Overview

The folder item extends the shortcut (because it have a label and an icon) and add folder specific services such as open/close.

Summary

Public Methods
void close()
Close the folder if it is currently open.
Container getContainer()
Returns the container holding items for this folder.
Image getWindowBackground()
Retrieve the image currently displayed as the folder window background.
boolean isOpen()
Returns the current folder state.
void launch()
Open the folder if it is currently closed, else close it.
void open()
Open the folder if it not already opened.
void openFrom(int x, int y)
Open the folder if it not already opened, using an absolute position for the start point of the animation.
void setContainerId(int id)
Change the container of this folder.
void setWindowBackground(Image image)
Set a window background image.
[Expand]
Inherited Methods
From class net.pierrox.lightning_launcher.script.api.Shortcut
From class net.pierrox.lightning_launcher.script.api.Item
From class java.lang.Object

Public Methods

public void close ()

Close the folder if it is currently open. Does nothing if the script is run in the background.

public Container getContainer ()

Returns the container holding items for this folder.

public Image getWindowBackground ()

Retrieve the image currently displayed as the folder window background. Note: the object returned by this method may not be the one set through #setWindowBackground.

Returns
  • an image, or null if there is no image

public boolean isOpen ()

Returns the current folder state. This function will always return false if the script is run in the background.

Returns
  • true if the folder is open

public void launch ()

Open the folder if it is currently closed, else close it.

public void open ()

Open the folder if it not already opened. Does nothing when the script is run in background.

public void openFrom (int x, int y)

Open the folder if it not already opened, using an absolute position for the start point of the animation. Does nothing when the script is run in background.

Parameters
x absolute abscissa on the screen
y absolute ordinate on the screen

public void setContainerId (int id)

Change the container of this folder. That is: use an alternate set of items in the folder window.

public void setWindowBackground (Image image)

Set a window background image. This is done in memory for a given screen and is not persisted. Note: instances of ImageAnimation are currently not supported