mirror of
https://github.com/wanghongenpin/proxypin.git
synced 2026-03-15 04:23:17 +08:00
1.2.6-beta
This commit is contained in:
@@ -7,6 +7,7 @@ import android.graphics.Canvas
|
||||
import android.graphics.drawable.BitmapDrawable
|
||||
import android.graphics.drawable.Drawable
|
||||
import java.io.ByteArrayOutputStream
|
||||
import androidx.core.graphics.createBitmap
|
||||
|
||||
class ProcessInfo(name: CharSequence, packageName: String, icon: ByteArray?, versionName: String?) :
|
||||
HashMap<String, Any?>() {
|
||||
@@ -55,11 +56,16 @@ class ProcessInfo(name: CharSequence, packageName: String, icon: ByteArray?, ver
|
||||
if (drawable is BitmapDrawable) {
|
||||
return drawable.bitmap
|
||||
}
|
||||
val bitmap = Bitmap.createBitmap(
|
||||
drawable.intrinsicWidth,
|
||||
drawable.intrinsicHeight,
|
||||
Bitmap.Config.ARGB_8888
|
||||
)
|
||||
|
||||
// 获取宽度和高度,如果无效则使用默认值 96dp
|
||||
var width = drawable.intrinsicWidth
|
||||
var height = drawable.intrinsicHeight
|
||||
|
||||
// 如果宽度或高度无效(≤ 0),使用默认的 96 作为大小
|
||||
if (width <= 0) width = 96
|
||||
if (height <= 0) height = 96
|
||||
|
||||
val bitmap = createBitmap(width, height)
|
||||
val canvas = Canvas(bitmap)
|
||||
drawable.setBounds(0, 0, canvas.width, canvas.height)
|
||||
drawable.draw(canvas)
|
||||
|
||||
@@ -20,5 +20,7 @@
|
||||
<string>????</string>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>1.0</string>
|
||||
<key>MinimumOSVersion</key>
|
||||
<string>13.0</string>
|
||||
</dict>
|
||||
</plist>
|
||||
|
||||
@@ -54,18 +54,16 @@ class AudioManager: NSObject {
|
||||
self.backgroundAudioPlayer?.delegate = self
|
||||
}
|
||||
|
||||
//主要修改了这里
|
||||
private func setupListener() {
|
||||
|
||||
NotificationCenter.default.addObserver(self, selector: #selector(didEnterBackground), name: UIApplication.didEnterBackgroundNotification, object: nil)
|
||||
NotificationCenter.default.addObserver(self, selector: #selector(didBecomeActive), name: UIApplication.didBecomeActiveNotification, object: nil)
|
||||
|
||||
NotificationCenter.default.addObserver(self, selector: #selector(audioSessionInterruption(notification:)), name: AVAudioSession.interruptionNotification, object: nil)
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// MARK: - 扩展 监听通知
|
||||
extension AudioManager {
|
||||
/// 进入后台 播放无声音乐
|
||||
@@ -126,6 +124,7 @@ extension AudioManager {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// MARK: - 扩展 定时器任务
|
||||
extension AudioManager {
|
||||
fileprivate func setupTimer() {
|
||||
|
||||
@@ -63,7 +63,7 @@ class ThemeModel {
|
||||
}
|
||||
|
||||
class AppConfiguration {
|
||||
static const String version = "1.2.5";
|
||||
static const String version = "1.2.6";
|
||||
|
||||
ValueNotifier<bool> globalChange = ValueNotifier(false);
|
||||
|
||||
@@ -71,7 +71,7 @@ class AppConfiguration {
|
||||
Locale? _language;
|
||||
|
||||
//是否显示更新内容公告
|
||||
bool upgradeNoticeV25 = true;
|
||||
bool upgradeNoticeV26 = true;
|
||||
|
||||
/// 是否启用画中画
|
||||
ValueNotifier<bool> pipEnabled = ValueNotifier(Platform.isAndroid);
|
||||
@@ -199,7 +199,7 @@ class AppConfiguration {
|
||||
_theme = ThemeModel(mode: mode, useMaterial3: config['useMaterial3'] ?? true);
|
||||
_theme.color = config['themeColor'] ?? "Blue";
|
||||
|
||||
upgradeNoticeV25 = config['upgradeNoticeV25'] ?? true;
|
||||
upgradeNoticeV26 = config['upgradeNoticeV26'] ?? true;
|
||||
_language = config['language'] == null
|
||||
? null
|
||||
: Locale.fromSubtags(
|
||||
@@ -251,7 +251,7 @@ class AppConfiguration {
|
||||
'mode': _theme.mode.name,
|
||||
'themeColor': _theme.color,
|
||||
'useMaterial3': _theme.useMaterial3,
|
||||
'upgradeNoticeV25': upgradeNoticeV25,
|
||||
'upgradeNoticeV26': upgradeNoticeV26,
|
||||
"language": _language?.languageCode,
|
||||
"languageScript": _language?.scriptCode,
|
||||
"headerExpanded": headerExpanded,
|
||||
|
||||
@@ -93,7 +93,7 @@ class _DesktopHomePagePageState extends State<DesktopHomePage> implements EventL
|
||||
proxyServer.addListener(this);
|
||||
panel = NetworkTabController(tabStyle: const TextStyle(fontSize: 16), proxyServer: proxyServer);
|
||||
|
||||
if (widget.appConfiguration.upgradeNoticeV25) {
|
||||
if (widget.appConfiguration.upgradeNoticeV26) {
|
||||
WidgetsBinding.instance.addPostFrameCallback((_) {
|
||||
showUpgradeNotice();
|
||||
});
|
||||
@@ -162,7 +162,7 @@ class _DesktopHomePagePageState extends State<DesktopHomePage> implements EventL
|
||||
actions: [
|
||||
TextButton(
|
||||
onPressed: () {
|
||||
widget.appConfiguration.upgradeNoticeV25 = false;
|
||||
widget.appConfiguration.upgradeNoticeV26 = false;
|
||||
widget.appConfiguration.flushConfig();
|
||||
Navigator.pop(context);
|
||||
},
|
||||
@@ -176,24 +176,21 @@ class _DesktopHomePagePageState extends State<DesktopHomePage> implements EventL
|
||||
isCN
|
||||
? '提示:默认不会开启HTTPS抓包,请安装证书后再开启HTTPS抓包。\n'
|
||||
'点击HTTPS抓包(加锁图标),选择安装根证书,按照提示操作即可。\n\n'
|
||||
'1. 增加收藏导出和导入;\n'
|
||||
'2. 增加请求解密,可配置AES自动解密消息体;\n'
|
||||
'3. 脚本支持远程URL获取执行;\n'
|
||||
'4. HTTP Header 展示增加文本和表格切换;\n'
|
||||
'5. 增加 Request Param 列表展示;\n'
|
||||
'6. 添加zlib解码支持\n'
|
||||
'7. 应用过滤列表增加是否显示系统应用;\n'
|
||||
'8. 更新JSON深色主题色,以提高可见度和美观度;\n'
|
||||
'1. 新增请求断点,可修改请求、响应后发送;\n'
|
||||
'2. 在请求编辑器中为Header添加自动补全建议;\n'
|
||||
'3. Android、iOS新增系统代理IP忽略设置;\n'
|
||||
'4. Android新增系统代理是否启用设置;\n'
|
||||
'5. Socks5代理新增 IPV6 支持;\n'
|
||||
'6. 修复 MacOS 网线代理设置失败问题;\n'
|
||||
: 'Note: HTTPS capture is disabled by default — please install the certificate before enabling HTTPS capture.\n'
|
||||
'Click the HTTPS capture (lock) icon, choose "Install Root Certificate", and follow the prompts to complete installation.\n\n'
|
||||
'1. Added import/export for Favorites.\n'
|
||||
'2. Added request decryption with configurable AES automatic body decryption.\n'
|
||||
'3. Scripts can now be fetched from remote URLs and executed.\n'
|
||||
'4. HTTP header view now supports switching between text and table modes.\n'
|
||||
'5. Added a Request Params list view.\n'
|
||||
'6. Add zlib decoding support.\n'
|
||||
'7. App filter list now includes an option to show system apps.\n'
|
||||
'8. Updated JSON dark-theme colors for better visibility and appearance.\n',
|
||||
'1. Added request breakpoint feature, allowing modification of requests and responses before sending;\n'
|
||||
'2. Added autocomplete suggestions for HTTP headers in request editor;\n'
|
||||
'3. Added system proxy IP ignore settings for Android and iOS;\n'
|
||||
'4. Added system proxy enable/disable settings for Android;\n'
|
||||
'5. Added IPv6 support for Socks5 proxy;\n'
|
||||
'6. Fixed an issue where proxy settings failed on macOS; \n'
|
||||
,
|
||||
style: const TextStyle(fontSize: 14))));
|
||||
});
|
||||
}
|
||||
|
||||
@@ -193,6 +193,7 @@ class _SocketLaunchState extends State<SocketLaunch> with WindowListener, Widget
|
||||
});
|
||||
widget.onStart?.call();
|
||||
}).catchError((e) {
|
||||
logger.e("启动代理服务器失败", error: e);
|
||||
String message = localizations.proxyPortRepeat(widget.proxyServer.port);
|
||||
FlutterToastr.show(message, context, duration: 3);
|
||||
});
|
||||
|
||||
@@ -120,7 +120,7 @@ class MobileHomeState extends State<MobileHomePage> implements EventListener, Li
|
||||
proxyServer.addListener(this);
|
||||
proxyServer.start();
|
||||
|
||||
if (widget.appConfiguration.upgradeNoticeV25) {
|
||||
if (widget.appConfiguration.upgradeNoticeV26) {
|
||||
WidgetsBinding.instance.addPostFrameCallback((_) {
|
||||
showUpgradeNotice();
|
||||
});
|
||||
@@ -138,9 +138,8 @@ class MobileHomeState extends State<MobileHomePage> implements EventListener, Li
|
||||
builder: (context) => BreakpointExecutor(
|
||||
requestId: args['requestId'],
|
||||
request: HttpRequest.fromJson(jsonDecode(jsonEncode(args['request']))),
|
||||
response: args['response'] == null
|
||||
? null
|
||||
: HttpResponse.fromJson(jsonDecode(jsonEncode(args['response']))),
|
||||
response:
|
||||
args['response'] == null ? null : HttpResponse.fromJson(jsonDecode(jsonEncode(args['response']))),
|
||||
isResponse: args['type'] == 'response',
|
||||
),
|
||||
),
|
||||
@@ -310,26 +309,22 @@ class MobileHomeState extends State<MobileHomePage> implements EventListener, Li
|
||||
|
||||
String content = isCN
|
||||
? '提示:默认不会开启HTTPS抓包,请安装证书后再开启HTTPS抓包。\n\n'
|
||||
'1. 增加收藏导出和导入;\n'
|
||||
'2. 增加请求解密,可配置AES自动解密消息体;\n'
|
||||
'3. 脚本支持远程URL获取执行;\n'
|
||||
'4. HTTP Header 展示增加文本和表格切换;\n'
|
||||
'5. 增加 Request Param 列表展示;\n'
|
||||
'6. 添加zlib解码支持\n'
|
||||
'7. 应用过滤列表增加是否显示系统应用;\n'
|
||||
'8. 更新JSON深色主题色,以提高可见度和美观度;\n'
|
||||
'1. 新增请求断点,可修改请求、响应后发送;\n'
|
||||
'2. 在请求编辑器中为Header添加自动补全建议;\n'
|
||||
'3. Android、iOS新增系统代理IP忽略设置;\n'
|
||||
'4. Android新增系统代理是否启用设置;\n'
|
||||
'5. Socks5代理新增 IPV6 支持;\n'
|
||||
'6. 修复 MacOS 网线代理设置失败问题;\n'
|
||||
: 'Note: HTTPS capture is disabled by default — please install the certificate before enabling HTTPS capture.\n\n'
|
||||
'1. Added import/export for Favorites.\n'
|
||||
'2. Added request decryption with configurable AES automatic body decryption.\n'
|
||||
'3. Scripts can now be fetched from remote URLs and executed.\n'
|
||||
'4. HTTP header view now supports switching between text and table modes.\n'
|
||||
'5. Added a Request Params list view.\n'
|
||||
'6. Added zlib decoding support.\n'
|
||||
'7. App filter list now includes an option to show system apps.\n'
|
||||
'8. Updated JSON dark-theme colors for better visibility and appearance.\n';
|
||||
'1. Added request breakpoint feature, allowing modification of requests and responses before sending;\n'
|
||||
'2. Added autocomplete suggestions for HTTP headers in request editor;\n'
|
||||
'3. Added system proxy IP ignore settings for Android and iOS;\n'
|
||||
'4. Added system proxy enable/disable settings for Android;\n'
|
||||
'5. Added IPv6 support for Socks5 proxy;\n'
|
||||
'6. Fixed an issue where proxy settings failed on macOS; \n';
|
||||
showAlertDialog(isCN ? '更新内容V${AppConfiguration.version}' : "What's new in V${AppConfiguration.version}", content,
|
||||
() {
|
||||
widget.appConfiguration.upgradeNoticeV25 = false;
|
||||
widget.appConfiguration.upgradeNoticeV26 = false;
|
||||
widget.appConfiguration.flushConfig();
|
||||
});
|
||||
}
|
||||
|
||||
@@ -5,7 +5,7 @@ cd ../build/linux/x64/release
|
||||
rm -rf package
|
||||
mkdir -p package/DEBIAN
|
||||
echo "Package: ProxyPin" >> package/DEBIAN/control
|
||||
echo "Version: 1.2.5" >> package/DEBIAN/control
|
||||
echo "Version: 1.2.6" >> package/DEBIAN/control
|
||||
echo "Priority: optional" >> package/DEBIAN/control
|
||||
echo "Architecture: amd64" >> package/DEBIAN/control
|
||||
echo "Depends: ca-certificates" >> package/DEBIAN/control
|
||||
|
||||
@@ -10,6 +10,7 @@ import device_info_plus
|
||||
import file_picker
|
||||
import flutter_desktop_context_menu
|
||||
import flutter_js
|
||||
import path_provider_foundation
|
||||
import proxy_manager
|
||||
import screen_retriever_macos
|
||||
import share_plus
|
||||
@@ -24,6 +25,7 @@ func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) {
|
||||
FilePickerPlugin.register(with: registry.registrar(forPlugin: "FilePickerPlugin"))
|
||||
FlutterDesktopContextMenuPlugin.register(with: registry.registrar(forPlugin: "FlutterDesktopContextMenuPlugin"))
|
||||
FlutterJsPlugin.register(with: registry.registrar(forPlugin: "FlutterJsPlugin"))
|
||||
PathProviderPlugin.register(with: registry.registrar(forPlugin: "PathProviderPlugin"))
|
||||
ProxyManagerPlugin.register(with: registry.registrar(forPlugin: "ProxyManagerPlugin"))
|
||||
ScreenRetrieverMacosPlugin.register(with: registry.registrar(forPlugin: "ScreenRetrieverMacosPlugin"))
|
||||
SharePlusMacosPlugin.register(with: registry.registrar(forPlugin: "SharePlusMacosPlugin"))
|
||||
|
||||
@@ -2,7 +2,7 @@ name: proxypin
|
||||
description: ProxyPin
|
||||
publish_to: 'none' # Remove this line if you wish to publish to pub.dev
|
||||
|
||||
version: 1.2.5+28
|
||||
version: 1.2.6+29
|
||||
|
||||
environment:
|
||||
sdk: '>=3.0.2 <4.0.0'
|
||||
|
||||
@@ -3,7 +3,7 @@ publisher_display_name: ProxyPin
|
||||
publisher: CN=8EC6F6C3-E66C-4189-8421-A6F2A451F552
|
||||
identity_name: ProxyPin.ProxyPin
|
||||
publisher_url: https://github.com/wanghongenpin/proxypin
|
||||
msix_version: 1.2.5.0
|
||||
msix_version: 1.2.6.0
|
||||
logo_path: D:\IdeaProjects\proxypin\assets\icon.png
|
||||
capabilities: internetClient
|
||||
store: "true"
|
||||
|
||||
Reference in New Issue
Block a user