mirror of
https://github.com/fadden/6502bench.git
synced 2024-06-12 23:29:32 +00:00
Move WorkProgress dialog into CommonWPF library
This commit is contained in:
parent
be0e6bead1
commit
b6132b029a
|
@ -65,6 +65,9 @@
|
||||||
<DesignTimeSharedInput>True</DesignTimeSharedInput>
|
<DesignTimeSharedInput>True</DesignTimeSharedInput>
|
||||||
</Compile>
|
</Compile>
|
||||||
<Compile Include="WindowPlacement.cs" />
|
<Compile Include="WindowPlacement.cs" />
|
||||||
|
<Compile Include="WorkProgress.xaml.cs">
|
||||||
|
<DependentUpon>WorkProgress.xaml</DependentUpon>
|
||||||
|
</Compile>
|
||||||
<Compile Include="WPFExtensions.cs" />
|
<Compile Include="WPFExtensions.cs" />
|
||||||
<EmbeddedResource Include="Properties\Resources.resx">
|
<EmbeddedResource Include="Properties\Resources.resx">
|
||||||
<Generator>ResXFileCodeGenerator</Generator>
|
<Generator>ResXFileCodeGenerator</Generator>
|
||||||
|
@ -75,5 +78,11 @@
|
||||||
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
|
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
|
||||||
</None>
|
</None>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Page Include="WorkProgress.xaml">
|
||||||
|
<Generator>MSBuild:Compile</Generator>
|
||||||
|
<SubType>Designer</SubType>
|
||||||
|
</Page>
|
||||||
|
</ItemGroup>
|
||||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||||
</Project>
|
</Project>
|
|
@ -14,17 +14,23 @@ See the License for the specific language governing permissions and
|
||||||
limitations under the License.
|
limitations under the License.
|
||||||
-->
|
-->
|
||||||
|
|
||||||
<Window x:Class="SourceGenWPF.WpfGui.WorkProgress"
|
<Window x:Class="CommonWPF.WorkProgress"
|
||||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||||
xmlns:local="clr-namespace:SourceGenWPF.AsmGen.WpfGui"
|
xmlns:system="clr-namespace:System;assembly=mscorlib"
|
||||||
|
xmlns:local="clr-namespace:CommonWPF"
|
||||||
mc:Ignorable="d"
|
mc:Ignorable="d"
|
||||||
Title="Progress"
|
Title="Progress"
|
||||||
SizeToContent="WidthAndHeight" ResizeMode="NoResize"
|
SizeToContent="WidthAndHeight" ResizeMode="NoResize"
|
||||||
ShowInTaskbar="False" WindowStartupLocation="CenterOwner"
|
ShowInTaskbar="False" WindowStartupLocation="CenterOwner"
|
||||||
Loaded="Window_Loaded" Closing="Window_Closing">
|
Loaded="Window_Loaded" Closing="Window_Closing">
|
||||||
|
|
||||||
|
<Window.Resources>
|
||||||
|
<system:String x:Key="str_OperationFailedCaption">Failed</system:String>
|
||||||
|
</Window.Resources>
|
||||||
|
|
||||||
<StackPanel Margin="8">
|
<StackPanel Margin="8">
|
||||||
<TextBlock Name="messageText" HorizontalAlignment="Left" Text="Preparing..."/>
|
<TextBlock Name="messageText" HorizontalAlignment="Left" Text="Preparing..."/>
|
||||||
<ProgressBar Name="progressBar" Width="600" Height="23" Margin="0,8,0,0"/>
|
<ProgressBar Name="progressBar" Width="600" Height="23" Margin="0,8,0,0"/>
|
|
@ -18,7 +18,7 @@ using System.ComponentModel;
|
||||||
using System.Diagnostics;
|
using System.Diagnostics;
|
||||||
using System.Windows;
|
using System.Windows;
|
||||||
|
|
||||||
namespace SourceGenWPF.WpfGui {
|
namespace CommonWPF {
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Cancelable progress dialog.
|
/// Cancelable progress dialog.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
@ -127,7 +127,8 @@ namespace SourceGenWPF.WpfGui {
|
||||||
}
|
}
|
||||||
} else if (e.Error != null) {
|
} else if (e.Error != null) {
|
||||||
// Unexpected; success/failure should be passed through e.Result.
|
// Unexpected; success/failure should be passed through e.Result.
|
||||||
MessageBox.Show(e.Error.ToString(), Res.Strings.OPERATION_FAILED,
|
string failMsg = (string)FindResource("str_OperationFailedCaption");
|
||||||
|
MessageBox.Show(e.Error.ToString(), failMsg,
|
||||||
MessageBoxButton.OK, MessageBoxImage.Error);
|
MessageBoxButton.OK, MessageBoxImage.Error);
|
||||||
DialogResult = false;
|
DialogResult = false;
|
||||||
} else {
|
} else {
|
|
@ -23,6 +23,7 @@ using System.Windows;
|
||||||
using System.Windows.Controls;
|
using System.Windows.Controls;
|
||||||
|
|
||||||
using CommonUtil;
|
using CommonUtil;
|
||||||
|
using CommonWPF;
|
||||||
using SourceGenWPF.WpfGui;
|
using SourceGenWPF.WpfGui;
|
||||||
|
|
||||||
namespace SourceGenWPF.AsmGen.WpfGui {
|
namespace SourceGenWPF.AsmGen.WpfGui {
|
||||||
|
|
|
@ -130,9 +130,6 @@
|
||||||
<Compile Include="Tools\WpfGui\HexDumpViewer.xaml.cs">
|
<Compile Include="Tools\WpfGui\HexDumpViewer.xaml.cs">
|
||||||
<DependentUpon>HexDumpViewer.xaml</DependentUpon>
|
<DependentUpon>HexDumpViewer.xaml</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
<Compile Include="WpfGui\WorkProgress.xaml.cs">
|
|
||||||
<DependentUpon>WorkProgress.xaml</DependentUpon>
|
|
||||||
</Compile>
|
|
||||||
<Compile Include="AsmGen\WpfGui\GenAndAsm.xaml.cs">
|
<Compile Include="AsmGen\WpfGui\GenAndAsm.xaml.cs">
|
||||||
<DependentUpon>GenAndAsm.xaml</DependentUpon>
|
<DependentUpon>GenAndAsm.xaml</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
|
@ -293,10 +290,6 @@
|
||||||
<SubType>Designer</SubType>
|
<SubType>Designer</SubType>
|
||||||
<Generator>MSBuild:Compile</Generator>
|
<Generator>MSBuild:Compile</Generator>
|
||||||
</Page>
|
</Page>
|
||||||
<Page Include="WpfGui\WorkProgress.xaml">
|
|
||||||
<SubType>Designer</SubType>
|
|
||||||
<Generator>MSBuild:Compile</Generator>
|
|
||||||
</Page>
|
|
||||||
<Page Include="AsmGen\WpfGui\GenAndAsm.xaml">
|
<Page Include="AsmGen\WpfGui\GenAndAsm.xaml">
|
||||||
<SubType>Designer</SubType>
|
<SubType>Designer</SubType>
|
||||||
<Generator>MSBuild:Compile</Generator>
|
<Generator>MSBuild:Compile</Generator>
|
||||||
|
|
Loading…
Reference in New Issue
Block a user