mirror of
https://github.com/qinyuhang/ShadowsocksX-NG-R.git
synced 2026-11-05 11:45:06 +00:00
Compare commits
10
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c5f1fc72f8 | ||
|
|
539cba7f60 | ||
|
|
f38c2b8fd2 | ||
|
|
509b996fa6 | ||
|
|
f38ade4584 | ||
|
|
abfb8c1dd3 | ||
|
|
61e40e77bf | ||
|
|
8baf1c8485 | ||
|
|
682fc346f8 | ||
|
|
8e09347fac |
@@ -85,9 +85,9 @@ class AppDelegate: NSObject, NSApplicationDelegate, NSUserNotificationCenterDele
|
|||||||
"LocalSocks5.EnableUDPRelay": NSNumber(value: false as Bool),
|
"LocalSocks5.EnableUDPRelay": NSNumber(value: false as Bool),
|
||||||
"LocalSocks5.EnableVerboseMode": NSNumber(value: false as Bool),
|
"LocalSocks5.EnableVerboseMode": NSNumber(value: false as Bool),
|
||||||
"GFWListURL": "https://raw.githubusercontent.com/gfwlist/gfwlist/master/gfwlist.txt",
|
"GFWListURL": "https://raw.githubusercontent.com/gfwlist/gfwlist/master/gfwlist.txt",
|
||||||
"ACLWhiteListURL": "https://raw.githubusercontent.com/shadowsocksr/shadowsocksr-libev/master/acl/chn.acl",
|
"ACLWhiteListURL": "https://raw.githubusercontent.com/shadowsocks/shadowsocks-libev/master/acl/chn.acl",
|
||||||
"ACLAutoListURL": "https://raw.githubusercontent.com/shadowsocksr/shadowsocksr-libev/master/acl/gfwlist.acl",
|
"ACLAutoListURL": "https://raw.githubusercontent.com/shadowsocks/shadowsocks-libev/master/acl/gfwlist.acl",
|
||||||
"ACLProxyBackCHNURL":"https://raw.githubusercontent.com/shadowsocksr/ShadowsocksX-NG/develop/ShadowsocksX-NG/backchn.acl",
|
"ACLProxyBackCHNURL":"https://raw.githubusercontent.com/shadowsocks/shadowsocks-libev/master/ShadowsocksX-NG/server_block_chn.acl",
|
||||||
"AutoConfigureNetworkServices": NSNumber(value: true as Bool),
|
"AutoConfigureNetworkServices": NSNumber(value: true as Bool),
|
||||||
"LocalHTTP.ListenAddress": "127.0.0.1",
|
"LocalHTTP.ListenAddress": "127.0.0.1",
|
||||||
"LocalHTTP.ListenPort": NSNumber(value: 1087 as UInt16),
|
"LocalHTTP.ListenPort": NSNumber(value: 1087 as UInt16),
|
||||||
@@ -759,7 +759,7 @@ class AppDelegate: NSObject, NSApplicationDelegate, NSUserNotificationCenterDele
|
|||||||
let alertResult = versionChecker.showAlertView(Title: newVersion["Title"] as! String, SubTitle: newVersion["SubTitle"] as! String, ConfirmBtn: newVersion["ConfirmBtn"] as! String, CancelBtn: newVersion["CancelBtn"] as! String)
|
let alertResult = versionChecker.showAlertView(Title: newVersion["Title"] as! String, SubTitle: newVersion["SubTitle"] as! String, ConfirmBtn: newVersion["ConfirmBtn"] as! String, CancelBtn: newVersion["CancelBtn"] as! String)
|
||||||
print(alertResult)
|
print(alertResult)
|
||||||
if (newVersion["newVersion"] as! Bool && alertResult == 1000){
|
if (newVersion["newVersion"] as! Bool && alertResult == 1000){
|
||||||
NSWorkspace.shared().open(URL(string: "https://github.com/shadowsocksr/ShadowsocksX-NG/releases")!)
|
NSWorkspace.shared().open(URL(string: "https://github.com/qinyuhang/ShadowsocksX-NG-R/releases")!)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -375,7 +375,7 @@ DQ
|
|||||||
<constraints>
|
<constraints>
|
||||||
<constraint firstAttribute="width" constant="69" id="s2I-cF-RJc"/>
|
<constraint firstAttribute="width" constant="69" id="s2I-cF-RJc"/>
|
||||||
</constraints>
|
</constraints>
|
||||||
<buttonCell key="cell" type="push" title="Cacnel" bezelStyle="rounded" alignment="center" borderStyle="border" imageScaling="proportionallyDown" inset="2" id="j03-9E-uHW">
|
<buttonCell key="cell" type="push" title="Cancel" bezelStyle="rounded" alignment="center" borderStyle="border" imageScaling="proportionallyDown" inset="2" id="j03-9E-uHW">
|
||||||
<behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
|
<behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
|
||||||
<font key="font" metaFont="system"/>
|
<font key="font" metaFont="system"/>
|
||||||
<string key="keyEquivalent" base64-UTF8="YES">
|
<string key="keyEquivalent" base64-UTF8="YES">
|
||||||
|
|||||||
@@ -17,7 +17,7 @@
|
|||||||
<key>CFBundlePackageType</key>
|
<key>CFBundlePackageType</key>
|
||||||
<string>APPL</string>
|
<string>APPL</string>
|
||||||
<key>CFBundleShortVersionString</key>
|
<key>CFBundleShortVersionString</key>
|
||||||
<string>1.4.2-R8</string>
|
<string>1.4.3-R8</string>
|
||||||
<key>CFBundleSignature</key>
|
<key>CFBundleSignature</key>
|
||||||
<string>????</string>
|
<string>????</string>
|
||||||
<key>CFBundleURLTypes</key>
|
<key>CFBundleURLTypes</key>
|
||||||
@@ -48,7 +48,7 @@
|
|||||||
</dict>
|
</dict>
|
||||||
</array>
|
</array>
|
||||||
<key>CFBundleVersion</key>
|
<key>CFBundleVersion</key>
|
||||||
<string>1</string>
|
<string>3</string>
|
||||||
<key>LSApplicationCategoryType</key>
|
<key>LSApplicationCategoryType</key>
|
||||||
<string>public.app-category.utilities</string>
|
<string>public.app-category.utilities</string>
|
||||||
<key>LSMinimumSystemVersion</key>
|
<key>LSMinimumSystemVersion</key>
|
||||||
|
|||||||
@@ -8,7 +8,7 @@
|
|||||||
|
|
||||||
import Foundation
|
import Foundation
|
||||||
|
|
||||||
let SS_LOCAL_VERSION = "2.5.6.11.static"
|
let SS_LOCAL_VERSION = "2.5.6.12.static"
|
||||||
let PRIVOXY_VERSION = "3.0.26.static"
|
let PRIVOXY_VERSION = "3.0.26.static"
|
||||||
let APP_SUPPORT_DIR = "/Library/Application Support/ShadowsocksX-NG/"
|
let APP_SUPPORT_DIR = "/Library/Application Support/ShadowsocksX-NG/"
|
||||||
let LAUNCH_AGENT_DIR = "/Library/LaunchAgents/"
|
let LAUNCH_AGENT_DIR = "/Library/LaunchAgents/"
|
||||||
|
|||||||
@@ -50,9 +50,9 @@
|
|||||||
CGContextRef bitmapRef = CGBitmapContextCreate(nil, width, height, 8, 0, cs, (CGBitmapInfo)kCGImageAlphaNone);
|
CGContextRef bitmapRef = CGBitmapContextCreate(nil, width, height, 8, 0, cs, (CGBitmapInfo)kCGImageAlphaNone);
|
||||||
|
|
||||||
#if TARGET_OS_IPHONE
|
#if TARGET_OS_IPHONE
|
||||||
CIContext *context = [CIContext contextWithOptions:nil];
|
CIContext *context = [CIContext contextWithOptions: @{kCIContextUseSoftwareRenderer: true}];
|
||||||
#else
|
#else
|
||||||
CIContext *context = [CIContext contextWithCGContext:bitmapRef options:nil];
|
CIContext *context = [CIContext contextWithCGContext:bitmapRef options:@{kCIContextUseSoftwareRenderer: @true}];
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
CGImageRef bitmapImage = [context createCGImage:image fromRect:extent];
|
CGImageRef bitmapImage = [context createCGImage:image fromRect:extent];
|
||||||
|
|||||||
@@ -45,7 +45,7 @@ void ScanQRCodeOnScreen() {
|
|||||||
NSMutableArray* foundSSUrls = [NSMutableArray array];
|
NSMutableArray* foundSSUrls = [NSMutableArray array];
|
||||||
|
|
||||||
CIDetector *detector = [CIDetector detectorOfType:@"CIDetectorTypeQRCode"
|
CIDetector *detector = [CIDetector detectorOfType:@"CIDetectorTypeQRCode"
|
||||||
context:nil
|
context:[CIContext contextWithOptions:@{kCIContextUseSoftwareRenderer: @true}]
|
||||||
options:@{ CIDetectorAccuracy:CIDetectorAccuracyHigh }];
|
options:@{ CIDetectorAccuracy:CIDetectorAccuracyHigh }];
|
||||||
|
|
||||||
for (unsigned int displaysIndex = 0; displaysIndex < dspCount; displaysIndex++)
|
for (unsigned int displaysIndex = 0; displaysIndex < dspCount; displaysIndex++)
|
||||||
@@ -66,7 +66,7 @@ void ScanQRCodeOnScreen() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
free(displays);
|
free(displays);
|
||||||
|
// TODO if not find any urls push a notification tells there is no QR on the screen
|
||||||
[[NSNotificationCenter defaultCenter]
|
[[NSNotificationCenter defaultCenter]
|
||||||
postNotificationName:@"NOTIFY_FOUND_SS_URL"
|
postNotificationName:@"NOTIFY_FOUND_SS_URL"
|
||||||
object:nil
|
object:nil
|
||||||
|
|||||||
@@ -8,7 +8,7 @@
|
|||||||
|
|
||||||
import Foundation
|
import Foundation
|
||||||
|
|
||||||
let _VERSION_XML_URL = "https://raw.githubusercontent.com/shadowsocksr/ShadowsocksX-NG/develop/ShadowsocksX-NG/Info.plist"
|
let _VERSION_XML_URL = "https://raw.githubusercontent.com/qinyuhang/ShadowsocksX-NG-R/develop/ShadowsocksX-NG/Info.plist"
|
||||||
let _VERSION_XML_LOCAL:String = Bundle.main.bundlePath + "/Contents/Info.plist"
|
let _VERSION_XML_LOCAL:String = Bundle.main.bundlePath + "/Contents/Info.plist"
|
||||||
|
|
||||||
class VersionChecker: NSObject {
|
class VersionChecker: NSObject {
|
||||||
|
|||||||
@@ -8,7 +8,7 @@
|
|||||||
|
|
||||||
|
|
||||||
cd `dirname "${BASH_SOURCE[0]}"`
|
cd `dirname "${BASH_SOURCE[0]}"`
|
||||||
ssLocalVersion=2.5.6.11.static
|
ssLocalVersion=2.5.6.12.static
|
||||||
mkdir -p "$HOME/Library/Application Support/ShadowsocksX-NG/ss-local-$ssLocalVersion"
|
mkdir -p "$HOME/Library/Application Support/ShadowsocksX-NG/ss-local-$ssLocalVersion"
|
||||||
cp -f ss-local "$HOME/Library/Application Support/ShadowsocksX-NG/ss-local-$ssLocalVersion/"
|
cp -f ss-local "$HOME/Library/Application Support/ShadowsocksX-NG/ss-local-$ssLocalVersion/"
|
||||||
rm -f "$HOME/Library/Application Support/ShadowsocksX-NG/ss-local"
|
rm -f "$HOME/Library/Application Support/ShadowsocksX-NG/ss-local"
|
||||||
|
|||||||
Binary file not shown.
@@ -26,7 +26,7 @@
|
|||||||
/* Class = "NSTextFieldCell"; title = "Obfs Param"; ObjectID = "g7c-fW-7J4"; */
|
/* Class = "NSTextFieldCell"; title = "Obfs Param"; ObjectID = "g7c-fW-7J4"; */
|
||||||
"g7c-fW-7J4.title" = "混淆参数:";
|
"g7c-fW-7J4.title" = "混淆参数:";
|
||||||
|
|
||||||
/* Class = "NSButtonCell"; title = "Cacnel"; ObjectID = "j03-9E-uHW"; */
|
/* Class = "NSButtonCell"; title = "Cancel"; ObjectID = "j03-9E-uHW"; */
|
||||||
"j03-9E-uHW.title" = "取消";
|
"j03-9E-uHW.title" = "取消";
|
||||||
|
|
||||||
/* Class = "NSTextFieldCell"; title = "Password:"; ObjectID = "kil-xC-HPD"; */
|
/* Class = "NSTextFieldCell"; title = "Password:"; ObjectID = "kil-xC-HPD"; */
|
||||||
|
|||||||
Reference in New Issue
Block a user