Skip to content

Commit ba4d9b3

Browse files
committed
2 parents 2eb6e1f + 018c02e commit ba4d9b3

File tree

3 files changed

+32
-2
lines changed

3 files changed

+32
-2
lines changed

custom.conf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,12 @@
33
"content": "控制背光",
44
"button1": {
55
"cmd": "lua /system/share/lua/5.1/tp_entry.lua sys_api.release_backlight",
6-
"txt": "解锁背光",
6+
"txt": "自动熄灭",
77
"code": {"0": "执行成功", "-1": "执行失败"}
88
},
99
"button2": {
1010
"cmd": "lua /system/share/lua/5.1/tp_entry.lua sys_api.lock_backlight",
11-
"txt": "锁定背光",
11+
"txt": "屏幕长亮",
1212
"code": {"0": "执行成功", "-1": "执行失败"}
1313
}
1414
}

init

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,16 @@ uninstall() {
5353
$REMOVE "$LAUNCHER_CONFIG_FILE"
5454
}
5555

56+
relase_backlight() {
57+
RC = $(lua /system/share/lua/5.1/tp_entry.lua sys_api.release_backlight)
58+
echo $RC
59+
}
60+
61+
lock_backlight() {
62+
RC = $(lua /system/share/lua/5.1/tp_entry.lua sys_api.lock_backlight)
63+
echo $RC
64+
}
65+
5666
# main
5767
if [ $# -lt 1 ]; then
5868
usage
@@ -71,6 +81,12 @@ case "$1" in
7181
config;;
7282
"uninstall" )
7383
uninstall;;
84+
"config" )
85+
config;;
86+
"release_backlight" )
87+
relase_backlight;;
88+
"lock_backlight" )
89+
lock_backlight;;
7490
* )
7591
usage ;;
7692
esac

manifest.json

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
{
2+
"package_id" : "com.modouwifi.backlight-control",
3+
"name" : "背光控制",
4+
"author" : "魔豆开发团队",
5+
"author_mail" : "[email protected]",
6+
"homepage" : "www.modouwifi.com",
7+
"version" : "0.2.1",
8+
"release_date" : "2014.08.18",
9+
"icon" : "./appicon_backlight_normal.png",
10+
"location" : "internal",
11+
"description" : "使用此应用可以开启或关闭魔豆屏幕的背光自动熄灭功能",
12+
"instruction" : "开启应用后就两个按钮,简单明了",
13+
"os_version" : "0.6.17"
14+
}

0 commit comments

Comments
 (0)