mirror of
https://github.com/eried/portapack-mayhem.git
synced 2025-05-12 11:42:13 -04:00
Move CaptureThread::static_fn into .cpp.
This commit is contained in:
parent
264c19b312
commit
003ce4990d
2 changed files with 14 additions and 12 deletions
|
@ -109,6 +109,19 @@ void CaptureThread::check_fifo_isr() {
|
|||
}
|
||||
}
|
||||
|
||||
msg_t CaptureThread::static_fn(void* arg) {
|
||||
auto obj = static_cast<CaptureThread*>(arg);
|
||||
const auto error = obj->run();
|
||||
if( error.is_valid() && obj->error_callback ) {
|
||||
obj->error_callback(error.value());
|
||||
} else {
|
||||
if( obj->success_callback ) {
|
||||
obj->success_callback();
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
Optional<File::Error> CaptureThread::run() {
|
||||
StreamOutput stream { &config };
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue