use of com.frostwire.platform.DefaultFileSystem in project frostwire by frostwire.
the class AndroidPlatform method buildFileSystem.
private static FileSystem buildFileSystem(Application app) {
FileSystem fs;
if (Build.VERSION.SDK_INT >= VERSION_CODE_LOLLIPOP) {
LollipopFileSystem lfs = new LollipopFileSystem(app);
PosixCalls w = new PosixCalls(lfs);
w.swigReleaseOwnership();
libtorrent.set_posix_wrapper(w);
// LibTorrent.setPosixWrapper(new PosixCalls(lfs));
fs = lfs;
} else {
fs = new DefaultFileSystem() {
@Override
public void scan(File file) {
Librarian.instance().scan(app, file);
}
};
}
return fs;
}
Aggregations