mirror of
https://github.com/rakshasa/rtorrent.git
synced 2026-10-14 21:26:17 +00:00
* Added posix_fallocate to File::reserve, though it is disabled by
default. * Added some checks to the keyboard input code in the client, perhaps it'll fix the bug some OpenBSD people are encountering. git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@501 e378c898-3ddf-0310-93e7-cc216c733640
This commit is contained in:
@@ -36,7 +36,6 @@
|
|||||||
|
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
|
|
||||||
#include <sstream>
|
|
||||||
#include <ncurses.h>
|
#include <ncurses.h>
|
||||||
|
|
||||||
#include "text_input.h"
|
#include "text_input.h"
|
||||||
@@ -45,8 +44,6 @@ namespace input {
|
|||||||
|
|
||||||
bool
|
bool
|
||||||
TextInput::pressed(int key) {
|
TextInput::pressed(int key) {
|
||||||
//std::stringstream str;
|
|
||||||
|
|
||||||
if (m_alt) {
|
if (m_alt) {
|
||||||
m_alt = false;
|
m_alt = false;
|
||||||
|
|
||||||
@@ -102,18 +99,6 @@ TextInput::pressed(int key) {
|
|||||||
|
|
||||||
default:
|
default:
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
// Testcode.
|
|
||||||
// if (key == KEY_ENTER || key == '\n')
|
|
||||||
// return false;
|
|
||||||
|
|
||||||
// str << "\\x" << std::hex << key;
|
|
||||||
|
|
||||||
// Base::insert(m_pos, str.str());
|
|
||||||
|
|
||||||
// m_pos += str.str().length();
|
|
||||||
|
|
||||||
// return true;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -241,6 +241,9 @@ DownloadList::receive_check_hash() {
|
|||||||
|
|
||||||
void
|
void
|
||||||
DownloadList::receive_view_input(bool useDefault) {
|
DownloadList::receive_view_input(bool useDefault) {
|
||||||
|
if (m_windowTextInput->get_active())
|
||||||
|
return;
|
||||||
|
|
||||||
m_control->get_ui().window_statusbar()->set_active(false);
|
m_control->get_ui().window_statusbar()->set_active(false);
|
||||||
m_windowTextInput->set_active(true);
|
m_windowTextInput->set_active(true);
|
||||||
m_control->get_display().adjust_layout();
|
m_control->get_display().adjust_layout();
|
||||||
@@ -255,6 +258,9 @@ DownloadList::receive_view_input(bool useDefault) {
|
|||||||
|
|
||||||
void
|
void
|
||||||
DownloadList::receive_exit_input(bool useDefault) {
|
DownloadList::receive_exit_input(bool useDefault) {
|
||||||
|
if (!m_windowTextInput->get_active())
|
||||||
|
return;
|
||||||
|
|
||||||
m_control->get_ui().window_statusbar()->set_active(true);
|
m_control->get_ui().window_statusbar()->set_active(true);
|
||||||
m_windowTextInput->set_active(false);
|
m_windowTextInput->set_active(false);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user