void ImmediateWorkItemQueue::enqueue(ImmediateWorkItem* newWorkItem) { EsifMutexHelper esifMutexHelper(&m_mutex); esifMutexHelper.lock(); // In the case of an interrupt storm we need to make sure we don't enqueue a temperature threshold crossed // event if the same event is already in the queue. throwIfDuplicateThermalThresholdCrossedEvent(newWorkItem); insertSortedByPriority(newWorkItem); updateMaxCount(); esifMutexHelper.unlock(); }
void DeferredWorkItemQueue::enqueue(DeferredWorkItem* newWorkItem) { // FIMXE: during round 2, need to add statistics logging // Insert into the queue sorted based on time stamp. The timer must be set to expire // when the first item in the queue is ready to process. EsifMutexHelper esifMutexHelper(&m_mutex); esifMutexHelper.lock(); insertSortedByDeferredProcessingTime(newWorkItem); updateMaxCount(); setTimer(); esifMutexHelper.unlock(); }
DisplayFilterCombo::DisplayFilterCombo(QWidget *parent) : QComboBox(parent) { setEditable(true); // Enabling autocompletion here gives us two simultaneous completions: // Inline (highlighted text) for entire filters, handled here and popup // completion for fields handled by DisplayFilterEdit. setAutoCompletion(false); setLineEdit(new DisplayFilterEdit(this, false)); setSizePolicy(QSizePolicy::MinimumExpanding, QSizePolicy::Fixed); setAccessibleName(tr("Display filter selector")); cur_display_filter_combo = this; setStyleSheet( "QComboBox {" #ifdef Q_OS_MAC " border: 1px solid gray;" #else " border: 1px solid palette(shadow);" #endif " border-radius: 3px;" " padding: 0px 0px 0px 0px;" " margin-left: 0px;" " min-width: 20em;" " }" "QComboBox::drop-down {" " subcontrol-origin: padding;" " subcontrol-position: top right;" " width: 16px;" " border-left-width: 0px;" " }" "QComboBox::down-arrow {" " image: url(:/dfilter/dfilter_dropdown.png);" " }" "QComboBox::down-arrow:on { /* shift the arrow when popup is open */" " top: 1px;" " left: 1px;" "}" ); #ifndef QT_NO_TOOLTIP setToolTip(tr("Select from previously used filters")); #endif // QT_NO_TOOLTIP connect(wsApp, SIGNAL(preferencesChanged()), this, SLOT(updateMaxCount())); }