Skip to content

Commit

Permalink
Fix text overflow in flag import dialog (#608)
Browse files Browse the repository at this point in the history
  • Loading branch information
pizzaboxer committed Nov 3, 2023
1 parent c4d3c5b commit 499a0f9
Showing 1 changed file with 10 additions and 7 deletions.
17 changes: 10 additions & 7 deletions Bloxstrap/UI/Elements/Menu/Pages/FastFlagEditorPage.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -271,14 +271,17 @@ private void ImportJSONButton_Click(object sender, RoutedEventArgs e)

if (conflictingFlags.Any())
{
var result = Controls.ShowMessageBox(
"Some of the flags you are attempting to import already have set values. Would you like to overwrite their current values with the ones defined in the import?\n" +
int count = conflictingFlags.Count();

string message = "Some of the flags you are attempting to import already have set values. Would you like to overwrite their current values with the ones defined in the import?\n" +
"\n" +
"Conflicting flags:\n" +
String.Join(", ", conflictingFlags),
MessageBoxImage.Question,
MessageBoxButton.YesNo
);
$"There are {count} conflicting flag definitions:\n" +
String.Join(", ", conflictingFlags.Take(25));

if (count > 25)
message += "...";

var result = Controls.ShowMessageBox(message, MessageBoxImage.Question, MessageBoxButton.YesNo);

overwriteConflicting = result == MessageBoxResult.Yes;
}
Expand Down

0 comments on commit 499a0f9

Please sign in to comment.