Skip to content

Commit f4d36df

Browse files
authored
Build 21.10.19.103
1 parent e2194e1 commit f4d36df

File tree

6 files changed

+29
-299
lines changed

6 files changed

+29
-299
lines changed

KMZRebuilder.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@
137137
</Compile>
138138
<Compile Include="MapsForgeReader.cs" />
139139
<Compile Include="MapViewerForm.cs">
140-
<SubType>Form</SubType>
140+
<SubType>Component</SubType>
141141
</Compile>
142142
<Compile Include="MapViewerForm.Designer.cs">
143143
<DependentUpon>MapViewerForm.cs</DependentUpon>

KMZRebuilederForm.cs

Lines changed: 13 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -73,36 +73,19 @@ public static string TempDirectory()
7373
return dir;
7474
}
7575

76-
public KMZRebuilederForm(string[] args, string captiondop)
76+
public KMZRebuilederForm(string[] args)
7777
{
7878
this.args = args;
7979

8080
InitializeComponent();
8181
System.Reflection.Assembly assembly = System.Reflection.Assembly.GetExecutingAssembly();
8282
System.Diagnostics.FileVersionInfo fvi = System.Diagnostics.FileVersionInfo.GetVersionInfo(assembly.Location);
83-
Text += " " + captiondop + fvi.FileVersion + " by " + fvi.CompanyName;
83+
Text += " " + fvi.FileVersion + " by " + fvi.CompanyName;
8484

8585
RegisterFileAsses();
8686
prepareTranslit();
8787
MapIcons.InitZip(CurrentDirectory() + @"\mapicons\default.zip");
88-
89-
try
90-
{
91-
memFile = new MemFile.MemoryFile("KMZRebuilder");
92-
memFile.onGetNotify = OnGetNotifyEvent;
93-
}
94-
catch { };
95-
}
96-
97-
private void OnGetNotifyEvent(MemFile.MemoryFile.NotifyEvent notify, MemFile.MemoryFile.NotifySource source, byte notifyParam)
98-
{
99-
if (notify != MemFile.MemoryFile.NotifyEvent.fUserEvent) return;
100-
if (notifyParam == 1)
101-
{
102-
this.args = (string[]) memFile.GetSeriazable();
103-
this.Invoke(new EventHandler(LoadFiles), new object[] { null, null });
104-
};
105-
}
88+
}
10689

10790
private void RegisterFileAsses()
10891
{
@@ -3453,13 +3436,15 @@ protected override void WndProc(ref Message m)
34533436
if (dt.StartsWith("reb: about:"))
34543437
text += "\r\n" + dt.Substring(11).Trim();
34553438
}
3456-
catch { };
3439+
catch (Exception ex)
3440+
{
3441+
};
34573442
MessageBox.Show(text, this.Text, MessageBoxButtons.OK, MessageBoxIcon.Information);
34583443
};
34593444
if ((m.Msg == WM_SYSCOMMAND) && ((int)m.WParam == SYSMENU_NEW_INST))
34603445
{
34613446
string fn = System.Diagnostics.Process.GetCurrentProcess().MainModule.FileName;
3462-
System.Diagnostics.Process.Start(fn, "/multiple");
3447+
System.Diagnostics.Process.Start(fn);
34633448
};
34643449
}
34653450

@@ -9679,8 +9664,13 @@ public void GPX2KML(string origin_name)
96799664
foreach (XmlNode trkseg in trk.SelectNodes("trkseg"))
96809665
{
96819666
string xyz = "";
9682-
foreach (XmlNode trkpt in trkseg.SelectNodes("trkpt"))
9667+
XmlNodeList nl = trkseg.SelectNodes("trkpt");
9668+
int cnt = 0;
9669+
foreach (XmlNode trkpt in nl) // FOR DEBUG COUNTER
9670+
{
96839671
xyz += trkpt.Attributes["lon"].Value + "," + trkpt.Attributes["lat"].Value + ",0 ";
9672+
cnt++;
9673+
};
96849674
sw.WriteLine("\t\t\t<Placemark>");
96859675
sw.WriteLine("\t\t\t\t<name>" + nam + "</name>");
96869676
sw.WriteLine("\t\t\t\t<description><![CDATA[" + desc + "]]></description>");

0 commit comments

Comments
 (0)