X-Git-Url: https://sigrok.org/gitweb/?a=blobdiff_plain;f=pv%2Fviews%2Ftrace%2Fdecodetrace.cpp;h=d9b4691b310e883816a4bfd373cf93644608708a;hb=0bb3dd25421a8638afb881d46799a13378d3f00b;hp=52ba83d64ddb94a4063bd46d5973d22591fd67f5;hpb=02078aa15a4747b8ab7a91d54e2e141c3acb5628;p=pulseview.git diff --git a/pv/views/trace/decodetrace.cpp b/pv/views/trace/decodetrace.cpp index 52ba83d6..d9b4691b 100644 --- a/pv/views/trace/decodetrace.cpp +++ b/pv/views/trace/decodetrace.cpp @@ -697,7 +697,7 @@ void DecodeTrace::mouse_left_press_event(const QMouseEvent* event) void DecodeTrace::draw_annotations(deque& annotations, QPainter &p, const ViewItemPaintParams &pp, int y, const DecodeTraceRow& row) { - Annotation::Class block_class = 0; + uint32_t block_class = 0; bool block_class_uniform = true; qreal block_start = 0; int block_ann_count = 0; @@ -802,7 +802,7 @@ void DecodeTrace::draw_annotation(const Annotation* a, QPainter &p, } void DecodeTrace::draw_annotation_block(qreal start, qreal end, - Annotation::Class ann_class, bool use_ann_format, QPainter &p, int y, + uint32_t ann_class, bool use_ann_format, QPainter &p, int y, const DecodeTraceRow& row) const { const double top = y + .5 - annotation_height_ / 2; @@ -1142,7 +1142,7 @@ QComboBox* DecodeTrace::create_channel_selector(QWidget *parent, const DecodeCha QComboBox *selector = new QComboBox(parent); - selector->addItem("-", qVariantFromValue((void*)nullptr)); + selector->addItem("-", QVariant::fromValue((void*)nullptr)); if (!ch->assigned_signal) selector->setCurrentIndex(0); @@ -1151,7 +1151,7 @@ QComboBox* DecodeTrace::create_channel_selector(QWidget *parent, const DecodeCha assert(b); if (b->logic_data() && b->enabled()) { selector->addItem(b->name(), - qVariantFromValue((void*)b.get())); + QVariant::fromValue((void*)b.get())); if (ch->assigned_signal == b.get()) selector->setCurrentIndex(selector->count() - 1); @@ -1166,9 +1166,9 @@ QComboBox* DecodeTrace::create_channel_selector_init_state(QWidget *parent, { QComboBox *selector = new QComboBox(parent); - selector->addItem("0", qVariantFromValue((int)SRD_INITIAL_PIN_LOW)); - selector->addItem("1", qVariantFromValue((int)SRD_INITIAL_PIN_HIGH)); - selector->addItem("X", qVariantFromValue((int)SRD_INITIAL_PIN_SAME_AS_SAMPLE0)); + selector->addItem("0", QVariant::fromValue((int)SRD_INITIAL_PIN_LOW)); + selector->addItem("1", QVariant::fromValue((int)SRD_INITIAL_PIN_HIGH)); + selector->addItem("X", QVariant::fromValue((int)SRD_INITIAL_PIN_SAME_AS_SAMPLE0)); selector->setCurrentIndex(ch->initial_pin_state);