diff options
author | Alexey 'Cluster' Avdyukhin <clusterrr@clusterrr.com> | 2018-02-20 01:39:51 +0300 |
---|---|---|
committer | Alexey 'Cluster' Avdyukhin <clusterrr@clusterrr.com> | 2018-02-20 01:39:51 +0300 |
commit | 855ec1bcd2ba2f060966e024aec732833d2eecee (patch) | |
tree | 5ed1244c172191548ac4ed0b15d5b9268333581e | |
parent | 59b9ef19e80411d98bff4bbd2f791fa1dae39e64 (diff) |
Some fixes
-rw-r--r-- | AboutBox.resx | 7 | ||||
-rw-r--r-- | Apps/NesMiniApplication.cs | 16 |
2 files changed, 10 insertions, 13 deletions
diff --git a/AboutBox.resx b/AboutBox.resx index dd8e64e0..f14140af 100644 --- a/AboutBox.resx +++ b/AboutBox.resx @@ -632,15 +632,12 @@ Patrik Žec <patrik.zec@gmail.com> AcK AcK <Acoustik666@gmail.com>
Xavier M-M <bamargera_666@hotmail.com>
Jumpman <jumpman@jumpman.fr>
-Angus MACGYVER
- <r4dius@gmail.com>
+Angus MACGYVER <r4dius@gmail.com>
KNTRO <kntro@msn.com>
-
Truchen <tarduschl@hotmail.com>
Jelmer de Groot <de.groot@live.nl>
Piklz <pixelpiklz@gmail.com>
-Marco Coelho
-Christian bon_vivant Lindström <christian.lindstrom89@gmail.com>
+Marco Coelho Christian bon_vivant Lindström <christian.lindstrom89@gmail.com>
Luoti-Lasse maande80 <andre.ronggo@gmail.com>
Teguh Aditya <tguh.aditya@gmail.com>
九五二七 <3q.9527.tw>
diff --git a/Apps/NesMiniApplication.cs b/Apps/NesMiniApplication.cs index 07e5d5b3..c5c8c6f5 100644 --- a/Apps/NesMiniApplication.cs +++ b/Apps/NesMiniApplication.cs @@ -24,7 +24,7 @@ namespace com.clusterrr.hakchi_gui public static bool? NeedPatch;
public static bool? Need3rdPartyEmulator;
public static bool? NeedAutoDownloadCover;
- const int MaxCompressSize = 10 * 1024;
+ const int MaxCompressSize = 10 * 1024 * 1024;
public static string GamesDirectory
{
@@ -262,11 +262,11 @@ namespace com.clusterrr.hakchi_gui {
var files = Directory.GetFiles(gamePath, "*.*", SearchOption.AllDirectories);
foreach (var f in files)
- try
- {
+ try
+ {
File.Delete(f);
- }
- catch { }
+ }
+ catch { }
}
Directory.CreateDirectory(gamePath);
File.WriteAllBytes(romPath, rawRomData);
@@ -384,7 +384,7 @@ namespace com.clusterrr.hakchi_gui var sortRawTitle = Name.ToLower();
if (sortRawTitle.StartsWith("the "))
sortRawTitle = sortRawTitle.Substring(4); // Sorting without "THE"
- File.WriteAllText(ConfigPath,
+ File.WriteAllText(ConfigPath,
$"[Desktop Entry]\n" +
$"Type=Application\n" +
$"Exec={command}\n" +
@@ -514,14 +514,14 @@ namespace com.clusterrr.hakchi_gui if (File.Exists(imagePath))
cover = LoadBitmap(imagePath);
}
- if( cover == null )
+ if (cover == null)
{
// do a bidirectional search on sanitized filenames to allow minor variance in filenames, also allows subdirectories
Regex rgx = new Regex("[^a-zA-Z0-9]", RegexOptions.Compiled);
var sanitizedName = rgx.Replace(name, string.Empty).ToLower();
var covers = Directory.GetFiles(artDirectory, "*.*", SearchOption.AllDirectories);
- foreach(var file in covers)
+ foreach (var file in covers)
{
var sanitized = rgx.Replace(System.IO.Path.GetFileNameWithoutExtension(file), "").ToLower();
if (sanitizedName.StartsWith(sanitized) || sanitized.StartsWith(sanitizedName))
|