From 586e22e4a5dd8285b2dae2768e4cc96d7b2a96d3 Mon Sep 17 00:00:00 2001 From: Akash Mozumdar Date: Tue, 9 Oct 2018 05:45:49 -0400 Subject: [PATCH] read filter from ini --- GUI/mainwindow.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/GUI/mainwindow.cpp b/GUI/mainwindow.cpp index 7a1311e..982f939 100644 --- a/GUI/mainwindow.cpp +++ b/GUI/mainwindow.cpp @@ -15,6 +15,7 @@ MainWindow::MainWindow(QWidget *parent) : // TODO: add GUI for changing these if (settings.contains("Flush_Delay")) TextThread::flushDelay = settings.value("Flush_Delay").toInt(); if (settings.contains("Max_Buffer_Size")) TextThread::maxBufferSize = settings.value("Max_Buffer_Size").toInt(); + if (settings.contains("Filter")) TextThread::filter = settings.value("Filter").toString().toStdWString().c_str(); processCombo = findChild("processCombo"); ttCombo = findChild("ttCombo"); @@ -43,6 +44,7 @@ MainWindow::~MainWindow() settings.setValue("Window", this->geometry()); settings.setValue("Flush_Delay", TextThread::flushDelay); settings.setValue("Max_Buffer_Size", TextThread::maxBufferSize); + settings.setValue("Filter", QString::fromStdWString(TextThread::filter)); settings.sync(); Host::Close(); delete ui;