mirror of
https://github.com/rvtr/TwlToolsRED.git
synced 2025-10-31 06:41:18 -04:00
マスタエディタ:エラーリスト出力機能を実装。
git-svn-id: file:///Users/lillianskinner/Downloads/platinum/twl/TwlToolsRED@313 7061adef-622a-194b-ae81-725974e89856
This commit is contained in:
parent
7033479efa
commit
b152e31697
Binary file not shown.
Binary file not shown.
Binary file not shown.
File diff suppressed because it is too large
Load Diff
@ -117,9 +117,6 @@
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<data name="gboxSrl.Text" xml:space="preserve">
|
||||
<value>ROMデータ情報</value>
|
||||
</data>
|
||||
<assembly alias="System.Drawing" name="System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
|
||||
<data name="labPlatform.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>73, 12</value>
|
||||
@ -172,6 +169,9 @@
|
||||
<data name="labRemasterVer.Text" xml:space="preserve">
|
||||
<value>リマスターバージョン</value>
|
||||
</data>
|
||||
<data name="gboxSrl.Text" xml:space="preserve">
|
||||
<value>ROMデータ情報</value>
|
||||
</data>
|
||||
<data name="labBackup.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>20, 20</value>
|
||||
</data>
|
||||
@ -388,9 +388,6 @@
|
||||
<data name="cboxIsInputPerson2.Text" xml:space="preserve">
|
||||
<value>担当者2を入力する(任意)</value>
|
||||
</data>
|
||||
<data name="gboxPerson2.Text" xml:space="preserve">
|
||||
<value>担当者2</value>
|
||||
</data>
|
||||
<data name="labArbit4.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>37, 12</value>
|
||||
</data>
|
||||
@ -427,8 +424,8 @@
|
||||
<data name="labCompany2.Text" xml:space="preserve">
|
||||
<value>貴社名</value>
|
||||
</data>
|
||||
<data name="gboxPerson1.Text" xml:space="preserve">
|
||||
<value>担当者1</value>
|
||||
<data name="gboxPerson2.Text" xml:space="preserve">
|
||||
<value>担当者2</value>
|
||||
</data>
|
||||
<data name="labArbit2.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>37, 12</value>
|
||||
@ -466,8 +463,8 @@
|
||||
<data name="labCompany1.Text" xml:space="preserve">
|
||||
<value>貴社名</value>
|
||||
</data>
|
||||
<data name="gboxUsage.Text" xml:space="preserve">
|
||||
<value>目的</value>
|
||||
<data name="gboxPerson1.Text" xml:space="preserve">
|
||||
<value>担当者1</value>
|
||||
</data>
|
||||
<data name="rUsageOther.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>54, 16</value>
|
||||
@ -493,8 +490,8 @@
|
||||
<data name="rUsageSale.Text" xml:space="preserve">
|
||||
<value>一般販売用</value>
|
||||
</data>
|
||||
<data name="gboxSubmitWay.Text" xml:space="preserve">
|
||||
<value>提出方法</value>
|
||||
<data name="gboxUsage.Text" xml:space="preserve">
|
||||
<value>目的</value>
|
||||
</data>
|
||||
<data name="rSubmitHand.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>56, 16</value>
|
||||
@ -508,6 +505,9 @@
|
||||
<data name="rSubmitPost.Text" xml:space="preserve">
|
||||
<value>郵送</value>
|
||||
</data>
|
||||
<data name="gboxSubmitWay.Text" xml:space="preserve">
|
||||
<value>提出方法</value>
|
||||
</data>
|
||||
<data name="labSubmiteDate.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>31, 143</value>
|
||||
</data>
|
||||
@ -589,15 +589,15 @@
|
||||
<data name="labProductCodeForeign.Text" xml:space="preserve">
|
||||
<value>製品コード</value>
|
||||
</data>
|
||||
<data name="gboxShared2Size.Text" xml:space="preserve">
|
||||
<value>Shared2ファイルサイズ</value>
|
||||
</data>
|
||||
<data name="cboxIsShared2.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>123, 16</value>
|
||||
</data>
|
||||
<data name="cboxIsShared2.Text" xml:space="preserve">
|
||||
<value>Shared2ファイル使用</value>
|
||||
</data>
|
||||
<data name="gboxShared2Size.Text" xml:space="preserve">
|
||||
<value>Shared2ファイルサイズ</value>
|
||||
</data>
|
||||
<data name="labLib.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>70, 12</value>
|
||||
</data>
|
||||
@ -610,9 +610,6 @@
|
||||
<data name="labSDK.Text" xml:space="preserve">
|
||||
<value>SDKバージョン</value>
|
||||
</data>
|
||||
<data name="gboxTWLExInfo.Text" xml:space="preserve">
|
||||
<value>TWL拡張情報</value>
|
||||
</data>
|
||||
<data name="labIsCodec.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>72, 12</value>
|
||||
</data>
|
||||
@ -628,6 +625,9 @@
|
||||
<data name="labKeyTableRomOffset.Text" xml:space="preserve">
|
||||
<value>TWL専用領域ROMオフセット</value>
|
||||
</data>
|
||||
<data name="gboxTWLExInfo.Text" xml:space="preserve">
|
||||
<value>TWL拡張情報</value>
|
||||
</data>
|
||||
<data name="labNormalRomOffset.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>266, 147</value>
|
||||
</data>
|
||||
@ -667,9 +667,6 @@
|
||||
<data name="cboxIsTmpJump.Text" xml:space="preserve">
|
||||
<value>tmpジャンプ許可</value>
|
||||
</data>
|
||||
<data name="gboxAccess.Text" xml:space="preserve">
|
||||
<value>アクセスコントロール情報</value>
|
||||
</data>
|
||||
<data name="labSDAccessRight.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>96, 12</value>
|
||||
</data>
|
||||
@ -697,6 +694,9 @@
|
||||
<data name="cboxIsSD.Text" xml:space="preserve">
|
||||
<value>SDカード</value>
|
||||
</data>
|
||||
<data name="gboxAccess.Text" xml:space="preserve">
|
||||
<value>アクセスコントロール情報</value>
|
||||
</data>
|
||||
<data name="labIsGameCardOn2.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>294, 328</value>
|
||||
</data>
|
||||
@ -748,38 +748,47 @@
|
||||
<data name="gboxProd.Text" xml:space="preserve">
|
||||
<value>ROM提出情報</value>
|
||||
</data>
|
||||
<data name="stripFile.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>51, 20</value>
|
||||
</data>
|
||||
<data name="stripFile.Text" xml:space="preserve">
|
||||
<value>ファイル</value>
|
||||
</data>
|
||||
<data name="stripItemOpenRom.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>211, 22</value>
|
||||
<value>399, 22</value>
|
||||
</data>
|
||||
<data name="stripItemOpenRom.Text" xml:space="preserve">
|
||||
<value>ROMデータを開く</value>
|
||||
</data>
|
||||
<data name="stripItemSepFile1.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>208, 6</value>
|
||||
<value>396, 6</value>
|
||||
</data>
|
||||
<data name="stripItemSaveTemp.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>211, 22</value>
|
||||
<value>399, 22</value>
|
||||
</data>
|
||||
<data name="stripItemSaveTemp.Text" xml:space="preserve">
|
||||
<value>提出情報を一時保存する</value>
|
||||
</data>
|
||||
<data name="stripItemLoadTemp.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>211, 22</value>
|
||||
<value>399, 22</value>
|
||||
</data>
|
||||
<data name="stripItemLoadTemp.Text" xml:space="preserve">
|
||||
<value>一時保存した提出情報を開く</value>
|
||||
</data>
|
||||
<data name="stripMaster.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>53, 20</value>
|
||||
<data name="toolStripSeparator1.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>396, 6</value>
|
||||
</data>
|
||||
<data name="stripMaster.Text" xml:space="preserve">
|
||||
<value>マスター</value>
|
||||
<data name="stripItemErrorListRead.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>399, 22</value>
|
||||
</data>
|
||||
<data name="stripItemErrorListRead.Text" xml:space="preserve">
|
||||
<value>エラー情報をHTMLファイルに出力する(ROMデータ読み込み時の情報)</value>
|
||||
</data>
|
||||
<data name="stripItemErrorListCurrent.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>399, 22</value>
|
||||
</data>
|
||||
<data name="stripItemErrorListCurrent.Text" xml:space="preserve">
|
||||
<value>エラー情報をHTMLファイルに出力する(現在の入力を反映した情報)</value>
|
||||
</data>
|
||||
<data name="stripFile.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>51, 20</value>
|
||||
</data>
|
||||
<data name="stripFile.Text" xml:space="preserve">
|
||||
<value>ファイル</value>
|
||||
</data>
|
||||
<data name="stripItemSheet.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>280, 22</value>
|
||||
@ -808,17 +817,17 @@
|
||||
<data name="stripItemMiddlewareHtml.Text" xml:space="preserve">
|
||||
<value>ミドルウェアリストのみを作成する(HTML形式)</value>
|
||||
</data>
|
||||
<data name="tabRomInfo.Text" xml:space="preserve">
|
||||
<value>ROM基本情報</value>
|
||||
<data name="stripMaster.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>53, 20</value>
|
||||
</data>
|
||||
<data name="stripMaster.Text" xml:space="preserve">
|
||||
<value>マスター</value>
|
||||
</data>
|
||||
<data name="tboxGuideRomInfo.Text" xml:space="preserve">
|
||||
<value>このタブの情報は編集不可です。データに誤りがある場合にはROMデータ作成時の設定を見直してください。</value>
|
||||
</data>
|
||||
<data name="tabTWLInfo.Text" xml:space="preserve">
|
||||
<value>TWL拡張情報</value>
|
||||
</data>
|
||||
<data name="gboxLaunch.Text" xml:space="preserve">
|
||||
<value>DSiメニュー上での起動制限</value>
|
||||
<data name="tabRomInfo.Text" xml:space="preserve">
|
||||
<value>ROM基本情報</value>
|
||||
</data>
|
||||
<data name="labConnectIcon.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>173, 12</value>
|
||||
@ -826,21 +835,21 @@
|
||||
<data name="labConnectIcon.Text" xml:space="preserve">
|
||||
<value>DSiメニュー上での通信アイコン表示</value>
|
||||
</data>
|
||||
<data name="gboxLaunch.Text" xml:space="preserve">
|
||||
<value>DSiメニュー上での起動制限</value>
|
||||
</data>
|
||||
<data name="tboxGuideTWLInfo.Text" xml:space="preserve">
|
||||
<value>このタブの情報は編集不可です。データに誤りがある場合にはROMデータ作成時の設定を見直してください。</value>
|
||||
</data>
|
||||
<data name="gboxExFlags.Text" xml:space="preserve">
|
||||
<value>TWL拡張諸フラグ</value>
|
||||
</data>
|
||||
<data name="tabNandSizeInfo.Text" xml:space="preserve">
|
||||
<value>DSiウェア情報</value>
|
||||
<data name="tabTWLInfo.Text" xml:space="preserve">
|
||||
<value>TWL拡張情報</value>
|
||||
</data>
|
||||
<data name="tboxGuideNandSizeInfo.Text" xml:space="preserve">
|
||||
<value>このタブの情報はDSiウェア(NANDアプリ)による本体NANDメモリ領域の使用量を確認する場合に必要です。<newline>アプリがゲームカード向けの場合にはNANDメモリ使用量の確認は必要ありません。</value>
|
||||
</data>
|
||||
<data name="gboxNandSize.Text" xml:space="preserve">
|
||||
<value>DSiウェアによる本体NANDメモリの使用量</value>
|
||||
</data>
|
||||
<data name="labNandSize.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>154, 23</value>
|
||||
</data>
|
||||
@ -901,11 +910,11 @@
|
||||
<data name="labTmdSize.Text" xml:space="preserve">
|
||||
<value>その他ファイルサイズ</value>
|
||||
</data>
|
||||
<data name="tabRomEditInfo.Text" xml:space="preserve">
|
||||
<value>リージョンとレーティング(編集可)</value>
|
||||
<data name="gboxNandSize.Text" xml:space="preserve">
|
||||
<value>DSiウェアによる本体NANDメモリの使用量</value>
|
||||
</data>
|
||||
<data name="gboxOtherSpec.Text" xml:space="preserve">
|
||||
<value>その他ROM仕様</value>
|
||||
<data name="tabNandSizeInfo.Text" xml:space="preserve">
|
||||
<value>DSiウェア情報</value>
|
||||
</data>
|
||||
<data name="cboxIsUGC.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>210, 16</value>
|
||||
@ -919,15 +928,15 @@
|
||||
<data name="cboxIsPhotoEx.Text" xml:space="preserve">
|
||||
<value>写真交換対応</value>
|
||||
</data>
|
||||
<data name="gboxOtherSpec.Text" xml:space="preserve">
|
||||
<value>その他ROM仕様</value>
|
||||
</data>
|
||||
<data name="butSetBack.Text" xml:space="preserve">
|
||||
<value>読み込み時の設定に戻す</value>
|
||||
</data>
|
||||
<data name="tboxGuideRomEditInfo.Text" xml:space="preserve">
|
||||
<value>このタブの各項目への入力は提出確認書およびマスターROMの作成のために必要です。<newline>これらの情報はマスターROMの作成時にROM内登録データとして登録されます(「その他ROM仕様」を除く)。</value>
|
||||
</data>
|
||||
<data name="gboxParental.Text" xml:space="preserve">
|
||||
<value>リージョンとレーティング情報</value>
|
||||
</data>
|
||||
<data name="combGRB.Items" xml:space="preserve">
|
||||
<value>全体利用可</value>
|
||||
</data>
|
||||
@ -949,8 +958,11 @@
|
||||
<data name="cboxIsUnnecessaryRating.Text" xml:space="preserve">
|
||||
<value>レーティング表示不要 (ツール類のみ選択可)</value>
|
||||
</data>
|
||||
<data name="tabSubmitInfo.Text" xml:space="preserve">
|
||||
<value>提出情報(要入力)</value>
|
||||
<data name="gboxParental.Text" xml:space="preserve">
|
||||
<value>リージョンとレーティング情報</value>
|
||||
</data>
|
||||
<data name="tabRomEditInfo.Text" xml:space="preserve">
|
||||
<value>リージョンとレーティング(編集可)</value>
|
||||
</data>
|
||||
<data name="labProductNameLimit.Text" xml:space="preserve">
|
||||
<value>(100文字以内)</value>
|
||||
@ -958,9 +970,6 @@
|
||||
<data name="tboxGuideSubmitInfo.Text" xml:space="preserve">
|
||||
<value>このタブの情報は提出確認書の作成に必要です。入力してください。</value>
|
||||
</data>
|
||||
<data name="gboxForeign.Text" xml:space="preserve">
|
||||
<value>海外版</value>
|
||||
</data>
|
||||
<data name="labProductNameLimitForeign.Text" xml:space="preserve">
|
||||
<value>(100文字以内)</value>
|
||||
</data>
|
||||
@ -970,21 +979,21 @@
|
||||
<data name="labMultiForeign2.Text" xml:space="preserve">
|
||||
<value>(複数ある場合のみ)</value>
|
||||
</data>
|
||||
<data name="tabCompanyInfo.Text" xml:space="preserve">
|
||||
<value>会社情報(要入力)</value>
|
||||
<data name="gboxForeign.Text" xml:space="preserve">
|
||||
<value>海外版</value>
|
||||
</data>
|
||||
<data name="tabSubmitInfo.Text" xml:space="preserve">
|
||||
<value>提出情報(要入力)</value>
|
||||
</data>
|
||||
<data name="tboxGuideCompanyInfo.Text" xml:space="preserve">
|
||||
<value>このタブの情報は提出確認書の作成に必要です。入力してください。</value>
|
||||
</data>
|
||||
<data name="tabErrorInfo.Text" xml:space="preserve">
|
||||
<value>エラー情報</value>
|
||||
<data name="tabCompanyInfo.Text" xml:space="preserve">
|
||||
<value>会社情報(要入力)</value>
|
||||
</data>
|
||||
<data name="tboxGuideErrorInfo.Text" xml:space="preserve">
|
||||
<value>このタブには読み込んだROMデータの問題点と本プログラムでの入力ミスが列挙されます。<newline>赤文字の項目は、本プログラムで修正不可です。ROMデータ作成時の設定をご確認ください。<newline>青文字の項目は、ROMデータの問題点のうち、本プログラムで修正できるものです。<newline>黒文字の項目は、提出情報と会社情報の入力ミスおよび入力漏れです。</value>
|
||||
</data>
|
||||
<data name="gboxErrorTiming.Text" xml:space="preserve">
|
||||
<value>いつの情報を表示するか</value>
|
||||
</data>
|
||||
<data name="rErrorCurrent.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>114, 16</value>
|
||||
</data>
|
||||
@ -997,6 +1006,9 @@
|
||||
<data name="rErrorReading.Text" xml:space="preserve">
|
||||
<value>ROMデータ読み込み時</value>
|
||||
</data>
|
||||
<data name="gboxErrorTiming.Text" xml:space="preserve">
|
||||
<value>いつの情報を表示するか</value>
|
||||
</data>
|
||||
<data name="labWarn.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>339, 12</value>
|
||||
</data>
|
||||
@ -1033,6 +1045,9 @@
|
||||
<data name="colErrorCause.HeaderText" xml:space="preserve">
|
||||
<value>要因</value>
|
||||
</data>
|
||||
<data name="tabErrorInfo.Text" xml:space="preserve">
|
||||
<value>エラー情報</value>
|
||||
</data>
|
||||
<data name="labFile.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>92, 12</value>
|
||||
</data>
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,159 @@
|
||||
// ----------------------------------------------
|
||||
// エラーリストの書き出し
|
||||
// ----------------------------------------------
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "Form1.h"
|
||||
|
||||
using namespace System;
|
||||
using namespace System::ComponentModel;
|
||||
using namespace System::Collections;
|
||||
using namespace System::Windows::Forms;
|
||||
using namespace System::Data;
|
||||
using namespace System::Drawing;
|
||||
using namespace MasterEditorTWL;
|
||||
|
||||
static System::Xml::XmlElement^ CreateErrorListElement(System::Xml::XmlDocument ^doc, RCMrcError ^err, int errtype,
|
||||
System::String ^tagname, System::Boolean isJapanese)
|
||||
{
|
||||
System::Xml::XmlElement ^tag = doc->CreateElement(tagname);
|
||||
MasterEditorTWL::appendXmlTag( doc, tag, "name", (isJapanese)?err->Name:err->NameE );
|
||||
MasterEditorTWL::appendXmlTag( doc, tag, "type", errtype.ToString() );
|
||||
MasterEditorTWL::appendXmlTag( doc, tag, "begin", err->Begin.ToString("X04")+"h" );
|
||||
MasterEditorTWL::appendXmlTag( doc, tag, "end", err->End.ToString("X04")+"h" );
|
||||
MasterEditorTWL::appendXmlTag( doc, tag, "msg", (isJapanese)?err->Msg:err->MsgE );
|
||||
return tag;
|
||||
}
|
||||
|
||||
// XML形式でリストを作成
|
||||
System::Void Form1::makeErrorListXml(System::Xml::XmlDocument ^doc, System::Boolean isCurrent)
|
||||
{
|
||||
System::Xml::XmlElement ^root = doc->CreateElement( "twl-master-editor" );
|
||||
System::Reflection::Assembly ^ass = System::Reflection::Assembly::GetEntryAssembly();
|
||||
root->SetAttribute( "version", this->getVersion() );
|
||||
doc->AppendChild( root );
|
||||
|
||||
// ゲーム情報
|
||||
System::Xml::XmlElement ^game = doc->CreateElement( "game" );
|
||||
root->AppendChild( game );
|
||||
if( System::String::IsNullOrEmpty( this->tboxProductName->Text ) )
|
||||
{
|
||||
MasterEditorTWL::appendXmlTag( doc, game, "product-name", this->tboxTitleName->Text ); // 製品名が未入力のときはソフトタイトルで代用
|
||||
}
|
||||
else
|
||||
{
|
||||
MasterEditorTWL::appendXmlTag( doc, game, "product-name", this->tboxProductName->Text );
|
||||
}
|
||||
MasterEditorTWL::appendXmlTag( doc, game, "title-name", this->tboxTitleName->Text );
|
||||
MasterEditorTWL::appendXmlTag( doc, game, "game-code", this->tboxGameCode->Text );
|
||||
MasterEditorTWL::appendXmlTag( doc, game, "rom-version", this->tboxRemasterVer->Text );
|
||||
MasterEditorTWL::appendXmlTag( doc, game, "submit-version", System::Decimal::ToByte(this->numSubmitVersion->Value).ToString("X") );
|
||||
|
||||
// エラーリスト
|
||||
System::Xml::XmlElement ^errorlist = doc->CreateElement( "error-list" );
|
||||
root->AppendChild( errorlist );
|
||||
if( isCurrent ) // 現在の入力を反映
|
||||
{
|
||||
if( this->hSrl->hErrorList != nullptr ) // ROM読み込み時に発見されたエラー
|
||||
{
|
||||
for each( RCMrcError ^err in this->hSrl->hErrorList )
|
||||
{
|
||||
if( !err->IsEnableModify ) // 修正可能な情報は出力しない
|
||||
{
|
||||
errorlist->AppendChild( CreateErrorListElement(doc, err, 0, "error", this->isJapanese()) );
|
||||
}
|
||||
}
|
||||
}
|
||||
if( this->hErrorList != nullptr ) // 現在のフォーム入力から発見されたエラー
|
||||
{
|
||||
for each( RCMrcError ^err in this->hErrorList )
|
||||
{
|
||||
if( err->IsAffectRom ) // 書類上のエラーは出力しない
|
||||
{
|
||||
errorlist->AppendChild( CreateErrorListElement(doc, err, 1, "error", this->isJapanese()) );
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else // ROM読み込み時の情報
|
||||
{
|
||||
if( this->hSrl->hErrorList )
|
||||
{
|
||||
for each( RCMrcError ^err in this->hSrl->hErrorList )
|
||||
{
|
||||
int errtype = 0;
|
||||
if( err->IsEnableModify )
|
||||
{
|
||||
errtype = 1;
|
||||
}
|
||||
errorlist->AppendChild( CreateErrorListElement(doc, err, errtype, "error", this->isJapanese()) );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// 警告リスト
|
||||
System::Xml::XmlElement ^warnlist = doc->CreateElement( "warning-list" );
|
||||
root->AppendChild( warnlist );
|
||||
if( isCurrent ) // 現在の入力を反映
|
||||
{
|
||||
if( this->hSrl->hWarnList != nullptr ) // ROM読み込み時に発見されたエラー
|
||||
{
|
||||
for each( RCMrcError ^err in this->hSrl->hWarnList )
|
||||
{
|
||||
if( !err->IsEnableModify ) // 修正可能な情報は出力しない
|
||||
{
|
||||
warnlist->AppendChild( CreateErrorListElement(doc, err, 0, "warning", this->isJapanese()) );
|
||||
}
|
||||
}
|
||||
}
|
||||
if( this->hWarnList != nullptr ) // 現在のフォーム入力から発見されたエラー
|
||||
{
|
||||
for each( RCMrcError ^err in this->hWarnList )
|
||||
{
|
||||
if( err->IsAffectRom ) // 書類上のエラーは出力しない
|
||||
{
|
||||
warnlist->AppendChild( CreateErrorListElement(doc, err, 1, "warning", this->isJapanese()) );
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else // ROM読み込み時の情報
|
||||
{
|
||||
if( this->hSrl->hWarnList )
|
||||
{
|
||||
for each( RCMrcError ^err in this->hSrl->hWarnList )
|
||||
{
|
||||
int errtype = 0;
|
||||
if( err->IsEnableModify )
|
||||
{
|
||||
errtype = 1;
|
||||
}
|
||||
warnlist->AppendChild( CreateErrorListElement(doc, err, errtype, "warning", this->isJapanese()) );
|
||||
}
|
||||
}
|
||||
}
|
||||
} //System::Void Form1::makeErrorListXml
|
||||
|
||||
System::Void Form1::makeErrorListHtml(System::String ^filepath, System::Boolean isCurrent)
|
||||
{
|
||||
System::String ^tmpxml = gcnew System::String( this->getXmlToHtmlTmpFile() );
|
||||
try
|
||||
{
|
||||
// TMPファイルにXML版作成
|
||||
System::Xml::XmlDocument ^doc = gcnew System::Xml::XmlDocument();
|
||||
doc->AppendChild( doc->CreateXmlDeclaration("1.0","UTF-8",nullptr) );
|
||||
this->makeErrorListXml( doc, isCurrent );
|
||||
doc->Save( tmpxml );
|
||||
// XML=>HTML変換
|
||||
System::Xml::Xsl::XslCompiledTransform ^xslt = gcnew System::Xml::Xsl::XslCompiledTransform;
|
||||
xslt->Load( this->getErrorListXsl() );
|
||||
xslt->Transform( tmpxml, filepath );
|
||||
}
|
||||
catch (System::Exception ^s)
|
||||
{
|
||||
System::IO::File::Delete( tmpxml ); // 次のためにTMPファイルを削除しておく
|
||||
throw s; // 呼び出し元に例外を再throw
|
||||
return;
|
||||
}
|
||||
System::IO::File::Delete( tmpxml );
|
||||
} //System::Void Form1::makeErrorListHtml
|
||||
@ -231,6 +231,10 @@
|
||||
RelativePath=".\Form_deliv.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Form_errorlist.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Form_file.cpp"
|
||||
>
|
||||
|
||||
@ -317,6 +317,30 @@ namespace MasterEditorTWL
|
||||
{
|
||||
System::Boolean get(){ return this->isAffectRom; }
|
||||
}
|
||||
property System::String ^Name
|
||||
{
|
||||
System::String^ get(){ return System::String::Copy(this->hName); }
|
||||
}
|
||||
property System::String ^NameE
|
||||
{
|
||||
System::String^ get(){ return System::String::Copy(this->hNameE); }
|
||||
}
|
||||
property System::String ^Msg
|
||||
{
|
||||
System::String^ get(){ return System::String::Copy(this->hMsg); }
|
||||
}
|
||||
property System::String ^MsgE
|
||||
{
|
||||
System::String^ get(){ return System::String::Copy(this->hMsgE); }
|
||||
}
|
||||
property System::UInt32 Begin
|
||||
{
|
||||
System::UInt32 get(){ return this->begin; }
|
||||
}
|
||||
property System::UInt32 End
|
||||
{
|
||||
System::UInt32 get(){ return this->end; }
|
||||
}
|
||||
public:
|
||||
// gridViewの表示形式にあわせる
|
||||
cli::array<System::Object^>^ getAll( System::Boolean isJapanese )
|
||||
|
||||
146
build/tools/MasterEditor/MasterEditorTWL/resource/errorlist.xsl
Normal file
146
build/tools/MasterEditor/MasterEditorTWL/resource/errorlist.xsl
Normal file
@ -0,0 +1,146 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
|
||||
<xsl:template match="/">
|
||||
<html>
|
||||
<head>
|
||||
<title>TWL Error List</title>
|
||||
<style type="text/css">
|
||||
body {
|
||||
font-family: "verdana";
|
||||
font-size: 12px;
|
||||
text-align: left;
|
||||
}
|
||||
div.game-title {
|
||||
font-size: 16px;
|
||||
font-weight: bold;
|
||||
}
|
||||
div.game-version {
|
||||
font-size: 12px;
|
||||
font-weight: bold;
|
||||
}
|
||||
div.index
|
||||
{
|
||||
font-size: 14px;
|
||||
font-weight: bold;
|
||||
}
|
||||
div.spacer
|
||||
{
|
||||
font-size: 14px;
|
||||
}
|
||||
div.caption
|
||||
{
|
||||
font-size: 10px;
|
||||
font-weight: bold;
|
||||
}
|
||||
hr {
|
||||
width: 1000px;
|
||||
margin-left: 0;
|
||||
}
|
||||
tr {
|
||||
text-align: left;
|
||||
}
|
||||
th {
|
||||
font-size: 12px;
|
||||
background-color: #D6D3CE;
|
||||
color: black;
|
||||
}
|
||||
th.name {
|
||||
width: 200px;
|
||||
}
|
||||
th.type {
|
||||
width: 100px;
|
||||
}
|
||||
th.range {
|
||||
width: 100px;
|
||||
}
|
||||
th.msg {
|
||||
width: 600px;
|
||||
}
|
||||
td {
|
||||
font-weight: normal;
|
||||
font-size: 12px;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<xsl:apply-templates />
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="twl-master-editor">
|
||||
<xsl:apply-templates select="game" />
|
||||
<hr />
|
||||
<div class="index">Error</div>
|
||||
<xsl:apply-templates select="error-list" />
|
||||
<hr />
|
||||
<div class="index">Warning</div>
|
||||
<xsl:apply-templates select="warning-list" />
|
||||
<hr />
|
||||
<div class="caption">
|
||||
* Type 0 indicates problems with the ROM data that cannot be corrected using MasterEditorTWL.
|
||||
</div>
|
||||
<div class="caption">
|
||||
* Type 1 indicates problems with the ROM data that can be corrected using MasterEditorTWL.
|
||||
</div>
|
||||
<hr />
|
||||
<div class="footer">
|
||||
generated by MasterEditorTWL ver. <xsl:value-of select="@version" />
|
||||
</div>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="game">
|
||||
<div class="game-title">
|
||||
<xsl:value-of select="title-name" />(<xsl:value-of select="game-code" />)
|
||||
</div>
|
||||
<div class="game-version">
|
||||
version: <xsl:value-of select="rom-version" />
|
||||
</div>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="error-list">
|
||||
<table cellspacing="0">
|
||||
<tr>
|
||||
<th class="name">Item Name</th>
|
||||
<th class="type">Type</th>
|
||||
<th class="msg">Reason</th>
|
||||
</tr>
|
||||
|
||||
<xsl:apply-templates />
|
||||
|
||||
</table>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="error">
|
||||
<tr>
|
||||
<td class="name"><xsl:value-of select="name" /></td>
|
||||
<td class="type"><xsl:value-of select="type" /></td>
|
||||
<td class="msg"><xsl:value-of select="msg" /></td>
|
||||
</tr>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="warning-list">
|
||||
<table cellspacing="0">
|
||||
<tr>
|
||||
<th class="name">Item Name</th>
|
||||
<th class="type">Type</th>
|
||||
<th class="msg">Reason</th>
|
||||
</tr>
|
||||
|
||||
<xsl:apply-templates />
|
||||
|
||||
</table>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="warning">
|
||||
<tr>
|
||||
<td class="name"><xsl:value-of select="name" /></td>
|
||||
<td class="type"><xsl:value-of select="type" /></td>
|
||||
<td class="msg"><xsl:value-of select="msg" /></td>
|
||||
</tr>
|
||||
</xsl:template>
|
||||
|
||||
</xsl:stylesheet>
|
||||
@ -77,6 +77,11 @@ Exception:{0}
|
||||
<E_MWList_Default>Failed to create the middleware list.</E_MWList_Default>
|
||||
<MWList_Success>Succeeded in creating middleware list.</MWList_Success>
|
||||
|
||||
<!-- Export Error List -->
|
||||
<E_ErrList_Empty>ROM data file has not been read.</E_ErrList_Empty>
|
||||
<E_ErrList_Default>Failed to create the error list.</E_ErrList_Default>
|
||||
<ErrList_Success>Succeeded in creating error list.</ErrList_Success>
|
||||
|
||||
<!-- Save Temp File -->
|
||||
<E_SaveTemp>Failed to save temporary information.</E_SaveTemp>
|
||||
|
||||
|
||||
@ -77,6 +77,11 @@
|
||||
<E_MWList_Default>ミドルウェアリストの作成に失敗しました。</E_MWList_Default>
|
||||
<MWList_Success>ミドルウェアリストの作成に成功しました。</MWList_Success>
|
||||
|
||||
<!-- Export Error List -->
|
||||
<E_ErrList_Empty>ROMデータファイルが読み込まれていません。</E_ErrList_Empty>
|
||||
<E_ErrList_Default>エラーリストの作成に失敗しました。</E_ErrList_Default>
|
||||
<ErrList_Success>エラーリストの作成に成功しました。</ErrList_Success>
|
||||
|
||||
<!-- Save Temp File -->
|
||||
<E_SaveTemp>一時情報の保存に失敗しました。</E_SaveTemp>
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user