## Summary Before, any sub-activity of a reader activity needed to override `isReaderActivity` to maintain correct bookkeeping through `ActivityManager::isReaderActivity`. We could easily miss this in any new sub-activities. Instead, simplify so each reader activity correctly reports and then `ActivityManager` checks for any reader activity in its stack. --- ### AI Usage While CrossPoint doesn't have restrictions on AI tools in contributing, please be transparent about their usage as it helps set the right context for reviewers. Did you use AI tools to help write this code? _**NO**_
21 lines
500 B
C++
21 lines
500 B
C++
#pragma once
|
|
#include <I18n.h>
|
|
|
|
#include <string>
|
|
|
|
#include "activities/Activity.h"
|
|
|
|
class QrDisplayActivity final : public Activity {
|
|
public:
|
|
explicit QrDisplayActivity(GfxRenderer& renderer, MappedInputManager& mappedInput, const std::string& textPayload)
|
|
: Activity("QrDisplay", renderer, mappedInput), textPayload(textPayload) {}
|
|
|
|
void onEnter() override;
|
|
void onExit() override;
|
|
void loop() override;
|
|
void render(RenderLock&&) override;
|
|
|
|
private:
|
|
std::string textPayload;
|
|
};
|