* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
-#include "progress_bar.hxx"
+#include "ProgressBar.hxx"
#include <assert.h>
void
-progress_bar_paint(const struct progress_bar *p)
+progress_bar_paint(const ProgressBar *p)
{
assert(p != nullptr);
}
static bool
-progress_bar_calc(struct progress_bar *p)
+progress_bar_calc(ProgressBar *p)
{
if (p->max == 0)
return false;
}
void
-progress_bar_resize(struct progress_bar *p, unsigned width, int y, int x)
+progress_bar_resize(ProgressBar *p, unsigned width, int y, int x)
{
assert(p != nullptr);
}
bool
-progress_bar_set(struct progress_bar *p, unsigned current, unsigned max)
+progress_bar_set(ProgressBar *p, unsigned current, unsigned max)
{
assert(p != nullptr);
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
-#ifndef NCMPC_PROGRESS_BAR_H
-#define NCMPC_PROGRESS_BAR_H
+#ifndef NCMPC_PROGRESS_BAR_HXX
+#define NCMPC_PROGRESS_BAR_HXX
#include "window.hxx"
-struct progress_bar {
+struct ProgressBar {
struct window window;
unsigned current, max;
};
static inline void
-progress_bar_init(struct progress_bar *p, unsigned width, int y, int x)
+progress_bar_init(ProgressBar *p, unsigned width, int y, int x)
{
window_init(&p->window, 1, width, y, x);
leaveok(p->window.w, true);
}
static inline void
-progress_bar_deinit(struct progress_bar *p)
+progress_bar_deinit(ProgressBar *p)
{
delwin(p->window.w);
}
void
-progress_bar_paint(const struct progress_bar *p);
+progress_bar_paint(const ProgressBar *p);
void
-progress_bar_resize(struct progress_bar *p, unsigned width, int y, int x);
+progress_bar_resize(ProgressBar *p, unsigned width, int y, int x);
bool
-progress_bar_set(struct progress_bar *p, unsigned current, unsigned max);
+progress_bar_set(ProgressBar *p, unsigned current, unsigned max);
#endif
#include "command.hxx"
#include "window.hxx"
#include "TitleBar.hxx"
-#include "progress_bar.hxx"
+#include "ProgressBar.hxx"
#include "StatusBar.hxx"
#include "ncmpc_curses.h"
public:
TitleBar title_bar;
struct window main_window;
- struct progress_bar progress_bar;
+ ProgressBar progress_bar;
StatusBar status_bar;
using PageMap = std::map<const struct screen_functions *,