* renamed SoundRecorder.canCapture to isAvailable
* some internal fixes/changes git-svn-id: https://sfml.svn.sourceforge.net/svnroot/sfml/branches/sfml2@1352 4e206d99-4929-0410-ac5d-dfc041789085
This commit is contained in:
parent
8a848e3175
commit
9f1354b2a9
6 changed files with 74 additions and 70 deletions
|
@ -46,6 +46,30 @@ string loadFromSharedLib(string fname)
|
|||
return fname ~ " = " ~ "cast(typeof(" ~ fname ~ ")) dll.getSymbol(\"" ~ fname ~ "\");";
|
||||
}
|
||||
|
||||
//used to mixin code function
|
||||
string loadFromSharedLib2(S...)(string lib, S fnames)
|
||||
{
|
||||
string res = `static this()
|
||||
{
|
||||
debug
|
||||
DllLoader dll = DllLoader.load("` ~ lib ~ `-d");
|
||||
else
|
||||
DllLoader dll = DllLoader.load("` ~ lib ~ `");
|
||||
|
||||
`;
|
||||
|
||||
foreach(fname; fnames)
|
||||
{
|
||||
res ~= "\t" ~ fname ~ " = " ~ "cast(typeof(" ~ fname ~ ")) dll.getSymbol(\"" ~ fname ~ "\");\n";
|
||||
}
|
||||
return res ~ "}\n";
|
||||
}
|
||||
|
||||
string loadDerivedFromSharedLib(string base, string fname, string derived)
|
||||
{
|
||||
return base ~ "_" ~ fname ~ " = " ~ "cast(typeof(" ~ base ~ "_" ~ fname ~ ")) dll.getSymbol(\"" ~ derived ~ "_" ~ fname ~ "\");";
|
||||
}
|
||||
|
||||
/**
|
||||
* Base class for all DSFML classes.
|
||||
*/
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue