Skip to content

Commit ac3b1dd

Browse files
Override virtual functions explicitly
1 parent 601c5c3 commit ac3b1dd

147 files changed

Lines changed: 678 additions & 678 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

src/aac/aac.cc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,9 @@ class AACDecoder : public InputPlugin
2424
.with_exts (exts)
2525
.with_mimes (mimes)) {}
2626

27-
bool is_our_file (const char * filename, VFSFile & file);
28-
bool read_tag (const char * filename, VFSFile & file, Tuple & tuple, Index<char> * image);
29-
bool play (const char * filename, VFSFile & file);
27+
bool is_our_file (const char * filename, VFSFile & file) override;
28+
bool read_tag (const char * filename, VFSFile & file, Tuple & tuple, Index<char> * image) override;
29+
bool play (const char * filename, VFSFile & file) override;
3030
};
3131

3232
EXPORT AACDecoder aud_plugin_instance;

src/adplug/adplug-xmms.cc

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -75,12 +75,12 @@ class AdPlugXMMS : public InputPlugin
7575
.with_priority (_AUD_PLUGIN_DEFAULT_PRIO + 1) // prefer OpenMPT
7676
.with_exts (exts)) {}
7777

78-
bool init ();
79-
void cleanup ();
78+
bool init () override;
79+
void cleanup () override;
8080

81-
bool is_our_file (const char * filename, VFSFile & file);
82-
bool read_tag (const char * filename, VFSFile & file, Tuple & tuple, Index<char> * image);
83-
bool play (const char * filename, VFSFile & file);
81+
bool is_our_file (const char * filename, VFSFile & file) override;
82+
bool read_tag (const char * filename, VFSFile & file, Tuple & tuple, Index<char> * image) override;
83+
bool play (const char * filename, VFSFile & file) override;
8484
};
8585

8686
EXPORT AdPlugXMMS aud_plugin_instance;

src/adplug/adplug-xmms.h

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -41,22 +41,22 @@ class vfsistream : public binistream
4141
err |= NotFound;
4242
}
4343

44-
Byte getByte()
44+
Byte getByte() override
4545
{
4646
Byte b = (Byte)-1;
4747
if (fd->fread(&b, 1, 1) != 1)
4848
err |= Eof;
4949
return b;
5050
}
5151

52-
void seek(long pos, Offset offs = Set)
52+
void seek(long pos, Offset offs = Set) override
5353
{
5454
VFSSeekType wh = (offs == Add) ? VFS_SEEK_CUR : (offs == End) ? VFS_SEEK_END : VFS_SEEK_SET;
5555
if (fd->fseek (pos, wh))
5656
err |= Eof;
5757
}
5858

59-
long pos()
59+
long pos() override
6060
{
6161
return fd->ftell ();
6262
}
@@ -77,7 +77,7 @@ class CFileVFSProvider : public CFileProvider
7777
CFileVFSProvider(VFSFile &file) :
7878
m_file(file) {}
7979

80-
binistream *open(std::string filename) const
80+
binistream *open(std::string filename) const override
8181
{
8282
binistream *f;
8383

@@ -94,7 +94,7 @@ class CFileVFSProvider : public CFileProvider
9494
return f;
9595
}
9696

97-
void close(binistream *f) const
97+
void close(binistream *f) const override
9898
{
9999
delete f;
100100
}

src/albumart-qt/albumart.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ class AlbumArtQt : public GeneralPlugin {
4040
};
4141

4242
constexpr AlbumArtQt () : GeneralPlugin (info, false) {}
43-
void * get_qt_widget ();
43+
void * get_qt_widget () override;
4444
};
4545

4646
class ArtLabel : public QLabel {

src/albumart/albumart.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ class AlbumArtPlugin : public GeneralPlugin
3737

3838
constexpr AlbumArtPlugin () : GeneralPlugin (info, false) {}
3939

40-
void * get_gtk_widget ();
40+
void * get_gtk_widget () override;
4141
};
4242

4343
EXPORT AlbumArtPlugin aud_plugin_instance;

src/alsa/alsa.h

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -69,23 +69,23 @@ class ALSAPlugin : public OutputPlugin
6969

7070
constexpr ALSAPlugin () : OutputPlugin (info, 5) {}
7171

72-
bool init ();
73-
void cleanup ();
72+
bool init () override;
73+
void cleanup () override;
7474

75-
StereoVolume get_volume ();
76-
void set_volume (StereoVolume v);
75+
StereoVolume get_volume () override;
76+
void set_volume (StereoVolume v) override;
7777

78-
bool open_audio (int aud_format, int rate, int chans, String & error);
79-
void close_audio ();
78+
bool open_audio (int aud_format, int rate, int chans, String & error) override;
79+
void close_audio () override;
8080

81-
void period_wait ();
82-
int write_audio (const void * data, int size);
83-
void drain ();
81+
void period_wait () override;
82+
int write_audio (const void * data, int size) override;
83+
void drain () override;
8484

85-
int get_delay ();
85+
int get_delay () override;
8686

87-
void pause (bool pause);
88-
void flush ();
87+
void pause (bool pause) override;
88+
void flush () override;
8989

9090
private:
9191
static void open_mixer ();

src/amidiplug/amidi-plug.cc

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -49,15 +49,15 @@ class AMIDIPlug : public InputPlugin
4949
.with_exts (exts)
5050
.with_mimes (mimes)) {}
5151

52-
bool init ();
53-
void cleanup ();
52+
bool init () override;
53+
void cleanup () override;
5454

55-
bool is_our_file (const char * filename, VFSFile & file);
56-
bool read_tag (const char * filename, VFSFile & file, Tuple & tuple, Index<char> * image);
57-
bool play (const char * filename, VFSFile & file);
55+
bool is_our_file (const char * filename, VFSFile & file) override;
56+
bool read_tag (const char * filename, VFSFile & file, Tuple & tuple, Index<char> * image) override;
57+
bool play (const char * filename, VFSFile & file) override;
5858

5959
#ifdef USE_GTK
60-
bool file_info_box (const char * filename, VFSFile & file)
60+
bool file_info_box (const char * filename, VFSFile & file) override
6161
{ return i_fileinfo_gui (filename, file); }
6262
#endif
6363

src/amidiplug/i_configure-fluidsynth.cc

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -315,16 +315,16 @@ class SoundFontListModel : public QAbstractListModel
315315
~SoundFontListModel ();
316316

317317
protected:
318-
int rowCount (const QModelIndex & parent) const
318+
int rowCount (const QModelIndex & parent) const override
319319
{
320320
return parent.isValid() ? 0 : m_file_names.len();
321321
}
322322

323-
int columnCount (const QModelIndex &) const { return NColumns; }
324-
QVariant data (const QModelIndex & index, int role) const;
325-
QVariant headerData (int section, Qt::Orientation, int role) const;
323+
int columnCount (const QModelIndex &) const override { return NColumns; }
324+
QVariant data (const QModelIndex & index, int role) const override;
325+
QVariant headerData (int section, Qt::Orientation, int role) const override;
326326

327-
Qt::ItemFlags flags (const QModelIndex & index) const
327+
Qt::ItemFlags flags (const QModelIndex & index) const override
328328
{
329329
if (index.isValid ())
330330
return Qt::ItemIsSelectable | Qt::ItemIsDragEnabled | Qt::ItemIsEnabled;

src/aosd/aosd.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,8 @@ class AOSD : public GeneralPlugin
4444

4545
constexpr AOSD () : GeneralPlugin (info, false) {}
4646

47-
bool init ();
48-
void cleanup ();
47+
bool init () override;
48+
void cleanup () override;
4949
};
5050

5151
#endif /* !_I_AOSD_H */

src/asx/asx.cc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ class ASXLoader : public PlaylistPlugin
3535
constexpr ASXLoader () : PlaylistPlugin (info, asx_exts, false) {}
3636

3737
bool load (const char * filename, VFSFile & file, String & title,
38-
Index<PlaylistAddItem> & items);
38+
Index<PlaylistAddItem> & items) override;
3939
};
4040

4141
EXPORT ASXLoader aud_plugin_instance;
@@ -53,10 +53,10 @@ class ASXParser : public IniParser
5353
Index<PlaylistAddItem> & items;
5454
bool valid_heading;
5555

56-
void handle_heading (const char * heading)
56+
void handle_heading (const char * heading) override
5757
{ valid_heading = ! strcmp_nocase (heading, "reference"); }
5858

59-
void handle_entry (const char * key, const char * value)
59+
void handle_entry (const char * key, const char * value) override
6060
{
6161
if (! valid_heading || ! str_has_prefix_nocase (key, "ref"))
6262
return;

0 commit comments

Comments
 (0)