Skip to content

Commit

Permalink
Merge pull request #1901 from nemphys/pvr-iconpath-scan
Browse files Browse the repository at this point in the history
pvr: new advanced setting that allows to turn of channel icon auto scan during internal channel groups loading
  • Loading branch information
Lars Op den Kamp committed Dec 10, 2012
2 parents 0eec821 + 1f5b852 commit 9375047
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 5 deletions.
2 changes: 1 addition & 1 deletion xbmc/epg/Epg.cpp
Expand Up @@ -465,7 +465,7 @@ bool CEpg::Update(const time_t start, const time_t end, int iUpdateTime, bool bF

/* enforce advanced settings update interval override for TV Channels with no EPG data */
if (m_tags.empty() && !bUpdate && ChannelID() > 0 && !Channel()->IsRadio())
iUpdateTime = g_advancedSettings.m_bEpgUpdateEmptyTagsInterval;
iUpdateTime = g_advancedSettings.m_iEpgUpdateEmptyTagsInterval;

if (!bForceUpdate)
{
Expand Down
5 changes: 4 additions & 1 deletion xbmc/pvr/channels/PVRChannelGroupInternal.cpp
Expand Up @@ -21,6 +21,7 @@
#include "PVRChannelGroupInternal.h"

#include "settings/GUISettings.h"
#include "settings/AdvancedSettings.h"
#include "guilib/GUIWindowManager.h"
#include "dialogs/GUIDialogYesNo.h"
#include "dialogs/GUIDialogOK.h"
Expand Down Expand Up @@ -330,7 +331,9 @@ bool CPVRChannelGroupInternal::UpdateGroupEntries(const CPVRChannelGroup &channe
if (CPVRChannelGroup::UpdateGroupEntries(channels))
{
/* try to find channel icons */
SearchAndSetChannelIcons();
if (g_advancedSettings.m_bPVRChannelIconsAutoScan)
SearchAndSetChannelIcons();

g_PVRTimers->UpdateChannels();
Persist();

Expand Down
6 changes: 4 additions & 2 deletions xbmc/settings/AdvancedSettings.cpp
Expand Up @@ -237,7 +237,7 @@ void CAdvancedSettings::Initialize()
m_iEpgCleanupInterval = 900; /* remove old entries from the EPG every 15 minutes */
m_iEpgActiveTagCheckInterval = 60; /* check for updated active tags every minute */
m_iEpgRetryInterruptedUpdateInterval = 30; /* retry an interrupted epg update after 30 seconds */
m_bEpgUpdateEmptyTagsInterval = 60; /* override user selectable EPG update interval for empty EPG tags */
m_iEpgUpdateEmptyTagsInterval = 60; /* override user selectable EPG update interval for empty EPG tags */
m_bEpgDisplayUpdatePopup = true; /* display a progress popup while updating EPG data from clients */
m_bEpgDisplayIncrementalUpdatePopup = false; /* also display a progress popup while doing incremental EPG updates */

Expand Down Expand Up @@ -295,6 +295,7 @@ void CAdvancedSettings::Initialize()
m_iPVRMinVideoCacheLevel = 5;
m_iPVRMinAudioCacheLevel = 10;
m_bPVRCacheInDvdPlayer = true;
m_bPVRChannelIconsAutoScan = true;

m_measureRefreshrate = false;

Expand Down Expand Up @@ -797,7 +798,7 @@ void CAdvancedSettings::ParseSettingsFile(const CStdString &file)
XMLUtils::GetInt(pElement, "cleanupinterval", m_iEpgCleanupInterval);
XMLUtils::GetInt(pElement, "activetagcheckinterval", m_iEpgActiveTagCheckInterval);
XMLUtils::GetInt(pElement, "retryinterruptedupdateinterval", m_iEpgRetryInterruptedUpdateInterval);
XMLUtils::GetInt(pElement, "updateemptytagsinterval", m_bEpgUpdateEmptyTagsInterval);
XMLUtils::GetInt(pElement, "updateemptytagsinterval", m_iEpgUpdateEmptyTagsInterval);
XMLUtils::GetBoolean(pElement, "displayupdatepopup", m_bEpgDisplayUpdatePopup);
XMLUtils::GetBoolean(pElement, "displayincrementalupdatepopup", m_bEpgDisplayIncrementalUpdatePopup);
}
Expand Down Expand Up @@ -982,6 +983,7 @@ void CAdvancedSettings::ParseSettingsFile(const CStdString &file)
XMLUtils::GetInt(pPVR, "minvideocachelevel", m_iPVRMinVideoCacheLevel, 0, 100);
XMLUtils::GetInt(pPVR, "minaudiocachelevel", m_iPVRMinAudioCacheLevel, 0, 100);
XMLUtils::GetBoolean(pPVR, "cacheindvdplayer", m_bPVRCacheInDvdPlayer);
XMLUtils::GetBoolean(pPVR, "channeliconsautoscan", m_bPVRChannelIconsAutoScan);
}

XMLUtils::GetBoolean(pRootElement, "measurerefreshrate", m_measureRefreshrate);
Expand Down
3 changes: 2 additions & 1 deletion xbmc/settings/AdvancedSettings.h
Expand Up @@ -276,7 +276,7 @@ class CAdvancedSettings
int m_iEpgCleanupInterval; // seconds
int m_iEpgActiveTagCheckInterval; // seconds
int m_iEpgRetryInterruptedUpdateInterval; // seconds
int m_bEpgUpdateEmptyTagsInterval; // seconds
int m_iEpgUpdateEmptyTagsInterval; // seconds
bool m_bEpgDisplayUpdatePopup;
bool m_bEpgDisplayIncrementalUpdatePopup;

Expand Down Expand Up @@ -335,6 +335,7 @@ class CAdvancedSettings
int m_iPVRMinVideoCacheLevel; /*!< @brief cache up to this level in the video buffer buffer before resuming playback if the buffers run dry */
int m_iPVRMinAudioCacheLevel; /*!< @brief cache up to this level in the audio buffer before resuming playback if the buffers run dry */
bool m_bPVRCacheInDvdPlayer; /*!< @brief true to use "CACHESTATE_PVR" in CDVDPlayer (default) */
bool m_bPVRChannelIconsAutoScan; /*!< @brief automatically scan user defined folder for channel icons when loading internal channel groups */

bool m_measureRefreshrate; //when true the videoreferenceclock will measure the refreshrate when direct3d is used
//otherwise it will use the windows refreshrate
Expand Down

0 comments on commit 9375047

Please sign in to comment.