Skip to content

Conversation

@kubaflo
Copy link
Contributor

@kubaflo kubaflo commented Dec 12, 2025

Improved comments for clarity in image rotation logic. Updated ShouldUsePngFormat to prioritize original PNG files and clarified the conditions for preserving PNG format.

Fixes #33119

Improved comments for clarity in image rotation logic. Updated ShouldUsePngFormat to prioritize original PNG files and clarified the conditions for preserving PNG format.
@kubaflo kubaflo self-assigned this Dec 12, 2025
@dotnet-policy-service dotnet-policy-service bot added the community ✨ Community Contribution label Dec 12, 2025
@dotnet-policy-service
Copy link
Contributor

Hey there @@kubaflo! Thank you so much for your PR! Someone from the team will get assigned to your PR shortly and we'll get it reviewed.

@kubaflo kubaflo marked this pull request as ready for review December 12, 2025 19:14
Copilot AI review requested due to automatic review settings December 12, 2025 19:14
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR refactors the PNG format detection logic in the iOS MediaPicker to improve clarity and fix inconsistencies. The changes prioritize preserving PNG format for original PNG files and align the quality threshold comment with the actual implementation (90 instead of 95).

Key Changes:

  • Simplified PNG extension check using Path.GetExtension() instead of multiple EndsWith() calls
  • Reordered logic to prioritize original PNG files first
  • Aligned compression quality threshold from 95 to 90 to match the comment and unused variable

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

community ✨ Community Contribution

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[iOS] MediaPicker ShouldUsePngFormat method has conflicting/redundant code

1 participant