Commit graph

60 commits

Author SHA1 Message Date
isaac
69bfc65da7 Postbox refactor waves 138–276: 168-commit squash
Consolidates 137 wave commits + 31 supporting commits (CLAUDE.md bump,
typealias additions, AnyObject→EngineMedia restoration) into one squashed
commit. Migrates dozens of consumer-side public APIs, struct fields,
protocol methods, and enum payloads from Postbox protocols/structs to
TelegramEngine engine wrappers and typealiases. Drops `import Postbox`
from many files. Adds new TelegramCore typealiases and one
TelegramEngineUnauthorized facade.

Notable changes by category:

**TelegramCore typealias additions** (rule 2 — narrow utility typealiases):
- EngineChatListIndex, EngineTempBoxFile, EngineItemCollectionItemIndex,
  EngineItemCollectionViewEntryIndex, EngineValueBoxEncryptionParameters,
  EngineMessageAndThreadId, EnginePeerStoryStats, EngineMessageHistoryAnchorIndex,
  EngineChatListTotalUnreadStateCategory, EngineChatListTotalUnreadStateStats,
  EnginePeerSummaryCounterTags, EngineChatListTotalUnreadState,
  EngineItemCacheEntryId, EngineHashFunctions,
  EngineCachedMediaResourceRepresentationResult,
  EngineMediaResourceDataFetchResult, EngineMediaResourceDataFetchError,
  EngineMediaResourceStatus, EngineCachedPeerData

**TelegramCore engine extensions/forwarders**:
- EngineMessage.engineMedia, EngineMessage.enginePeers,
  EngineMessage.adAttribute, EngineMessage.effectivelyIncoming
- engineFileSize forwarder
- TelegramEngine.Resources.clearCachedMediaResources(mediaResourceIds: Set<EngineMediaResource.Id>)
- TelegramEngine.Resources.fetchStatus(id:resourceSize:)
- TelegramEngineUnauthorized.UnauthorizedResources facade with storeResourceData

**Public API/struct migrations to engine types**:
- ChatAvailableMessageActions.banAuthor/banAuthors → EnginePeer?/[EnginePeer]
- WebSessionsContextState.peers → [EnginePeer.Id: EnginePeer]
- CacheUsageStats.peers → [EnginePeer.Id: EnginePeer]
- PeerCommand.peer → EnginePeer
- PeerInfoControllerMode.calls(messages:) → [EngineMessage]
- CallControllerNodeProtocol.updatePeer → EnginePeer params
- ChatHistoryListNode.messageInCurrentHistoryView (and 4 variants) → EngineMessage?
- ChatHistorySearchContainerNode.messageForGallery → EngineMessage?
- PeerInfoPaneNode.findLoadedMessage / ensureMessageIsVisible /
  transitionNodeForGallery → engine-typed
- GalleryHiddenMediaTarget.getTransitionInfo /
  GalleryHiddenMediaManager.findTarget → engine-typed
- ChatPanelInterfaceInteraction.presentReactionDeletionOptions /
  presentBan*MessageOptions → EnginePeer
- DrawingMessageRenderer.messages → [EngineMessage]
- ChatVideoGalleryItemScrubberView.setFetchStatusSignal →
  EngineMediaResource.FetchStatus
- ChannelDiscussionGroupActionSheetItem.peer, VoiceChatPeerEntry.peer,
  VoiceChatFullscreenParticipantItem.peer, MediaStreamComponent.chatPeer,
  MediaStreamVideoComponent.callPeer, ChatMessageContactBubbleContentNode.contactPeer,
  ChatMessageForwardInfoNode.peer, ChatMessageCommentFooterContentNode.replyPeers,
  ChatReportPeerTitlePanelNode.peer, ChatMessageActionUrlAuthController.bot,
  PeerMediaCollectionInterfaceState.peer, ChatMessageCallBubbleContentNode.peopleAvatars,
  ChatLoadingNode.renderedPeer (→ EngineRenderedPeer) — all to engine types

**Wave-71-shadow stored-field migrations** (Postbox Peer/Message → Engine wrapper):
- LegacyCallControllerNode.peer
- CallStatusBarNode.currentPeer

**Dead-code / dead-field removals**:
- CallController.peer, CallControllerNodeV2.account,
  ContactMultiselectionController PeerNameIndex fields,
  preparedChatListNodeViewTransition account: Account param,
  FetchResource.swift entirely (unused function)

**Module-level Postbox import drops**: 30+ files including TelegramRootController,
EditStories, GiftViewScreen, AnimatedStickerUtils, FetchPhotoLibraryImageResource,
PeerInfoGiftsPaneNode, PeerInfoPaneContainerNode, PresentAddMembers,
PeerInfoProfileItems, ChatControllerAdminBanUsers, PresentationData typealiases,
DefaultDayPresentationTheme, ChatListViewTransition, GalleryHiddenMediaManager,
RecentSessionsController, GifContext, AuthorizationSequenceController,
PeerInfoHeaderEditingContentNode, PeerInfoHeaderNode,
PeerAllowedReactionListController, CallControllerNodeV2, and 6 PeerInfo pane files.

**AnyObject restoration**: rule 8 added (never substitute Postbox protocols
with Any/AnyObject) — undid previous AnyObject substitutions in waves 141/143
back to EngineMedia.

Doc maintenance: CLAUDE.md updated to reflect new typealiases and forwarders.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-05 00:44:27 +02:00
isaac
8408e0ae19 Postbox -> TelegramEngine waves 27-36
Consumer-sweep, facade-addition, and Peer→EnginePeer migrations:

- Wave 27: preferencesView consumer sweep
- Wave 28: resourceData consumer sweep
- Wave 29: resourceStatus consumer sweep
- Wave 30: _asStatus() bridge cleanup
- Wave 31: unused-import sweep re-run
- Wave 32: resourceStatus residue sweep
- Wave 33: loadedPeerWithId consumer sweep
- Wave 34: FoundPeer.peer Peer -> EnginePeer
- Wave 35: SendAsPeer.peer Peer -> EnginePeer
- Wave 36: ContactListPeer.peer Peer -> EnginePeer

Also includes per-wave specs, implementation plans, outcome logs, and
a CLAUDE.md wave-counter update.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-24 11:24:13 +04:00
Isaac
4a13c3830a Glass 2025-12-26 20:29:30 +08:00
Isaac
0619f73819 Updates 2025-10-18 02:00:35 +08:00
Ilya Laktyushin
0915a42e64 Various improvements 2025-10-16 05:30:06 +04:00
Ilya Laktyushin
ecd495e1d4 Various fixes 2025-09-29 23:27:10 +04:00
Isaac
7593cc2724 Group call participants may not have a peer available (support blockchain ids) 2025-04-14 20:18:33 +04:00
Isaac
a4717b7906 [WIP] Conference 2025-01-21 11:04:37 +04:00
Isaac
7e9b1fcc40 [WIP] Conference calls 2024-12-10 22:17:36 +08:00
Isaac
b90e3563a3 Voice chat optimizations (video and mic blob) 2024-05-31 18:00:30 +04:00
Isaac
7c0d5519bf Various improvements 2023-12-28 16:55:12 +04:00
Ilya Laktyushin
10b679446e Disable voice chat waves animation when energy saving 2023-03-02 12:55:37 +04:00
Ali
6e5c503338 Refactoring 2021-09-20 14:51:46 +03:00
Ali
e170f2fe5a Combo update 2021-08-06 19:11:22 +02:00
Ali
31bc746984 Fix more warnings 2021-08-05 01:42:59 +02:00
Ali
7bed1728bb Refactor string generation 2021-07-20 11:57:50 +02:00
Ilya Laktyushin
9f50d2e0ff Video Chat Fixes 2021-05-27 01:25:21 +04:00
Ilya Laktyushin
5eb61351f9 Video Chat Improvements 2021-05-26 15:53:03 +04:00
Ilya Laktyushin
013e5bd699 Merge branch 'master' of gitlab.com:peter-iakovlev/telegram-ios 2021-05-25 22:31:46 +04:00
Ilya Laktyushin
d3558a9c09 Video Chat Improvements 2021-05-25 22:09:48 +04:00
Ali
507668a6c7 Temporarily disable some animations 2021-05-25 19:11:11 +04:00
Ali
77a13c0926 Disable everything 2021-05-24 19:35:05 +04:00
Ilya Laktyushin
659ea466c9 Video Chat Improvements 2021-05-21 16:02:08 +04:00
Ilya Laktyushin
8c587463fd Voice Chat Fixes 2021-04-09 21:17:26 +03:00
Ilya Laktyushin
16b8b71e43 Voice Chat Fixes 2021-04-09 18:25:38 +03:00
Ilya Laktyushin
31d9ae2869 Voice Chat Fixes 2021-04-09 02:28:28 +03:00
Ilya Laktyushin
b9e52f27e3 Voice Chat Scheduling 2021-04-07 04:33:05 +03:00
Ilya Laktyushin
47409b6156 Voice Chat Fixes 2021-03-12 21:34:24 +04:00
Ilya Laktyushin
8dc3973f4f Fix custom voice chat title display in status bar 2021-03-11 23:30:05 +04:00
Ilya Laktyushin
a1a926c5cf Voice Chat fixes 2021-03-11 23:01:46 +04:00
Ilya Laktyushin
39304d1a60 Voice Chat Improvements 2021-03-11 21:01:12 +04:00
Ali
58f7578a5a WIP 2021-01-05 22:32:44 +04:00
Ilya Laktyushin
2db50460a9 Various fixes 2020-12-18 16:36:43 +04:00
Ilya Laktyushin
23d0ac26b8 Voice Chat UI fixes 2020-12-15 02:12:49 +04:00
Ilya Laktyushin
dc1006617b Merge branch 'master' of gitlab.com:peter-iakovlev/telegram-ios 2020-12-12 03:40:44 +04:00
Ilya Laktyushin
a2a722d87d Voice Chat UI improvements 2020-12-12 03:40:31 +04:00
Ali
e1d40e7ef4 Voice chat improvements 2020-12-12 00:02:53 +04:00
Ilya Laktyushin
f8760cd7db Voice Chat UI improvements 2020-12-11 16:16:18 +04:00
Ilya Laktyushin
16eae46449 Voice Chat UI improvements 2020-12-10 19:38:45 +04:00
Ilya Laktyushin
9a5e3867d6 Voice Chat UI improvements 2020-12-10 14:08:13 +04:00
Ilya Laktyushin
bf95bee548 Voice Chat UI improvements 2020-12-10 00:22:10 +04:00
Ilya Laktyushin
e94885aa08 Voice Chat UI improvements 2020-12-08 21:06:03 +04:00
Ilya Laktyushin
5867099883 Voice Chat UI fixes 2020-12-06 23:23:36 +04:00
Ilya Laktyushin
63bd91f33b Voice Chat UI fixes 2020-12-06 21:10:37 +04:00
Ilya Laktyushin
d2229c6192 Voice Chat UI fixes 2020-12-06 10:27:59 +04:00
Ilya Laktyushin
1522c6c7f6 Voice Chat UI fixes 2020-12-05 22:40:22 +04:00
Ilya Laktyushin
e26feea167 Voice Chat UI fixes 2020-12-05 20:32:22 +04:00
Ilya Laktyushin
0897f59b5b Voice Chat UI improvements 2020-12-04 10:09:19 +04:00
Ilya Laktyushin
dc4eed539e Voice Chat UI fixes 2020-12-03 05:22:39 +04:00
Ilya Laktyushin
623882121b Voice Chat UI fixes 2020-12-02 21:48:13 +04:00