forked from dolphin-emu/dolphin
		
	Should be faster than relying on the OS to cache the magic words. Also gets rid of the odd recursive call in VolumeDirectory.
		
			
				
	
	
		
			29 lines
		
	
	
		
			630 B
		
	
	
	
		
			C++
		
	
	
	
	
	
			
		
		
	
	
			29 lines
		
	
	
		
			630 B
		
	
	
	
		
			C++
		
	
	
	
	
	
// Copyright 2013 Dolphin Emulator Project
 | 
						|
// Licensed under GPLv2
 | 
						|
// Refer to the license.txt file included.
 | 
						|
 | 
						|
#include <cstddef>
 | 
						|
 | 
						|
#include "DiscIO/BannerLoader.h"
 | 
						|
#include "DiscIO/BannerLoaderGC.h"
 | 
						|
#include "DiscIO/BannerLoaderWii.h"
 | 
						|
#include "DiscIO/Filesystem.h"
 | 
						|
 | 
						|
namespace DiscIO
 | 
						|
{
 | 
						|
 | 
						|
class IBannerLoader;
 | 
						|
class IVolume;
 | 
						|
 | 
						|
IBannerLoader* CreateBannerLoader(DiscIO::IFileSystem& _rFileSystem, DiscIO::IVolume *pVolume)
 | 
						|
{
 | 
						|
	if (pVolume->IsWiiDisc() || pVolume->IsWadFile())
 | 
						|
		return new CBannerLoaderWii(pVolume);
 | 
						|
	if (_rFileSystem.IsValid())
 | 
						|
		return new CBannerLoaderGC(_rFileSystem, pVolume);
 | 
						|
 | 
						|
	return nullptr;
 | 
						|
}
 | 
						|
 | 
						|
} // namespace
 |