Skip to content
This repository was archived by the owner on Jan 27, 2022. It is now read-only.

Commit befd627

Browse files
committed
messagebox buttons and images
1 parent d1ebf18 commit befd627

File tree

3 files changed

+17
-22
lines changed

3 files changed

+17
-22
lines changed

MapPacker/AssetPacker.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
using System;
22
using System.Collections.Generic;
33
using System.Text;
4-
using System.Windows.Forms;
54
using System.IO;
65
using System.Threading;
76
using System.Media;
7+
using System.Windows;
88

99
namespace MapPacker {
1010
class AssetPacker{
@@ -44,7 +44,7 @@ public void GetAssets() {
4444
} else {
4545
parentForm.PrintToConsole("No assets found!");
4646
parentForm.SetProgress(0);
47-
MessageBox.Show("No assets could be found!", "Alert", MessageBoxButtons.OK, MessageBoxIcon.Information);
47+
MessageBox.Show("No assets could be found!", "Alert", MessageBoxButton.OK, MessageBoxImage.Information);
4848
return;
4949
}
5050
foreach(string asset in assets) {
@@ -136,7 +136,7 @@ public void CopyFiles() {
136136
//SoundPlayer player = new SoundPlayer(Properties.Resources.steam_message);
137137
//player.Play();
138138
parentForm.PrintToConsole("\nAsset move completed.");
139-
MessageBox.Show("Content successfully moved!", "Complete", MessageBoxButtons.OK, MessageBoxIcon.None);
139+
MessageBox.Show("Content successfully moved!", "Complete", MessageBoxButton.OK, MessageBoxImage.None);
140140
parentForm.SetCheckBoxEnabled(true);
141141
}
142142
}
@@ -160,7 +160,7 @@ public void PackVPK() {
160160
//SoundPlayer player = new SoundPlayer(Properties.Resources.steam_message);
161161
//player.Play();
162162
parentForm.PrintToConsole("\nAsset pack completed.");
163-
MessageBox.Show("Map Successfully packed!", "Complete", MessageBoxButtons.OK, MessageBoxIcon.None);
163+
MessageBox.Show("Map Successfully packed!", "Complete", MessageBoxButton.OK, MessageBoxImage.None);
164164
parentForm.SetCheckBoxEnabled(true);
165165
}
166166

MapPacker/MainWindow.xaml.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -160,21 +160,21 @@ private void ConfirmButton_Click(object sender, RoutedEventArgs e) {
160160
var text = (System.Windows.Controls.RichTextBox)this.FindName("vmapLocation");
161161
string vmapFile = new TextRange(text.Document.ContentStart, text.Document.ContentEnd).Text.Replace("\r\n", "");
162162
if(!File.Exists(vmapFile)) {
163-
System.Windows.MessageBox.Show("Vmap file path invalid!", "Error");
163+
System.Windows.MessageBox.Show("Vmap file path invalid!", "Error", MessageBoxButton.OK, MessageBoxImage.Warning);
164164
return;
165165
}
166166

167167
text = (RichTextBox)this.FindName("assetLocation");
168168
string assetDir = new TextRange(text.Document.ContentStart, text.Document.ContentEnd).Text.Replace("\r\n", "");
169169
if(!Directory.Exists(assetDir)) {
170-
System.Windows.MessageBox.Show("Asset Directory path invalid!", "Error");
170+
System.Windows.MessageBox.Show("Asset Directory path invalid!", "Error", MessageBoxButton.OK, MessageBoxImage.Warning);
171171
return;
172172
}
173173

174174
text = (RichTextBox)this.FindName("sboxLocation");
175175
string sboxDir = new TextRange(text.Document.ContentStart, text.Document.ContentEnd).Text.Replace("\r\n", "");
176176
if(!Directory.Exists(sboxDir)) {
177-
System.Windows.MessageBox.Show("s&box Directory path invalid!", "Error");
177+
System.Windows.MessageBox.Show("s&box Directory path invalid!", "Error", MessageBoxButton.OK, MessageBoxImage.Warning);
178178
return;
179179
}
180180

MapPacker/MapPacker.csproj

Lines changed: 10 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -17,21 +17,16 @@
1717
</PropertyGroup>
1818

1919
<ItemGroup>
20-
<Resource Include="icons\icon_eagleone.png">
21-
<CopyToOutputDirectory>Never</CopyToOutputDirectory>
22-
</Resource>
23-
<Resource Include="icons\icon_file.png">
24-
<CopyToOutputDirectory>Never</CopyToOutputDirectory>
25-
</Resource>
26-
<Resource Include="icons\icon_folder.png">
27-
<CopyToOutputDirectory>Never</CopyToOutputDirectory>
28-
</Resource>
29-
<Resource Include="icons\mappacker.png">
30-
<CopyToOutputDirectory>Never</CopyToOutputDirectory>
31-
</Resource>
32-
<Resource Include="icons\resizeIcon.png">
33-
<CopyToOutputDirectory>Never</CopyToOutputDirectory>
34-
</Resource>
20+
<None Remove="sounds\steam-message.wav" />
21+
</ItemGroup>
22+
23+
<ItemGroup>
24+
<Resource Include="icons\icon_eagleone.png" />
25+
<Resource Include="icons\icon_file.png" />
26+
<Resource Include="icons\icon_folder.png" />
27+
<Resource Include="icons\mappacker.png" />
28+
<Resource Include="icons\resizeIcon.png" />
29+
<Resource Include="sounds\steam-message.wav" />
3530
</ItemGroup>
3631

3732
<ItemGroup>

0 commit comments

Comments
 (0)