* Starting work on ElementText for displaying generic information.

* If a storage error was thrown from make_directory in
EntryList::open, it would try to erase a FileMeta that wasn't inserted.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@753 e378c898-3ddf-0310-93e7-cc216c733640
This commit is contained in:
rakshasa
2006-08-09 19:55:34 +00:00
parent ba28df3ff2
commit ca58b43d8b
17 changed files with 360 additions and 67 deletions
+15
View File
@@ -162,11 +162,17 @@ VariableVoidSlot::get() {
void
VariableVoidSlot::set(const torrent::Object& arg) {
if (!m_slotSet.is_valid())
return;
m_slotSet();
}
const torrent::Object&
VariableValueSlot::get() {
if (!m_slotGet.is_valid())
return m_cache;
m_cache = m_slotGet() / m_unit;
return m_cache;
@@ -174,6 +180,9 @@ VariableValueSlot::get() {
void
VariableValueSlot::set(const torrent::Object& arg) {
if (!m_slotSet.is_valid())
return;
value_type value;
switch (arg.type()) {
@@ -196,6 +205,9 @@ VariableValueSlot::set(const torrent::Object& arg) {
const torrent::Object&
VariableStringSlot::get() {
if (!m_slotGet.is_valid())
return m_cache;
m_cache = m_slotGet();
return m_cache;
@@ -203,6 +215,9 @@ VariableStringSlot::get() {
void
VariableStringSlot::set(const torrent::Object& arg) {
if (!m_slotSet.is_valid())
return;
switch (arg.type()) {
case torrent::Object::TYPE_STRING:
m_slotSet(arg.as_string());