void EffectElement::update( Real time, TransformInfo &info ) { // calculate the born time Real currentStartTime = mCurrentStartTime + time; if ( currentStartTime < mStartTime ) { mCurrentStartTime = currentStartTime; return; } /*if (mBasicNode) mBasicNode->setVisible(mVisible);*/ if ( false == mIsRenderInstanceCreated ) { if ( createRenderInstance() ) mIsRenderInstanceCreated = true; } //¡¡calculate the life time Real currentTime = mCurrentLifeTime + time; // if the life time is zero ,the element will not be deleted. if ( (currentTime > mLifeTime) && (mLifeTime > 0.0f) ) { // destroy destroyMe(); } else { mCurrentLifeTime = currentTime; updateRenderInstance(time,info); } }
IpcMessageRefCount CmpMessageObj::decrRefCount() { if (getRefCount()==1) { if (h_) { destroyMe(); h_->deallocateMemory(this); } else delete this; return 0; } return IpcMessageObj::decrRefCount(); }
Kfind::Kfind(QWidget *parent, const char *name) : QWidget(parent, name) { kdDebug() << "Kfind::Kfind " << this << endl; QBoxLayout *mTopLayout = new QBoxLayout(this, QBoxLayout::LeftToRight, KDialog::marginHint(), KDialog::spacingHint()); // create tabwidget tabWidget = new KfindTabWidget(this); mTopLayout->addWidget(tabWidget); /* * This is ugly. Might be a KSeparator bug, but it makes a small black * pixel for me which is visually distracting (GS). // create separator KSeparator * mActionSep = new KSeparator( this ); mActionSep->setFocusPolicy( QWidget::ClickFocus ); mActionSep->setOrientation( QFrame::VLine ); mTopLayout->addWidget(mActionSep); */ // create button box QVBox *mButtonBox = new QVBox(this); QVBoxLayout *lay = (QVBoxLayout *)mButtonBox->layout(); lay->addStretch(1); mTopLayout->addWidget(mButtonBox); mSearch = new KPushButton(KGuiItem(i18n("&Find"), "find"), mButtonBox); mButtonBox->setSpacing((tabWidget->sizeHint().height() - 4 * mSearch->sizeHint().height()) / 4); connect(mSearch, SIGNAL(clicked()), this, SLOT(startSearch())); mStop = new KPushButton(KGuiItem(i18n("Stop"), "stop"), mButtonBox); connect(mStop, SIGNAL(clicked()), this, SLOT(stopSearch())); mSave = new KPushButton(KStdGuiItem::saveAs(), mButtonBox); connect(mSave, SIGNAL(clicked()), this, SLOT(saveResults())); KPushButton *mClose = new KPushButton(KStdGuiItem::close(), mButtonBox); connect(mClose, SIGNAL(clicked()), this, SIGNAL(destroyMe())); // react to search requests from widget connect(tabWidget, SIGNAL(startSearch()), this, SLOT(startSearch())); mSearch->setEnabled(true); // Enable "Search" mStop->setEnabled(false); // Disable "Stop" mSave->setEnabled(false); // Disable "Save..." dirlister = new KDirLister(); }
CmpMessageISPRequest::~CmpMessageISPRequest() { destroyMe(); }
CmpMessageEnvs::~CmpMessageEnvs() { destroyMe(); }
CmpMessageReplyCode::~CmpMessageReplyCode() { destroyMe(); }
CmpMessageReply::~CmpMessageReply() { destroyMe(); }