Hi, i want to create item and set event, all by script.
Hi, i want to create item and set event, all by script. On long press execute another script (for example delete this item). How to do it?
Hi, i want to create item and set event, all by script. On long press execute another script (for example delete this item). How to do it?
Have a look at scripts in the wiki (http://www.lightninglauncher.com/wiki/doku.php?id=script_repository) for scripts that are doing similar things.
Basically what you need is to use a method on a Container object (http://www.lightninglauncher.com/scripting/reference/api/reference/net/pierrox/lightning_launcher/script/api/Container.html) such as addShortcut, addPanel, etc. Then you can edit properties including events this way: some_item.getProperties().edit().setEventHandler(“i.longTap”, EventHandler.ZOOM_FULL_SCALE, null).commit()
Thank you Pierre Hébert very much! Help a lot!