mirror of
https://github.com/crskycode/GARbro.git
synced 2024-12-24 03:44:13 +08:00
accept extract dialog on enter key press.
This commit is contained in:
parent
9dd07eea06
commit
0003be4a4c
@ -47,6 +47,7 @@ namespace GARbro.GUI
|
|||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
ExtractLabel.Text = string.Format (guiStrings.LabelExtractAllTo, filename);
|
ExtractLabel.Text = string.Format (guiStrings.LabelExtractAllTo, filename);
|
||||||
Destination = destination;
|
Destination = destination;
|
||||||
|
DestinationDir.EnterKeyDown += acb_OnEnterKeyDown;
|
||||||
|
|
||||||
ExtractImages.IsChecked = Settings.Default.appExtractImages;
|
ExtractImages.IsChecked = Settings.Default.appExtractImages;
|
||||||
ExtractText.IsChecked = Settings.Default.appExtractText;
|
ExtractText.IsChecked = Settings.Default.appExtractText;
|
||||||
|
@ -97,6 +97,13 @@ namespace GARbro.GUI
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
protected void acb_OnEnterKeyDown (object sender, KeyEventArgs e)
|
||||||
|
{
|
||||||
|
string path = (sender as AutoCompleteBox).Text;
|
||||||
|
if (!string.IsNullOrEmpty (path))
|
||||||
|
this.DialogResult = true;
|
||||||
|
}
|
||||||
|
|
||||||
public void CanExecuteAlways (object sender, CanExecuteRoutedEventArgs e)
|
public void CanExecuteAlways (object sender, CanExecuteRoutedEventArgs e)
|
||||||
{
|
{
|
||||||
e.CanExecute = true;
|
e.CanExecute = true;
|
||||||
|
@ -45,6 +45,7 @@ namespace GARbro.GUI
|
|||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
ExtractLabel.Text = string.Format (guiStrings.LabelExtractFileTo, entry.Name);
|
ExtractLabel.Text = string.Format (guiStrings.LabelExtractFileTo, entry.Name);
|
||||||
Destination = destination;
|
Destination = destination;
|
||||||
|
DestinationDir.EnterKeyDown += acb_OnEnterKeyDown;
|
||||||
if ("image" == entry.Type)
|
if ("image" == entry.Type)
|
||||||
{
|
{
|
||||||
ImageConversionOptions.Visibility = Visibility.Visible;
|
ImageConversionOptions.Visibility = Visibility.Visible;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user