Skip to content

Commit

Permalink
Update datafiles to version 1550152
Browse files Browse the repository at this point in the history
Fix #181 by saving and restoring path to active tree node when updating ship mastery.
  • Loading branch information
peterhaneve committed Aug 15, 2019
1 parent d96e6f3 commit dc77bbf
Show file tree
Hide file tree
Showing 10 changed files with 155 additions and 151 deletions.
6 changes: 3 additions & 3 deletions SharedAssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,9 @@
// Build Number
// Revision
//
[assembly: AssemblyVersion("4.0.12.0")]
[assembly: AssemblyFileVersion("4.0.12.4946")]
[assembly: AssemblyInformationalVersion("4.0.12")]
[assembly: AssemblyVersion("4.0.13.0")]
[assembly: AssemblyFileVersion("4.0.13.4949")]
[assembly: AssemblyInformationalVersion("4.0.13")]

// Neutral Language
[assembly: NeutralResourcesLanguage("en-US")]
6 changes: 3 additions & 3 deletions SharedAssemblyInfo.template.cs
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,9 @@
// Build Number
// Revision
//
[assembly: AssemblyVersion("4.0.12.0")]
[assembly: AssemblyFileVersion("4.0.12.$REVNUM$")]
[assembly: AssemblyInformationalVersion("4.0.12")]
[assembly: AssemblyVersion("4.0.13.0")]
[assembly: AssemblyFileVersion("4.0.13.$REVNUM$")]
[assembly: AssemblyInformationalVersion("4.0.13")]

// Neutral Language
[assembly: NeutralResourcesLanguage("en-US")]
6 changes: 3 additions & 3 deletions src/EVEMon.Common/Resources/MD5Sums.txt
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
43d1a14dab27b26ff69c3045a7a9a5b0 *eve-blueprints-en-US.xml.gzip
540000f7c111354769a54fa31e57d411 *eve-certificates-en-US.xml.gzip
3f3195abb75a73b1383dbb13ad853a9e *eve-geography-en-US.xml.gzip
bcd1a0a4bf3ed374803843c9b3b4c326 *eve-items-en-US.xml.gzip
8de7aa1e9c6f39800e0860077302ec21 *eve-geography-en-US.xml.gzip
1bbe94c88368d70fd0a4b6f069d99da7 *eve-items-en-US.xml.gzip
3668b50996fc40a0c0853fec427b5712 *eve-masteries-en-US.xml.gzip
9588388c2309c01eb99aa974e4bdb824 *eve-properties-en-US.xml.gzip
b989d5e1c917344a3a063126cca8afbd *eve-reprocessing-en-US.xml.gzip
662c9c149b5b35362f7b52546c89d6b7 *eve-reprocessing-en-US.xml.gzip
48e837bfe4a365d6d41da82e813db001 *eve-skills-en-US.xml.gzip
Binary file modified src/EVEMon.Common/Resources/eve-geography-en-US.xml.gzip
Binary file not shown.
Binary file modified src/EVEMon.Common/Resources/eve-items-en-US.xml.gzip
Binary file not shown.
Binary file modified src/EVEMon.Common/Resources/eve-reprocessing-en-US.xml.gzip
Binary file not shown.
62 changes: 41 additions & 21 deletions src/EVEMon/SkillPlanner/MasteryTreeDisplayControl.cs
Original file line number Diff line number Diff line change
Expand Up @@ -287,11 +287,11 @@ private void treeView_NodeMouseDoubleClick(object sender, TreeNodeMouseClickEven
/// </summary>
private void UpdateTree()
{
Mastery oldSelection = SelectedMasteryLevel;
TreeNode newSelection = null;
// Multiple copies of "CPU Management IV" etc. could exist in the tree. To restore
// the same selection, the full path to the selection must be stored
string path = treeView.SelectedNode?.FullPath ?? "";

treeView.ImageList = Settings.UI.SafeForWork ? m_emptyImageList : imageList;

treeView.BeginUpdate();
try
{
Expand All @@ -304,27 +304,47 @@ private void UpdateTree()

// Create the nodes when not done, yet
if (treeView.Nodes.Count == 0)
{
foreach (Mastery masteryLevel in m_masteryShip)
{
TreeNode node = CreateNode(masteryLevel);
var node = CreateNode(masteryLevel);
treeView.Nodes.Add(node);

// Does the old selection still exists ?
if (masteryLevel == oldSelection)
newSelection = node;
}
}

// Update the nodes
foreach (TreeNode node in treeView.Nodes)
{
UpdateNode(node);
}

// Is the old selection kept ? Then we select the matching node
if (newSelection != null)
treeView.SelectedNode = newSelection;
// If old selection exists, select it
if (!string.IsNullOrEmpty(path))
{
var nodes = treeView.Nodes;
// Iterate through all components in the path
string[] components = path.Split(new string[] { treeView.PathSeparator },
StringSplitOptions.None);
int nc = components.Length;
for (int index = 0; index < nc && nodes != null; index++)
{
TreeNode child = null;
string component = components[index];
int n = nodes.Count;
// Search nodes for a node with the same text
for (int i = 0; i < n && child == null; i++)
{
var candidate = nodes[i];
if (candidate.Text?.Equals(component) ?? false)
child = candidate;
}
nodes = child?.Nodes;
if (index == nc - 1 && child != null)
{
// Found node, select it
child.EnsureVisible();
treeView.SelectedNode = child;
}
}
}
}
finally
{
Expand All @@ -336,19 +356,19 @@ private void UpdateTree()
/// Create a node from a mastery.
/// </summary>
/// <param name="masteryLevel">The mastery level.</param>
/// <returns></returns>
/// <returns>The node created.</returns>
private TreeNode CreateNode(Mastery masteryLevel)
{
TreeNode node = new TreeNode
var node = new TreeNode
{
Text = masteryLevel.ToString(),
Tag = masteryLevel
};

foreach (CertificateLevel certificate in masteryLevel
.OrderBy(cert => cert.Certificate.Class.Name)
.Select(cert => cert.ToCharacter(m_character).GetCertificateLevel(masteryLevel.Level)))
foreach (var cert in masteryLevel.OrderBy(cert => cert.Certificate.Class.Name))
{
var certificate = cert.ToCharacter(m_character).GetCertificateLevel(
masteryLevel.Level);
node.Nodes.Add(CreateNode(certificate));
}

Expand Down Expand Up @@ -391,10 +411,10 @@ private static TreeNode CreateNode(SkillLevel skillPrereq)
};

// Add this skill's prerequisites
foreach (SkillLevel prereqSkill in skillPrereq.Skill.Prerequisites
.Where(prereqSkill => prereqSkill.Skill != skillPrereq.Skill))
foreach (var prereqSkill in skillPrereq.Skill.Prerequisites)
{
node.Nodes.Add(CreateNode(prereqSkill));
if (prereqSkill.Skill != skillPrereq.Skill)
node.Nodes.Add(CreateNode(prereqSkill));
}

return node;
Expand Down
80 changes: 39 additions & 41 deletions tools/PatchXmlCreator/Output/patch-old.xml
Original file line number Diff line number Diff line change
@@ -1,29 +1,27 @@
<?xml version="1.0"?>
<evemon xmlns:xsd="https://www.w3.org/2001/XMLSchema" xmlns:xsi="https://www.w3.org/2001/XMLSchema-instance">
<newest>
<date>07 February 2019</date>
<version>4.0.11.4937</version>
<md5>24aa72e69a5c20854f8a58f643ec46ca</md5>
<url>https://forums.eveonline.com/t/evemon-4-0-11-beta-under-new-ownership-conversion-for-esi/75953</url>
<autopatchurl>https://github.com/peterhaneve/evemon/releases/download/4.0.11/EVEMon-install-4.0.11.exe</autopatchurl>
<date>18 May 2019</date>
<version>4.0.12.4946</version>
<md5>e2278d55fff70e842ebf1d3e04c15c40</md5>
<url>https://forums.eveonline.com/t/evemon-4-0-12-beta-esi-edition/75953</url>
<autopatchurl>https://github.com/peterhaneve/evemon/releases/download/4.0.12/EVEMon-install-4.0.12.exe</autopatchurl>
<autopatchargs>/S /AUTORUN /SKIPDOTNET</autopatchargs>
<additionalargs>/D=%EVEMON_EXECUTABLE_PATH%</additionalargs>
<message><![CDATA[# Release v4.0.11
<message><![CDATA[# Release v4.0.12
## New Features
- Loyalty points can be viewed for each character
- New column "Group" added to all CSV exports that are grouped in the UI (such as character comparison, mail, and so on).
- Available industry jobs per character can be displayed on the overview
- Omega/Alpha status can be overridden on a per-character basis if automatic detection reports "Unknown"
## Bug Fixes
- ESI endpoint versions rolled to latest versions, and obsolete scopes regarding outposts and starbases removed
- Right click compatibility improved with touch devices
- Occasional crashes fixed when reading EVE mail and notification messages
## Contributors
- Peter Han
- wvdvegt
- IamTechknow
- AnrDaemon
- marfenij]]></message>
- rayanth
- zhlzhl123]]></message>
</newest>
<releases>
<release>
Expand Down Expand Up @@ -53,66 +51,66 @@
<datafiles>
<datafile>
<name>eve-blueprints-en-US.xml.gzip</name>
<date>18 May 2019</date>
<md5>fcf27adfb6833f4f336d07ee3cff57b3</md5>
<url>https://peterhaneve.github.io/evemon-datafiles/Into the Abyss/1506886</url>
<message><![CDATA[Into the Abyss 1.4 (1506886) blueprints data file by the EVEMon Development Team
<date>14 June 2019</date>
<md5>43d1a14dab27b26ff69c3045a7a9a5b0</md5>
<url>https://peterhaneve.github.io/evemon-datafiles/Invasion/1522434</url>
<message><![CDATA[Invasion 1.0 (1522434) blueprints data file by the EVEMon Development Team
NOT COMPATIBLE with EVEMon prior to version 2.2.0]]></message>
</datafile>
<datafile>
<name>eve-certificates-en-US.xml.gzip</name>
<date>05 June 2018</date>
<md5>540000f7c111354769a54fa31e57d411</md5>
<url>https://peterhaneve.github.io/evemon-datafiles/Into the Abyss/1506886</url>
<message><![CDATA[Into the Abyss 1.4 (1506886) certificates data file by the EVEMon Development Team
<url>https://peterhaneve.github.io/evemon-datafiles/Invasion/1522434</url>
<message><![CDATA[Invasion 1.0 (1522434) certificates data file by the EVEMon Development Team
NOT COMPATIBLE with EVEMon prior to version 2.2.0]]></message>
</datafile>
<datafile>
<name>eve-geography-en-US.xml.gzip</name>
<date>18 May 2019</date>
<md5>062c656d9913c91533ec4bca655b4825</md5>
<url>https://peterhaneve.github.io/evemon-datafiles/Into the Abyss/1506886</url>
<message><![CDATA[Into the Abyss 1.4 (1506886) geography data file by the EVEMon Development Team
<date>14 June 2019</date>
<md5>3f3195abb75a73b1383dbb13ad853a9e</md5>
<url>https://peterhaneve.github.io/evemon-datafiles/Invasion/1522434</url>
<message><![CDATA[Invasion 1.0 (1522434) geography data file by the EVEMon Development Team
NOT COMPATIBLE with EVEMon prior to version 2.2.0]]></message>
</datafile>
<datafile>
<name>eve-items-en-US.xml.gzip</name>
<date>18 May 2019</date>
<md5>e307d9d1b13c559e5b54594ce9b2147c</md5>
<url>https://peterhaneve.github.io/evemon-datafiles/Into the Abyss/1506886</url>
<message><![CDATA[Into the Abyss 1.4 (1506886) items data file by the EVEMon Development Team
<date>14 June 2019</date>
<md5>bcd1a0a4bf3ed374803843c9b3b4c326</md5>
<url>https://peterhaneve.github.io/evemon-datafiles/Invasion/1522434</url>
<message><![CDATA[Invasion 1.0 (1522434) items data file by the EVEMon Development Team
NOT COMPATIBLE with EVEMon prior to version 2.2.0]]></message>
</datafile>
<datafile>
<name>eve-masteries-en-US.xml.gzip</name>
<date>05 June 2018</date>
<md5>3668b50996fc40a0c0853fec427b5712</md5>
<url>https://peterhaneve.github.io/evemon-datafiles/Into the Abyss/1506886</url>
<message><![CDATA[Into the Abyss 1.4 (1506886) masteries data file by the EVEMon Development Team
<url>https://peterhaneve.github.io/evemon-datafiles/Invasion/1522434</url>
<message><![CDATA[Invasion 1.0 (1522434) masteries data file by the EVEMon Development Team
NOT COMPATIBLE with EVEMon prior to version 2.2.0]]></message>
</datafile>
<datafile>
<name>eve-properties-en-US.xml.gzip</name>
<date>18 May 2019</date>
<md5>7f75d04e17605f0e0670737f39b38e4a</md5>
<url>https://peterhaneve.github.io/evemon-datafiles/Into the Abyss/1506886</url>
<message><![CDATA[Into the Abyss 1.4 (1506886) properties data file by the EVEMon Development Team
<date>14 June 2019</date>
<md5>9588388c2309c01eb99aa974e4bdb824</md5>
<url>https://peterhaneve.github.io/evemon-datafiles/Invasion/1522434</url>
<message><![CDATA[Invasion 1.0 (1522434) properties data file by the EVEMon Development Team
NOT COMPATIBLE with EVEMon prior to version 2.2.0]]></message>
</datafile>
<datafile>
<name>eve-reprocessing-en-US.xml.gzip</name>
<date>18 May 2019</date>
<md5>7bf035106cf497cbe688a115c74ec0f4</md5>
<url>https://peterhaneve.github.io/evemon-datafiles/Into the Abyss/1506886</url>
<message><![CDATA[Into the Abyss 1.4 (1506886) reprocessing data file by the EVEMon Development Team
<date>14 June 2019</date>
<md5>b989d5e1c917344a3a063126cca8afbd</md5>
<url>https://peterhaneve.github.io/evemon-datafiles/Invasion/1522434</url>
<message><![CDATA[Invasion 1.0 (1522434) reprocessing data file by the EVEMon Development Team
NOT COMPATIBLE with EVEMon prior to version 2.2.0]]></message>
</datafile>
<datafile>
<name>eve-skills-en-US.xml.gzip</name>
<date>18 May 2019</date>
<md5>7eec9427cfdb6d5bcd58e8191731cd07</md5>
<url>https://peterhaneve.github.io/evemon-datafiles/Into the Abyss/1506886</url>
<message><![CDATA[Into the Abyss 1.4 (1506886) skills data file by the EVEMon Development Team
<date>14 June 2019</date>
<md5>48e837bfe4a365d6d41da82e813db001</md5>
<url>https://peterhaneve.github.io/evemon-datafiles/Invasion/1522434</url>
<message><![CDATA[Invasion 1.0 (1522434) skills data file by the EVEMon Development Team
NOT COMPATIBLE with EVEMon prior to version 2.2.0]]></message>
</datafile>
</datafiles>
Expand Down
Loading

0 comments on commit dc77bbf

Please sign in to comment.