void ResetTLDStatistics( void ) { lnode_t *tn, *tn2; TLD *t; tn = list_first( tldstatlist ); while( tn != NULL ) { t = lnode_get( tn ); ResetStatistic( &t->users ); if( t->users.current == 0 ) { /* don't delete the tld entry ??? as its our "unknown" entry */ if( ircstrcasecmp( t->tld, UNKNOWN_COUNTRY_CODE ) ) { tn2 = list_next( tldstatlist, tn ); ns_free( t ); list_delete_destroy_node( tldstatlist, tn ); tn = tn2; continue; } } tn = list_next( tldstatlist, tn ); } }
CAudioAnalyzer::~CAudioAnalyzer() { if (m_callback != NULL) { m_callback->Release(); m_callback = NULL; } ResetStatistic(); DbgLog((LOG_MEMORY,1,TEXT("AudioAnalyzer destroyed"))); }
void OverviewDataStreamsWidget::TwAudioCustomContextMenuEvent(const QPoint &pPos) { QAction *tAction; QMenu tMenu(this); tAction = tMenu.addAction("Save all"); QIcon tIcon1; tIcon1.addPixmap(QPixmap(":/images/22_22/Save.png"), QIcon::Normal, QIcon::Off); tAction->setIcon(tIcon1); tAction = tMenu.addAction("Save row history"); tAction->setIcon(tIcon1); tAction = tMenu.addAction("Reset row"); QIcon tIcon2; tIcon2.addPixmap(QPixmap(":/images/22_22/Reload.png"), QIcon::Normal, QIcon::Off); tAction->setIcon(tIcon2); QAction* tPopupRes = tMenu.exec(QCursor::pos()); if (tPopupRes != NULL) { if (tPopupRes->text().compare("Reset row") == 0) { ResetStatistic(DATA_TYPE_AUDIO, mTwAudio->currentRow()); return; } if (tPopupRes->text().compare("Save row history") == 0) { SaveHistory(DATA_TYPE_AUDIO, mTwAudio->currentRow()); return; } if (tPopupRes->text().compare("Save all") == 0) { SaveCompleteStatistic(); return; } } }