mirror of
https://github.com/rakshasa/rtorrent.git
synced 2026-08-12 21:22:31 +00:00
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@251 e378c898-3ddf-0310-93e7-cc216c733640
This commit is contained in:
@@ -1,27 +1,20 @@
|
||||
#include "config.h"
|
||||
|
||||
#include <torrent/torrent.h>
|
||||
|
||||
#include "canvas.h"
|
||||
#include "window_title.h"
|
||||
|
||||
namespace display {
|
||||
|
||||
WindowTitle::WindowTitle() :
|
||||
WindowTitle::WindowTitle(const std::string& s) :
|
||||
Window(new Canvas, false, 1),
|
||||
m_counter(0) {
|
||||
|
||||
m_title += "rtorrent " VERSION " - ";
|
||||
m_title += torrent::get(torrent::LIBRARY_NAME);
|
||||
m_title(s) {
|
||||
}
|
||||
|
||||
void
|
||||
WindowTitle::redraw() {
|
||||
m_counter++;
|
||||
|
||||
m_canvas->erase();
|
||||
m_canvas->print(std::max(0, (m_canvas->get_width() - (int)m_title.size()) / 2 - 4), 0,
|
||||
"*** %s *** %i", m_title.c_str(), m_counter);
|
||||
"*** %s ***", m_title.c_str());
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user