mirror of
https://github.com/2dust/v2rayN.git
synced 2025-08-23 03:16:53 +00:00
Add Helper folder
This commit is contained in:
parent
5201dd5ad0
commit
c9c1cd8cbb
8 changed files with 11 additions and 10 deletions
|
@ -4,7 +4,7 @@ using ZXing.SkiaSharp;
|
|||
|
||||
namespace ServiceLib.Common;
|
||||
|
||||
public class QRCodeHelper
|
||||
public class QRCodeUtils
|
||||
{
|
||||
public static byte[]? GenQRCode(string? url)
|
||||
{
|
|
@ -1,7 +1,8 @@
|
|||
global using ServiceLib.Base;
|
||||
global using ServiceLib.Base;
|
||||
global using ServiceLib.Common;
|
||||
global using ServiceLib.Enums;
|
||||
global using ServiceLib.Handler;
|
||||
global using ServiceLib.Helper;
|
||||
global using ServiceLib.Handler.Fmt;
|
||||
global using ServiceLib.Services;
|
||||
global using ServiceLib.Services.Statistics;
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
using System.Net;
|
||||
using Downloader;
|
||||
|
||||
namespace ServiceLib.Common;
|
||||
namespace ServiceLib.Helper;
|
||||
|
||||
public class DownloaderHelper
|
||||
{
|
|
@ -2,7 +2,7 @@ using System.Net.Http.Headers;
|
|||
using System.Net.Mime;
|
||||
using System.Text;
|
||||
|
||||
namespace ServiceLib.Common;
|
||||
namespace ServiceLib.Helper;
|
||||
|
||||
/// <summary>
|
||||
/// </summary>
|
|
@ -1,7 +1,7 @@
|
|||
using System.Collections;
|
||||
using SQLite;
|
||||
|
||||
namespace ServiceLib.Common;
|
||||
namespace ServiceLib.Helper;
|
||||
|
||||
public sealed class SQLiteHelper
|
||||
{
|
|
@ -420,7 +420,7 @@ public class MainWindowViewModel : MyReactiveObject
|
|||
|
||||
public async Task ScanScreenResult(byte[]? bytes)
|
||||
{
|
||||
var result = QRCodeHelper.ParseBarcode(bytes);
|
||||
var result = QRCodeUtils.ParseBarcode(bytes);
|
||||
await AddScanResultAsync(result);
|
||||
}
|
||||
|
||||
|
@ -437,7 +437,7 @@ public class MainWindowViewModel : MyReactiveObject
|
|||
return;
|
||||
}
|
||||
|
||||
var result = QRCodeHelper.ParseBarcode(fileName);
|
||||
var result = QRCodeUtils.ParseBarcode(fileName);
|
||||
await AddScanResultAsync(result);
|
||||
}
|
||||
|
||||
|
|
|
@ -23,7 +23,7 @@ public partial class QrcodeView : UserControl
|
|||
|
||||
private Bitmap? GetQRCode(string? url)
|
||||
{
|
||||
var bytes = QRCodeHelper.GenQRCode(url);
|
||||
var bytes = QRCodeUtils.GenQRCode(url);
|
||||
return ByteToBitmap(bytes);
|
||||
}
|
||||
|
||||
|
|
|
@ -17,7 +17,7 @@ public class QRCodeHelper
|
|||
}
|
||||
try
|
||||
{
|
||||
var qrCodeImage = ServiceLib.Common.QRCodeHelper.GenQRCode(strContent);
|
||||
var qrCodeImage = QRCodeUtils.GenQRCode(strContent);
|
||||
return qrCodeImage is null ? null : ByteToImage(qrCodeImage);
|
||||
}
|
||||
catch
|
||||
|
|
Loading…
Reference in a new issue