diff --git a/libretroshare/src/ft/ftserver.cc b/libretroshare/src/ft/ftserver.cc index 1a558f9d6..06c538a70 100644 --- a/libretroshare/src/ft/ftserver.cc +++ b/libretroshare/src/ft/ftserver.cc @@ -44,11 +44,6 @@ const int ftserverzone = 29539; #include "pqi/p3notify.h" #include "rsserver/p3face.h" - -// Includes CacheStrapper / FiMonitor / FiStore for us. - -#include "ft/ftdbase.h" - #include "pqi/pqi.h" #include "pqi/p3linkmgr.h" @@ -299,14 +294,6 @@ bool ftServer::FileClearCompleted() { return mFtController->FileClearCompleted(); } -void ftServer::setMinPrioritizedTransfers(uint32_t s) -{ - mFtController->setMinPrioritizedTransfers(s) ; -} -uint32_t ftServer::getMinPrioritizedTransfers() -{ - return mFtController->getMinPrioritizedTransfers() ; -} void ftServer::setQueueSize(uint32_t s) { mFtController->setQueueSize(s) ; diff --git a/libretroshare/src/ft/ftserver.h b/libretroshare/src/ft/ftserver.h index 1173d8311..e61a72e49 100644 --- a/libretroshare/src/ft/ftserver.h +++ b/libretroshare/src/ft/ftserver.h @@ -47,7 +47,6 @@ #include "turtle/turtleclientservice.h" #include "services/p3service.h" #include "retroshare/rsfiles.h" -//#include "dbase/cachestrapper.h" #include "pqi/pqi.h" #include "pqi/p3cfgmgr.h" @@ -55,10 +54,6 @@ class p3ConnectMgr; class p3FileDatabase; -class CacheStrapper; -class CacheTransfer; - -class ftCacheStrapper; class ftFiStore; class ftFiMonitor; @@ -145,8 +140,6 @@ public: /*** * Control of Downloads Priority. ***/ - virtual uint32_t getMinPrioritizedTransfers() ; - virtual void setMinPrioritizedTransfers(uint32_t s) ; virtual uint32_t getQueueSize() ; virtual void setQueueSize(uint32_t s) ; virtual bool changeQueuePosition(const RsFileHash& hash, QueueMove queue_mv); diff --git a/libretroshare/src/libretroshare.pro b/libretroshare/src/libretroshare.pro index 260626db0..971578c0a 100644 --- a/libretroshare/src/libretroshare.pro +++ b/libretroshare/src/libretroshare.pro @@ -371,7 +371,6 @@ HEADERS += ft/ftchunkmap.h \ ft/ftcontroller.h \ ft/ftdata.h \ ft/ftdatamultiplex.h \ - ft/ftdbase.h \ ft/ftextralist.h \ ft/ftfilecreator.h \ ft/ftfileprovider.h \ @@ -531,7 +530,6 @@ HEADERS += util/folderiterator.h \ SOURCES += ft/ftchunkmap.cc \ ft/ftcontroller.cc \ ft/ftdatamultiplex.cc \ - ft/ftdbase.cc \ ft/ftextralist.cc \ ft/ftfilecreator.cc \ ft/ftfileprovider.cc \ diff --git a/libretroshare/src/plugins/pluginmanager.cc b/libretroshare/src/plugins/pluginmanager.cc index af1bfbb65..688cc0bb0 100644 --- a/libretroshare/src/plugins/pluginmanager.cc +++ b/libretroshare/src/plugins/pluginmanager.cc @@ -410,7 +410,8 @@ void RsPluginManager::slowTickPlugins(time_t seconds) void RsPluginManager::registerCacheServices() { -#warning this code should go + // this is removed since the old cache syste is gone, but we need to make it register new GXS group services instead. +#ifdef REMOVED std::cerr << " Registering cache services." << std::endl; for(uint32_t i=0;i<_plugins.size();++i) @@ -419,6 +420,7 @@ void RsPluginManager::registerCacheServices() //rsFiles->getCacheStrapper()->addCachePair(CachePair(_plugins[i].plugin->rs_cache_service(),_plugins[i].plugin->rs_cache_service(),CacheId(_plugins[i].plugin->rs_service_id(), 0))) ; std::cerr << " adding new cache pair for plugin " << _plugins[i].plugin->getPluginName() << ", with RS_ID " << _plugins[i].plugin->rs_service_id() << std::endl ; } +#endif } void RsPluginManager::registerClientServices(p3ServiceServer *pqih) @@ -547,14 +549,6 @@ bool RsPluginManager::saveList(bool& cleanup, std::list& list) return true; } -// RsCacheService::RsCacheService(uint16_t service_type,uint32_t tick_delay, RsPluginHandler* pgHandler) -// : CacheSource(service_type, true, pgHandler->getFileServer()->getCacheStrapper(), pgHandler->getLocalCacheDir()), -// CacheStore (service_type, true, pgHandler->getFileServer()->getCacheStrapper(), pgHandler->getFileServer()->getCacheTransfer(), pgHandler->getRemoteCacheDir()), -// p3Config(), -// _tick_delay_in_seconds(tick_delay) -// { -// } - RsPQIService::RsPQIService(uint16_t /*service_type*/, uint32_t /*tick_delay_in_seconds*/, RsPluginHandler* /*pgHandler*/) : p3Service(),p3Config() { diff --git a/libretroshare/src/retroshare/rsfiles.h b/libretroshare/src/retroshare/rsfiles.h index 2236a6a8b..247270007 100644 --- a/libretroshare/src/retroshare/rsfiles.h +++ b/libretroshare/src/retroshare/rsfiles.h @@ -37,8 +37,6 @@ class RsFiles; extern RsFiles *rsFiles; namespace RsRegularExpression { class Expression; } -class CacheStrapper ; -class CacheTransfer; /* These are used mainly by ftController at the moment */ const uint32_t RS_FILE_CTRL_PAUSE = 0x00000100; @@ -147,8 +145,6 @@ class RsFiles /*** * Control of Downloads Priority. ***/ - virtual uint32_t getMinPrioritizedTransfers() = 0 ; - virtual void setMinPrioritizedTransfers(uint32_t s) = 0 ; virtual uint32_t getQueueSize() = 0 ; virtual void setQueueSize(uint32_t s) = 0 ; virtual bool changeQueuePosition(const RsFileHash& hash, QueueMove mv) = 0; diff --git a/libretroshare/src/rsserver/rsinit.cc b/libretroshare/src/rsserver/rsinit.cc index 066616633..82c5168f9 100644 --- a/libretroshare/src/rsserver/rsinit.cc +++ b/libretroshare/src/rsserver/rsinit.cc @@ -1675,11 +1675,6 @@ int RsServer::StartupRetroShare() /**************************************************************************/ std::cerr << "(2) Load configuration files" << std::endl; - /* NOTE: CacheStrapper's load causes Cache Files to be - * loaded into all the CacheStores/Sources. This happens - * after all the other configurations have happened. - */ - mConfigMgr->loadConfiguration(); /**************************************************************************/ diff --git a/retroshare-gui/src/gui/FileTransfer/TransfersDialog.cpp b/retroshare-gui/src/gui/FileTransfer/TransfersDialog.cpp index c19762027..195959e16 100644 --- a/retroshare-gui/src/gui/FileTransfer/TransfersDialog.cpp +++ b/retroshare-gui/src/gui/FileTransfer/TransfersDialog.cpp @@ -349,9 +349,6 @@ TransfersDialog::TransfersDialog(QWidget *parent) // ui.tunnelInfoWidget->setFocusPolicy(Qt::NoFocus); /** Setup the actions for the context menu */ - toggleShowCacheTransfersAct = new QAction(tr( "Show file list transfers" ), this ); - toggleShowCacheTransfersAct->setCheckable(true) ; - connect(toggleShowCacheTransfersAct,SIGNAL(triggered()),this,SLOT(toggleShowCacheTransfers())) ; // Actions. Only need to be defined once. pauseAct = new QAction(QIcon(IMAGE_PAUSE), tr("Pause"), this); @@ -519,12 +516,6 @@ UserNotify *TransfersDialog::getUserNotify(QObject *parent) return new TransferUserNotify(parent); } -void TransfersDialog::toggleShowCacheTransfers() -{ - _show_cache_transfers = !_show_cache_transfers ; - insertTransfers() ; -} - void TransfersDialog::processSettings(bool bLoad) { m_bProcessSettings = true; @@ -537,9 +528,6 @@ void TransfersDialog::processSettings(bool bLoad) if (bLoad) { // load settings - // state of checks - _show_cache_transfers = Settings->value("showCacheTransfers", false).toBool(); - // state of the lists DLHeader->restoreState(Settings->value("downloadList").toByteArray()); ULHeader->restoreState(Settings->value("uploadList").toByteArray()); @@ -565,9 +553,6 @@ void TransfersDialog::processSettings(bool bLoad) } else { // save settings - // state of checks - Settings->setValue("showCacheTransfers", _show_cache_transfers); - // state of the lists Settings->setValue("downloadList", DLHeader->saveState()); Settings->setValue("uploadList", ULHeader->saveState()); @@ -801,9 +786,6 @@ void TransfersDialog::downloadListCustomPopupMenu( QPoint /*point*/ ) contextMnu.addSeparator() ;//----------------------------------------------- - contextMnu.addAction( toggleShowCacheTransfersAct ) ; - toggleShowCacheTransfersAct->setChecked(_show_cache_transfers) ; - collCreateAct->setEnabled(true) ; collModifAct->setEnabled(single && add_CollActions) ; collViewAct->setEnabled(single && add_CollActions) ; diff --git a/retroshare-gui/src/gui/FileTransfer/TransfersDialog.h b/retroshare-gui/src/gui/FileTransfer/TransfersDialog.h index 0e6e9ad4b..8477d0749 100644 --- a/retroshare-gui/src/gui/FileTransfer/TransfersDialog.h +++ b/retroshare-gui/src/gui/FileTransfer/TransfersDialog.h @@ -199,7 +199,6 @@ private: QAction *chunkProgressiveAct; QAction *chunkStreamingAct; QAction *detailsFileAct; - QAction *toggleShowCacheTransfersAct; QAction *renameFileAct; QAction *specifyDestinationDirectoryAct; QAction *expandAllAct; @@ -249,7 +248,6 @@ private: /** Qt Designer generated object */ Ui::TransfersDialog ui; - bool _show_cache_transfers ; public slots: // these two functions add entries to the transfers dialog, and return the row id of the entry modified/added // @@ -259,7 +257,6 @@ public slots: int addUploadItem(const QString& symbol, const QString& name, const QString& coreID, qlonglong size, const FileProgressInfo& pinfo, double dlspeed, const QString& sources,const QString& source_id, const QString& status, qlonglong completed, qlonglong remaining); void showFileDetails() ; - void toggleShowCacheTransfers() ; double getProgress(int row, QStandardItemModel *model); double getSpeed(int row, QStandardItemModel *model); diff --git a/retroshare-gui/src/gui/settings/TransferPage.cpp b/retroshare-gui/src/gui/settings/TransferPage.cpp index 273f5be5b..bccdcea3c 100644 --- a/retroshare-gui/src/gui/settings/TransferPage.cpp +++ b/retroshare-gui/src/gui/settings/TransferPage.cpp @@ -36,7 +36,6 @@ TransferPage::TransferPage(QWidget * parent, Qt::WindowFlags flags) ui.setupUi(this); ui._queueSize_SB->setValue(rsFiles->getQueueSize()) ; - ui._minPrioritized_SB->setValue(rsFiles->getMinPrioritizedTransfers()) ; switch(rsFiles->defaultChunkStrategy()) { @@ -48,7 +47,6 @@ TransferPage::TransferPage(QWidget * parent, Qt::WindowFlags flags) ui._diskSpaceLimit_SB->setValue(rsFiles->freeDiskSpaceLimit()) ; QObject::connect(ui._queueSize_SB,SIGNAL(valueChanged(int)),this,SLOT(updateQueueSize(int))) ; - QObject::connect(ui._minPrioritized_SB,SIGNAL(valueChanged(int)),this,SLOT(updateMinPrioritized(int))) ; QObject::connect(ui._defaultStrategy_CB,SIGNAL(activated(int)),this,SLOT(updateDefaultStrategy(int))) ; QObject::connect(ui._diskSpaceLimit_SB,SIGNAL(valueChanged(int)),this,SLOT(updateDiskSizeLimit(int))) ; QObject::connect(ui._max_tr_up_per_sec_SB, SIGNAL( valueChanged( int ) ), this, SLOT( updateMaxTRUpRate(int) ) ); @@ -80,15 +78,7 @@ void TransferPage::updateDiskSizeLimit(int s) rsFiles->setFreeDiskSpaceLimit(s) ; } -void TransferPage::updateMinPrioritized(int s) -{ - rsFiles->setMinPrioritizedTransfers(s) ; -} void TransferPage::updateQueueSize(int s) { - if(ui._minPrioritized_SB->value() > s) - { - ui._minPrioritized_SB->setValue(s) ; - } rsFiles->setQueueSize(s) ; } diff --git a/retroshare-gui/src/gui/settings/TransferPage.h b/retroshare-gui/src/gui/settings/TransferPage.h index 3a28f41ac..373d9a17f 100644 --- a/retroshare-gui/src/gui/settings/TransferPage.h +++ b/retroshare-gui/src/gui/settings/TransferPage.h @@ -46,7 +46,6 @@ class TransferPage: public ConfigPage public slots: void updateQueueSize(int) ; - void updateMinPrioritized(int) ; void updateDefaultStrategy(int) ; void updateDiskSizeLimit(int) ; void updateMaxTRUpRate(int); diff --git a/retroshare-gui/src/gui/settings/TransferPage.ui b/retroshare-gui/src/gui/settings/TransferPage.ui index 14023f0ab..ceeae7f47 100644 --- a/retroshare-gui/src/gui/settings/TransferPage.ui +++ b/retroshare-gui/src/gui/settings/TransferPage.ui @@ -6,8 +6,8 @@ 0 0 - 604 - 340 + 700 + 356 @@ -28,13 +28,6 @@ - - - - Slots reserved for non-cache transfers: - - - @@ -76,19 +69,6 @@ - - - - <html><head/><body><p>You can use this to force RetroShare to download your files rather <br/>than cache files for as many slots as requested. Setting that number <br/>to be equal to the queue size above will always prioritize your files<br/>over cache. <br/><br/>It is however recommended to leave at least a few slots for cache files. For now, cache files are only used to transfer friend file lists.</p></body></html> - - - 1 - - - 3 - - - @@ -168,12 +148,12 @@ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> <html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'Ubuntu'; font-size:11pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Sans'; font-size:8pt; font-weight:600;">RetroShare</span><span style=" font-family:'Sans'; font-size:8pt;"> is capable of transferring data and search requests between peers that are not necessarily friends. This traffic however only transits through a connected list of friends and is anonymous.</span></p> -<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'Sans'; font-size:8pt;"><br /></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Sans'; font-size:8pt;">You can separately setup share flags for each shared directory in the shared files dialog to be:</span></p> -<ul style="margin-top: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; -qt-list-indent: 1;"><li style=" font-family:'Sans'; font-size:8pt;" style=" margin-top:12px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;">Browsable by friends</span>: files are seen by your friends.</li> -<li style=" font-family:'Sans'; font-size:8pt;" style=" margin-top:0px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;">Anonymously shared</span>: files are anonymously reachable through distant F2F tunnels.</li></ul></body></html> +</style></head><body style=" font-family:'Sans'; font-size:9pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt; font-weight:600;">RetroShare</span><span style=" font-size:8pt;"> is capable of transferring data and search requests between peers that are not necessarily friends. This traffic however only transits through a connected list of friends and is anonymous.</span></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"><br /></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">You can separately setup share flags for each shared directory in the shared files dialog to be:</span></p> +<ul style="margin-top: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; -qt-list-indent: 1;"><li style=" font-size:8pt;" style=" margin-top:12px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;">Browsable by friends</span>: files are seen by your friends.</li> +<li style=" font-size:8pt;" style=" margin-top:0px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;">Anonymously shared</span>: files are anonymously reachable through distant F2F tunnels.</li></ul></body></html>