Added logging of some ui events.

This commit is contained in:
rakshasa
2013-11-06 23:23:20 +09:00
parent 67236d7757
commit 2e9baa1635
3 changed files with 29 additions and 4 deletions
+7
View File
@@ -55,6 +55,8 @@ ElementStringList::activate(display::Frame* frame, bool focus) {
if (is_active())
throw torrent::internal_error("ui::ElementStringList::activate(...) is_active().");
lt_log_print(torrent::LOG_UI_EVENTS, "element_string_list: activate");
control->input()->push_back(&m_bindings);
m_window = new WStringList();
@@ -69,6 +71,8 @@ ElementStringList::disable() {
if (!is_active())
throw torrent::internal_error("ui::ElementStringList::disable(...) !is_active().");
lt_log_print(torrent::LOG_UI_EVENTS, "element_string_list: deactivate");
control->input()->erase(&m_bindings);
m_frame->clear();
@@ -80,6 +84,9 @@ ElementStringList::disable() {
void
ElementStringList::next_screen() {
if (m_window == NULL)
return;
if (m_window->get_draw_end() != m_list.end())
m_window->set_range(m_window->get_draw_end(), m_list.end());
else