mirror of
				https://github.com/DigitalDevices/pvr.octonet.git
				synced 2025-03-01 10:53:09 +00:00 
			
		
		
		
	OctonetData: Add getter for channel name
This commit is contained in:
		@@ -286,6 +286,16 @@ const std::string& OctonetData::getUrl(int id) const {
 | 
				
			|||||||
	return channels[0].url;
 | 
						return channels[0].url;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					const std::string& OctonetData::getName(int id) const {
 | 
				
			||||||
 | 
						for(std::vector<OctonetChannel>::const_iterator iter = channels.begin(); iter != channels.end(); ++iter) {
 | 
				
			||||||
 | 
							if(iter->id == id) {
 | 
				
			||||||
 | 
								return iter->name;
 | 
				
			||||||
 | 
							}
 | 
				
			||||||
 | 
						}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						return channels[0].name;
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
int OctonetData::getGroupCount(void)
 | 
					int OctonetData::getGroupCount(void)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
	return groups.size();
 | 
						return groups.size();
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -71,6 +71,7 @@ class OctonetData : public P8PLATFORM::CThread
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
		virtual PVR_ERROR getEPG(ADDON_HANDLE handle, const PVR_CHANNEL &channel, time_t start, time_t end);
 | 
							virtual PVR_ERROR getEPG(ADDON_HANDLE handle, const PVR_CHANNEL &channel, time_t start, time_t end);
 | 
				
			||||||
		const std::string& getUrl(int id) const;
 | 
							const std::string& getUrl(int id) const;
 | 
				
			||||||
 | 
							const std::string& getName(int id) const;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	protected:
 | 
						protected:
 | 
				
			||||||
		virtual bool loadChannelList(void);
 | 
							virtual bool loadChannelList(void);
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user