mirror of
https://github.com/neon443/StickerSlack.git
synced 2026-03-11 13:26:17 +00:00
added sticker count to the corner
ps: finally got proof that ts project will work!!!!! "The sticker browser presents the stickers provided by its dataSource property. The data source can dynamically change the list of stickers at runtime." https://developer.apple.com/documentation/messages/msstickerbrowserview#:~:text=The%20data%20source%20can%20dynamically%20change%20the%20list%20of%20stickers%20at%20runtime.
This commit is contained in:
@@ -9,7 +9,8 @@ import UIKit
|
||||
import Messages
|
||||
|
||||
class MessagesViewController: MSMessagesAppViewController {
|
||||
|
||||
var hoard: EmojiHoarder = EmojiHoarder()
|
||||
|
||||
override func viewDidLoad() {
|
||||
super.viewDidLoad()
|
||||
// Do any additional setup after loading the view.
|
||||
@@ -18,6 +19,13 @@ class MessagesViewController: MSMessagesAppViewController {
|
||||
// MARK: - Conversation Handling
|
||||
|
||||
override func willBecomeActive(with conversation: MSConversation) {
|
||||
print(hoard.emojis.count)
|
||||
let l = UILabel()
|
||||
l.frame = CGRect(x: 20, y: 20, width: 1000, height: 40)
|
||||
l.textColor = .systemOrange
|
||||
l.text = "\(hoard.emojis.count)"
|
||||
view.addSubview(l)
|
||||
view.bringSubviewToFront(l)
|
||||
// Called when the extension is about to move from the inactive to active state.
|
||||
// This will happen when the extension is about to present UI.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user