mirror of
https://github.com/GoldenCheetah/GoldenCheetah.git
synced 2026-02-13 16:18:42 +00:00
Fix -Wdelete-non-virtual-dtor warnings
Base classes should have virtual destructors to ensure derived classes destructor is also virtual. This is not a major issue, since in all of the warning cases there is no base destructor, but its nice to shutup the compiler warnings.
This commit is contained in:
@@ -85,6 +85,7 @@ typedef QSharedPointer<Devices> DevicesPtr;
|
||||
|
||||
struct Devices
|
||||
{
|
||||
virtual ~Devices() {}
|
||||
virtual DevicePtr newDevice( CommPortPtr, Device::StatusCallback ) = 0;
|
||||
|
||||
// port *might* be supported by this device type implementation:
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
class ProtocolMessage {
|
||||
public:
|
||||
ProtocolMessage() { }
|
||||
~ProtocolMessage() { }
|
||||
virtual ~ProtocolMessage() { }
|
||||
|
||||
enum {
|
||||
HELLO, HELLOFAIL, HELLOSUCCEED, CLIENTLIST, CLIENT, TELEMETRY,
|
||||
|
||||
@@ -46,7 +46,7 @@ class RideFileCommand : public QObject
|
||||
|
||||
public:
|
||||
RideFileCommand(RideFile *ride);
|
||||
~RideFileCommand();
|
||||
virtual ~RideFileCommand();
|
||||
|
||||
void setPointValue(int index, RideFile::SeriesType series, double value);
|
||||
void deletePoint(int index);
|
||||
@@ -97,7 +97,9 @@ class RideCommand
|
||||
enum commandtype { NoOp, LUW, SetPointValue, DeletePoint, DeletePoints, InsertPoint, AppendPoints, SetDataPresent };
|
||||
typedef enum commandtype CommandType;
|
||||
|
||||
|
||||
RideCommand(RideFile *ride) : type(NoOp), ride(ride), docount(0) {}
|
||||
virtual ~RideCommand() {}
|
||||
virtual bool doCommand() { return true; }
|
||||
virtual bool undoCommand() { return true; }
|
||||
|
||||
|
||||
Reference in New Issue
Block a user