Commit c99eb604 authored by keyongyu's avatar keyongyu

2.2.8.0

parent a7145efa
...@@ -363,8 +363,8 @@ void AboutToolStripMenuItemClick(object sender, EventArgs e) ...@@ -363,8 +363,8 @@ void AboutToolStripMenuItemClick(object sender, EventArgs e)
MyMsg.Show( MyMsg.Show(
LANG.GetMsg(LMSG.About)+"\t"+Application.ProductName+"\n" LANG.GetMsg(LMSG.About)+"\t"+Application.ProductName+"\n"
+LANG.GetMsg(LMSG.Version)+"\t1.1.0.0\n" +LANG.GetMsg(LMSG.Version)+"\t1.1.0.0\n"
+LANG.GetMsg(LMSG.Author)+"\t247321453\n" + LANG.GetMsg(LMSG.Author) + "\t柯永裕\n"
+"Email:\tkeyoyu@foxmail.com"); +"Email:\t247321453@qq.com\n\n我的支付宝账户就是Email,谢谢大家捐助。");
} }
void Menuitem_openClick(object sender, EventArgs e) void Menuitem_openClick(object sender, EventArgs e)
......
...@@ -199,15 +199,15 @@ public string idString ...@@ -199,15 +199,15 @@ public string idString
public bool IsSetCode(long sc) public bool IsSetCode(long sc)
{ {
if((this.setcode&0xffff)==sc) long settype = sc & 0xfff;
return true; long setsubtype = sc & 0xf000;
else if(((this.setcode>>0x10)&0xffff)==sc) long setcode = this.setcode;
return true; while (setcode != 0)
else if(((this.setcode>>0x20)&0xffff)==sc) {
return true; if ((setcode & 0xfff) == settype && (setcode & 0xf000 & setsubtype) == setsubtype)
else if(((this.setcode>>0x30)&0xffff)==sc)
return true; return true;
else setcode = setcode >> 0x10;
}
return false; return false;
} }
/// <summary> /// <summary>
......
...@@ -70,36 +70,40 @@ public void Cancel() ...@@ -70,36 +70,40 @@ public void Cancel()
cardlist=cards; cardlist=cards;
mArgs=args; mArgs=args;
} }
public void OnCheckUpdate(bool showNew){ public static void CheckVersion(bool showNew)
string newver=CheckUpdate.Check( {
string newver = CheckUpdate.Check(
ConfigurationManager.AppSettings["updateURL"]); ConfigurationManager.AppSettings["updateURL"]);
int iver,iver2; int iver, iver2;
int.TryParse(Application.ProductVersion.Replace(".",""), out iver); int.TryParse(Application.ProductVersion.Replace(".", ""), out iver);
int.TryParse(newver.Replace(".",""), out iver2); int.TryParse(newver.Replace(".", ""), out iver2);
if(iver2>iver) if (iver2 > iver)
{//has new version {//has new version
if(!MyMsg.Question(LMSG.HaveNewVersion)) if (!MyMsg.Question(LMSG.HaveNewVersion))
return; return;
} }
else if(iver2>0) else if (iver2 > 0)
{//now is last version {//now is last version
if(!showNew) if (!showNew)
return; return;
if(!MyMsg.Question(LMSG.NowIsNewVersion)) if (!MyMsg.Question(LMSG.NowIsNewVersion))
return; return;
} }
else else
{ {
if(!showNew) if (!showNew)
return; return;
MyMsg.Error(LMSG.CheckUpdateFail); MyMsg.Error(LMSG.CheckUpdateFail);
return; return;
} }
if(CheckUpdate.DownLoad( if (CheckUpdate.DownLoad(
MyPath.Combine(Application.StartupPath, newver+".zip"))) MyPath.Combine(Application.StartupPath, newver + ".zip")))
MyMsg.Show(LMSG.DownloadSucceed); MyMsg.Show(LMSG.DownloadSucceed);
else else
MyMsg.Show(LMSG.DownloadFail); MyMsg.Show(LMSG.DownloadFail);
}
public void OnCheckUpdate(bool showNew){
TaskHelper.CheckVersion(showNew);
} }
public void CutImages(string imgpath,bool isreplace) public void CutImages(string imgpath,bool isreplace)
{ {
......
...@@ -102,9 +102,9 @@ void DataEditFormLoad(object sender, EventArgs e) ...@@ -102,9 +102,9 @@ void DataEditFormLoad(object sender, EventArgs e)
oldCard=new Card(0); oldCard=new Card(0);
SetCard(oldCard); SetCard(oldCard);
if(File.Exists(nowCdbFile)) if (nowCdbFile !=null && File.Exists(nowCdbFile))
Open(nowCdbFile); Open(nowCdbFile);
//checkupdate(false);//检查更新 // CheckUpdate(false);//检查更新
} }
//窗体关闭 //窗体关闭
void DataEditFormFormClosing(object sender, FormClosingEventArgs e) void DataEditFormFormClosing(object sender, FormClosingEventArgs e)
...@@ -982,15 +982,15 @@ void Menuitem_aboutClick(object sender, EventArgs e) ...@@ -982,15 +982,15 @@ void Menuitem_aboutClick(object sender, EventArgs e)
MyMsg.Show( MyMsg.Show(
LANG.GetMsg(LMSG.About)+"\t"+Application.ProductName+"\n" LANG.GetMsg(LMSG.About)+"\t"+Application.ProductName+"\n"
+LANG.GetMsg(LMSG.Version)+"\t"+Application.ProductVersion+"\n" +LANG.GetMsg(LMSG.Version)+"\t"+Application.ProductVersion+"\n"
+LANG.GetMsg(LMSG.Author)+"\t247321453\n" + LANG.GetMsg(LMSG.Author) + "\t柯永裕\n"
+"Email:\tkeyoyu@foxmail.com"); + "Email:\t247321453@qq.com\n\n我的支付宝账户就是Email,谢谢大家捐助。");
} }
void Menuitem_checkupdateClick(object sender, EventArgs e) void Menuitem_checkupdateClick(object sender, EventArgs e)
{ {
checkupdate(true); CheckUpdate(true);
} }
void checkupdate(bool showNew) public void CheckUpdate(bool showNew)
{ {
if(!isRun()) if(!isRun())
{ {
......
...@@ -67,6 +67,7 @@ private void InitializeComponent() ...@@ -67,6 +67,7 @@ private void InitializeComponent()
this.menuitem_comp2 = new System.Windows.Forms.ToolStripMenuItem(); this.menuitem_comp2 = new System.Windows.Forms.ToolStripMenuItem();
this.toolStripSeparator1 = new System.Windows.Forms.ToolStripSeparator(); this.toolStripSeparator1 = new System.Windows.Forms.ToolStripSeparator();
this.menuitem_history = new System.Windows.Forms.ToolStripMenuItem(); this.menuitem_history = new System.Windows.Forms.ToolStripMenuItem();
this.menuitem_shistory = new System.Windows.Forms.ToolStripMenuItem();
this.toolStripSeparator5 = new System.Windows.Forms.ToolStripSeparator(); this.toolStripSeparator5 = new System.Windows.Forms.ToolStripSeparator();
this.menuitem_quit = new System.Windows.Forms.ToolStripMenuItem(); this.menuitem_quit = new System.Windows.Forms.ToolStripMenuItem();
this.menuitem_windows = new System.Windows.Forms.ToolStripMenuItem(); this.menuitem_windows = new System.Windows.Forms.ToolStripMenuItem();
...@@ -76,7 +77,7 @@ private void InitializeComponent() ...@@ -76,7 +77,7 @@ private void InitializeComponent()
this.menuitem_close = new System.Windows.Forms.ToolStripMenuItem(); this.menuitem_close = new System.Windows.Forms.ToolStripMenuItem();
this.menuitem_closeother = new System.Windows.Forms.ToolStripMenuItem(); this.menuitem_closeother = new System.Windows.Forms.ToolStripMenuItem();
this.menuitem_closeall = new System.Windows.Forms.ToolStripMenuItem(); this.menuitem_closeall = new System.Windows.Forms.ToolStripMenuItem();
this.menuitem_shistory = new System.Windows.Forms.ToolStripMenuItem(); this.bgWorker1 = new System.ComponentModel.BackgroundWorker();
this.menuStrip1.SuspendLayout(); this.menuStrip1.SuspendLayout();
this.SuspendLayout(); this.SuspendLayout();
// //
...@@ -262,6 +263,12 @@ private void InitializeComponent() ...@@ -262,6 +263,12 @@ private void InitializeComponent()
this.menuitem_history.Size = new System.Drawing.Size(261, 22); this.menuitem_history.Size = new System.Drawing.Size(261, 22);
this.menuitem_history.Text = "History(&H)"; this.menuitem_history.Text = "History(&H)";
// //
// menuitem_shistory
//
this.menuitem_shistory.Name = "menuitem_shistory";
this.menuitem_shistory.Size = new System.Drawing.Size(261, 22);
this.menuitem_shistory.Text = "Script History";
//
// toolStripSeparator5 // toolStripSeparator5
// //
this.toolStripSeparator5.Name = "toolStripSeparator5"; this.toolStripSeparator5.Name = "toolStripSeparator5";
...@@ -328,11 +335,9 @@ private void InitializeComponent() ...@@ -328,11 +335,9 @@ private void InitializeComponent()
this.menuitem_closeall.Text = "Close All"; this.menuitem_closeall.Text = "Close All";
this.menuitem_closeall.Click += new System.EventHandler(this.CloseAllToolStripMenuItemClick); this.menuitem_closeall.Click += new System.EventHandler(this.CloseAllToolStripMenuItemClick);
// //
// menuitem_shistory // bgWorker1
// //
this.menuitem_shistory.Name = "menuitem_shistory"; this.bgWorker1.DoWork += new System.ComponentModel.DoWorkEventHandler(this.bgWorker1_DoWork);
this.menuitem_shistory.Size = new System.Drawing.Size(261, 22);
this.menuitem_shistory.Text = "Script History";
// //
// MainForm // MainForm
// //
...@@ -381,6 +386,7 @@ private void InitializeComponent() ...@@ -381,6 +386,7 @@ private void InitializeComponent()
private System.Windows.Forms.MenuStrip menuStrip1; private System.Windows.Forms.MenuStrip menuStrip1;
private WeifenLuo.WinFormsUI.Docking.DockPanel dockPanel1; private WeifenLuo.WinFormsUI.Docking.DockPanel dockPanel1;
private System.Windows.Forms.ToolStripMenuItem menuitem_shistory; private System.Windows.Forms.ToolStripMenuItem menuitem_shistory;
private System.ComponentModel.BackgroundWorker bgWorker1;
} }
} }
...@@ -42,7 +42,7 @@ public partial class MainForm : Form ...@@ -42,7 +42,7 @@ public partial class MainForm : Form
public MainForm(string datapath, string file) public MainForm(string datapath, string file)
{ {
Init(datapath); Init(datapath);
if(file.EndsWith("lua",StringComparison.OrdinalIgnoreCase)) if(MainForm.isScript(file))
OpenScript(file); OpenScript(file);
else else
Open(file); Open(file);
...@@ -73,6 +73,7 @@ void Init(string datapath) ...@@ -73,6 +73,7 @@ void Init(string datapath)
LANG.SetLanguage(this); LANG.SetLanguage(this);
ReadHistory(); ReadHistory();
MenuHistory(); MenuHistory();
bgWorker1.RunWorkerAsync();
} }
#endregion #endregion
...@@ -283,7 +284,6 @@ public void Open(string file) ...@@ -283,7 +284,6 @@ public void Open(string file)
LANG.SetLanguage(def); LANG.SetLanguage(def);
InitDataEditor(); InitDataEditor();
def.InitGameData(datacfg); def.InitGameData(datacfg);
def.DockAreas = DockAreas.Document;
def.Show(dockPanel1, DockState.Document); def.Show(dockPanel1, DockState.Document);
} }
...@@ -367,7 +367,7 @@ void DataEditorToolStripMenuItemClick(object sender, EventArgs e) ...@@ -367,7 +367,7 @@ void DataEditorToolStripMenuItemClick(object sender, EventArgs e)
#region form #region form
void MainFormLoad(object sender, System.EventArgs e) void MainFormLoad(object sender, System.EventArgs e)
{ {
//
} }
void MainFormFormClosing(object sender, FormClosingEventArgs e) void MainFormFormClosing(object sender, FormClosingEventArgs e)
...@@ -587,5 +587,10 @@ void Menuitem_findluafuncClick(object sender, EventArgs e) ...@@ -587,5 +587,10 @@ void Menuitem_findluafuncClick(object sender, EventArgs e)
} }
} }
#endregion #endregion
private void bgWorker1_DoWork(object sender, System.ComponentModel.DoWorkEventArgs e)
{
TaskHelper.CheckVersion(false);
}
} }
} }
...@@ -118,7 +118,10 @@ ...@@ -118,7 +118,10 @@
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader> </resheader>
<metadata name="menuStrip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"> <metadata name="menuStrip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>130, 17</value> <value>135, 17</value>
</metadata>
<metadata name="bgWorker1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata> </metadata>
<metadata name="$this.TrayHeight" type="System.Int32, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="$this.TrayHeight" type="System.Int32, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>25</value> <value>25</value>
......
...@@ -28,4 +28,4 @@ ...@@ -28,4 +28,4 @@
// //
// You can specify all the values or you can use the default the Revision and // You can specify all the values or you can use the default the Revision and
// Build Numbers by using the '*' as shown below: // Build Numbers by using the '*' as shown below:
[assembly: AssemblyVersion("2.2.7.5")] [assembly: AssemblyVersion("2.2.8.0")]
[DataEditorX]2.2.7.5[DataEditorX] [DataEditorX]2.2.8.0[DataEditorX]
[URL]https://github.com/247321453/DataEditorX/raw/master/win32/win32.zip[URL] [URL]https://github.com/247321453/DataEditorX/raw/master/win32/win32.zip[URL]
★捐助
如果你觉得这个软件做得好,可以捐助。
姓名:柯永裕
支付宝帐号:247321453@qq.com
★文件关联 ★文件关联
.lua notepad++/sublime text/DataEditorX .lua notepad++/sublime text/DataEditorX
.cdb DataEditorX .cdb DataEditorX
...@@ -58,6 +63,9 @@ Ctrl+鼠标左键 跳转到函数定义 ...@@ -58,6 +63,9 @@ Ctrl+鼠标左键 跳转到函数定义
Ctrl+鼠标滑轮 缩放文字 Ctrl+鼠标滑轮 缩放文字
★更新历史 ★更新历史
2.2.8.0
修正setcode搜索
在打开的时候,自动检查更新
2.2.7.5 2.2.7.5
lua编辑器,编辑完,返回当前页数 lua编辑器,编辑完,返回当前页数
2.2.7.4 2.2.7.4
......
No preview for this file type
[DataEditorX]2.2.7.5[DataEditorX] [DataEditorX]2.2.8.0[DataEditorX]
[URL]https://github.com/247321453/DataEditorX/raw/master/win32/win32.zip[URL] [URL]https://github.com/247321453/DataEditorX/raw/master/win32/win32.zip[URL]
★捐助
如果你觉得这个软件做得好,可以捐助。
姓名:柯永裕
支付宝帐号:247321453@qq.com
★文件关联 ★文件关联
.lua notepad++/sublime text/DataEditorX .lua notepad++/sublime text/DataEditorX
.cdb DataEditorX .cdb DataEditorX
...@@ -58,6 +63,9 @@ Ctrl+鼠标左键 跳转到函数定义 ...@@ -58,6 +63,9 @@ Ctrl+鼠标左键 跳转到函数定义
Ctrl+鼠标滑轮 缩放文字 Ctrl+鼠标滑轮 缩放文字
★更新历史 ★更新历史
2.2.8.0
修正setcode搜索
在打开的时候,自动检查更新
2.2.7.5 2.2.7.5
lua编辑器,编辑完,返回当前页数 lua编辑器,编辑完,返回当前页数
2.2.7.4 2.2.7.4
......
No preview for this file type
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment