Rename the search type menu items to more accurately reflect what we're
[metze/wireshark/wip.git] / ui / qt / label_stack.cpp
index 142d0977168375d75de75e7c321b4b8907faad7f..8480a3eb5e83e34123e810b126c38562019ae0b8 100644 (file)
@@ -79,16 +79,19 @@ void LabelStack::fillLabel() {
 
 void LabelStack::pushText(QString &text, int ctx) {
     StackItem *si = new StackItem;
-    si->text = text;
-    si->ctx = ctx;
-    labels_.prepend(si);
 
     if (ctx == temporary_ctx_) {
+        temporary_timer_.stop();
+        popText(temporary_ctx_);
+
         temporary_epoch_.start();
         temporary_timer_.start(temporary_flash_timeout_);
         emit toggleTemporaryFlash(true);
     }
 
+    si->text = text;
+    si->ctx = ctx;
+    labels_.prepend(si);
     fillLabel();
 }