This commit is contained in:
Tobias Wohlleben 2025-01-21 11:18:37 +01:00
parent bbf81a46ab
commit 02178bb7c8
2 changed files with 7 additions and 6 deletions

View File

@ -7,7 +7,7 @@
mc:Ignorable="d"
Title="PictureGalleryPage" Width="1600" Height="795"
xmlns:ui="http://schemas.lepo.co/wpfui/2022/xaml"
Background="Magenta">
Background="Black">
<Grid>
<WrapPanel VerticalAlignment="Stretch" x:Name="PicturesPanel" Orientation="Horizontal" />
<ContentPresenter x:Name="RootContentDialogPresenter" Grid.Row="0" />

View File

@ -73,11 +73,12 @@ public partial class PictureGalleryPage : Page, IDisposable
var hyperlink = new Hyperlink();
hyperlink.Click += Hyperlink_OnClick;
hyperlink.Tag = thumbnail.UriSource;
hyperlink.TextDecorations = null;
var imageControl = new Wpf.Ui.Controls.Image
{
Source = thumbnail,
Width = 388,
Margin = new Thickness(3)
Width = 381,
Margin = new Thickness(6)
};
hyperlink.Inlines.Add(new InlineUIContainer(imageControl));
@ -100,12 +101,12 @@ public partial class PictureGalleryPage : Page, IDisposable
var imageToShow = new Image
{
VerticalAlignment = VerticalAlignment.Center,
Source = PictureGalleryService.CreateThumbnail(picturePathUri.AbsolutePath, 500, 300)
Source = PictureGalleryService.CreateThumbnail(picturePathUri.AbsolutePath, 499, 300)
};
contentDialog.DialogWidth = 940;
contentDialog.CloseButtonAppearance = ControlAppearance.Dark;
contentDialog.PrimaryButtonAppearance = ControlAppearance.Light;
contentDialog.PrimaryButtonAppearance = ControlAppearance.Success;
contentDialog.CloseButtonAppearance = ControlAppearance.Primary;
//contentDialog.SetCurrentValue(ContentDialog.TitleProperty, "Hello World");
contentDialog.SetCurrentValue(ContentControl.ContentProperty, imageToShow);
contentDialog.SetCurrentValue(ContentDialog.CloseButtonTextProperty, "Schließen");