Skip to content

Commit

Permalink
tidy: Use boolean literals.
Browse files Browse the repository at this point in the history
Replace instances of 1/0 being cast to a boolean with the literals
true/false.

https://clang.llvm.org/extra/clang-tidy/checks/modernize-use-bool-literals.html
  • Loading branch information
linuxdude42 committed Dec 23, 2019
1 parent 8b345c5 commit cd3108a
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions mythtv/libs/libmythbase/mythcorecontext.h
Expand Up @@ -161,13 +161,13 @@ class MBASE_PUBLIC MythCoreContext : public QObject, public MythObservable, publ
QString GetSettingOnHost(const QString &key, const QString &host,
const QString &defaultval = "");
bool GetBoolSettingOnHost(const QString &key, const QString &host,
bool defaultval = 0);
bool defaultval = false);
int GetNumSettingOnHost(const QString &key, const QString &host,
int defaultval = 0);
int GetBoolSettingOnHost(const QString &key, const QString &host,
int defaultval) = delete;
bool GetNumSettingOnHost(const QString &key, const QString &host,
bool defaultval = 0) = delete;
bool defaultval = false) = delete;
double GetFloatSettingOnHost(const QString &key, const QString &host,
double defaultval = 0.0);

Expand Down
Expand Up @@ -125,7 +125,7 @@ class SERVICE_PUBLIC CaptureCard : public QObject
m_FirewireConnection(0), m_SignalTimeout(1000),
m_ChannelTimeout(3000), m_DVBTuningDelay(0),
m_Contrast(0), m_Brightness(0), m_Colour(0),
m_Hue(0), m_DiSEqCId(0), m_DVBEITScan(1),
m_Hue(0), m_DiSEqCId(0), m_DVBEITScan(true),
m_SourceId(0), m_DishnetEit(false), m_RecPriority(0),
m_QuickTune(false), m_SchedOrder(0), m_LiveTVOrder(0),
m_RecLimit(0), m_SchedGroup(false)
Expand Down
Expand Up @@ -107,7 +107,7 @@ class SERVICE_PUBLIC ChannelInfo : public QObject
m_FineTune ( 0 ),
m_SourceId ( 0 ),
m_InputId ( 0 ),
m_CommFree ( 0 ),
m_CommFree ( false ),
m_UseEIT ( false ),
m_Visible ( true ),
m_SerializeDetails( true )
Expand Down
2 changes: 1 addition & 1 deletion mythtv/libs/libmythtv/cc708window.h
Expand Up @@ -155,7 +155,7 @@ class CC708Pen
m_attr.m_edgeType = edge_type;
m_attr.m_underline = underline;
m_attr.m_italics = italics;
m_attr.m_boldface = 0;
m_attr.m_boldface = false;
}
public:
CC708CharacterAttribute m_attr;
Expand Down
2 changes: 1 addition & 1 deletion mythtv/libs/libmythtv/ringbuffer.h
Expand Up @@ -77,7 +77,7 @@ class MTV_PUBLIC RingBuffer : protected MThread
QString GetSubtitleFilename(void) const;
QString GetLastError(void) const;
bool GetCommsError(void) const { return m_commsError; }
void ResetCommsError(void) { m_commsError = 0; }
void ResetCommsError(void) { m_commsError = false; }

/// Returns value of stopreads
/// \sa StartReads(void), StopReads(void)
Expand Down

0 comments on commit cd3108a

Please sign in to comment.