* UI refactoring, added display::Frame and started cleaning up the

code.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@747 e378c898-3ddf-0310-93e7-cc216c733640
This commit is contained in:
rakshasa
2006-07-26 21:41:09 +00:00
parent ef90f0f51e
commit fc76a11d71
41 changed files with 889 additions and 471 deletions
+13 -7
View File
@@ -60,26 +60,32 @@ ElementTrackerList::ElementTrackerList(core::Download* d) :
}
void
ElementTrackerList::activate(Control* c, MItr mItr) {
ElementTrackerList::activate(display::Frame* frame) {
if (m_window != NULL)
throw torrent::client_error("ui::ElementTrackerList::activate(...) called on an object in the wrong state");
throw torrent::client_error("ui::ElementTrackerList::activate(...) is_active().");
c->input()->push_front(&m_bindings);
control->input()->push_front(&m_bindings);
*mItr = m_window = new WTrackerList(m_download, &m_focus);
m_window = new WTrackerList(m_download, &m_focus);
m_frame = frame;
}
void
ElementTrackerList::disable(Control* c) {
ElementTrackerList::disable() {
if (m_window == NULL)
throw torrent::client_error("ui::ElementTrackerList::disable(...) called on an object in the wrong state");
throw torrent::client_error("ui::ElementTrackerList::disable(...) !is_active().");
c->input()->erase(&m_bindings);
control->input()->erase(&m_bindings);
delete m_window;
m_window = NULL;
}
display::Window*
ElementTrackerList::window() {
return m_window;
}
void
ElementTrackerList::receive_disable() {
if (m_window == NULL)