mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-05-10 01:55:19 -04:00
* Switched to new rsFiles interface.
* Updated Transfers/SharedFiles/Messages.. etc Dialogs. * Disabled 'Recommendation Lists' for the moment. * updated Interface files. git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@631 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
be392405e8
commit
32973f0838
13 changed files with 215 additions and 213 deletions
|
@ -25,6 +25,7 @@
|
|||
|
||||
#include "rsiface/rsiface.h"
|
||||
#include "rsiface/rspeers.h"
|
||||
#include "rsiface/rsfiles.h"
|
||||
#include "rsiface/RemoteDirModel.h"
|
||||
#include "util/RsAction.h"
|
||||
#include "msgs/ChanMsgDialog.h"
|
||||
|
@ -135,7 +136,7 @@ SharedFilesDialog::SharedFilesDialog(QWidget *parent)
|
|||
void SharedFilesDialog::checkUpdate()
|
||||
{
|
||||
/* update */
|
||||
if (rsicontrol->InDirectoryCheck())
|
||||
if (rsFiles->InDirectoryCheck())
|
||||
{
|
||||
ui.hashLabel->setPixmap(QPixmap(IMAGE_HASH_BUSY));
|
||||
/*QMovie *movie = new QMovie(IMAGE_PROGRESS);
|
||||
|
@ -153,7 +154,7 @@ void SharedFilesDialog::checkUpdate()
|
|||
|
||||
void SharedFilesDialog::forceCheck()
|
||||
{
|
||||
rsicontrol->ForceDirectoryCheck();
|
||||
rsFiles->ForceDirectoryCheck();
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -191,32 +192,6 @@ void SharedFilesDialog::downloadRemoteSelected()
|
|||
}
|
||||
|
||||
|
||||
void SharedFilesDialog::addMsgRemoteSelected()
|
||||
{
|
||||
/* call back to the model (which does all the interfacing? */
|
||||
|
||||
std::cerr << "Recommending Files";
|
||||
std::cerr << std::endl;
|
||||
|
||||
QItemSelectionModel *qism = ui.remoteDirTreeView->selectionModel();
|
||||
model -> recommendSelected(qism->selectedIndexes());
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
void SharedFilesDialog::recommendfile()
|
||||
{
|
||||
/* call back to the model (which does all the interfacing? */
|
||||
|
||||
std::cerr << "Recommending Files";
|
||||
std::cerr << std::endl;
|
||||
|
||||
QItemSelectionModel *qism = ui.localDirTreeView->selectionModel();
|
||||
localModel -> recommendSelected(qism->selectedIndexes());
|
||||
}
|
||||
|
||||
|
||||
void SharedFilesDialog::playselectedfiles()
|
||||
{
|
||||
|
@ -235,7 +210,7 @@ void SharedFilesDialog::playselectedfiles()
|
|||
for(it = paths.begin(); it != paths.end(); it++)
|
||||
{
|
||||
std::string fullpath;
|
||||
rsicontrol->ConvertSharedFilePath(*it, fullpath);
|
||||
rsFiles->ConvertSharedFilePath(*it, fullpath);
|
||||
fullpaths.push_back(QString::fromStdString(fullpath));
|
||||
|
||||
std::cerr << "Playing: " << fullpath;
|
||||
|
@ -246,6 +221,34 @@ void SharedFilesDialog::playselectedfiles()
|
|||
}
|
||||
|
||||
|
||||
#if 0
|
||||
|
||||
void SharedFilesDialog::addMsgRemoteSelected()
|
||||
{
|
||||
/* call back to the model (which does all the interfacing? */
|
||||
|
||||
std::cerr << "Recommending Files";
|
||||
std::cerr << std::endl;
|
||||
|
||||
QItemSelectionModel *qism = ui.remoteDirTreeView->selectionModel();
|
||||
model -> recommendSelected(qism->selectedIndexes());
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
void SharedFilesDialog::recommendfile()
|
||||
{
|
||||
/* call back to the model (which does all the interfacing? */
|
||||
|
||||
std::cerr << "Recommending Files";
|
||||
std::cerr << std::endl;
|
||||
|
||||
QItemSelectionModel *qism = ui.localDirTreeView->selectionModel();
|
||||
localModel -> recommendSelected(qism->selectedIndexes());
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
void SharedFilesDialog::recommendFileSetOnly()
|
||||
|
@ -284,9 +287,9 @@ void SharedFilesDialog::recommendFilesTo( std::string rsid )
|
|||
nMsgDialog->close();
|
||||
}
|
||||
|
||||
|
||||
|
||||
void SharedFilesDialog::recommendFilesToMsg( std::string rsid )
|
||||
|
||||
void SharedFilesDialog::recommendFilesToMsg( std::string rsid )
|
||||
{
|
||||
recommendFileSetOnly();
|
||||
|
||||
|
@ -308,8 +311,9 @@ void SharedFilesDialog::recommendFilesToMsg( std::string rsid )
|
|||
nMsgDialog->show();
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
void SharedFilesDialog::openfile()
|
||||
{
|
||||
/* call back to the model (which does all the interfacing? */
|
||||
|
@ -364,9 +368,9 @@ void SharedFilesDialog::shareddirtreeWidgetCostumPopupMenu( QPoint point )
|
|||
openfolderAct = new QAction(QIcon(IMAGE_DOWNLOAD), tr( "Play File(s)" ), this );
|
||||
connect( openfolderAct , SIGNAL( triggered() ), this, SLOT( playselectedfiles() ) );
|
||||
|
||||
#if 0
|
||||
openfileAct = new QAction(QIcon(IMAGE_ATTACHMENT), tr( "Add to Recommend List" ), this );
|
||||
connect( openfileAct , SIGNAL( triggered() ), this, SLOT( recommendfile() ) );
|
||||
|
||||
|
||||
/* now we're going to ask who to recommend it to...
|
||||
* First Level.
|
||||
|
@ -416,12 +420,14 @@ void SharedFilesDialog::shareddirtreeWidgetCostumPopupMenu( QPoint point )
|
|||
/* create list of ids */
|
||||
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
contextMnu2.addAction( openfolderAct);
|
||||
contextMnu2.addAction( openfileAct);
|
||||
contextMnu2.addSeparator();
|
||||
contextMnu2.addMenu( recMenu);
|
||||
contextMnu2.addMenu( msgMenu);
|
||||
//contextMnu2.addAction( openfileAct);
|
||||
//contextMnu2.addSeparator();
|
||||
//contextMnu2.addMenu( recMenu);
|
||||
//contextMnu2.addMenu( msgMenu);
|
||||
|
||||
|
||||
contextMnu2.exec( mevent2->globalPos() );
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue