mirror of
https://github.com/Sunnyyoung/WeChatTweak-macOS.git
synced 2025-05-23 06:46:10 +08:00
commit
cd43c17a08
|
@ -17,6 +17,9 @@
|
|||
|
||||

|
||||
|
||||
### LaunchBar action
|
||||

|
||||
|
||||
## 功能
|
||||
|
||||
- 阻止消息撤回
|
||||
|
|
|
@ -17,6 +17,9 @@ A dynamic library tweak for WeChat macOS.
|
|||
|
||||

|
||||
|
||||
### LaunchBar action
|
||||

|
||||
|
||||
## Feature
|
||||
|
||||
- Prevent message revoked
|
||||
|
|
BIN
Screenshot/0x03.png
Normal file
BIN
Screenshot/0x03.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 42 KiB |
53
WeChatTweak.lbaction/Contents/Info.plist
Normal file
53
WeChatTweak.lbaction/Contents/Info.plist
Normal file
|
@ -0,0 +1,53 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>CFBundleIconFile</key>
|
||||
<string>icon.png</string>
|
||||
<key>CFBundleIdentifier</key>
|
||||
<string>com.viko16.LaunchBar.action.WeChatTweak</string>
|
||||
<key>CFBundleName</key>
|
||||
<string>WeChatTweak</string>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>1.0</string>
|
||||
<key>LBAbbreviation</key>
|
||||
<string>wc</string>
|
||||
<key>LBDescription</key>
|
||||
<dict>
|
||||
<key>LBAuthor</key>
|
||||
<string>viko16</string>
|
||||
<key>LBEmail</key>
|
||||
<string></string>
|
||||
<key>LBSummary</key>
|
||||
<string>A LaunchBar action for WeChatTweak.</string>
|
||||
<key>LBTwitter</key>
|
||||
<string></string>
|
||||
<key>LBWebsiteURL</key>
|
||||
<string>https://github.com/viko16</string>
|
||||
</dict>
|
||||
<key>LBScripts</key>
|
||||
<dict>
|
||||
<key>LBDefaultScript</key>
|
||||
<dict>
|
||||
<key>LBAcceptedArgumentTypes</key>
|
||||
<array>
|
||||
<string>string</string>
|
||||
</array>
|
||||
<key>LBKeepWindowActive</key>
|
||||
<true/>
|
||||
<key>LBLiveFeedbackEnabled</key>
|
||||
<true/>
|
||||
<key>LBRequiresArgument</key>
|
||||
<true/>
|
||||
<key>LBResultType</key>
|
||||
<string>unknown</string>
|
||||
<key>LBReturnsResult</key>
|
||||
<true/>
|
||||
<key>LBScriptName</key>
|
||||
<string>default.js</string>
|
||||
</dict>
|
||||
</dict>
|
||||
<key>LBTextInputTitle</key>
|
||||
<string>Search your friend...</string>
|
||||
</dict>
|
||||
</plist>
|
BIN
WeChatTweak.lbaction/Contents/Resources/icon.png
Normal file
BIN
WeChatTweak.lbaction/Contents/Resources/icon.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 62 KiB |
32
WeChatTweak.lbaction/Contents/Scripts/default.js
Normal file
32
WeChatTweak.lbaction/Contents/Scripts/default.js
Normal file
|
@ -0,0 +1,32 @@
|
|||
// LaunchBar Action Script
|
||||
|
||||
function run(string) {
|
||||
if (!string) return [];
|
||||
|
||||
var url = 'http://localhost:48065/wechat/search?keyword=';
|
||||
var result = HTTP.getJSON(url + encodeURIComponent(string.trim()));
|
||||
|
||||
if (result == undefined) {
|
||||
LaunchBar.alert('HTTP.getJSON() returned undefined');
|
||||
return [];
|
||||
}
|
||||
|
||||
if (result.error != undefined) {
|
||||
LaunchBar.log('Error in HTTP request: ' + result.error);
|
||||
return [];
|
||||
}
|
||||
|
||||
return result.data.map(function (i) {
|
||||
return {
|
||||
title: i.m_nsRemark || i.m_nsNickName,
|
||||
subtitle: i.m_nsNickName,
|
||||
icon: "icon.png",
|
||||
action: "open",
|
||||
actionArgument: i.m_nsUsrName
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function open(id) {
|
||||
HTTP.get('http://localhost:48065/wechat/start?session=' + id);
|
||||
}
|
Loading…
Reference in New Issue
Block a user