mirror of
https://github.com/rakshasa/rtorrent.git
synced 2026-10-07 14:49:21 +00:00
Removed deprecated rak header files.
This commit is contained in:
@@ -2,7 +2,6 @@
|
||||
|
||||
#include <cassert>
|
||||
|
||||
#include <rak/string_manip.h>
|
||||
#include <torrent/exceptions.h>
|
||||
#include <torrent/chunk_manager.h>
|
||||
#include <torrent/connection_manager.h>
|
||||
|
||||
+13
-17
@@ -1,35 +1,31 @@
|
||||
#include "config.h"
|
||||
|
||||
#include "ui/download_list.h"
|
||||
|
||||
#include <cassert>
|
||||
#include <sstream>
|
||||
|
||||
#include <rak/string_manip.h>
|
||||
#include <torrent/exceptions.h>
|
||||
#include <torrent/torrent.h>
|
||||
#include <torrent/utils/log.h>
|
||||
#include <torrent/utils/string_manip.h>
|
||||
|
||||
#include "control.h"
|
||||
#include "core/download.h"
|
||||
#include "core/download_list.h"
|
||||
#include "core/manager.h"
|
||||
#include "core/view.h"
|
||||
#include "core/view_manager.h"
|
||||
|
||||
#include "display/window_log.h"
|
||||
#include "display/window_title.h"
|
||||
#include "input/bindings.h"
|
||||
#include "input/manager.h"
|
||||
#include "input/path_input.h"
|
||||
|
||||
#include "display/window_log.h"
|
||||
#include "display/window_title.h"
|
||||
|
||||
#include "rpc/parse_commands.h"
|
||||
|
||||
#include "control.h"
|
||||
#include "download.h"
|
||||
#include "download_list.h"
|
||||
#include "element_download_list.h"
|
||||
#include "element_log_complete.h"
|
||||
#include "element_string_list.h"
|
||||
#include "root.h"
|
||||
#include "ui/download.h"
|
||||
#include "ui/element_download_list.h"
|
||||
#include "ui/element_log_complete.h"
|
||||
#include "ui/element_string_list.h"
|
||||
#include "ui/root.h"
|
||||
|
||||
namespace ui {
|
||||
|
||||
@@ -231,7 +227,7 @@ DownloadList::receive_view_input(Input type) {
|
||||
|
||||
while(ss.good()) {
|
||||
std::getline(ss, view_name_var, ',');
|
||||
if (current_view()->name() == rak::trim(view_name_var)) {
|
||||
if (current_view()->name() == torrent::utils::trim_spaces_str(view_name_var)) {
|
||||
control->core()->push_log_std("View '" + current_view()->name() + "' can't be filtered.");
|
||||
return;
|
||||
}
|
||||
@@ -304,7 +300,7 @@ DownloadList::receive_exit_input(Input type) {
|
||||
if ((*current_view()->focus())->is_open())
|
||||
throw torrent::input_error("Cannot change root directory on an open download.");
|
||||
|
||||
rpc::call_command("d.directory.set", rak::trim(input->str()), rpc::make_target(*current_view()->focus()));
|
||||
rpc::call_command("d.directory.set", torrent::utils::trim_spaces_str(input->str()), rpc::make_target(*current_view()->focus()));
|
||||
control->core()->push_log_std("New root directory \"" + rpc::call_command_string("d.directory", rpc::make_target(*current_view()->focus())) + "\" for torrent.");
|
||||
break;
|
||||
|
||||
|
||||
@@ -1,37 +1,3 @@
|
||||
// rTorrent - BitTorrent client
|
||||
// Copyright (C) 2005-2011, Jari Sundell
|
||||
//
|
||||
// This program is free software; you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License as published by
|
||||
// the Free Software Foundation; either version 2 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// This program is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public License
|
||||
// along with this program; if not, write to the Free Software
|
||||
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
//
|
||||
// In addition, as a special exception, the copyright holders give
|
||||
// permission to link the code of portions of this program with the
|
||||
// OpenSSL library under certain conditions as described in each
|
||||
// individual source file, and distribute linked combinations
|
||||
// including the two.
|
||||
//
|
||||
// You must obey the GNU General Public License in all respects for
|
||||
// all of the code used other than OpenSSL. If you modify file(s)
|
||||
// with this exception, you may extend this exception to your version
|
||||
// of the file(s), but you are not obligated to do so. If you do not
|
||||
// wish to do so, delete this exception statement from your version.
|
||||
// If you delete this exception statement from all source files in the
|
||||
// program, then also delete it here.
|
||||
//
|
||||
// Contact: Jari Sundell <sundell.software@gmail.com>
|
||||
|
||||
|
||||
#include "config.h"
|
||||
|
||||
#include <torrent/exceptions.h>
|
||||
|
||||
@@ -1,37 +1,3 @@
|
||||
// rTorrent - BitTorrent client
|
||||
// Copyright (C) 2005-2011, Jari Sundell
|
||||
//
|
||||
// This program is free software; you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License as published by
|
||||
// the Free Software Foundation; either version 2 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// This program is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public License
|
||||
// along with this program; if not, write to the Free Software
|
||||
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
//
|
||||
// In addition, as a special exception, the copyright holders give
|
||||
// permission to link the code of portions of this program with the
|
||||
// OpenSSL library under certain conditions as described in each
|
||||
// individual source file, and distribute linked combinations
|
||||
// including the two.
|
||||
//
|
||||
// You must obey the GNU General Public License in all respects for
|
||||
// all of the code used other than OpenSSL. If you modify file(s)
|
||||
// with this exception, you may extend this exception to your version
|
||||
// of the file(s), but you are not obligated to do so. If you do not
|
||||
// wish to do so, delete this exception statement from your version.
|
||||
// If you delete this exception statement from all source files in the
|
||||
// program, then also delete it here.
|
||||
//
|
||||
// Contact: Jari Sundell <sundell.software@gmail.com>
|
||||
|
||||
|
||||
#ifndef RTORRENT_UI_ELEMENT_BASE_H
|
||||
#define RTORRENT_UI_ELEMENT_BASE_H
|
||||
|
||||
|
||||
@@ -1,40 +1,5 @@
|
||||
// rTorrent - BitTorrent client
|
||||
// Copyright (C) 2005-2011, Jari Sundell
|
||||
//
|
||||
// This program is free software; you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License as published by
|
||||
// the Free Software Foundation; either version 2 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// This program is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public License
|
||||
// along with this program; if not, write to the Free Software
|
||||
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
//
|
||||
// In addition, as a special exception, the copyright holders give
|
||||
// permission to link the code of portions of this program with the
|
||||
// OpenSSL library under certain conditions as described in each
|
||||
// individual source file, and distribute linked combinations
|
||||
// including the two.
|
||||
//
|
||||
// You must obey the GNU General Public License in all respects for
|
||||
// all of the code used other than OpenSSL. If you modify file(s)
|
||||
// with this exception, you may extend this exception to your version
|
||||
// of the file(s), but you are not obligated to do so. If you do not
|
||||
// wish to do so, delete this exception statement from your version.
|
||||
// If you delete this exception statement from all source files in the
|
||||
// program, then also delete it here.
|
||||
//
|
||||
// Contact: Jari Sundell <sundell.software@gmail.com>
|
||||
|
||||
|
||||
#include "config.h"
|
||||
|
||||
#include <rak/algorithm.h>
|
||||
#include <torrent/exceptions.h>
|
||||
#include <torrent/data/file.h>
|
||||
#include <torrent/data/file_list.h>
|
||||
@@ -80,10 +45,10 @@ element_file_list_create_info() {
|
||||
|
||||
element->push_back("File info:");
|
||||
element->push_back("");
|
||||
|
||||
|
||||
element->push_column("Filename:", te_command("fi.filename_last="));
|
||||
element->push_back("");
|
||||
|
||||
|
||||
element->push_column("Size:", te_command("if=$fi.is_file=,$convert.xb=$f.size_bytes=,---"));
|
||||
element->push_column("Chunks:", te_command("cat=$f.completed_chunks=,\" / \",$f.size_chunks="));
|
||||
element->push_column("Range:", te_command("cat=$f.range_first=,\" - \",$f.range_second="));
|
||||
@@ -213,7 +178,7 @@ ElementFileList::receive_pagenext() {
|
||||
m_selected = iterator(fl->begin());
|
||||
|
||||
} else {
|
||||
m_selected = rak::advance_forward(m_selected, iterator(fl->end()), (m_window->height() - 1) / 2);
|
||||
m_selected = display::advance_forward(m_selected, iterator(fl->end()), (m_window->height() - 1) / 2);
|
||||
|
||||
if (m_selected == iterator(fl->end()))
|
||||
m_selected = --iterator(fl->end());
|
||||
@@ -232,7 +197,7 @@ ElementFileList::receive_pageprev() {
|
||||
if (m_selected == iterator(fl->begin()))
|
||||
m_selected = --iterator(fl->end());
|
||||
else
|
||||
m_selected = rak::advance_backward(m_selected, iterator(fl->begin()), (m_window->height() - 1) / 2);
|
||||
m_selected = display::advance_backward(m_selected, iterator(fl->begin()), (m_window->height() - 1) / 2);
|
||||
|
||||
update_itr();
|
||||
}
|
||||
|
||||
@@ -1,37 +1,3 @@
|
||||
// rTorrent - BitTorrent client
|
||||
// Copyright (C) 2005-2011, Jari Sundell
|
||||
//
|
||||
// This program is free software; you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License as published by
|
||||
// the Free Software Foundation; either version 2 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// This program is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public License
|
||||
// along with this program; if not, write to the Free Software
|
||||
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
//
|
||||
// In addition, as a special exception, the copyright holders give
|
||||
// permission to link the code of portions of this program with the
|
||||
// OpenSSL library under certain conditions as described in each
|
||||
// individual source file, and distribute linked combinations
|
||||
// including the two.
|
||||
//
|
||||
// You must obey the GNU General Public License in all respects for
|
||||
// all of the code used other than OpenSSL. If you modify file(s)
|
||||
// with this exception, you may extend this exception to your version
|
||||
// of the file(s), but you are not obligated to do so. If you do not
|
||||
// wish to do so, delete this exception statement from your version.
|
||||
// If you delete this exception statement from all source files in the
|
||||
// program, then also delete it here.
|
||||
//
|
||||
// Contact: Jari Sundell <sundell.software@gmail.com>
|
||||
|
||||
|
||||
#ifndef RTORRENT_UI_ELEMENT_FILE_LIST_H
|
||||
#define RTORRENT_UI_ELEMENT_FILE_LIST_H
|
||||
|
||||
|
||||
+4
-4
@@ -5,11 +5,11 @@
|
||||
#include <fstream>
|
||||
#include <stdexcept>
|
||||
#include <string.h>
|
||||
#include <rak/string_manip.h>
|
||||
#include <torrent/throttle.h>
|
||||
#include <torrent/torrent.h>
|
||||
#include <torrent/download/resource_manager.h>
|
||||
#include <torrent/utils/log.h>
|
||||
#include <torrent/utils/string_manip.h>
|
||||
|
||||
#include "control.h"
|
||||
#include "core/download_list.h"
|
||||
@@ -286,8 +286,8 @@ Root::add_to_input_history(ui::DownloadList::Input type, std::string item) {
|
||||
|
||||
// Don't store item if it's empty or the same as the last one in the category.
|
||||
if (!item.empty() && item != itr->second.at(prev_item_pointer)) {
|
||||
itr->second.at(pitr->second) = rak::trim(item);
|
||||
m_input_history_pointers[type] = (pitr->second + 1) % m_input_history_length;
|
||||
itr->second.at(pitr->second) = torrent::utils::trim_spaces_str(item);
|
||||
m_input_history_pointers[type] = (pitr->second + 1) % m_input_history_length;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -403,7 +403,7 @@ Root::load_input_history() {
|
||||
InputHistory::iterator itr = input_history_tmp.find(type);
|
||||
|
||||
if (itr != input_history_tmp.end()) {
|
||||
std::string input_str = rak::trim(line.substr(delim_pos + 1));
|
||||
auto input_str = torrent::utils::trim_spaces_str(line.substr(delim_pos + 1));
|
||||
|
||||
if (!input_str.empty())
|
||||
itr->second.push_back(input_str);
|
||||
|
||||
Reference in New Issue
Block a user