1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2024-11-26 09:48:45 -05:00

Deep redesign: removed inheritance depedency between bladeRF serializer and sample source serializer

This commit is contained in:
f4exb 2015-08-28 03:26:57 +02:00
parent 77fed9a1c7
commit beadd4d861
3 changed files with 4 additions and 3 deletions

View File

@ -39,6 +39,7 @@ public:
static const QByteArray& writeSerializedData(const Data& data); static const QByteArray& writeSerializedData(const Data& data);
static bool readSerializedData(const QByteArray& serializedData, Data& data); static bool readSerializedData(const QByteArray& serializedData, Data& data);
static void setDefaults(Data& data); static void setDefaults(Data& data);
static uint getSerializerVersion() { return m_version; }
protected: protected:
static const uint m_version; static const uint m_version;

View File

@ -45,7 +45,7 @@ bool BladeRFSerializer::readSerializedData(const QByteArray& serializedData, Bla
return false; return false;
} }
if (d.getVersion() == m_version) if (d.getVersion() == SampleSourceSerializer::getSerializerVersion())
{ {
int intval; int intval;

View File

@ -19,12 +19,12 @@
#include "util/samplesourceserializer.h" #include "util/samplesourceserializer.h"
class BladeRFSerializer : public SampleSourceSerializer class BladeRFSerializer
{ {
public: public:
struct BladeRFData struct BladeRFData
{ {
Data m_data; SampleSourceSerializer::Data m_data;
bool m_xb200; bool m_xb200;
quint32 m_xb200Path; quint32 m_xb200Path;
quint32 m_xb200Filter; quint32 m_xb200Filter;