|
@@ -85,6 +85,10 @@ namespace Compdfkit_Tools.PDFControlUI
|
|
|
|
|
|
private void InsertButton_Click(object sender, RoutedEventArgs e)
|
|
private void InsertButton_Click(object sender, RoutedEventArgs e)
|
|
{
|
|
{
|
|
|
|
+ if (string.IsNullOrEmpty(PageTextBox.Text))
|
|
|
|
+ {
|
|
|
|
+ InsertIndexChanged?.Invoke(null, -1);
|
|
|
|
+ }
|
|
InsertEvent?.Invoke(null, EventArgs.Empty);
|
|
InsertEvent?.Invoke(null, EventArgs.Empty);
|
|
}
|
|
}
|
|
|
|
|
|
@@ -152,7 +156,7 @@ namespace Compdfkit_Tools.PDFControlUI
|
|
{
|
|
{
|
|
index = int.Parse(PageTextBox.Text);
|
|
index = int.Parse(PageTextBox.Text);
|
|
}
|
|
}
|
|
- if (PageTextBox.Text != string.Empty)
|
|
|
|
|
|
+ if (index != -2)
|
|
{
|
|
{
|
|
if (PageLocationComboBox.SelectedIndex == 0)
|
|
if (PageLocationComboBox.SelectedIndex == 0)
|
|
{
|
|
{
|