Skip to content

Commit

Permalink
Merge pull request #18 from lgolouz/lgolouz_zxtr-17
Browse files Browse the repository at this point in the history
Fixed [ZXTR-17] Unable to build the app using Qt 6
  • Loading branch information
lgolouz authored Aug 8, 2021
2 parents fae6891 + 84eabba commit 2f2ac53
Show file tree
Hide file tree
Showing 19 changed files with 122 additions and 3 deletions.
15 changes: 13 additions & 2 deletions ZXTapeReviver.pro
Original file line number Diff line number Diff line change
@@ -1,6 +1,17 @@
QT += quick gui quickcontrols2
#*******************************************************************************
# ZX Tape Reviver
#-----------------
#
# Author: Leonid Golouz
# E-mail: [email protected]
# YouTube channel: https://www.youtube.com/channel/UCz_ktTqWVekT0P4zVW8Xgcg
# YouTube channel e-mail: [email protected]
#
# Code modification and distribution of any kind is not allowed without direct
# permission of the Author.
#*******************************************************************************

CONFIG += c++11
QT += quick gui quickcontrols2

# The following define makes your compiler emit warnings if you use
# any Qt feature that has been marked deprecated (the exact warnings
Expand Down
5 changes: 5 additions & 0 deletions qml/Frequency.qml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
//
// Author: Leonid Golouz
// E-mail: [email protected]
// YouTube channel: https://www.youtube.com/channel/UCz_ktTqWVekT0P4zVW8Xgcg
// YouTube channel e-mail: [email protected]
//
// Code modification and distribution of any kind is not allowed without direct
// permission of the Author.
//*******************************************************************************

import QtQuick 2.3
Expand Down
5 changes: 5 additions & 0 deletions qml/GoToAddress.qml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
//
// Author: Leonid Golouz
// E-mail: [email protected]
// YouTube channel: https://www.youtube.com/channel/UCz_ktTqWVekT0P4zVW8Xgcg
// YouTube channel e-mail: [email protected]
//
// Code modification and distribution of any kind is not allowed without direct
// permission of the Author.
//*******************************************************************************

import QtQuick 2.3
Expand Down
5 changes: 5 additions & 0 deletions qml/ParserSettings.qml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
//
// Author: Leonid Golouz
// E-mail: [email protected]
// YouTube channel: https://www.youtube.com/channel/UCz_ktTqWVekT0P4zVW8Xgcg
// YouTube channel e-mail: [email protected]
//
// Code modification and distribution of any kind is not allowed without direct
// permission of the Author.
//*******************************************************************************

import QtQuick 2.3
Expand Down
5 changes: 5 additions & 0 deletions qml/main.qml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
//
// Author: Leonid Golouz
// E-mail: [email protected]
// YouTube channel: https://www.youtube.com/channel/UCz_ktTqWVekT0P4zVW8Xgcg
// YouTube channel e-mail: [email protected]
//
// Code modification and distribution of any kind is not allowed without direct
// permission of the Author.
//*******************************************************************************

import QtQuick 2.15
Expand Down
5 changes: 5 additions & 0 deletions sources/controls/waveformcontrol.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
//
// Author: Leonid Golouz
// E-mail: [email protected]
// YouTube channel: https://www.youtube.com/channel/UCz_ktTqWVekT0P4zVW8Xgcg
// YouTube channel e-mail: [email protected]
//
// Code modification and distribution of any kind is not allowed without direct
// permission of the Author.
//*******************************************************************************

#include "waveformcontrol.h"
Expand Down
5 changes: 5 additions & 0 deletions sources/controls/waveformcontrol.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
//
// Author: Leonid Golouz
// E-mail: [email protected]
// YouTube channel: https://www.youtube.com/channel/UCz_ktTqWVekT0P4zVW8Xgcg
// YouTube channel e-mail: [email protected]
//
// Code modification and distribution of any kind is not allowed without direct
// permission of the Author.
//*******************************************************************************

#ifndef WAVEFORMCONTROL_H
Expand Down
17 changes: 16 additions & 1 deletion sources/core/waveformparser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,19 @@
//
// Author: Leonid Golouz
// E-mail: [email protected]
// YouTube channel: https://www.youtube.com/channel/UCz_ktTqWVekT0P4zVW8Xgcg
// YouTube channel e-mail: [email protected]
//
// Code modification and distribution of any kind is not allowed without direct
// permission of the Author.
//*******************************************************************************

#include "waveformparser.h"
#include "sources/models/parsersettingsmodel.h"
#include <QDebug>
#include <QDateTime>
#include <QByteArray>
#include <algorithm>

WaveformParser::WaveformParser(QObject* parent) :
QObject(parent),
Expand Down Expand Up @@ -330,7 +336,16 @@ QVariantList WaveformParser::getParsedChannelData(uint chNum) const
m.insert("blockSize", sizeText);
QString nameText;
if (blockType >= 0) {
for (auto idx = 2; idx < std::min(12, i.data.size()); ++idx) {
const auto loopRange { std::min(
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
(int)
#else
(qsizetype)
#endif
12, i.data.size())
};

for (auto idx = 2; idx < loopRange; ++idx) {
nameText += QChar(i.data.at(idx));
}
}
Expand Down
5 changes: 5 additions & 0 deletions sources/core/waveformparser.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
//
// Author: Leonid Golouz
// E-mail: [email protected]
// YouTube channel: https://www.youtube.com/channel/UCz_ktTqWVekT0P4zVW8Xgcg
// YouTube channel e-mail: [email protected]
//
// Code modification and distribution of any kind is not allowed without direct
// permission of the Author.
//*******************************************************************************

#ifndef WAVEFORMPARSER_H
Expand Down
5 changes: 5 additions & 0 deletions sources/core/wavreader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
//
// Author: Leonid Golouz
// E-mail: [email protected]
// YouTube channel: https://www.youtube.com/channel/UCz_ktTqWVekT0P4zVW8Xgcg
// YouTube channel e-mail: [email protected]
//
// Code modification and distribution of any kind is not allowed without direct
// permission of the Author.
//*******************************************************************************

#include "wavreader.h"
Expand Down
5 changes: 5 additions & 0 deletions sources/core/wavreader.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
//
// Author: Leonid Golouz
// E-mail: [email protected]
// YouTube channel: https://www.youtube.com/channel/UCz_ktTqWVekT0P4zVW8Xgcg
// YouTube channel e-mail: [email protected]
//
// Code modification and distribution of any kind is not allowed without direct
// permission of the Author.
//*******************************************************************************

#ifndef WAVREADER_H
Expand Down
13 changes: 13 additions & 0 deletions sources/defines.h
Original file line number Diff line number Diff line change
@@ -1,3 +1,16 @@
//*******************************************************************************
// ZX Tape Reviver
//-----------------
//
// Author: Leonid Golouz
// E-mail: [email protected]
// YouTube channel: https://www.youtube.com/channel/UCz_ktTqWVekT0P4zVW8Xgcg
// YouTube channel e-mail: [email protected]
//
// Code modification and distribution of any kind is not allowed without direct
// permission of the Author.
//*******************************************************************************

#ifndef DEFINES_H
#define DEFINES_H

Expand Down
5 changes: 5 additions & 0 deletions sources/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
//
// Author: Leonid Golouz
// E-mail: [email protected]
// YouTube channel: https://www.youtube.com/channel/UCz_ktTqWVekT0P4zVW8Xgcg
// YouTube channel e-mail: [email protected]
//
// Code modification and distribution of any kind is not allowed without direct
// permission of the Author.
//*******************************************************************************

#include <QGuiApplication>
Expand Down
5 changes: 5 additions & 0 deletions sources/models/fileworkermodel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
//
// Author: Leonid Golouz
// E-mail: [email protected]
// YouTube channel: https://www.youtube.com/channel/UCz_ktTqWVekT0P4zVW8Xgcg
// YouTube channel e-mail: [email protected]
//
// Code modification and distribution of any kind is not allowed without direct
// permission of the Author.
//*******************************************************************************

#include "fileworkermodel.h"
Expand Down
5 changes: 5 additions & 0 deletions sources/models/fileworkermodel.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
//
// Author: Leonid Golouz
// E-mail: [email protected]
// YouTube channel: https://www.youtube.com/channel/UCz_ktTqWVekT0P4zVW8Xgcg
// YouTube channel e-mail: [email protected]
//
// Code modification and distribution of any kind is not allowed without direct
// permission of the Author.
//*******************************************************************************

#ifndef FILEWORKERMODEL_H
Expand Down
5 changes: 5 additions & 0 deletions sources/models/parsersettingsmodel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
//
// Author: Leonid Golouz
// E-mail: [email protected]
// YouTube channel: https://www.youtube.com/channel/UCz_ktTqWVekT0P4zVW8Xgcg
// YouTube channel e-mail: [email protected]
//
// Code modification and distribution of any kind is not allowed without direct
// permission of the Author.
//*******************************************************************************

#include "parsersettingsmodel.h"
Expand Down
5 changes: 5 additions & 0 deletions sources/models/parsersettingsmodel.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
//
// Author: Leonid Golouz
// E-mail: [email protected]
// YouTube channel: https://www.youtube.com/channel/UCz_ktTqWVekT0P4zVW8Xgcg
// YouTube channel e-mail: [email protected]
//
// Code modification and distribution of any kind is not allowed without direct
// permission of the Author.
//*******************************************************************************

#ifndef PARSERSETTINGSMODEL_H
Expand Down
5 changes: 5 additions & 0 deletions sources/models/suspiciouspointsmodel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
//
// Author: Leonid Golouz
// E-mail: [email protected]
// YouTube channel: https://www.youtube.com/channel/UCz_ktTqWVekT0P4zVW8Xgcg
// YouTube channel e-mail: [email protected]
//
// Code modification and distribution of any kind is not allowed without direct
// permission of the Author.
//*******************************************************************************

#include "suspiciouspointsmodel.h"
Expand Down
5 changes: 5 additions & 0 deletions sources/models/suspiciouspointsmodel.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
//
// Author: Leonid Golouz
// E-mail: [email protected]
// YouTube channel: https://www.youtube.com/channel/UCz_ktTqWVekT0P4zVW8Xgcg
// YouTube channel e-mail: [email protected]
//
// Code modification and distribution of any kind is not allowed without direct
// permission of the Author.
//*******************************************************************************

#ifndef SUSPICIOUSPOINTSMODEL_H
Expand Down

0 comments on commit 2f2ac53

Please sign in to comment.