Permalink
Browse files

Merge pull request #1487 from alcoheca/rpc-scanstart

json-rpc: add new notification OnScanStarted for libraries
  • Loading branch information...
2 parents bcbd32c + 0a370b3 commit ef7f03ee93acdef40b34a8fafc92dc4895a6b6e9 @Montellese Montellese committed Oct 1, 2012
@@ -2915,6 +2915,15 @@ namespace JSONRPC
"],"
"\"returns\": null"
"}",
+ "\"AudioLibrary.OnScanStarted\": {"
+ "\"type\": \"notification\","
+ "\"description\": \"An audio library scan has started.\","
+ "\"params\": ["
+ "{ \"name\": \"sender\", \"type\": \"string\", \"required\": true },"
+ "{ \"name\": \"data\", \"type\": \"null\", \"required\": true }"
+ "],"
+ "\"returns\": null"
+ "}",
"\"AudioLibrary.OnScanFinished\": {"
"\"type\": \"notification\","
"\"description\": \"Scanning the audio library has been finished.\","
@@ -2953,6 +2962,15 @@ namespace JSONRPC
"],"
"\"returns\": null"
"}",
+ "\"VideoLibrary.OnScanStarted\": {"
+ "\"type\": \"notification\","
+ "\"description\": \"A video library scan has started.\","
+ "\"params\": ["
+ "{ \"name\": \"sender\", \"type\": \"string\", \"required\": true },"
+ "{ \"name\": \"data\", \"type\": \"null\", \"required\": true }"
+ "],"
+ "\"returns\": null"
+ "}",
"\"VideoLibrary.OnScanFinished\": {"
"\"type\": \"notification\","
"\"description\": \"Scanning the video library has been finished.\","
@@ -82,6 +82,15 @@
],
"returns": null
},
+ "AudioLibrary.OnScanStarted": {
+ "type": "notification",
+ "description": "An audio library scan has started.",
+ "params": [
+ { "name": "sender", "type": "string", "required": true },
+ { "name": "data", "type": "null", "required": true }
+ ],
+ "returns": null
+ },
"AudioLibrary.OnScanFinished": {
"type": "notification",
"description": "Scanning the audio library has been finished.",
@@ -120,6 +129,15 @@
],
"returns": null
},
+ "VideoLibrary.OnScanStarted": {
+ "type": "notification",
+ "description": "A video library scan has started.",
+ "params": [
+ { "name": "sender", "type": "string", "required": true },
+ { "name": "data", "type": "null", "required": true }
+ ],
+ "returns": null
+ },
"VideoLibrary.OnScanFinished": {
"type": "notification",
"description": "Scanning the video library has been finished.",
@@ -73,6 +73,7 @@ CMusicInfoScanner::~CMusicInfoScanner()
void CMusicInfoScanner::Process()
{
+ ANNOUNCEMENT::CAnnouncementManager::Announce(ANNOUNCEMENT::AudioLibrary, "xbmc", "OnScanStarted");
try
{
unsigned int tick = XbmcThreads::SystemClockMillis();
@@ -84,6 +84,7 @@ namespace VIDEO
m_bCanInterrupt = true;
CLog::Log(LOGNOTICE, "VideoInfoScanner: Starting scan ..");
+ ANNOUNCEMENT::CAnnouncementManager::Announce(ANNOUNCEMENT::VideoLibrary, "xbmc", "OnScanStarted");
// Reset progress vars
m_currentItem = 0;

0 comments on commit ef7f03e

Please sign in to comment.