Fixed default profile creation

Don't allow dropping a folder into itself
This commit is contained in:
Robert committed 2019-11-25 19:27:55 +01:00
1 parent 602a0e6fee
commit 3084869d75
9 files changed
+49 -34

No files matched your search

@@ -15,7 +15,8 @@
<TextBox materialDesign:HintAssist.Hint="Element name"
Margin="0 8 0 16"
Style="{StaticResource MaterialDesignFloatingHintTextBox}"
Text="{Binding ElementName, UpdateSourceTrigger=PropertyChanged}"/>
Text="{Binding ElementName, UpdateSourceTrigger=PropertyChanged}"
Loaded="FrameworkElement_OnLoaded"/>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right">
<Button Style="{StaticResource MaterialDesignFlatButton}" IsCancel="True" Margin="0 8 8 0" Command="{s:Action Cancel}">
@@ -1,22 +1,11 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
namespace Artemis.UI.Screens.Module.ProfileEditor.Dialogs
{
/// <summary>
/// Interaction logic for ProfileElementRenameView.xaml
/// Interaction logic for ProfileElementRenameView.xaml
/// </summary>
public partial class ProfileElementRenameView : UserControl
{
@@ -24,5 +13,12 @@ namespace Artemis.UI.Screens.Module.ProfileEditor.Dialogs
{
InitializeComponent();
}
private void FrameworkElement_OnLoaded(object sender, RoutedEventArgs e)
{
var textBox = (TextBox) sender;
Keyboard.Focus(textBox);
textBox.SelectAll();
}
}
}
}