Skip to content

Commit 9c23fe9

Browse files
CopilotTheJoeFin
andcommitted
Add logo padding pixels to history persistence
Co-authored-by: TheJoeFin <[email protected]>
1 parent 9a2e144 commit 9c23fe9

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

Simple QR Code Maker/Models/HistoryItem.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,8 @@ public ErrorCorrectionLevel ErrorCorrection
4242
public string? LogoImagePath { get; set; }
4343

4444
public double LogoSizePercentage { get; set; } = 15;
45+
46+
public double LogoPaddingPixels { get; set; } = 4.0;
4547

4648
public HistoryItem()
4749
{

Simple QR Code Maker/ViewModels/MainViewModel.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,7 @@ partial void OnSelectedHistoryItemChanged(HistoryItem? value)
131131
}
132132

133133
LogoSizePercentage = value.LogoSizePercentage;
134+
LogoPaddingPixels = value.LogoPaddingPixels;
134135

135136
SelectedHistoryItem = null;
136137
}
@@ -855,6 +856,7 @@ public async Task SaveCurrentStateToHistory()
855856
ErrorCorrection = SelectedOption.ErrorCorrectionLevel,
856857
LogoImagePath = logoImagePath,
857858
LogoSizePercentage = LogoSizePercentage,
859+
LogoPaddingPixels = LogoPaddingPixels,
858860
};
859861

860862
HistoryItems.Remove(historyItem);

0 commit comments

Comments
 (0)