xbmc
xbmc
pvr
guilib
PVRGUIProgressHandler.h
1
/*
2
* Copyright (C) 2017-2018 Team Kodi
3
* This file is part of Kodi - https://kodi.tv
4
*
5
* SPDX-License-Identifier: GPL-2.0-or-later
6
* See LICENSES/README.md for more information.
7
*/
8
9
#pragma once
10
11
#include "threads/CriticalSection.h"
12
#include "threads/Thread.h"
13
14
#include <string>
15
16
namespace
PVR
17
{
18
class
CPVRGUIProgressHandler
:
private
CThread
19
{
20
public
:
21
CPVRGUIProgressHandler
() =
delete
;
22
27
explicit
CPVRGUIProgressHandler
(
const
std::string& strTitle);
28
29
~
CPVRGUIProgressHandler
()
override
=
default
;
30
36
void
UpdateProgress
(
const
std::string& strText,
float
fProgress);
37
44
void
UpdateProgress
(
const
std::string& strText,
int
iCurrent,
int
iMax);
45
46
protected
:
47
// CThread implementation
48
void
Process()
override
;
49
50
private
:
51
CCriticalSection m_critSection;
52
const
std::string m_strTitle;
53
std::string m_strText;
54
float
m_fProgress{0.0f};
55
bool
m_bChanged{
false
};
56
bool
m_bCreated{
false
};
57
};
58
59
}
// namespace PVR
CThread
Definition:
Thread.h:44
PVR
Definition:
ContextMenuManager.h:24
PVR::CPVRGUIProgressHandler::UpdateProgress
void UpdateProgress(const std::string &strText, float fProgress)
Update the progress dialogs's content.
Definition:
PVRGUIProgressHandler.cpp:32
PVR::CPVRGUIProgressHandler
Definition:
PVRGUIProgressHandler.h:18
Generated by
1.8.13