Skip to content
This repository
Browse code

Merge pull request #1923 from nemphys/pvr-channels-userset

pvr: new advanced setting that allows marking channel icons populated by auto scan as "user-set"
  • Loading branch information...
commit aea12804a033163aa54e85d4d6bbf30fda94a6d9 2 parents 7899597 + 63c6186
Lars Op den Kamp authored December 12, 2012
3  xbmc/pvr/channels/PVRChannelGroup.cpp
@@ -24,6 +24,7 @@
24 24
  */
25 25
 
26 26
 #include "settings/GUISettings.h"
  27
+#include "settings/AdvancedSettings.h"
27 28
 #include "guilib/GUIWindowManager.h"
28 29
 #include "dialogs/GUIDialogYesNo.h"
29 30
 #include "dialogs/GUIDialogOK.h"
@@ -222,7 +223,7 @@ bool CPVRChannelGroup::SetChannelIconPath(CPVRChannelPtr channel, const std::str
222 223
 {
223 224
   if (CFile::Exists(strIconPath))
224 225
   {
225  
-    channel->SetIconPath(strIconPath);
  226
+    channel->SetIconPath(strIconPath, g_advancedSettings.m_bPVRAutoScanIconsUserSet);
226 227
     return true;
227 228
   }
228 229
   return false;
2  xbmc/settings/AdvancedSettings.cpp
@@ -296,6 +296,7 @@ void CAdvancedSettings::Initialize()
296 296
   m_iPVRMinAudioCacheLevel         = 10;
297 297
   m_bPVRCacheInDvdPlayer           = true;
298 298
   m_bPVRChannelIconsAutoScan       = true;
  299
+  m_bPVRAutoScanIconsUserSet       = false;
299 300
 
300 301
   m_measureRefreshrate = false;
301 302
 
@@ -984,6 +985,7 @@ void CAdvancedSettings::ParseSettingsFile(const CStdString &file)
984 985
     XMLUtils::GetInt(pPVR, "minaudiocachelevel", m_iPVRMinAudioCacheLevel, 0, 100);
985 986
     XMLUtils::GetBoolean(pPVR, "cacheindvdplayer", m_bPVRCacheInDvdPlayer);
986 987
     XMLUtils::GetBoolean(pPVR, "channeliconsautoscan", m_bPVRChannelIconsAutoScan);
  988
+    XMLUtils::GetBoolean(pPVR, "autoscaniconsuserset", m_bPVRAutoScanIconsUserSet);
987 989
   }
988 990
 
989 991
   XMLUtils::GetBoolean(pRootElement, "measurerefreshrate", m_measureRefreshrate);
1  xbmc/settings/AdvancedSettings.h
@@ -336,6 +336,7 @@ class CAdvancedSettings
336 336
     int m_iPVRMinAudioCacheLevel;      /*!< @brief cache up to this level in the audio buffer before resuming playback if the buffers run dry */
337 337
     bool m_bPVRCacheInDvdPlayer; /*!< @brief true to use "CACHESTATE_PVR" in CDVDPlayer (default) */
338 338
     bool m_bPVRChannelIconsAutoScan; /*!< @brief automatically scan user defined folder for channel icons when loading internal channel groups */
  339
+    bool m_bPVRAutoScanIconsUserSet; /*!< @brief mark channel icons populated by auto scan as "user set" */
339 340
 
340 341
     bool m_measureRefreshrate; //when true the videoreferenceclock will measure the refreshrate when direct3d is used
341 342
                                //otherwise it will use the windows refreshrate

0 notes on commit aea1280

Please sign in to comment.
Something went wrong with that request. Please try again.