mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-06-16 05:55:20 +00:00
Tag search fixes
This commit is contained in:
parent
9ee9845439
commit
ea9c9ae777
@ -173,7 +173,9 @@ class MessageHistoryTagsSummaryTable: Table {
|
||||
}
|
||||
|
||||
func getCustomTags(tag: MessageTags, peerId: PeerId, threadId: Int64?, namespace: MessageId.Namespace) -> [MemoryBuffer] {
|
||||
let peerKey = self.keyInternal(key: MessageHistoryTagsSummaryKey(tag: tag, peerId: peerId, threadId: threadId, namespace: namespace, customTag: nil), allowShared: false)
|
||||
let key = MessageHistoryTagsSummaryKey(tag: tag, peerId: peerId, threadId: threadId, namespace: namespace, customTag: nil)
|
||||
|
||||
let peerKey = self.keyInternal(key: key, allowShared: false)
|
||||
let prefixLength = 4 + 8 + 4 + 8
|
||||
var result: [MemoryBuffer] = []
|
||||
self.valueBox.range(self.table, start: peerKey.predecessor, end: peerKey.successor, keys: { key in
|
||||
@ -187,6 +189,17 @@ class MessageHistoryTagsSummaryTable: Table {
|
||||
}
|
||||
return true
|
||||
}, limit: 0)
|
||||
|
||||
for updatedKey in self.updatedKeys {
|
||||
if updatedKey.peerId == peerId && updatedKey.tag == tag && updatedKey.threadId == threadId && updatedKey.namespace == namespace {
|
||||
if let customTag = updatedKey.customTag {
|
||||
if !result.contains(customTag) {
|
||||
result.append(customTag)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return result
|
||||
}
|
||||
|
||||
|
@ -287,7 +287,7 @@ final class PeerInfoHeaderNavigationButton: HighlightableButtonNode {
|
||||
self.textNode.attributedText = NSAttributedString(string: text, font: font, textColor: .white)
|
||||
transition.updateTintColor(layer: self.textNode.layer, color: self.contentsColor)
|
||||
self.iconNode.image = icon
|
||||
transition.updateTintColor(layer: self.iconNode.layer, color: self.contentsColor)
|
||||
transition.updateTintColor(view: self.iconNode.view, color: self.contentsColor)
|
||||
|
||||
if isAnimation {
|
||||
self.iconNode.isHidden = true
|
||||
|
Loading…
x
Reference in New Issue
Block a user