MCPcopy Create free account
hub / github.com/TDesktop-x64/tdesktop / processPoll

Method processPoll

Telegram/SourceFiles/data/data_session.cpp:4539–4553  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4537}
4538
4539not_null<PollData*> Session::processPoll(const MTPPoll &data) {
4540 return data.match([&](const MTPDpoll &data) {
4541 const auto id = data.vid().v;
4542 const auto result = poll(id);
4543 const auto changed = result->applyChanges(data);
4544 if (changed) {
4545 notifyPollUpdateDelayed(result);
4546 }
4547 if (result->closeDate > 0 && !result->closed()) {
4548 _pollsClosings.emplace(result->closeDate, result);
4549 checkPollsClosings();
4550 }
4551 return result;
4552 });
4553}
4554
4555not_null<PollData*> Session::processPoll(const MTPDmessageMediaPoll &data) {
4556 const auto result = processPoll(data.vpoll());

Callers 2

updateSentMediaMethod · 0.80
CreateMediaMethod · 0.80

Calls 7

emplaceMethod · 0.80
applyResultsMethod · 0.80
PollMediaClass · 0.70
LocationPointClass · 0.70
applyChangesMethod · 0.45
closedMethod · 0.45
typeMethod · 0.45

Tested by

no test coverage detected