Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
D
DataEditorX
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
聖園ミカ
DataEditorX
Commits
ca0729aa
Commit
ca0729aa
authored
Jun 09, 2020
by
JoyJ
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
code format
parent
c45b91fe
Changes
15
Hide whitespace changes
Inline
Side-by-side
Showing
15 changed files
with
63 additions
and
63 deletions
+63
-63
DataEditorX/CodeEditForm.cs
DataEditorX/CodeEditForm.cs
+3
-3
DataEditorX/Common/CheckUpdate.cs
DataEditorX/Common/CheckUpdate.cs
+4
-4
DataEditorX/Common/MyPath.cs
DataEditorX/Common/MyPath.cs
+2
-2
DataEditorX/Common/User32.cs
DataEditorX/Common/User32.cs
+1
-1
DataEditorX/Common/XMLReader.cs
DataEditorX/Common/XMLReader.cs
+3
-3
DataEditorX/Common/ZipStorer.cs
DataEditorX/Common/ZipStorer.cs
+5
-5
DataEditorX/Config/MyConfig.cs
DataEditorX/Config/MyConfig.cs
+8
-8
DataEditorX/Controls/FastColoredTextBoxEx.cs
DataEditorX/Controls/FastColoredTextBoxEx.cs
+12
-12
DataEditorX/Controls/MySyntaxHighlighter.cs
DataEditorX/Controls/MySyntaxHighlighter.cs
+9
-9
DataEditorX/Core/DataBase.cs
DataEditorX/Core/DataBase.cs
+2
-2
DataEditorX/Core/Mse/MSEConfig.cs
DataEditorX/Core/Mse/MSEConfig.cs
+3
-3
DataEditorX/Core/Mse/MseMaker.cs
DataEditorX/Core/Mse/MseMaker.cs
+3
-3
DataEditorX/Core/TaskHelper.cs
DataEditorX/Core/TaskHelper.cs
+1
-1
DataEditorX/DataEditForm.cs
DataEditorX/DataEditForm.cs
+6
-6
DataEditorX/MainForm.cs
DataEditorX/MainForm.cs
+1
-1
No files found.
DataEditorX/CodeEditForm.cs
View file @
ca0729aa
...
...
@@ -79,14 +79,14 @@ void InitForm()
}
Font
ft
=
new
Font
(
this
.
fctb
.
Font
.
Name
,
this
.
fctb
.
Font
.
Size
/
1.2f
,
FontStyle
.
Regular
);
this
.
popupMenu
=
new
FastColoredTextBoxNS
.
AutocompleteMenu
(
this
.
fctb
)
this
.
popupMenu
=
new
AutocompleteMenu
(
this
.
fctb
)
{
MinFragmentLength
=
2
};
this
.
popupMenu
.
ToolTip
.
Popup
+=
this
.
ToolTip_Popup
;
this
.
popupMenu
.
Items
.
Font
=
ft
;
this
.
popupMenu
.
AutoSize
=
true
;
this
.
popupMenu
.
MinimumSize
=
new
S
ystem
.
Drawing
.
S
ize
(
300
,
0
);
this
.
popupMenu
.
MinimumSize
=
new
Size
(
300
,
0
);
this
.
popupMenu
.
BackColor
=
this
.
fctb
.
BackColor
;
this
.
popupMenu
.
ForeColor
=
this
.
fctb
.
ForeColor
;
this
.
popupMenu
.
Closed
+=
new
ToolStripDropDownClosedEventHandler
(
this
.
popupMenu_Closed
);
...
...
@@ -567,7 +567,7 @@ void FctbMouseClick(object sender, MouseEventArgs e)
return
;
}
if
(
e
.
Button
==
MouseButtons
.
Left
&&
Control
.
ModifierKeys
==
Keys
.
Control
)
if
(
e
.
Button
==
MouseButtons
.
Left
&&
ModifierKeys
==
Keys
.
Control
)
{
List
<
int
>
linenums
=
this
.
fctb
.
FindLines
(
@"function\s+?\S+?\."
+
text
+
@"\("
,
RegexOptions
.
Singleline
);
if
(
linenums
.
Count
>
0
)
...
...
DataEditorX/Common/CheckUpdate.cs
View file @
ca0729aa
...
...
@@ -146,21 +146,21 @@ public static bool DownLoad(string filename)
File
.
Delete
(
filename
);
}
HttpWebRequest
Myrq
=
(
HttpWebRequest
)
System
.
Net
.
Http
WebRequest
.
Create
(
URL
);
HttpWebRequest
Myrq
=
(
HttpWebRequest
)
WebRequest
.
Create
(
URL
);
HttpWebResponse
myrp
=
(
HttpWebResponse
)
Myrq
.
GetResponse
();
long
totalBytes
=
myrp
.
ContentLength
;
Stream
st
=
myrp
.
GetResponseStream
();
Stream
so
=
new
System
.
IO
.
FileStream
(
filename
+
".tmp"
,
FileMode
.
Create
);
Stream
so
=
new
FileStream
(
filename
+
".tmp"
,
FileMode
.
Create
);
long
totalDownloadedByte
=
0
;
byte
[]
by
=
new
byte
[
1024
*
512
];
int
osize
=
st
.
Read
(
by
,
0
,
(
int
)
by
.
Length
);
int
osize
=
st
.
Read
(
by
,
0
,
by
.
Length
);
while
(
osize
>
0
)
{
totalDownloadedByte
=
osize
+
totalDownloadedByte
;
System
.
Windows
.
Forms
.
Application
.
DoEvents
();
so
.
Write
(
by
,
0
,
osize
);
osize
=
st
.
Read
(
by
,
0
,
(
int
)
by
.
Length
);
osize
=
st
.
Read
(
by
,
0
,
by
.
Length
);
}
so
.
Close
();
st
.
Close
();
...
...
DataEditorX/Common/MyPath.cs
View file @
ca0729aa
...
...
@@ -26,7 +26,7 @@ public static string GetRealPath(string dir)
string
path
=
Application
.
StartupPath
;
if
(
dir
.
StartsWith
(
"."
))
{
dir
=
MyPath
.
Combine
(
path
,
dir
.
Substring
(
2
));
dir
=
Combine
(
path
,
dir
.
Substring
(
2
));
}
return
dir
;
}
...
...
@@ -89,7 +89,7 @@ public static string CheckDir(string dir,string defalut)
DirectoryInfo
fo
;
try
{
fo
=
new
DirectoryInfo
(
MyPath
.
GetRealPath
(
dir
));
fo
=
new
DirectoryInfo
(
GetRealPath
(
dir
));
}
catch
{
//路径不合法
...
...
DataEditorX/Common/User32.cs
View file @
ca0729aa
...
...
@@ -43,6 +43,6 @@ public class User32
/// </summary>
/// <returns></returns>
[
DllImport
(
"user32.dll"
,
CharSet
=
CharSet
.
Auto
)]
public
static
extern
System
.
IntPtr
GetForegroundWindow
();
public
static
extern
IntPtr
GetForegroundWindow
();
}
}
\ No newline at end of file
DataEditorX/Common/XMLReader.cs
View file @
ca0729aa
...
...
@@ -19,7 +19,7 @@ public class XMLReader
public
static
void
Save
(
string
appKey
,
string
appValue
)
{
XmlDocument
xDoc
=
new
XmlDocument
();
xDoc
.
Load
(
System
.
Windows
.
Forms
.
Application
.
ExecutablePath
+
".config"
);
xDoc
.
Load
(
Application
.
ExecutablePath
+
".config"
);
XmlNode
xNode
=
xDoc
.
SelectSingleNode
(
"//appSettings"
);
...
...
@@ -35,7 +35,7 @@ public static void Save(string appKey, string appValue)
xNewElem
.
SetAttribute
(
"value"
,
appValue
);
xNode
.
AppendChild
(
xNewElem
);
}
xDoc
.
Save
(
System
.
Windows
.
Forms
.
Application
.
ExecutablePath
+
".config"
);
xDoc
.
Save
(
Application
.
ExecutablePath
+
".config"
);
}
/// <summary>
/// 获取值
...
...
@@ -45,7 +45,7 @@ public static void Save(string appKey, string appValue)
public
static
string
GetAppConfig
(
string
appKey
)
{
XmlDocument
xDoc
=
new
XmlDocument
();
xDoc
.
Load
(
System
.
Windows
.
Forms
.
Application
.
ExecutablePath
+
".config"
);
xDoc
.
Load
(
Application
.
ExecutablePath
+
".config"
);
XmlNode
xNode
=
xDoc
.
SelectSingleNode
(
"//appSettings"
);
...
...
DataEditorX/Common/ZipStorer.cs
View file @
ca0729aa
...
...
@@ -183,7 +183,7 @@ public static ZipStorer Open(Stream _stream, FileAccess _access)
return
zip
;
}
throw
new
System
.
IO
.
InvalidDataException
();
throw
new
InvalidDataException
();
}
/// <summary>
/// Add full contents of a file into the Zip storage
...
...
@@ -380,7 +380,7 @@ public List<ZipFileEntry> ReadCentralDir()
public
bool
ExtractFile
(
ZipFileEntry
_zfe
,
string
_filename
)
{
// Make sure the parent directory exist
string
path
=
System
.
IO
.
Path
.
GetDirectoryName
(
_filename
);
string
path
=
Path
.
GetDirectoryName
(
_filename
);
if
(!
Directory
.
Exists
(
path
))
{
...
...
@@ -485,7 +485,7 @@ public static bool RemoveEntries(ref ZipStorer _zip, List<ZipFileEntry> _zfes)
try
{
ZipStorer
tempZip
=
ZipStorer
.
Create
(
tempZipName
,
string
.
Empty
);
ZipStorer
tempZip
=
Create
(
tempZipName
,
string
.
Empty
);
foreach
(
ZipFileEntry
zfe
in
fullList
)
{
...
...
@@ -503,7 +503,7 @@ public static bool RemoveEntries(ref ZipStorer _zip, List<ZipFileEntry> _zfes)
File
.
Delete
(
_zip
.
fileName
);
File
.
Move
(
tempZipName
,
_zip
.
fileName
);
_zip
=
ZipStorer
.
Open
(
_zip
.
fileName
,
_zip
.
access
);
_zip
=
Open
(
_zip
.
fileName
,
_zip
.
access
);
}
catch
{
...
...
@@ -682,7 +682,7 @@ private void Store(ref ZipFileEntry _zfe, Stream _source)
for
(
uint
i
=
0
;
i
<
bytesRead
;
i
++)
{
_zfe
.
Crc32
=
ZipStorer
.
_crcTable
[(
_zfe
.
Crc32
^
buffer
[
i
])
&
0xFF
]
^
(
_zfe
.
Crc32
>>
8
);
_zfe
.
Crc32
=
_crcTable
[(
_zfe
.
Crc32
^
buffer
[
i
])
&
0xFF
]
^
(
_zfe
.
Crc32
>>
8
);
}
}
}
while
(
bytesRead
==
buffer
.
Length
);
...
...
DataEditorX/Config/MyConfig.cs
View file @
ca0729aa
...
...
@@ -288,7 +288,7 @@ public static string GetLanguageFile(string path)
string
[]
files
=
Directory
.
GetFiles
(
path
);
foreach
(
string
file
in
files
)
{
string
name
=
MyPath
.
GetFullFileName
(
MyConfig
.
TAG_LANGUAGE
,
file
);
string
name
=
MyPath
.
GetFullFileName
(
TAG_LANGUAGE
,
file
);
if
(
string
.
IsNullOrEmpty
(
name
))
{
continue
;
...
...
@@ -296,12 +296,12 @@ public static string GetLanguageFile(string path)
if
(
syslang
.
Equals
(
name
,
StringComparison
.
OrdinalIgnoreCase
))
{
Save
(
MyConfig
.
TAG_LANGUAGE
,
syslang
);
Save
(
TAG_LANGUAGE
,
syslang
);
break
;
}
}
}
return
MyPath
.
Combine
(
path
,
MyPath
.
GetFileName
(
MyConfig
.
TAG_LANGUAGE
,
GetAppConfig
(
TAG_LANGUAGE
)));
return
MyPath
.
Combine
(
path
,
MyPath
.
GetFileName
(
TAG_LANGUAGE
,
GetAppConfig
(
TAG_LANGUAGE
)));
}
/// <summary>
/// 卡片信息配置文件名
...
...
@@ -310,7 +310,7 @@ public static string GetLanguageFile(string path)
/// <returns></returns>
public
static
string
GetCardInfoFile
(
string
path
)
{
return
MyPath
.
Combine
(
path
,
MyPath
.
GetFileName
(
MyConfig
.
TAG_CARDINFO
,
GetAppConfig
(
TAG_LANGUAGE
)));
return
MyPath
.
Combine
(
path
,
MyPath
.
GetFileName
(
TAG_CARDINFO
,
GetAppConfig
(
TAG_LANGUAGE
)));
}
/// <summary>
/// 发送消息打开文件
...
...
@@ -327,20 +327,20 @@ public static bool OpenOnExistForm(string file)
else
{
//把需要打开的文件写入临时文件
string
tmpfile
=
Path
.
Combine
(
Application
.
StartupPath
,
MyConfig
.
FILE_TEMP
);
string
tmpfile
=
Path
.
Combine
(
Application
.
StartupPath
,
FILE_TEMP
);
File
.
WriteAllText
(
tmpfile
,
file
);
//发送消息
User32
.
SendMessage
(
instance
.
MainWindowHandle
,
MyConfig
.
WM_OPEN
,
0
,
0
);
User32
.
SendMessage
(
instance
.
MainWindowHandle
,
WM_OPEN
,
0
,
0
);
return
true
;
}
}
public
static
void
OpenFileInThis
(
string
file
)
{
//把需要打开的文件写入临时文件
string
tmpfile
=
Path
.
Combine
(
Application
.
StartupPath
,
MyConfig
.
FILE_TEMP
);
string
tmpfile
=
Path
.
Combine
(
Application
.
StartupPath
,
FILE_TEMP
);
File
.
WriteAllText
(
tmpfile
,
file
);
//发送消息
User32
.
SendMessage
(
Process
.
GetCurrentProcess
().
MainWindowHandle
,
MyConfig
.
WM_OPEN
,
0
,
0
);
User32
.
SendMessage
(
Process
.
GetCurrentProcess
().
MainWindowHandle
,
WM_OPEN
,
0
,
0
);
}
public
static
Process
RunningInstance
(
string
filename
)
{
...
...
DataEditorX/Controls/FastColoredTextBoxEx.cs
View file @
ca0729aa
...
...
@@ -119,31 +119,31 @@ void FctbTextChanged(object sender, TextChangedEventArgs e)
private
void
InitializeComponent
()
{
this
.
lbTooltip
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
lbTooltip
=
new
Label
();
((
System
.
ComponentModel
.
ISupportInitialize
)(
this
)).
BeginInit
();
this
.
SuspendLayout
();
//
// lbTooltip
//
this
.
lbTooltip
.
AutoSize
=
true
;
this
.
lbTooltip
.
BackColor
=
System
.
Drawing
.
System
Colors
.
Desktop
;
this
.
lbTooltip
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
15.75F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
0
)));
this
.
lbTooltip
.
ForeColor
=
System
.
Drawing
.
System
Colors
.
Control
;
this
.
lbTooltip
.
Location
=
new
System
.
Drawing
.
Point
(
221
,
117
);
this
.
lbTooltip
.
MaximumSize
=
new
S
ystem
.
Drawing
.
S
ize
(
480
,
0
);
this
.
lbTooltip
.
BackColor
=
SystemColors
.
Desktop
;
this
.
lbTooltip
.
Font
=
new
Font
(
"微软雅黑"
,
15.75F
,
FontStyle
.
Regular
,
GraphicsUnit
.
Point
,
((
byte
)(
0
)));
this
.
lbTooltip
.
ForeColor
=
SystemColors
.
Control
;
this
.
lbTooltip
.
Location
=
new
Point
(
221
,
117
);
this
.
lbTooltip
.
MaximumSize
=
new
Size
(
480
,
0
);
this
.
lbTooltip
.
Name
=
"lbTooltip"
;
this
.
lbTooltip
.
Size
=
new
S
ystem
.
Drawing
.
S
ize
(
0
,
28
);
this
.
lbTooltip
.
Size
=
new
Size
(
0
,
28
);
this
.
lbTooltip
.
TabIndex
=
1
;
this
.
lbTooltip
.
MouseMove
+=
new
System
.
Windows
.
Forms
.
MouseEventHandler
(
this
.
lbTooltip_MouseMove
);
this
.
lbTooltip
.
MouseMove
+=
new
MouseEventHandler
(
this
.
lbTooltip_MouseMove
);
//
// FastColoredTextBoxEx
//
this
.
AutoScrollMinSize
=
new
S
ystem
.
Drawing
.
S
ize
(
27
,
14
);
this
.
BackColor
=
System
.
Drawing
.
System
Colors
.
Control
;
this
.
AutoScrollMinSize
=
new
Size
(
27
,
14
);
this
.
BackColor
=
SystemColors
.
Control
;
this
.
Controls
.
Add
(
this
.
lbTooltip
);
this
.
Name
=
"FastColoredTextBoxEx"
;
this
.
Size
=
new
S
ystem
.
Drawing
.
S
ize
(
584
,
327
);
this
.
Load
+=
new
System
.
EventHandler
(
this
.
FastColoredTextBoxEx_Load
);
this
.
Size
=
new
Size
(
584
,
327
);
this
.
Load
+=
new
EventHandler
(
this
.
FastColoredTextBoxEx_Load
);
((
System
.
ComponentModel
.
ISupportInitialize
)(
this
)).
EndInit
();
this
.
ResumeLayout
(
false
);
this
.
PerformLayout
();
...
...
DataEditorX/Controls/MySyntaxHighlighter.cs
View file @
ca0729aa
...
...
@@ -47,23 +47,23 @@ public override void LuaSyntaxHighlight(Range range)
//clear style of changed range
range
.
ClearStyle
(
this
.
mStrStyle
,
this
.
mGrayStyle
,
this
.
conStyle
,
this
.
mNumberStyle
,
this
.
mKeywordStyle
,
this
.
mFunStyle
);
//
if
(
base
.
LuaStringRegex
==
null
)
if
(
LuaStringRegex
==
null
)
{
base
.
InitLuaRegex
();
InitLuaRegex
();
}
//string highlighting
range
.
SetStyle
(
this
.
mStrStyle
,
base
.
LuaStringRegex
);
range
.
SetStyle
(
this
.
mStrStyle
,
LuaStringRegex
);
//comment highlighting
range
.
SetStyle
(
this
.
mGrayStyle
,
base
.
LuaCommentRegex1
);
range
.
SetStyle
(
this
.
mGrayStyle
,
base
.
LuaCommentRegex2
);
range
.
SetStyle
(
this
.
mGrayStyle
,
base
.
LuaCommentRegex3
);
range
.
SetStyle
(
this
.
mGrayStyle
,
LuaCommentRegex1
);
range
.
SetStyle
(
this
.
mGrayStyle
,
LuaCommentRegex2
);
range
.
SetStyle
(
this
.
mGrayStyle
,
LuaCommentRegex3
);
//number highlighting
range
.
SetStyle
(
this
.
mNumberStyle
,
base
.
LuaNumberRegex
);
range
.
SetStyle
(
this
.
mNumberStyle
,
LuaNumberRegex
);
//keyword highlighting
range
.
SetStyle
(
this
.
mKeywordStyle
,
base
.
LuaKeywordRegex
);
range
.
SetStyle
(
this
.
mKeywordStyle
,
LuaKeywordRegex
);
//functions highlighting
range
.
SetStyle
(
this
.
mFunStyle
,
base
.
LuaFunctionsRegex
);
range
.
SetStyle
(
this
.
mFunStyle
,
LuaFunctionsRegex
);
range
.
SetStyle
(
this
.
mNumberStyle
,
@"\bc\d+\b"
);
range
.
SetStyle
(
this
.
conStyle
,
@"[\s|\(|+|,]{0,1}(?<range>[A-Z_]+?)[\)|+|\s|,|;]"
);
...
...
DataEditorX/Core/DataBase.cs
View file @
ca0729aa
...
...
@@ -273,7 +273,7 @@ public static int CopyDB(string DB, bool ignore, params Card[] cards)
{
foreach
(
Card
c
in
cards
)
{
cmd
.
CommandText
=
DataBase
.
GetInsertSQL
(
c
,
ignore
);
cmd
.
CommandText
=
GetInsertSQL
(
c
,
ignore
);
result
+=
cmd
.
ExecuteNonQuery
();
}
}
...
...
@@ -301,7 +301,7 @@ public static int DeleteDB(string DB, params Card[] cards)
{
foreach
(
Card
c
in
cards
)
{
cmd
.
CommandText
=
DataBase
.
GetDeleteSQL
(
c
);
cmd
.
CommandText
=
GetDeleteSQL
(
c
);
result
+=
cmd
.
ExecuteNonQuery
();
}
}
...
...
DataEditorX/Core/Mse/MSEConfig.cs
View file @
ca0729aa
...
...
@@ -75,7 +75,7 @@ public void SetConfig(string config, string path)
this
.
regx_monster
=
"(\\s\\S*?)"
;
this
.
regx_pendulum
=
"(\\s\\S*?)"
;
//设置文件名
this
.
configName
=
MyPath
.
GetFullFileName
(
MSEConfig
.
TAG
,
config
);
this
.
configName
=
MyPath
.
GetFullFileName
(
TAG
,
config
);
this
.
replaces
=
new
SortedList
<
string
,
string
>();
...
...
@@ -184,11 +184,11 @@ public void Init(string path)
this
.
Iscn2tw
=
false
;
//读取配置
string
tmp
=
MyPath
.
Combine
(
path
,
MyPath
.
GetFileName
(
MSEConfig
.
TAG
,
MyConfig
.
ReadString
(
MyConfig
.
TAG_MSE
)));
string
tmp
=
MyPath
.
Combine
(
path
,
MyPath
.
GetFileName
(
TAG
,
MyConfig
.
ReadString
(
MyConfig
.
TAG_MSE
)));
if
(!
File
.
Exists
(
tmp
))
{
tmp
=
MyPath
.
Combine
(
path
,
MyPath
.
GetFileName
(
MSEConfig
.
TAG
,
FILE_CONFIG_NAME
));
tmp
=
MyPath
.
Combine
(
path
,
MyPath
.
GetFileName
(
TAG
,
FILE_CONFIG_NAME
));
if
(!
File
.
Exists
(
tmp
))
{
return
;
//如果默认的也不存在
...
...
DataEditorX/Core/Mse/MseMaker.cs
View file @
ca0729aa
...
...
@@ -908,14 +908,14 @@ public Card[] ReadCards(string set, bool repalceOld)
private
static
void
exportSetThread
(
object
obj
){
string
[]
args
=(
string
[])
obj
;
if
(
args
==
null
||
args
.
Length
<
3
){
System
.
Windows
.
Forms
.
MessageBox
.
Show
(
Language
.
LanguageHelper
.
GetMsg
(
LMSG
.
exportMseImagesErr
));
MessageBox
.
Show
(
LanguageHelper
.
GetMsg
(
LMSG
.
exportMseImagesErr
));
return
;
}
string
mse_path
=
args
[
0
];
string
setfile
=
args
[
1
];
string
path
=
args
[
2
];
if
(
string
.
IsNullOrEmpty
(
mse_path
)||
string
.
IsNullOrEmpty
(
setfile
)){
System
.
Windows
.
Forms
.
MessageBox
.
Show
(
Language
.
LanguageHelper
.
GetMsg
(
LMSG
.
exportMseImagesErr
));
MessageBox
.
Show
(
LanguageHelper
.
GetMsg
(
LMSG
.
exportMseImagesErr
));
return
;
}
else
{
string
cmd
=
" --export "
+
setfile
.
Replace
(
"\\\\"
,
"\\"
).
Replace
(
"\\"
,
"/"
)+
" {card.gamecode}.png"
;
...
...
@@ -932,7 +932,7 @@ public Card[] ReadCards(string set, bool repalceOld)
_mseProcess
.
Exited
+=
new
EventHandler
(
_exitHandler
);
_mseProcess
.
Close
();
_mseProcess
=
null
;
System
.
Windows
.
Forms
.
MessageBox
.
Show
(
Language
.
LanguageHelper
.
GetMsg
(
LMSG
.
exportMseImages
));
MessageBox
.
Show
(
LanguageHelper
.
GetMsg
(
LMSG
.
exportMseImages
));
}
catch
{
}
...
...
DataEditorX/Core/TaskHelper.cs
View file @
ca0729aa
...
...
@@ -181,7 +181,7 @@ public static void CheckVersion(bool showNew)
}
public
void
OnCheckUpdate
(
bool
showNew
)
{
TaskHelper
.
CheckVersion
(
showNew
);
CheckVersion
(
showNew
);
}
#
endregion
...
...
DataEditorX/DataEditForm.cs
View file @
ca0729aa
...
...
@@ -1813,7 +1813,7 @@ void SetMseConfig_Click(object sender, EventArgs e)
//刷新菜单
this
.
AddMenuItemFormMSE
();
//保存配置
MyConfig
.
Save
(
MyConfig
.
TAG_MSE
,
tsmi
.
Text
);
XMLReader
.
Save
(
MyConfig
.
TAG_MSE
,
tsmi
.
Text
);
}
}
#
endregion
...
...
@@ -1964,26 +1964,26 @@ private void menuitem_compdb_Click(object sender, EventArgs e)
private
void
menuitem_deletecardsfile_Click
(
object
sender
,
EventArgs
e
)
{
this
.
menuitem_operacardsfile
.
Checked
=
!
this
.
menuitem_operacardsfile
.
Checked
;
MyConfig
.
Save
(
MyConfig
.
TAG_DELETE_WITH
,
this
.
menuitem_operacardsfile
.
Checked
.
ToString
().
ToLower
());
XMLReader
.
Save
(
MyConfig
.
TAG_DELETE_WITH
,
this
.
menuitem_operacardsfile
.
Checked
.
ToString
().
ToLower
());
}
//用CodeEditor打开lua
private
void
menuitem_openfileinthis_Click
(
object
sender
,
EventArgs
e
)
{
this
.
menuitem_openfileinthis
.
Checked
=
!
this
.
menuitem_openfileinthis
.
Checked
;
MyConfig
.
Save
(
MyConfig
.
TAG_OPEN_IN_THIS
,
this
.
menuitem_openfileinthis
.
Checked
.
ToString
().
ToLower
());
XMLReader
.
Save
(
MyConfig
.
TAG_OPEN_IN_THIS
,
this
.
menuitem_openfileinthis
.
Checked
.
ToString
().
ToLower
());
}
//自动检查更新
private
void
menuitem_autocheckupdate_Click
(
object
sender
,
EventArgs
e
)
{
this
.
menuitem_autocheckupdate
.
Checked
=
!
this
.
menuitem_autocheckupdate
.
Checked
;
MyConfig
.
Save
(
MyConfig
.
TAG_AUTO_CHECK_UPDATE
,
this
.
menuitem_autocheckupdate
.
Checked
.
ToString
().
ToLower
());
XMLReader
.
Save
(
MyConfig
.
TAG_AUTO_CHECK_UPDATE
,
this
.
menuitem_autocheckupdate
.
Checked
.
ToString
().
ToLower
());
}
//add require automatically
private
void
menuitem_addrequire_Click
(
object
sender
,
EventArgs
e
)
{
this
.
Addrequire
=
Microsoft
.
VisualBasic
.
Interaction
.
InputBox
(
"Module script?\n\nPress \"Cancel\" to remove module script."
,
""
,
this
.
Addrequire
);
this
.
menuitem_addrequire
.
Checked
=
(
this
.
Addrequire
.
Length
>
0
);
MyConfig
.
Save
(
MyConfig
.
TAG_ADD_REQUIRE
,
this
.
Addrequire
);
XMLReader
.
Save
(
MyConfig
.
TAG_ADD_REQUIRE
,
this
.
Addrequire
);
}
#
endregion
...
...
@@ -2028,7 +2028,7 @@ void SetLanguage_Click(object sender, EventArgs e)
if
(
sender
is
ToolStripMenuItem
tsmi
)
{
MyConfig
.
Save
(
MyConfig
.
TAG_LANGUAGE
,
tsmi
.
Text
);
XMLReader
.
Save
(
MyConfig
.
TAG_LANGUAGE
,
tsmi
.
Text
);
this
.
GetLanguageItem
();
MyMsg
.
Show
(
LMSG
.
PlzRestart
);
}
...
...
DataEditorX/MainForm.cs
View file @
ca0729aa
...
...
@@ -156,7 +156,7 @@ public void AddLuaMenu(ToolStripItem item)
#
endregion
#
region
处理窗口消息
protected
override
void
DefWndProc
(
ref
System
.
Windows
.
Forms
.
Message
m
)
protected
override
void
DefWndProc
(
ref
Message
m
)
{
switch
(
m
.
Msg
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment