Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/ClusterM/hakchi2.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/Apps
diff options
context:
space:
mode:
authorAlexey 'Cluster' Avdyukhin <clusterrr@clusterrr.com>2017-05-07 22:18:04 +0300
committerAlexey 'Cluster' Avdyukhin <clusterrr@clusterrr.com>2017-05-07 22:24:39 +0300
commitdf556366579cbe9c28bb71a876c64e7b90f3ebf7 (patch)
treeebaa6aca25f8b184906a1dc37f853cad2f385b19 /Apps
parent78d43197c2c7dfc778d2fd044ab9112e40d33a6a (diff)
ClickOnce ready. Finally installer and auto update.
Diffstat (limited to 'Apps')
-rw-r--r--Apps/NesGame.cs4
-rw-r--r--Apps/NesMiniApplication.cs6
2 files changed, 5 insertions, 5 deletions
diff --git a/Apps/NesGame.cs b/Apps/NesGame.cs
index a76b943a..35a814d5 100644
--- a/Apps/NesGame.cs
+++ b/Apps/NesGame.cs
@@ -95,7 +95,7 @@ namespace com.clusterrr.hakchi_gui
var code = GenerateCode(crc32, Prefix);
var gamePath = Path.Combine(GamesDirectory, code);
var nesPath = Path.Combine(gamePath, code + ".nes");
- var patchesDirectory = Path.Combine(Path.GetDirectoryName(Application.ExecutablePath), "patches");
+ var patchesDirectory = Path.Combine(Program.BaseDirectoryExternal, "patches");
Directory.CreateDirectory(patchesDirectory);
Directory.CreateDirectory(gamePath);
var patches = Directory.GetFiles(patchesDirectory, string.Format("{0:X8}*.ips", crc32), SearchOption.AllDirectories);
@@ -215,7 +215,7 @@ namespace com.clusterrr.hakchi_gui
{
try
{
- var xmlDataBasePath = Path.Combine(Path.Combine(Path.GetDirectoryName(Application.ExecutablePath), "data"), "nescarts.xml");
+ var xmlDataBasePath = Path.Combine(Path.Combine(Program.BaseDirectoryInternal, "data"), "nescarts.xml");
Debug.WriteLine("Loading " + xmlDataBasePath);
if (File.Exists(xmlDataBasePath))
diff --git a/Apps/NesMiniApplication.cs b/Apps/NesMiniApplication.cs
index fe699a06..d2b21946 100644
--- a/Apps/NesMiniApplication.cs
+++ b/Apps/NesMiniApplication.cs
@@ -14,7 +14,7 @@ namespace com.clusterrr.hakchi_gui
{
public class NesMiniApplication : INesMenuElement
{
- public readonly static string GamesDirectory = Path.Combine(Path.GetDirectoryName(Application.ExecutablePath), "games");
+ public readonly static string GamesDirectory = Path.Combine(Program.BaseDirectoryExternal, "games");
const string DefaultReleaseDate = "1900-01-01";
const string DefaultPublisher = "UNKNOWN";
@@ -379,7 +379,7 @@ namespace com.clusterrr.hakchi_gui
imagePath = Path.Combine(Path.GetDirectoryName(romFileName), Path.GetFileNameWithoutExtension(romFileName) + ".jpg");
if (File.Exists(imagePath))
cover = LoadBitmap(imagePath);
- var artDirectory = Path.Combine(Path.GetDirectoryName(Application.ExecutablePath), "art");
+ var artDirectory = Path.Combine(Program.BaseDirectoryExternal, "art");
Directory.CreateDirectory(artDirectory);
imagePath = Path.Combine(artDirectory, Path.GetFileNameWithoutExtension(romFileName) + ".png");
if (File.Exists(imagePath))
@@ -535,7 +535,7 @@ namespace com.clusterrr.hakchi_gui
private static byte[] Compress(string filename)
{
- SevenZipExtractor.SetLibraryPath(Path.Combine(MainForm.BaseDirectory, IntPtr.Size == 8 ? @"tools\7z64.dll" : @"tools\7z.dll"));
+ SevenZipExtractor.SetLibraryPath(Path.Combine(Program.BaseDirectoryInternal, IntPtr.Size == 8 ? @"tools\7z64.dll" : @"tools\7z.dll"));
var arch = new MemoryStream();
var compressor = new SevenZipCompressor();
compressor.CompressionLevel = CompressionLevel.High;