20 : screen_(screen), component_(std::move(component)) {
30 return screen_->HasQuitted();
37 screen_->RunOnce(component_);
42 screen_->RunOnceBlocking(component_);
bool HasQuitted()
ループが終了したかどうか。
void Run()
ループが終了するまで、現在のスレッドをブロックしてループを実行します。
Loop(ScreenInteractive *screen, Component component)
LoopはComponentとScreenInteractiveのラッパーです。 これはターミナルでコンポーネントを実行するために使用されます。
void RunOnce()
ループを実行します。componentに保留中のすべてのタスク/イベントを処理させます。 前のフレームが無効になった場合、新しいフレームが描画される可能性があります。 ループが完了するまでtrueを返し...
void RunOnceBlocking()
少なくとも1つのイベントが処理されるのを待ち、Loop::RunOnce()を実行します。
ScreenInteractive はイベントを処理し、メインループを実行し、コンポーネントを管理できる Screen です。
std::shared_ptr< ComponentBase > Component