User Tools

Site Tools


script_autosetupappfreeze

**This is an old revision of the document!** ----

A PCRE internal error occured. This might be caused by a faulty plugin

====== About the script ====== * Purpose : this script automatically sets up app freezing on long tap * Author : cdfa * Link: https://plus.google.com/+JaroslavGrochal/posts/BDKDMrTMfxt ====== How to use the script ====== This script uses 3C toolbox: https://play.google.com/store/apps/details?id=ccc71.at.free If you know any other app that has a shortcut for freezing of apps i can make that work too if you want :). After you've installed 3C toolbox ,run the script from a container and all items in that container which don't already have a custom long tap eventhandler will now freeze on long tap. ====== Script code ====== <sxh javascript> var e = LL.getEvent(); var it = e.getItem(); if(it==null){ var c = e.getContainer(); c.getProperties().edit().setEventHandler("i.longTap", EventHandler.RUN_SCRIPT, LL.getCurrentScript().getId()).commit(); }else{ LL.runAction(EventHandler.LAUNCH_SHORTCUT, "#Intent;action=ccc71.at.freeze;launchFlags=0x34000000;component=ccc71.at.free/ccc71.at.activities.tweaks.at_tweaker_activity;S.ccc71.at.packagename="+it.getIntent().getComponent().getPackageName()+";end") var frozen = it.getTag("frozen"); if(frozen=="true"){ it.getProperties().edit().setInteger("s.iconColorFilter",0x00ffffff).commit() it.setTag("frozen",false); }else{ it.getProperties().edit().setInteger("s.iconColorFilter",0xffffffff).commit() it.setTag("frozen",true); } } </sxh>

script_autosetupappfreeze.1447280132.txt.gz · Last modified: 2015/11/11 22:15 by cdfa