Skip to content
This repository has been archived by the owner on Feb 18, 2018. It is now read-only.

Commit

Permalink
CDT-28: Delete profile functionality
Browse files Browse the repository at this point in the history
Move CDTag.View namespace to CDTag.Views
Add GetInputWindow
  • Loading branch information
judwhite committed Feb 26, 2012
1 parent 6a441b9 commit 82bdb25
Show file tree
Hide file tree
Showing 41 changed files with 301 additions and 82 deletions.
2 changes: 1 addition & 1 deletion CDTag.Common/ApplicationServices/IDialogService.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using System;
using CDTag.Common.Wpf;
using CDTag.View.Interfaces;
using CDTag.Views.Interfaces;

namespace CDTag.Common.ApplicationServices
{
Expand Down
2 changes: 1 addition & 1 deletion CDTag.Common/Events/MessageBoxEvent.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using System.Windows;
using CDTag.View.Interfaces;
using CDTag.Views.Interfaces;

namespace CDTag.Common.Events
{
Expand Down
4 changes: 4 additions & 0 deletions CDTag.Common/MVVM/ViewModelBase.cs
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,9 @@ public abstract class ViewModelBase : IViewModelBase
/// <summary>Path service.</summary>
protected static readonly IPathService _pathService;

/// <summary>Dialog service.</summary>
protected static readonly IDialogService _dialogService;

/// <summary>Occurs when a property value changes.</summary>
public event PropertyChangedEventHandler PropertyChanged;

Expand All @@ -67,6 +70,7 @@ static ViewModelBase()
{
_dispatcher = IoC.Resolve<IDispatcher>();
_pathService = IoC.Resolve<IPathService>();
_dialogService = IoC.Resolve<IDialogService>();
}

/// <summary>
Expand Down
1 change: 0 additions & 1 deletion CDTag.Model/Settings/SettingsFile.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
using System.Text;
using CDTag.Common.ApplicationServices;
using CDTag.Common.Json;
using CDTag.View;

namespace CDTag.Common.Settings
{
Expand Down
2 changes: 1 addition & 1 deletion CDTag.View.Interfaces/About/IAboutWindow.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
namespace CDTag.View.Interfaces.About
namespace CDTag.Views.Interfaces.About
{
/// <summary>
/// IAboutWindow
Expand Down
1 change: 1 addition & 0 deletions CDTag.View.Interfaces/CDTag.View.Interfaces.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@
<Compile Include="About\IAboutWindow.cs" />
<Compile Include="Checksum\IChecksumWindow.cs" />
<Compile Include="Checksum\IVerifyEACLogWindow.cs" />
<Compile Include="General\IGetInputWindow.cs" />
<Compile Include="IWindow.cs" />
<Compile Include="Options\IOptionsWindow.cs" />
<Compile Include="Profile\EditProfile\IEditProfileWindow.cs" />
Expand Down
2 changes: 1 addition & 1 deletion CDTag.View.Interfaces/Checksum/IChecksumWindow.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
namespace CDTag.View.Interfaces.Checksum
namespace CDTag.Views.Interfaces.Checksum
{
/// <summary>
/// IChecksumWindow
Expand Down
2 changes: 1 addition & 1 deletion CDTag.View.Interfaces/Checksum/IVerifyEACLogWindow.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
namespace CDTag.View.Interfaces.Checksum
namespace CDTag.Views.Interfaces.Checksum
{
/// <summary>
/// IVerifyEACLogWindow
Expand Down
9 changes: 9 additions & 0 deletions CDTag.View.Interfaces/General/IGetInputWindow.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
namespace CDTag.Views.Interfaces.General
{
/// <summary>
/// IGetInputWindow
/// </summary>
public interface IGetInputWindow : IWindow
{
}
}
2 changes: 1 addition & 1 deletion CDTag.View.Interfaces/IWindow.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using System.Windows;

namespace CDTag.View.Interfaces
namespace CDTag.Views.Interfaces
{
/// <summary>
/// IWindow
Expand Down
2 changes: 1 addition & 1 deletion CDTag.View.Interfaces/Options/IOptionsWindow.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
namespace CDTag.View.Interfaces.Options
namespace CDTag.Views.Interfaces.Options
{
/// <summary>
/// IOptionsWindow
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
namespace CDTag.View.Interfaces.Profile.EditProfile
namespace CDTag.Views.Interfaces.Profile.EditProfile
{
/// <summary>
/// IEditProfileWindow
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
namespace CDTag.View.Interfaces.Profile.NewProfile
namespace CDTag.Views.Interfaces.Profile.NewProfile
{
/// <summary>
/// INewProfileWindow
Expand Down
2 changes: 1 addition & 1 deletion CDTag.View.Interfaces/Tag/EditTag/IEditTagWindow.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
namespace CDTag.View.Interfaces.Tag.EditTag
namespace CDTag.Views.Interfaces.Tag.EditTag
{
/// <summary>
/// IEditTagWindow
Expand Down
2 changes: 1 addition & 1 deletion CDTag.View.Interfaces/Tag/MassTag/IMassTagWindow.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
namespace CDTag.View.Interfaces.Tag.MassTag
namespace CDTag.Views.Interfaces.Tag.MassTag
{
/// <summary>
/// IMassTagWindow
Expand Down
2 changes: 1 addition & 1 deletion CDTag.View.Interfaces/Tag/TagAlbum/ITagAlbumWindow.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
namespace CDTag.View.Interfaces.Tag.TagAlbum
namespace CDTag.Views.Interfaces.Tag.TagAlbum
{
/// <summary>
/// ITagAlbumWindow
Expand Down
2 changes: 1 addition & 1 deletion CDTag.View.Interfaces/Tools/IEncodingInspectorWindow.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
namespace CDTag.View.Interfaces.Tools
namespace CDTag.Views.Interfaces.Tools
{
/// <summary>
/// IEncodingInspectorWindow
Expand Down
2 changes: 1 addition & 1 deletion CDTag.View.Interfaces/Tools/ISplitCueWindow.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
namespace CDTag.View.Interfaces.Tools
namespace CDTag.Views.Interfaces.Tools
{
/// <summary>
/// ISplitCueWindow
Expand Down
4 changes: 2 additions & 2 deletions CDTag.View/About/AboutWindow.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using CDTag.View.Interfaces.About;
using CDTag.ViewModels.About;
using CDTag.ViewModels.About;
using CDTag.Views.Interfaces.About;

namespace CDTag.Views.About
{
Expand Down
7 changes: 7 additions & 0 deletions CDTag.View/CDTag.View.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,9 @@
<Compile Include="Converters\PlayLengthConverter.cs" />
<Compile Include="Converters\ShortFileNameConverter.cs" />
<Compile Include="DialogService.cs" />
<Compile Include="General\GetInputWindow.xaml.cs">
<DependentUpon>GetInputWindow.xaml</DependentUpon>
</Compile>
<Compile Include="MainWindow.xaml.cs">
<DependentUpon>MainWindow.xaml</DependentUpon>
</Compile>
Expand Down Expand Up @@ -167,6 +170,10 @@
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="General\GetInputWindow.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="MainWindow.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
Expand Down
4 changes: 2 additions & 2 deletions CDTag.View/Checksum/ChecksumWindow.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using CDTag.View.Interfaces.Checksum;
using CDTag.ViewModels.Checksum;
using CDTag.ViewModels.Checksum;
using CDTag.Views.Interfaces.Checksum;

namespace CDTag.Views.Checksum
{
Expand Down
4 changes: 2 additions & 2 deletions CDTag.View/Checksum/VerifyEACLogWindow.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using CDTag.View.Interfaces.Checksum;
using CDTag.ViewModels.Checksum;
using CDTag.ViewModels.Checksum;
using CDTag.Views.Interfaces.Checksum;

namespace CDTag.Views.Checksum
{
Expand Down
5 changes: 2 additions & 3 deletions CDTag.View/DialogService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,10 @@
using CDTag.Common.Wpf;
using CDTag.Controls;
using CDTag.FileBrowser.Events;
using CDTag.View.Interfaces;
using CDTag.Views;
using CDTag.Views.Interfaces;
using Microsoft.Win32;

namespace CDTag.View
namespace CDTag.Views
{
public class DialogService : IDialogService
{
Expand Down
42 changes: 42 additions & 0 deletions CDTag.View/General/GetInputWindow.xaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
<Views:WindowViewBase
x:Class="CDTag.Views.General.GetInputWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:Views="clr-namespace:CDTag.Views"
Title="{Binding WindowTitle, Mode=OneWay}"
MinHeight="200"
MinWidth="200"
Height="200"
Width="350"
CurrentVisualState="{Binding CurrentVisualState}"
FocusManager.FocusedElement="{Binding ElementName=InputTextBox}"
>
<Grid Margin="8">
<Grid.RowDefinitions>
<RowDefinition Height="*" />
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>

<TextBlock Text="{Binding LabelText, Mode=OneWay}" Margin="0,0,8,0" />
<TextBox x:Name="InputTextBox" Text="{Binding InputValue, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" Grid.Row="1" />

<Path Grid.Row="1" Grid.ColumnSpan="2" Data="M0,0 L1,0" Stroke="#CCCCCC" Stretch="Fill" Margin="0,8" />

<Grid Grid.Row="2" Grid.ColumnSpan="2" Grid.IsSharedSizeScope="True">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
<ColumnDefinition Width="Auto" SharedSizeGroup="BottomButtons" MinWidth="80" />
<ColumnDefinition Width="Auto" SharedSizeGroup="BottomButtons" MinWidth="80" />
</Grid.ColumnDefinitions>

<Button Grid.Column="1" Content="_OK" Command="{Binding OKCommand}" Padding="7,2" Margin="8,0,0,0" />
<Button Grid.Column="2" Content="_Cancel" IsCancel="True" Padding="7,2" Margin="8,0,0,0" />
</Grid>

</Grid>
</Views:WindowViewBase>
15 changes: 15 additions & 0 deletions CDTag.View/General/GetInputWindow.xaml.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
using CDTag.Views.Interfaces.General;

namespace CDTag.Views.General
{
/// <summary>
/// Interaction logic for GetInputWindow.xaml
/// </summary>
public partial class GetInputWindow : WindowViewBase, IGetInputWindow
{
public GetInputWindow()
{
InitializeComponent();
}
}
}
4 changes: 2 additions & 2 deletions CDTag.View/Options/OptionsWindow.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using CDTag.View.Interfaces.Options;
using CDTag.ViewModel.Options;
using CDTag.ViewModel.Options;
using CDTag.Views.Interfaces.Options;

namespace CDTag.Views.Options
{
Expand Down
9 changes: 5 additions & 4 deletions CDTag.View/Profile/EditProfile/EditProfileWindow.xaml
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
<Views:WindowViewBase
<Views:WindowViewBase
x:Class="CDTag.Views.Profile.EditProfile.EditProfileWindow"
x:Name="editProfileWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:Views="clr-namespace:CDTag.Views" xmlns:EditProfile="clr-namespace:CDTag.Views.Profile.EditProfile"
xmlns:Views="clr-namespace:CDTag.Views"
xmlns:EditProfile="clr-namespace:CDTag.Views.Profile.EditProfile"
Title="{Binding WindowTitle, Mode=OneWay}"
MinHeight="540"
MinHeight="540"
MinWidth="600"
Height="580"
Height="580"
Width="780"
CurrentVisualState="{Binding CurrentVisualState}"
FocusManager.FocusedElement="{Binding ElementName=ProfileNameTextBox}"
Expand Down
4 changes: 2 additions & 2 deletions CDTag.View/Profile/EditProfile/EditProfileWindow.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using CDTag.View.Interfaces.Profile.EditProfile;
using CDTag.ViewModels.Profile.EditProfile;
using CDTag.ViewModels.Profile.EditProfile;
using CDTag.Views.Interfaces.Profile.EditProfile;

namespace CDTag.Views.Profile.EditProfile
{
Expand Down
2 changes: 1 addition & 1 deletion CDTag.View/Profile/NewProfile/NewProfileWindow.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using System;
using CDTag.View.Interfaces.Profile.NewProfile;
using CDTag.ViewModels.Profile.NewProfile;
using CDTag.Views.Interfaces.Profile.NewProfile;

namespace CDTag.Views.Profile.NewProfile
{
Expand Down
2 changes: 1 addition & 1 deletion CDTag.View/Tag/EditTag/ID3v2Window.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using System.Windows;
using CDTag.Model.Tag;
using CDTag.View.Interfaces.Tag.EditTag;
using CDTag.ViewModels.Tag.EditTag;
using CDTag.Views.Interfaces.Tag.EditTag;
using IdSharp.Common.Events;
using Microsoft.Win32;

Expand Down
4 changes: 2 additions & 2 deletions CDTag.View/Tag/MassTag/MassTagWindow.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using CDTag.View.Interfaces.Tag.MassTag;
using CDTag.ViewModels.Tag.MassTag;
using CDTag.ViewModels.Tag.MassTag;
using CDTag.Views.Interfaces.Tag.MassTag;

namespace CDTag.Views.Tag.MassTag
{
Expand Down
4 changes: 2 additions & 2 deletions CDTag.View/Tag/TagAlbum/TagAlbumWindow.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using CDTag.View.Interfaces.Tag.TagAlbum;
using CDTag.ViewModels.Tag.TagAlbum;
using CDTag.ViewModels.Tag.TagAlbum;
using CDTag.Views.Interfaces.Tag.TagAlbum;

namespace CDTag.Views.Tag.TagAlbum
{
Expand Down
4 changes: 2 additions & 2 deletions CDTag.View/Tools/EncodingInspectorWindow.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using CDTag.View.Interfaces.Tools;
using CDTag.ViewModels.Tools;
using CDTag.ViewModels.Tools;
using CDTag.Views.Interfaces.Tools;

namespace CDTag.Views.Tools
{
Expand Down
4 changes: 2 additions & 2 deletions CDTag.View/Tools/SplitCueWindow.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using CDTag.View.Interfaces.Tools;
using CDTag.ViewModels.Tools;
using CDTag.ViewModels.Tools;
using CDTag.Views.Interfaces.Tools;

namespace CDTag.Views.Tools
{
Expand Down
3 changes: 1 addition & 2 deletions CDTag.View/WindowViewBase.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,10 @@
using System.Windows;
using System.Windows.Input;
using System.Windows.Media;
using CDTag.Common;
using CDTag.Common.Events;
using CDTag.Common.Mvvm;
using CDTag.Common.Settings;
using CDTag.View.Interfaces;
using CDTag.Views.Interfaces;
using IdSharp.Common.Events;

namespace CDTag.Views
Expand Down
Loading

0 comments on commit 82bdb25

Please sign in to comment.