This repository was archived by the owner on Jun 3, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +60
-0
lines changed Expand file tree Collapse file tree 1 file changed +60
-0
lines changed Original file line number Diff line number Diff line change @@ -182,6 +182,66 @@ namespace Activities
182182 return Log ();
183183 }
184184
185+ State Activity::state () const
186+ {
187+ if (d) {
188+ std::lock_guard<std::mutex> _ (d->mMtx );
189+ return d->mState ;
190+ }
191+
192+ return State::Unknown;
193+ }
194+
195+ QString Activity::display () const
196+ {
197+ if (d) {
198+ std::lock_guard<std::mutex> _ (d->mMtx );
199+ return d->mDisplay ;
200+ }
201+
202+ return {};
203+ }
204+
205+ int Activity::curProgress () const
206+ {
207+ if (d) {
208+ std::lock_guard<std::mutex> _ (d->mMtx );
209+ return d->mTotalCurProgress ;
210+ }
211+
212+ return 0 ;
213+ }
214+
215+ int Activity::maxProgress () const
216+ {
217+ if (d) {
218+ std::lock_guard<std::mutex> _ (d->mMtx );
219+ return d->mTotalMaxProgress ;
220+ }
221+
222+ return 0 ;
223+ }
224+
225+ int Activity::curOwnProgress () const
226+ {
227+ if (d) {
228+ std::lock_guard<std::mutex> _ (d->mMtx );
229+ return d->mCurProgress ;
230+ }
231+
232+ return 0 ;
233+ }
234+
235+ int Activity::maxOwnProgress () const
236+ {
237+ if (d) {
238+ std::lock_guard<std::mutex> _ (d->mMtx );
239+ return d->mMaxProgress ;
240+ }
241+
242+ return 0 ;
243+ }
244+
185245 Step Activity::createStep (const QString& displayName)
186246 {
187247 if (d) {
You can’t perform that action at this time.
0 commit comments