void Task::execute(Time time) { if (m_is_looping) m_next_execution += m_period; onExecute(time); }
void Cmd::execute(Context* ctx) { ASSERT(m_state == State::NotExecuted); m_ctx = ctx; onExecute(); onFireNotifications(); #if _DEBUG m_state = State::Executed; #endif }
void Cmd::execute(Context* ctx) { DLOG("Cmd: Executing cmd '%s'\n", typeid(*this).name()); ASSERT(m_state == State::NotExecuted); m_ctx = ctx; onExecute(); onFireNotifications(); #if _DEBUG m_state = State::Executed; #endif }
CXUtilsWindow::CXUtilsWindow() : AXBaseWindow() { setGroupNumber(101); mProcess = NULL; QVBoxLayout* centralLayout = new QVBoxLayout(this); centralLayout->setMargin(7); centralLayout->setSpacing(6); mTreeWidget = new QTreeWidget(this); mTreeWidget->setHeaderHidden(true); mTreeWidget->setRootIsDecorated(false); centralLayout->addWidget(mTreeWidget); /**/ QHBoxLayout* buttonLayout = new QHBoxLayout; buttonLayout->setMargin(0); buttonLayout->setSpacing(6); buttonLayout->addStretch(); CXTouchButton* executeButton = new CXTouchButton(trUtf8("Запустить"), this); buttonLayout->addWidget(executeButton); CXTouchButton* closeButton = new CXTouchButton(trUtf8("Закрыть"), this); closeButton->setObjectName("mCloseButton"); buttonLayout->addWidget(closeButton); /**/ centralLayout->addLayout(buttonLayout); connect(executeButton, SIGNAL(clicked()), this, SLOT(onExecute())); connect(closeButton, SIGNAL(clicked()), this, SLOT(close())); registerManager(); load("utils.xml"); }
void IJob::execute(Thread::IThread* t) { // note: \p t can be null // Reseting data // We will keep the state in `waiting` until we have properly set // all other values pThread = t; pCanceling = 0; pProgression = 0; // Here we go ! pState = stateRunning; // Execute the specific implementation of the job onExecute(); // The state must be reset to idle as soon as possible while the // other values are still valid. pState = stateIdle; // Other values pThread = nullptr; pProgression = 100; }
void Command::execute(Context* context) { onExecute(context); }
void Cmd::onRedo() { // By default onRedo() uses onExecute() implementation onExecute(); }