Skip to content

Commit

Permalink
Fix *MythSystem* names unrelated to MythSystem that got mistakenly re…
Browse files Browse the repository at this point in the history
…named in an earlier commit.

Conflicts:

	mythtv/programs/mythbackend/backendhousekeeper.cpp
	mythtv/programs/mythbackend/housekeeper.h
  • Loading branch information
daniel-kristjansson committed Jun 9, 2013
1 parent 3e30a16 commit 877663c
Show file tree
Hide file tree
Showing 15 changed files with 60 additions and 60 deletions.
2 changes: 1 addition & 1 deletion mythtv/libs/libmythbase/mythversion.h
Expand Up @@ -12,7 +12,7 @@
/// Update this whenever the plug-in ABI changes.
/// Including changes in the libmythbase, libmyth, libmythtv, libmythav* and
/// libmythui class methods in exported headers.
#define MYTH_BINARY_VERSION "0.27.20130609-1"
#define MYTH_BINARY_VERSION "0.27.20130609-2"

/** \brief Increment this whenever the MythTV network protocol changes.
*
Expand Down
2 changes: 1 addition & 1 deletion mythtv/libs/libmythtv/mythplayer.cpp
Expand Up @@ -2659,7 +2659,7 @@ void MythPlayer::JumpToProgram(void)
return;
}

SendMythSystemLegacyPlayEvent("PLAY_CHANGED", pginfo);
SendMythSystemPlayEvent("PLAY_CHANGED", pginfo);

if (player_ctx->buffer->GetType() == ICRingBuffer::kRingBufferType)
{
Expand Down
44 changes: 22 additions & 22 deletions mythtv/libs/libmythtv/mythsystemevent.cpp
Expand Up @@ -12,7 +12,7 @@
#include "exitcodes.h"
#include "mythlogging.h"

#define LOC QString("MythSystemLegacyEventHandler: ")
#define LOC QString("MythSystemEventHandler: ")

/** \class SystemEventThread
* \brief QRunnable class for running MythSystemLegacyEvent handler commands
Expand Down Expand Up @@ -69,28 +69,28 @@ class SystemEventThread : public QRunnable
};


/** \fn MythSystemLegacyEventHandler::MythSystemLegacyEventHandler(void)
/** \fn MythSystemEventHandler::MythSystemEventHandler(void)
* \brief Null Constructor
*
* Adds this object as a gContext event listener.
*/
MythSystemLegacyEventHandler::MythSystemLegacyEventHandler(void)
MythSystemEventHandler::MythSystemEventHandler(void)
{
setObjectName("MythSystemLegacyEventHandler");
setObjectName("MythSystemEventHandler");
gCoreContext->addListener(this);
}

/** \fn MythSystemLegacyEventHandler::~MythSystemLegacyEventHandler()
/** \fn MythSystemEventHandler::~MythSystemEventHandler()
* \brief Destructor
*
* Removes this object as a gContext event listener.
*/
MythSystemLegacyEventHandler::~MythSystemLegacyEventHandler()
MythSystemEventHandler::~MythSystemEventHandler()
{
gCoreContext->removeListener(this);
}

/** \fn MythSystemLegacyEventHandler::SubstituteMatches(const QStringList &tokens,
/** \fn MythSystemEventHandler::SubstituteMatches(const QStringList &tokens,
QString &command)
* \brief Substitutes %MATCH% variables in given command line.
* \sa ProgramInfo::SubstituteMatches(QString &str)
Expand All @@ -103,7 +103,7 @@ MythSystemLegacyEventHandler::~MythSystemLegacyEventHandler()
* \param tokens Const QStringList containing token list passed with event.
* \param command Command line containing %MATCH% variables to be substituted.
*/
void MythSystemLegacyEventHandler::SubstituteMatches(const QStringList &tokens,
void MythSystemEventHandler::SubstituteMatches(const QStringList &tokens,
QString &command)
{
if (command.isEmpty())
Expand Down Expand Up @@ -212,7 +212,7 @@ void MythSystemLegacyEventHandler::SubstituteMatches(const QStringList &tokens,
.arg(command));
}

/** \fn MythSystemLegacyEventHandler::EventNameToSetting(const QString &name)
/** \fn MythSystemEventHandler::EventNameToSetting(const QString &name)
* \brief Convert an MythSystemLegacyEvent name to a database setting name
*
* Converts an underscored, all-capital-letters system event name of the form
Expand All @@ -221,7 +221,7 @@ void MythSystemLegacyEventHandler::SubstituteMatches(const QStringList &tokens,
*
* \param name Const QString containing System Event name to convert
*/
QString MythSystemLegacyEventHandler::EventNameToSetting(const QString &name)
QString MythSystemEventHandler::EventNameToSetting(const QString &name)
{
QString result("EventCmd");
QStringList parts = name.toLower().split('_', QString::SkipEmptyParts);
Expand All @@ -238,11 +238,11 @@ QString MythSystemLegacyEventHandler::EventNameToSetting(const QString &name)
return result;
}

/** \fn MythSystemLegacyEventHandler::customEvent(QEvent *e)
/** \fn MythSystemEventHandler::customEvent(QEvent *e)
* \brief Custom Event handler for receiving and processing System Events
* \sa MythSystemLegacyEventHandler::SubstituteMatches(const QStringList &tokens,
* \sa MythSystemEventHandler::SubstituteMatches(const QStringList &tokens,
QString &command)
* MythSystemLegacyEventHandler::EventNameToSetting(const QString &name)
* MythSystemEventHandler::EventNameToSetting(const QString &name)
*
* This function listens for SYSTEM_EVENT messages and fires off any
* necessary event handler commands. In addition to SYSTEM_EVENT messages,
Expand All @@ -253,7 +253,7 @@ QString MythSystemLegacyEventHandler::EventNameToSetting(const QString &name)
*
* \param e Pointer to QEvent containing event to handle
*/
void MythSystemLegacyEventHandler::customEvent(QEvent *e)
void MythSystemEventHandler::customEvent(QEvent *e)
{
if ((MythEvent::Type)(e->type()) == MythEvent::MythEventMessage)
{
Expand Down Expand Up @@ -313,13 +313,13 @@ void MythSystemLegacyEventHandler::customEvent(QEvent *e)

/****************************************************************************/

/** \fn SendMythSystemLegacyRecEvent(const QString msg, const RecordingInfo *pginfo)
/** \fn SendMythSystemRecEvent(const QString msg, const RecordingInfo *pginfo)
* \brief Sends a System Event for an in-progress recording
* \sa MythCoreContext::SendSystemEvent(const QString msg)
* \param msg Const QString to send as a System Event
* \param pginfo Pointer to a RecordingInfo containing info on a recording
*/
void SendMythSystemLegacyRecEvent(const QString msg, const RecordingInfo *pginfo)
void SendMythSystemRecEvent(const QString msg, const RecordingInfo *pginfo)
{
if (pginfo)
{
Expand All @@ -333,17 +333,17 @@ void SendMythSystemLegacyRecEvent(const QString msg, const RecordingInfo *pginfo
else
{
LOG(VB_GENERAL, LOG_ERR, LOC +
"SendMythSystemLegacyRecEvent() called with empty RecordingInfo");
"SendMythSystemRecEvent() called with empty RecordingInfo");
}
}

/** \fn SendMythSystemLegacyPlayEvent(const QString msg, const ProgramInfo *pginfo)
/** \fn SendMythSystemPlayEvent(const QString msg, const ProgramInfo *pginfo)
* \brief Sends a System Event for a previously recorded program
* \sa MythCoreContext::SendSystemEvent(const QString msg)
* \param msg Const QString to send as a System Event
* \param pginfo Pointer to a RecordingInfo containing info on a recording
*/
void SendMythSystemLegacyPlayEvent(const QString msg, const ProgramInfo *pginfo)
void SendMythSystemPlayEvent(const QString msg, const ProgramInfo *pginfo)
{
if (pginfo)
gCoreContext->SendSystemEvent(
Expand All @@ -352,13 +352,13 @@ void SendMythSystemLegacyPlayEvent(const QString msg, const ProgramInfo *pginfo)
.arg(pginfo->GetChanID())
.arg(pginfo->GetRecordingStartTime(MythDate::ISODate)));
else
LOG(VB_GENERAL, LOG_ERR, LOC + "SendMythSystemLegacyPlayEvent() called with "
LOG(VB_GENERAL, LOG_ERR, LOC + "SendMythSystemPlayEvent() called with "
"empty ProgramInfo");
}

/****************************************************************************/

/** \fn MythSystemLegacyEventEditor::MythSystemLegacyEventEditor(MythScreenStack *parent,
/** \fn MythSystemEventEditor::MythSystemEventEditor(MythScreenStack *parent,
const char *name)
* \brief Constructor for the MythSystemLegacyEvent settings editor
*
Expand All @@ -369,7 +369,7 @@ void SendMythSystemLegacyPlayEvent(const QString msg, const ProgramInfo *pginfo)
* \param parent Parent screen stack for this window
* \param name Name of this window
*/
MythSystemLegacyEventEditor::MythSystemLegacyEventEditor(MythScreenStack *parent,
MythSystemEventEditor::MythSystemEventEditor(MythScreenStack *parent,
const char *name)
: RawSettingsEditor(parent, name)
{
Expand Down
20 changes: 10 additions & 10 deletions mythtv/libs/libmythtv/mythsystemevent.h
Expand Up @@ -9,28 +9,28 @@
#include "rawsettingseditor.h"

// Helper commands for formatting and sending a MythSystemLegacyEvent
MTV_PUBLIC void SendMythSystemLegacyRecEvent(const QString msg,
MTV_PUBLIC void SendMythSystemRecEvent(const QString msg,
const RecordingInfo *pginfo);
MTV_PUBLIC void SendMythSystemLegacyPlayEvent(const QString msg,
MTV_PUBLIC void SendMythSystemPlayEvent(const QString msg,
const ProgramInfo *pginfo);

/** \class MythSystemLegacyEventHandler
/** \class MythSystemEventHandler
* \brief Handles incoming MythSystemLegacyEvent messages
*
* MythSystemLegacyEventHandler handles incoming MythSystemLegacyEvent messages and runs
* MythSystemEventHandler handles incoming MythSystemLegacyEvent messages and runs
* the appropriate event handler command on the local system if one is
* configured.
*/
class MTV_PUBLIC MythSystemLegacyEventHandler : public QObject
class MTV_PUBLIC MythSystemEventHandler : public QObject
{
Q_OBJECT

public:
// Constructor
MythSystemLegacyEventHandler();
MythSystemEventHandler();

// Destructor
~MythSystemLegacyEventHandler();
~MythSystemEventHandler();

private:
// Helpers for converting incoming events to command lines
Expand All @@ -41,18 +41,18 @@ class MTV_PUBLIC MythSystemLegacyEventHandler : public QObject
void customEvent(QEvent *e);
};

/** \class MythSystemLegacyEventEditor
/** \class MythSystemEventEditor
* \brief An editor for MythSystemLegacyEvent handler commands
*
* This class extends RawSettingsEditor and automatically populates the
* settings list with the MythSystemLegacyEvent handler command settings names.
*/
class MTV_PUBLIC MythSystemLegacyEventEditor : public RawSettingsEditor
class MTV_PUBLIC MythSystemEventEditor : public RawSettingsEditor
{
Q_OBJECT

public:
MythSystemLegacyEventEditor(MythScreenStack *parent, const char *name = 0);
MythSystemEventEditor(MythScreenStack *parent, const char *name = 0);
};

#endif
Expand Down
14 changes: 7 additions & 7 deletions mythtv/libs/libmythtv/tv_play.cpp
Expand Up @@ -356,7 +356,7 @@ bool TV::StartTV(ProgramInfo *tvrec, uint flags)
if (curProgram)
{
startSysEventSent = true;
SendMythSystemLegacyPlayEvent("PLAY_STARTED", curProgram);
SendMythSystemPlayEvent("PLAY_STARTED", curProgram);
}

// Notify others that we are about to play
Expand All @@ -375,7 +375,7 @@ bool TV::StartTV(ProgramInfo *tvrec, uint flags)
else if (!startSysEventSent)
{
startSysEventSent = true;
SendMythSystemLegacyPlayEvent("PLAY_STARTED", curProgram);
SendMythSystemPlayEvent("PLAY_STARTED", curProgram);
}

LOG(VB_PLAYBACK, LOG_INFO, LOC + "tv->Playback() -- end");
Expand Down Expand Up @@ -429,7 +429,7 @@ bool TV::StartTV(ProgramInfo *tvrec, uint flags)

curProgram = nextProgram;

SendMythSystemLegacyPlayEvent("PLAY_CHANGED", curProgram);
SendMythSystemPlayEvent("PLAY_CHANGED", curProgram);
continue;
}

Expand Down Expand Up @@ -463,7 +463,7 @@ bool TV::StartTV(ProgramInfo *tvrec, uint flags)

if (curProgram)
{
SendMythSystemLegacyPlayEvent("PLAY_STOPPED", curProgram);
SendMythSystemPlayEvent("PLAY_STOPPED", curProgram);

if (deleterecording)
{
Expand Down Expand Up @@ -6063,7 +6063,7 @@ void TV::DoPlay(PlayerContext *ctx)
if (ctx->ff_rew_state)
time = StopFFRew(ctx);
else if (ctx->player->IsPaused())
SendMythSystemLegacyPlayEvent("PLAY_UNPAUSED", ctx->playingInfo);
SendMythSystemPlayEvent("PLAY_UNPAUSED", ctx->playingInfo);

ctx->player->Play(ctx->ts_normal, true);
gCoreContext->emitTVPlaybackUnpaused();
Expand Down Expand Up @@ -6185,9 +6185,9 @@ void TV::DoTogglePause(PlayerContext *ctx, bool showOSD)
ctx->UnlockDeletePlayer(__FILE__, __LINE__);

if (paused)
SendMythSystemLegacyPlayEvent("PLAY_UNPAUSED", ctx->playingInfo);
SendMythSystemPlayEvent("PLAY_UNPAUSED", ctx->playingInfo);
else
SendMythSystemLegacyPlayEvent("PLAY_PAUSED", ctx->playingInfo);
SendMythSystemPlayEvent("PLAY_PAUSED", ctx->playingInfo);

if (!ignore)
DoTogglePauseFinish(ctx, DoTogglePauseStart(ctx), showOSD);
Expand Down
6 changes: 3 additions & 3 deletions mythtv/libs/libmythtv/tv_rec.cpp
Expand Up @@ -804,7 +804,7 @@ void TVRec::StartedRecording(RecordingInfo *curRec)
kAutoRunNone : kAutoRunProfile;
InitAutoRunJobs(curRec, t, NULL, __LINE__);

SendMythSystemLegacyRecEvent("REC_STARTED", curRec);
SendMythSystemRecEvent("REC_STARTED", curRec);
}

/** \brief If not a premature stop, adds program to history of recorded
Expand Down Expand Up @@ -893,7 +893,7 @@ void TVRec::FinishedRecording(RecordingInfo *curRec, RecordingQuality *recq)
if (HasFlags(kFlagDummyRecorderRunning))
{
curRec->FinishedRecording(true); // so end time is updated
SendMythSystemLegacyRecEvent("REC_FINISHED", curRec);
SendMythSystemRecEvent("REC_FINISHED", curRec);
return;
}

Expand Down Expand Up @@ -939,7 +939,7 @@ void TVRec::FinishedRecording(RecordingInfo *curRec, RecordingQuality *recq)
}

// send out REC_FINISHED message
SendMythSystemLegacyRecEvent("REC_FINISHED", curRec);
SendMythSystemRecEvent("REC_FINISHED", curRec);

// send out DONE_RECORDING message
int secsSince = curRec->GetRecordingStartTime()
Expand Down
2 changes: 1 addition & 1 deletion mythtv/programs/mythbackend/main_helpers.cpp
Expand Up @@ -566,7 +566,7 @@ int run_backend(MythBackendCommandLineParser &cmdline)
return GENERIC_EXIT_SETUP_ERROR;
}

MythSystemLegacyEventHandler *sysEventHandler = new MythSystemLegacyEventHandler();
MythSystemEventHandler *sysEventHandler = new MythSystemEventHandler();

if (ismaster)
{
Expand Down
2 changes: 1 addition & 1 deletion mythtv/programs/mythbackend/mainserver.cpp
Expand Up @@ -1017,7 +1017,7 @@ void MainServer::customEvent(QEvent *e)

if (recInfo.GetChanID())
{
SendMythSystemLegacyPlayEvent("REC_EXPIRED", &recInfo);
SendMythSystemPlayEvent("REC_EXPIRED", &recInfo);

// allow re-record if auto expired but not expired live
// or already "deleted" programs
Expand Down
2 changes: 1 addition & 1 deletion mythtv/programs/mythbackend/scheduler.cpp
Expand Up @@ -2283,7 +2283,7 @@ void Scheduler::HandleWakeSlave(RecordingInfo &ri, int prerollseconds)
{
if (!pendingEventSent)
{
SendMythSystemLegacyRecEvent(
SendMythSystemRecEvent(
QString("REC_PENDING SECS %1").arg(secsleft), &ri);
}

Expand Down
4 changes: 2 additions & 2 deletions mythtv/programs/mythfrontend/main.cpp
Expand Up @@ -946,7 +946,7 @@ static void TVMenuCallback(void *data, QString &selection)
{
MythScreenStack *mainStack = GetMythMainWindow()->GetMainStack();

MythSystemLegacyEventEditor *msee = new MythSystemLegacyEventEditor(
MythSystemEventEditor *msee = new MythSystemEventEditor(
mainStack, "System Event Editor");

if (msee->Create())
Expand Down Expand Up @@ -1687,7 +1687,7 @@ int main(int argc, char **argv)
if (gCoreContext->GetNumSetting("ThemeUpdateNofications", 1))
themeUpdateChecker = new ThemeUpdateChecker();

MythSystemLegacyEventHandler *sysEventHandler = new MythSystemLegacyEventHandler();
MythSystemEventHandler *sysEventHandler = new MythSystemEventHandler();

BackendConnectionManager bcm;

Expand Down

0 comments on commit 877663c

Please sign in to comment.