From 17e84c01907f91452045e7a742a3963fb0f0c529 Mon Sep 17 00:00:00 2001 From: kevin Date: Tue, 25 Mar 2025 18:12:52 -0400 Subject: [PATCH] cwIo.h/cpp : Added is_started_flag(). --- cwIo.cpp | 9 +++++++++ cwIo.h | 2 ++ 2 files changed, 11 insertions(+) diff --git a/cwIo.cpp b/cwIo.cpp index b2e362d..e25dad1 100644 --- a/cwIo.cpp +++ b/cwIo.cpp @@ -2536,6 +2536,15 @@ cw::rc_t cw::io::stop( handle_t h ) return rc; } +bool cw::io::is_started_flag( handle_t h ) +{ + if( h.isValid() ) + { + io_t* p = _handleToPtr(h); + return p->startedFl.load(); + } + return false; +} cw::rc_t cw::io::exec( handle_t h, unsigned timeOutMs, void* execCbArg ) { diff --git a/cwIo.h b/cwIo.h index 9fb1106..9199cc5 100644 --- a/cwIo.h +++ b/cwIo.h @@ -163,10 +163,12 @@ namespace cw rc_t destroy( handle_t& h ); + rc_t start( handle_t h ); rc_t pause( handle_t h ); rc_t stop( handle_t h ); + bool is_started_flag( handle_t h ); // Note that this call blocks on the the UI websocket handle for up to 'timeOutMs'. // See ui:ws:exec().