fix: save media-only deleted messages with type placeholder#382
Open
denfry wants to merge 2 commits into
Open
Conversation
…t high DPI AyuAssets::currentAppLogo() creates images with devicePixelRatio set to style::DevicePixelRatio() (e.g. 2.0 at 200% scaling). After scaledToWidth() Qt preserves that DPR, making the logical canvas size args.size/DPR while WithSmallCounter uses args.size as drawing coordinates — causing the badge to render partially outside bounds (visible as a grey triangle). Upstream Telegram loads logo from PNG files (DPR=1 by default), so this mismatch only affects AyuGram. Resetting to 1.0 before caching aligns the painter's logical space with the coordinate system used by counter drawing. Fixes AyuGram#310
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
addDeletedMessagehad an early return onmessage.text.empty(), silently discarding all media-only deleted messages (photos, videos, stickers, voice, GIFs, files without a caption)item->media()and assign a localized type placeholder ("Photo","Video","Video message","Voice message","Sticker","GIF","Audio file","File") before saving — same strings Telegram uses in the dialog list previewFixes #374
This PR was AI generated.