Skip to content

Commit

Permalink
Build 21.10.19.103
Browse files Browse the repository at this point in the history
  • Loading branch information
dkxce authored Oct 19, 2021
1 parent e2194e1 commit f4d36df
Show file tree
Hide file tree
Showing 6 changed files with 29 additions and 299 deletions.
2 changes: 1 addition & 1 deletion KMZRebuilder.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@
</Compile>
<Compile Include="MapsForgeReader.cs" />
<Compile Include="MapViewerForm.cs">
<SubType>Form</SubType>
<SubType>Component</SubType>
</Compile>
<Compile Include="MapViewerForm.Designer.cs">
<DependentUpon>MapViewerForm.cs</DependentUpon>
Expand Down
36 changes: 13 additions & 23 deletions KMZRebuilederForm.cs
Original file line number Diff line number Diff line change
Expand Up @@ -73,36 +73,19 @@ public static string TempDirectory()
return dir;
}

public KMZRebuilederForm(string[] args, string captiondop)
public KMZRebuilederForm(string[] args)
{
this.args = args;

InitializeComponent();
System.Reflection.Assembly assembly = System.Reflection.Assembly.GetExecutingAssembly();
System.Diagnostics.FileVersionInfo fvi = System.Diagnostics.FileVersionInfo.GetVersionInfo(assembly.Location);
Text += " " + captiondop + fvi.FileVersion + " by " + fvi.CompanyName;
Text += " " + fvi.FileVersion + " by " + fvi.CompanyName;

RegisterFileAsses();
prepareTranslit();
MapIcons.InitZip(CurrentDirectory() + @"\mapicons\default.zip");

try
{
memFile = new MemFile.MemoryFile("KMZRebuilder");
memFile.onGetNotify = OnGetNotifyEvent;
}
catch { };
}

private void OnGetNotifyEvent(MemFile.MemoryFile.NotifyEvent notify, MemFile.MemoryFile.NotifySource source, byte notifyParam)
{
if (notify != MemFile.MemoryFile.NotifyEvent.fUserEvent) return;
if (notifyParam == 1)
{
this.args = (string[]) memFile.GetSeriazable();
this.Invoke(new EventHandler(LoadFiles), new object[] { null, null });
};
}
}

private void RegisterFileAsses()
{
Expand Down Expand Up @@ -3453,13 +3436,15 @@ protected override void WndProc(ref Message m)
if (dt.StartsWith("reb: about:"))
text += "\r\n" + dt.Substring(11).Trim();
}
catch { };
catch (Exception ex)
{
};
MessageBox.Show(text, this.Text, MessageBoxButtons.OK, MessageBoxIcon.Information);
};
if ((m.Msg == WM_SYSCOMMAND) && ((int)m.WParam == SYSMENU_NEW_INST))
{
string fn = System.Diagnostics.Process.GetCurrentProcess().MainModule.FileName;
System.Diagnostics.Process.Start(fn, "/multiple");
System.Diagnostics.Process.Start(fn);
};
}

Expand Down Expand Up @@ -9679,8 +9664,13 @@ public void GPX2KML(string origin_name)
foreach (XmlNode trkseg in trk.SelectNodes("trkseg"))
{
string xyz = "";
foreach (XmlNode trkpt in trkseg.SelectNodes("trkpt"))
XmlNodeList nl = trkseg.SelectNodes("trkpt");
int cnt = 0;
foreach (XmlNode trkpt in nl) // FOR DEBUG COUNTER
{
xyz += trkpt.Attributes["lon"].Value + "," + trkpt.Attributes["lat"].Value + ",0 ";
cnt++;
};
sw.WriteLine("\t\t\t<Placemark>");
sw.WriteLine("\t\t\t\t<name>" + nam + "</name>");
sw.WriteLine("\t\t\t\t<description><![CDATA[" + desc + "]]></description>");
Expand Down
Loading

0 comments on commit f4d36df

Please sign in to comment.