add last backwards-compatible version

This commit is contained in:
2021-12-14 00:33:46 -07:00
parent 68b10d413b
commit b0dd3f07f3
335 changed files with 4746 additions and 19627 deletions

View File

@@ -29,10 +29,7 @@ namespace fb2k {
}
namespace pfc {
/*
Redirect PFC methods to shared.dll
If you're getting linker multiple-definition errors on these, change build configuration of PFC from "Debug" / "Release" to "Debug FB2K" / "Release FB2K"
*/
// Redirect PFC methods to shared.dll
BOOL winFormatSystemErrorMessageHook(pfc::string_base & p_out, DWORD p_code) {
return uFormatSystemErrorMessage(p_out, p_code);
}
@@ -40,38 +37,3 @@ namespace pfc {
uBugCheck();
}
}
// file_lock_manager.h functionality
#include "file_lock_manager.h"
namespace {
class file_lock_interrupt_impl : public file_lock_interrupt {
public:
void interrupt( abort_callback & a ) { f(a); }
std::function<void (abort_callback&)> f;
};
}
file_lock_interrupt::ptr file_lock_interrupt::create( std::function< void (abort_callback&)> f ) {
service_ptr_t<file_lock_interrupt_impl> i = new service_impl_t<file_lock_interrupt_impl>();
i->f = f;
return i;
}
// file_info_filter.h functionality
#include "file_info_filter.h"
namespace {
class file_info_filter_lambda : public file_info_filter {
public:
bool apply_filter(trackRef p_track,t_filestats p_stats,file_info & p_info) override {
return f(p_track, p_stats, p_info);
}
func_t f;
};
}
file_info_filter::ptr file_info_filter::create(func_t f) {
auto o = fb2k::service_new<file_info_filter_lambda>();
o->f = f;
return o;
}