feat(ui): 右側詳細パネルのシンプル化とスクリプト改造不可時の項目非表示化

This commit is contained in:
armonica committed 2026-10-20 10:54:53 +09:00
1 parent c03cc97af1
commit ec4d718311
4 files changed
+81 -31

No files matched your search

+51 -2
View File
@@ -148,6 +148,7 @@ namespace GameLauncher.Engines.Tkool
this.OnPropertyChanged(nameof(this.EvbExtractedVisibility));
this.OnPropertyChanged(nameof(this.EvbExtractedBadgeText));
this.OnPropertyChanged(nameof(this.EvbDetailStatusText));
this.OnPropertyChanged(nameof(this.CanApplyScriptMod));
this.OnPropertyChanged(nameof(this.IsEvbToolMissing));
}
}
@@ -170,6 +171,7 @@ namespace GameLauncher.Engines.Tkool
this.OnPropertyChanged(nameof(this.EvbExtractedVisibility));
this.OnPropertyChanged(nameof(this.EvbExtractedBadgeText));
this.OnPropertyChanged(nameof(this.EvbDetailStatusText));
this.OnPropertyChanged(nameof(this.CanApplyScriptMod));
}
}
}
@@ -192,7 +194,8 @@ namespace GameLauncher.Engines.Tkool
public string EvbUnderlyingEngine
{
get => this._evbUnderlyingEngine;
set { if (this._evbUnderlyingEngine != value) { this._evbUnderlyingEngine = value; this.OnPropertyChanged(); this.OnPropertyChanged(nameof(this.EvbDetailStatusText)); } }
set { if (this._evbUnderlyingEngine != value) { this._evbUnderlyingEngine = value; this.OnPropertyChanged(); this.OnPropertyChanged(nameof(this.EvbDetailStatusText));
this.OnPropertyChanged(nameof(this.CanApplyScriptMod)); } }
}
/// <summary>EVB として扱うか(UI バッジ判定用)</summary>
@@ -310,7 +313,7 @@ namespace GameLauncher.Engines.Tkool
public string PluginsJsPath
{
get => this._pluginsJsPath;
set { if (this._pluginsJsPath != value) { this._pluginsJsPath = value; this.OnPropertyChanged(); } }
set { if (this._pluginsJsPath != value) { this._pluginsJsPath = value; this.OnPropertyChanged(); this.OnPropertyChanged(nameof(this.CanApplyScriptMod)); } }
}
public string PluginsDirPath
@@ -330,6 +333,46 @@ namespace GameLauncher.Engines.Tkool
public override bool IsNwjs => this.EngineType == TkoolEngineType.Nwjs;
public override bool IsOther => this.EngineType == TkoolEngineType.Other;
/// <summary>
/// スクリプト改造(プラグイン注入など)が適用可能な状態かどうか。
/// 該当ゲームが改造非対応(ウディタ・SRPG・NW.js・その他・未解凍状態など)の場合は false を返します。
/// </summary>
public override bool CanApplyScriptMod
{
get
{
if (this.IsWolf || this.IsNwjs || this.IsSrpgStudio || this.IsOther)
{
return false;
}
if (this.IsEvbPacked && !this.IsEvbExtracted)
{
return false;
}
if (this.IsAsar && !this.IsAsarExtracted)
{
return false;
}
if (this.IsStandaloneExePackage && (string.IsNullOrEmpty(this.PluginsJsPath) || !File.Exists(this.PluginsJsPath)))
{
return false;
}
if (this.IsRgss)
{
if (this.HasRgssArchive && !this.IsRgssExtracted)
{
return false;
}
return !string.IsNullOrEmpty(this.PluginsJsPath) && File.Exists(this.PluginsJsPath);
}
if (this.IsMV || this.IsMZ || this.IsTyrano)
{
return !string.IsNullOrEmpty(this.PluginsJsPath) && File.Exists(this.PluginsJsPath);
}
return false;
}
}
/// <summary>
/// エンジン種別ラベルの表示文字列。該当エンジンが無い場合は空文字を返し、ラベル自体を非表示にします。
/// </summary>
@@ -454,6 +497,7 @@ namespace GameLauncher.Engines.Tkool
this.OnPropertyChanged(nameof(this.RgssBadgeText));
this.OnPropertyChanged(nameof(this.RgssBadgeBackground));
this.OnPropertyChanged(nameof(this.RgssDetailStatusText));
this.OnPropertyChanged(nameof(this.CanApplyScriptMod));
}
}
}
@@ -470,6 +514,7 @@ namespace GameLauncher.Engines.Tkool
this.OnPropertyChanged(nameof(this.RgssBadgeText));
this.OnPropertyChanged(nameof(this.RgssBadgeBackground));
this.OnPropertyChanged(nameof(this.RgssDetailStatusText));
this.OnPropertyChanged(nameof(this.CanApplyScriptMod));
}
}
}
@@ -507,6 +552,7 @@ namespace GameLauncher.Engines.Tkool
this.OnPropertyChanged(nameof(this.EngineDisplayName));
this.OnPropertyChanged(nameof(this.EngineLabelText));
this.OnPropertyChanged(nameof(this.EngineLabelBackground));
this.OnPropertyChanged(nameof(this.CanApplyScriptMod));
this.OnPropertyChanged(nameof(this.IsMV));
this.OnPropertyChanged(nameof(this.IsMZ));
this.OnPropertyChanged(nameof(this.IsTyrano));
@@ -532,6 +578,7 @@ namespace GameLauncher.Engines.Tkool
this.OnPropertyChanged(nameof(this.RgssBadgeText));
this.OnPropertyChanged(nameof(this.RgssBadgeBackground));
this.OnPropertyChanged(nameof(this.RgssDetailStatusText));
this.OnPropertyChanged(nameof(this.CanApplyScriptMod));
}
}
}
@@ -679,6 +726,7 @@ namespace GameLauncher.Engines.Tkool
this.OnPropertyChanged(nameof(this.AsarBadgeText));
this.OnPropertyChanged(nameof(this.AsarBadgeBackground));
this.OnPropertyChanged(nameof(this.AsarDetailStatusText));
this.OnPropertyChanged(nameof(this.CanApplyScriptMod));
}
}
}
@@ -695,6 +743,7 @@ namespace GameLauncher.Engines.Tkool
this.OnPropertyChanged(nameof(this.AsarBadgeText));
this.OnPropertyChanged(nameof(this.AsarBadgeBackground));
this.OnPropertyChanged(nameof(this.AsarDetailStatusText));
this.OnPropertyChanged(nameof(this.CanApplyScriptMod));
}
}
}