diff mbox series

[6/7] kernel-shark: Disable the pop-up offset dialog

Message ID 20210427162408.134001-7-y.karadz@gmail.com (mailing list archive)
State Superseded
Headers show
Series More minor modifications and fixes toward KS 2.0 | expand

Commit Message

Yordan Karadzhov April 27, 2021, 4:24 p.m. UTC
The pop-up dialog that asks for the time offset, when a trace data
file is appended, is a legacy from the time when we have been doing
the calculation of the offset by hand. It still can be useful in some
specific cases, but the user can do the same from the "Tools" menu.

Signed-off-by: Yordan Karadzhov (VMware) <y.karadz@gmail.com>
---
 src/KsMainWindow.cpp | 11 +----------
 1 file changed, 1 insertion(+), 10 deletions(-)
diff mbox series

Patch

diff --git a/src/KsMainWindow.cpp b/src/KsMainWindow.cpp
index e830c5e..d0a434a 100644
--- a/src/KsMainWindow.cpp
+++ b/src/KsMainWindow.cpp
@@ -1248,7 +1248,7 @@  void KsMainWindow::_load(const QString& fileName, bool append)
 	QString pbLabel("Loading    ");
 	bool loadDone = false;
 	struct stat st;
-	double shift;
+	double shift(.0);
 	int ret, sd;
 
 	ret = stat(fileName.toStdString().c_str(), &st);
@@ -1264,15 +1264,6 @@  void KsMainWindow::_load(const QString& fileName, bool append)
 
 	qInfo() << "Loading " << fileName;
 
-	if (append) {
-		bool ok;
-		shift = KsTimeOffsetDialog::getValueNanoSec(fileName, &ok);
-		if (ok)
-			shift *= 1000.;
-		else
-			shift = 0.;
-	}
-
 	if (fileName.size() < 40) {
 		pbLabel += fileName;
 	} else {