Redesigned the MessagesDialog to open the message in a new tab or new window for reading.

The MessageComposer is now only for writing a new message or editing a message from the draft box.
Added a new setting to the MessagePage.

git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@4230 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
thunder2 2011-06-04 00:46:02 +00:00
parent 50e243adf6
commit 7661f4486d
16 changed files with 2740 additions and 1171 deletions

View File

@ -270,6 +270,8 @@ HEADERS += rshare.h \
gui/channels/ShareKey.h \
gui/connect/ConfCertDialog.h \
gui/msgs/MessageComposer.h \
gui/msgs/MessageWindow.h \
gui/msgs/MessageWidget.h \
gui/msgs/TagsMenu.h \
gui/msgs/textformat.h \
gui/images/retroshare_win.rc.h \
@ -384,6 +386,8 @@ FORMS += gui/StartDialog.ui \
gui/chat/PopupChatDialog.ui \
gui/connect/ConfCertDialog.ui \
gui/msgs/MessageComposer.ui \
gui/msgs/MessageWindow.ui\
gui/msgs/MessageWidget.ui\
gui/settings/settings.ui \
gui/settings/GeneralPage.ui \
gui/settings/DirectoriesPage.ui \
@ -503,6 +507,8 @@ SOURCES += main.cpp \
gui/chat/ChatStyle.cpp \
gui/connect/ConfCertDialog.cpp \
gui/msgs/MessageComposer.cpp \
gui/msgs/MessageWidget.cpp \
gui/msgs/MessageWindow.cpp \
gui/msgs/TagsMenu.cpp \
gui/common/vmessagebox.cpp \
gui/common/rwindow.cpp \

File diff suppressed because it is too large Load Diff

View File

@ -27,6 +27,8 @@
#include "mainpage.h"
#include "ui_MessagesDialog.h"
class MessageWidget;
class MessagesDialog : public MainPage
{
Q_OBJECT
@ -50,7 +52,6 @@ public slots:
private slots:
/** Create the context popup menu and it's submenus */
void messageslistWidgetCostumPopupMenu( QPoint point );
void msgfilelistWidgetCostumPopupMenu(QPoint);
void folderlistWidgetCostumPopupMenu(QPoint);
void changeBox( int newrow );
@ -61,18 +62,10 @@ private slots:
void doubleClicked(const QModelIndex &);
void newmessage();
void openAsWindow();
void openAsTab();
void editmessage();
void replytomessage();
void replyallmessage();
void forwardmessage();
void print();
void printpreview();
bool fileSave();
bool fileSaveAs();
void removemessage();
void undeletemessage();
@ -82,17 +75,7 @@ private slots:
void emptyTrash();
void getcurrentrecommended();
void getallrecommended();
/* handle splitter */
void togglefileview();
void buttonstextbesideicon();
void buttonsicononly();
void buttonstextundericon();
void loadToolButtonsettings();
void buttonStyle();
void filterRegExpChanged();
void filterColumnChanged();
@ -102,6 +85,11 @@ private slots:
void tagSet(int tagId, bool set);
void tagRemoveAll();
void tabChanged(int tab);
void tabCloseRequested(int tab);
void updateInterface();
private:
class LockUpdate
{
@ -119,6 +107,8 @@ private:
class QStandardItemModel *MessagesModel;
QSortFilterProxyModel *proxyModel;
void connectActions();
void updateMessageSummaryList();
void insertMsgTxtAndFiles(QModelIndex index = QModelIndex(), bool bSetToRead = true);
@ -126,39 +116,31 @@ private:
void setMsgAsReadUnread(const QList<int> &Rows, bool read);
void setMsgStar(const QList<int> &Rows, bool mark);
void setCurrentFileName(const QString &fileName);
int getSelectedMsgCount (QList<int> *pRows, QList<int> *pRowsRead, QList<int> *pRowsUnread, QList<int> *pRowsStar);
bool isMessageRead(int nRow);
bool hasMessageStar(int nRow);
/* internal handle splitter */
void togglefileview_internal();
void processSettings(bool bLoad);
void clearTagLabels();
void showTagLabels();
void processSettings(bool load);
void setToolbarButtonStyle(Qt::ToolButtonStyle style);
void fillTags();
void closeTab(const std::string &msgId);
bool m_bProcessSettings;
bool m_bInChange;
int m_nLockUpdate; // use with LockUpdate
enum { LIST_NOTHING, LIST_BOX, LIST_TAG } m_eListMode;
std::string mCurrCertId;
std::string mCurrMsgId;
QList<QLabel*> tagLabels;
QString fileName;
QFont mFont;
// timer and index for showing message
QTimer *timer;
QModelIndex timerIndex;
MessageWidget *msgWidget;
/** Qt Designer generated object */
Ui::MessagesDialog ui;
};

View File

@ -990,7 +990,7 @@ border-image: url(:/images/closepressed.png)
<string>Tags</string>
</property>
<property name="text">
<string>Tag</string>
<string>Tags</string>
</property>
<property name="icon">
<iconset resource="images.qrc">
@ -1014,7 +1014,7 @@ border-image: url(:/images/closepressed.png)
</widget>
</item>
<item row="1" column="0">
<widget class="QTabWidget" name="tabWidget">
<widget class="RSTabWidget" name="tabWidget">
<property name="layoutDirection">
<enum>Qt::LeftToRight</enum>
</property>
@ -1023,8 +1023,8 @@ border-image: url(:/images/closepressed.png)
}
</string>
</property>
<property name="currentIndex">
<number>0</number>
<property name="tabsClosable">
<bool>true</bool>
</property>
<widget class="QWidget" name="tab">
<attribute name="title">
@ -1318,436 +1318,9 @@ padding: 4px;
</property>
</widget>
<widget class="QWidget" name="layoutWidget">
<layout class="QGridLayout" name="gridLayout_2">
<item row="1" column="0">
<widget class="QTextBrowser" name="msgText">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
<property name="openLinks">
<bool>true</bool>
</property>
</widget>
</item>
<item row="2" column="0">
<layout class="QHBoxLayout">
<item>
<layout class="QGridLayout">
<property name="margin">
<number>0</number>
</property>
<property name="spacing">
<number>6</number>
</property>
<item row="0" column="2">
<widget class="QLabel" name="label_6">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="images.qrc">:/images/attachment.png</pixmap>
</property>
</widget>
</item>
<item row="0" column="3">
<widget class="QLabel" name="label_2">
<property name="text">
<string>&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
p, li { white-space: pre-wrap; }
&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:'Arial'; font-size:8pt; font-weight:400; font-style:normal; text-decoration:none;&quot;&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-size:10pt; font-weight:600;&quot;&gt;Recommended Files&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
</widget>
</item>
<item row="0" column="4">
<widget class="QLabel" name="filesText">
<property name="font">
<font>
<pointsize>10</pointsize>
<italic>true</italic>
</font>
</property>
<property name="text">
<string/>
</property>
</widget>
</item>
</layout>
</item>
<item>
<spacer>
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>351</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QPushButton" name="downloadButton">
<property name="focusPolicy">
<enum>Qt::NoFocus</enum>
</property>
<property name="toolTip">
<string>Download all Recommended Files</string>
</property>
<property name="icon">
<iconset resource="images.qrc">
<normaloff>:/images/down.png</normaloff>:/images/down.png</iconset>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="expandFilesButton">
<property name="focusPolicy">
<enum>Qt::NoFocus</enum>
</property>
<property name="text">
<string/>
</property>
<property name="icon">
<iconset resource="images.qrc">
<normaloff>:/images/edit_remove24.png</normaloff>:/images/edit_remove24.png</iconset>
</property>
<property name="checkable">
<bool>true</bool>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item row="0" column="0">
<layout class="QHBoxLayout">
<property name="leftMargin">
<number>6</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>6</number>
</property>
<property name="bottomMargin">
<number>0</number>
</property>
<item>
<layout class="QGridLayout">
<property name="horizontalSpacing">
<number>6</number>
</property>
<property name="verticalSpacing">
<number>3</number>
</property>
<item row="0" column="0">
<widget class="QLabel" name="subjectlabel">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="font">
<font>
<pointsize>9</pointsize>
<weight>50</weight>
<bold>false</bold>
</font>
</property>
<property name="text">
<string>Subject:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="fromlabel">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="font">
<font>
<pointsize>9</pointsize>
<weight>50</weight>
<bold>false</bold>
</font>
</property>
<property name="text">
<string>From:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="1" column="2" colspan="2">
<widget class="QLabel" name="fromText">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>2</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>16777215</height>
</size>
</property>
<property name="font">
<font>
<pointsize>9</pointsize>
</font>
</property>
<property name="scaledContents">
<bool>true</bool>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="tolabel">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="font">
<font>
<pointsize>9</pointsize>
<weight>50</weight>
<bold>false</bold>
</font>
</property>
<property name="text">
<string>To:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="2" column="2" colspan="2">
<widget class="QLabel" name="toText">
<property name="wordWrap">
<bool>true</bool>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
</widget>
</item>
<item row="3" column="0">
<widget class="QLabel" name="cclabel">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="font">
<font>
<pointsize>9</pointsize>
<weight>50</weight>
<bold>false</bold>
</font>
</property>
<property name="text">
<string>Cc:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item row="4" column="0">
<widget class="QLabel" name="bcclabel">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="font">
<font>
<pointsize>9</pointsize>
<weight>50</weight>
<bold>false</bold>
</font>
</property>
<property name="text">
<string>Bcc:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="3" column="2" colspan="2">
<widget class="QLabel" name="ccText">
<property name="wordWrap">
<bool>true</bool>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
</widget>
</item>
<item row="4" column="2" colspan="2">
<widget class="QLabel" name="bccText">
<property name="wordWrap">
<bool>true</bool>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
</widget>
</item>
<item row="5" column="0">
<widget class="QLabel" name="tagslabel">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="font">
<font>
<pointsize>9</pointsize>
<weight>50</weight>
<bold>false</bold>
</font>
</property>
<property name="text">
<string>Tags:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="5" column="2" colspan="2">
<layout class="QHBoxLayout" name="taglayout"/>
</item>
<item row="0" column="2" colspan="2">
<layout class="QHBoxLayout" name="horizontalLayout_3">
<item>
<widget class="QLabel" name="subjectText">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="font">
<font>
<pointsize>9</pointsize>
</font>
</property>
<property name="wordWrap">
<bool>true</bool>
</property>
<property name="textInteractionFlags">
<set>Qt::LinksAccessibleByMouse|Qt::TextSelectableByMouse</set>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="dateText">
<property name="sizePolicy">
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="font">
<font>
<pointsize>9</pointsize>
</font>
</property>
<property name="layoutDirection">
<enum>Qt::LeftToRight</enum>
</property>
<property name="text">
<string notr="true">Date</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
<property name="textInteractionFlags">
<set>Qt::LinksAccessibleByMouse|Qt::TextSelectableByMouse</set>
</property>
</widget>
</item>
</layout>
</item>
</layout>
</item>
</layout>
</item>
</layout>
<layout class="QGridLayout" name="msgLayout"/>
</widget>
</widget>
<widget class="QTreeWidget" name="msgList">
<property name="font">
<font>
<pointsize>9</pointsize>
</font>
</property>
<property name="contextMenuPolicy">
<enum>Qt::CustomContextMenu</enum>
</property>
<property name="styleSheet">
<string notr="true"/>
</property>
<property name="sortingEnabled">
<bool>true</bool>
</property>
<column>
<property name="text">
<string>File Name</string>
</property>
</column>
<column>
<property name="text">
<string>Size</string>
</property>
</column>
<column>
<property name="text">
<string>Hash</string>
</property>
</column>
</widget>
</widget>
</widget>
</item>
@ -1793,39 +1366,29 @@ p, li { white-space: pre-wrap; }
<string>Set Text Under Icon</string>
</property>
</action>
<action name="actionSave_as">
<action name="actionSaveAs">
<property name="text">
<string>Save As...</string>
</property>
</action>
</widget>
<customwidgets>
<customwidget>
<class>RSTabWidget</class>
<extends>QTabWidget</extends>
<header>gui/common/RSTabWidget.h</header>
<container>1</container>
</customwidget>
</customwidgets>
<tabstops>
<tabstop>newmessageButton</tabstop>
<tabstop>replymessageButton</tabstop>
<tabstop>listWidget</tabstop>
<tabstop>msgText</tabstop>
<tabstop>msgList</tabstop>
</tabstops>
<resources>
<include location="images.qrc"/>
</resources>
<connections>
<connection>
<sender>expandFilesButton</sender>
<signal>clicked(bool)</signal>
<receiver>msgList</receiver>
<slot>setVisible(bool)</slot>
<hints>
<hint type="sourcelabel">
<x>184</x>
<y>348</y>
</hint>
<hint type="destinationlabel">
<x>399</x>
<y>397</y>
</hint>
</hints>
</connection>
<connection>
<sender>Tags_Button</sender>
<signal>toggled(bool)</signal>

View File

@ -0,0 +1,651 @@
/****************************************************************
* RetroShare is distributed under the following license:
*
* Copyright (C) 2006 - 2011 RetroShare Team
*
* 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., 51 Franklin Street, Fifth Floor,
* Boston, MA 02110-1301, USA.
****************************************************************/
#include <QMenu>
#include <QToolButton>
#include <QDateTime>
#include <QMessageBox>
#include <QPrinter>
#include <QPrintDialog>
#include "gui/notifyqt.h"
#include "gui/RetroShareLink.h"
#include "gui/common/TagDefs.h"
#include "gui/common/PeerDefs.h"
#include "gui/common/Emoticons.h"
#include "gui/settings/rsharesettings.h"
#include "MessageComposer.h"
#include "MessageWidget.h"
#include "MessageWindow.h"
#include "util/misc.h"
#include "util/printpreview.h"
#include <retroshare/rspeers.h>
#include <retroshare/rsfiles.h>
#include <retroshare/rsmsgs.h>
/* Images for context menu icons */
#define IMAGE_DOWNLOAD ":/images/start.png"
#define IMAGE_DOWNLOADALL ":/images/startall.png"
#define COLUMN_FILE_NAME 0
#define COLUMN_FILE_SIZE 1
#define COLUMN_FILE_HASH 2
#define COLUMN_FILE_COUNT 3
MessageWidget *MessageWidget::openMsg(const std::string &msgId, bool window)
{
if (msgId.empty()) {
return NULL;
}
MessageInfo msgInfo;
if (!rsMsgs->getMessage(msgId, msgInfo)) {
std::cerr << "MessageWidget::openMsg() Couldn't find Msg" << std::endl;
return NULL;
}
MessageWindow *parent = NULL;
if (window) {
parent = new MessageWindow;
}
MessageWidget *msgWidget = new MessageWidget(false, parent);
msgWidget->isWindow = window;
msgWidget->fill(msgId);
if (parent) {
parent->addWidget(msgWidget);
}
if (parent) {
parent->show();
parent->activateWindow();
}
return msgWidget;
}
/** Constructor */
MessageWidget::MessageWidget(bool controlled, QWidget *parent, Qt::WFlags flags)
: QWidget(parent, flags)
{
/* Invoke the Qt Designer generated object setup routine */
ui.setupUi(this);
isControlled = controlled;
isWindow = false;
connect(ui.msgList, SIGNAL(customContextMenuRequested(QPoint)), this, SLOT(msgfilelistWidgetCostumPopupMenu(QPoint)));
connect(ui.expandFilesButton, SIGNAL(clicked()), this, SLOT(togglefileview()));
connect(ui.downloadButton, SIGNAL(clicked()), this, SLOT(getallrecommended()));
connect(NotifyQt::getInstance(), SIGNAL(messagesTagsChanged()), this, SLOT(messagesTagsChanged()));
connect(NotifyQt::getInstance(), SIGNAL(messagesChanged()), this, SLOT(messagesChanged()));
/* hide the Tree +/- */
ui.msgList->setRootIsDecorated( false );
ui.msgList->setSelectionMode( QAbstractItemView::ExtendedSelection );
/* Set header resize modes and initial section sizes */
QHeaderView * msglheader = ui.msgList->header () ;
msglheader->setResizeMode (COLUMN_FILE_NAME, QHeaderView::Interactive);
msglheader->setResizeMode (COLUMN_FILE_SIZE, QHeaderView::Interactive);
msglheader->setResizeMode (COLUMN_FILE_HASH, QHeaderView::Interactive);
msglheader->resizeSection (COLUMN_FILE_NAME, 200);
msglheader->resizeSection (COLUMN_FILE_SIZE, 100);
msglheader->resizeSection (COLUMN_FILE_HASH, 200);
QFont font = QFont("Arial", 10, QFont::Bold);
ui.subjectText->setFont(font);
ui.bcclabel->setVisible(false);
ui.bccText->setVisible(false);
ui.cclabel->setVisible(false);
ui.ccText->setVisible(false);
ui.tagsLabel->setVisible(false);
if (isControlled == false) {
processSettings("MessageWidget", true);
}
/* Hide platform specific features */
#ifdef Q_WS_WIN
#endif
}
MessageWidget::~MessageWidget()
{
if (isControlled == false) {
processSettings("MessageWidget", false);
}
}
void MessageWidget::connectAction(enumActionType actionType, QToolButton* button)
{
switch (actionType) {
case ACTION_REMOVE:
connect(button, SIGNAL(clicked()), this, SLOT(remove()));
break;
case ACTION_REPLY:
connect(button, SIGNAL(clicked()), this, SLOT(reply()));
break;
case ACTION_REPLY_ALL:
connect(button, SIGNAL(clicked()), this, SLOT(replyAll()));
break;
case ACTION_FORWARD:
connect(button, SIGNAL(clicked()), this, SLOT(forward()));
break;
case ACTION_PRINT:
connect(button, SIGNAL(clicked()), this, SLOT(print()));
break;
case ACTION_PRINT_PREVIEW:
connect(button, SIGNAL(clicked()), this, SLOT(printPreview()));
break;
case ACTION_SAVE_AS:
connect(button, SIGNAL(clicked()), this, SLOT(saveAs()));
break;
}
}
void MessageWidget::connectAction(enumActionType actionType, QAction *action)
{
switch (actionType) {
case ACTION_REMOVE:
connect(action, SIGNAL(triggered()), this, SLOT(remove()));
break;
case ACTION_REPLY:
connect(action, SIGNAL(triggered()), this, SLOT(reply()));
break;
case ACTION_REPLY_ALL:
connect(action, SIGNAL(triggered()), this, SLOT(replyAll()));
break;
case ACTION_FORWARD:
connect(action, SIGNAL(triggered()), this, SLOT(forward()));
break;
case ACTION_PRINT:
connect(action, SIGNAL(triggered()), this, SLOT(print()));
break;
case ACTION_PRINT_PREVIEW:
connect(action, SIGNAL(triggered()), this, SLOT(printPreview()));
break;
case ACTION_SAVE_AS:
connect(action, SIGNAL(triggered()), this, SLOT(saveAs()));
break;
}
}
void MessageWidget::processSettings(const QString &settingsGroup, bool load)
{
Settings->beginGroup(settingsGroup);
if (load) {
// load settings
// expandFiles
bool value = Settings->value("expandFiles", true).toBool();
ui.expandFilesButton->setChecked(value);
ui.msgList->setVisible(value);
togglefileview();
} else {
// save settings
// expandFiles
Settings->setValue("expandFiles", ui.expandFilesButton->isChecked());
}
Settings->endGroup();
}
QString MessageWidget::subject(bool noEmpty)
{
QString subject = ui.subjectText->text();
if (subject.isEmpty() && noEmpty) {
return "[" + tr("No subject") + "]";
}
return subject;
}
void MessageWidget::msgfilelistWidgetCostumPopupMenu( QPoint point )
{
QMenu contextMnu(this);
contextMnu.addAction(QIcon(IMAGE_DOWNLOAD), tr("Download"), this, SLOT(getcurrentrecommended()));
contextMnu.addAction(QIcon(IMAGE_DOWNLOADALL), tr("Download all"), this, SLOT(getallrecommended()));
contextMnu.exec(QCursor::pos());
}
void MessageWidget::togglefileview()
{
/* if msg header visible -> change icon and tooltip
* three widgets...
*/
if (ui.expandFilesButton->isChecked()) {
ui.expandFilesButton->setIcon(QIcon(QString(":/images/edit_remove24.png")));
ui.expandFilesButton->setToolTip(tr("Hide"));
} else {
ui.expandFilesButton->setIcon(QIcon(QString(":/images/edit_add24.png")));
ui.expandFilesButton->setToolTip(tr("Expand"));
}
}
/* download the recommendations... */
void MessageWidget::getcurrentrecommended()
{
MessageInfo msgInfo;
if (rsMsgs->getMessage(currMsgId, msgInfo) == false) {
return;
}
std::list<std::string> srcIds;
srcIds.push_back(msgInfo.srcId);
QModelIndexList list = ui.msgList->selectionModel()->selectedIndexes();
std::map<int,FileInfo> files ;
for (QModelIndexList::const_iterator it(list.begin());it!=list.end();++it) {
FileInfo& fi(files[it->row()]) ;
switch (it->column()) {
case COLUMN_FILE_NAME:
fi.fname = it->data().toString().toStdString() ;
break ;
case COLUMN_FILE_SIZE:
fi.size = it->data().toULongLong() ;
break ;
case COLUMN_FILE_HASH:
fi.hash = it->data().toString().toStdString() ;
break ;
}
}
for(std::map<int,FileInfo>::const_iterator it(files.begin());it!=files.end();++it) {
const FileInfo& fi(it->second) ;
std::cout << "Requesting file " << fi.fname << ", size=" << fi.size << ", hash=" << fi.hash << std::endl ;
if (rsFiles->FileRequest(fi.fname, fi.hash, fi.size, "", RS_FILE_HINTS_NETWORK_WIDE, srcIds) == false) {
QMessageBox mb(QObject::tr("File Request canceled"), QObject::tr("The following has not been added to your download list, because you already have it:\n ") + QString::fromStdString(fi.fname), QMessageBox::Critical, QMessageBox::Ok, 0, 0);
mb.setWindowIcon(QIcon(QString::fromUtf8(":/images/rstray3.png")));
mb.exec();
}
}
}
void MessageWidget::getallrecommended()
{
/* get Message */
MessageInfo msgInfo;
if (rsMsgs->getMessage(currMsgId, msgInfo) == false) {
return;
}
const std::list<FileInfo> &recList = msgInfo.files;
std::list<FileInfo>::const_iterator it;
/* do the requests */
for(it = recList.begin(); it != recList.end(); it++) {
std::cerr << "MessageWidget::getallrecommended() Calling File Request" << std::endl;
std::list<std::string> srcIds;
srcIds.push_back(msgInfo.srcId);
rsFiles->FileRequest(it->fname, it->hash, it->size, "", RS_FILE_HINTS_NETWORK_WIDE, srcIds);
}
}
void MessageWidget::messagesTagsChanged()
{
showTagLabels();
}
void MessageWidget::messagesChanged()
{
if (isControlled) {
/* processed by MessagesDialog */
return;
}
/* test Message */
MessageInfo msgInfo;
if (rsMsgs->getMessage(currMsgId, msgInfo) == false) {
/* messages was removed */
if (isWindow) {
window()->close();
} else {
deleteLater();
}
}
}
void MessageWidget::clearTagLabels()
{
/* clear all tags */
while (tagLabels.size()) {
delete tagLabels.front();
tagLabels.pop_front();
}
while (ui.tagLayout->count()) {
delete ui.tagLayout->takeAt(0);
}
ui.tagsLabel->setVisible(false);
}
void MessageWidget::showTagLabels()
{
clearTagLabels();
if (currMsgId.empty()) {
return;
}
MsgTagInfo tagInfo;
rsMsgs->getMessageTag(currMsgId, tagInfo);
if (tagInfo.tagIds.empty() == false) {
ui.tagsLabel->setVisible(true);
MsgTagType Tags;
rsMsgs->getMessageTagTypes(Tags);
std::map<uint32_t, std::pair<std::string, uint32_t> >::iterator Tag;
for (std::list<uint32_t>::iterator tagId = tagInfo.tagIds.begin(); tagId != tagInfo.tagIds.end(); tagId++) {
Tag = Tags.types.find(*tagId);
if (Tag != Tags.types.end()) {
QLabel *tagLabel = new QLabel(TagDefs::name(Tag->first, Tag->second.first), this);
tagLabel->setMaximumHeight(16);
tagLabel->setStyleSheet(TagDefs::labelStyleSheet(Tag->second.second));
tagLabels.push_back(tagLabel);
ui.tagLayout->addWidget(tagLabel);
ui.tagLayout->addSpacing(3);
}
}
ui.tagLayout->addStretch();
} else {
ui.tagsLabel->setVisible(false);
}
}
void MessageWidget::fill(const std::string &msgId)
{
if (currMsgId == msgId) {
// message doesn't changed
return;
}
currMsgId = msgId;
if (currMsgId.empty()) {
/* blank it */
ui.dateText-> setText("");
ui.toText->setText("");
ui.fromText->setText("");
ui.filesText->setText("");
ui.cclabel->setVisible(false);
ui.ccText->setVisible(false);
ui.ccText->clear();
ui.bcclabel->setVisible(false);
ui.bccText->setVisible(false);
ui.bccText->clear();
ui.subjectText->setText("");
ui.msgList->clear();
ui.msgText->clear();
clearTagLabels();
return;
}
clearTagLabels();
MessageInfo msgInfo;
if (rsMsgs->getMessage(currMsgId, msgInfo) == false) {
std::cerr << "MessageWidget::fill() Couldn't find Msg" << std::endl;
return;
}
const std::list<FileInfo> &recList = msgInfo.files;
std::list<FileInfo>::const_iterator it;
ui.msgList->clear();
QList<QTreeWidgetItem*> items;
for (it = recList.begin(); it != recList.end(); it++) {
QTreeWidgetItem *item = new QTreeWidgetItem;
item->setText(COLUMN_FILE_NAME, QString::fromStdString(it->fname));
item->setText(COLUMN_FILE_SIZE, QString::number(it->size));
item->setText(COLUMN_FILE_HASH, QString::fromStdString(it->hash));
/* add to the list */
items.append(item);
}
/* add the items in! */
ui.msgList->insertTopLevelItems(0, items);
/* iterate through the sources */
std::list<std::string>::const_iterator pit;
RetroShareLink link;
QString text;
for(pit = msgInfo.msgto.begin(); pit != msgInfo.msgto.end(); pit++) {
if (link.createMessage(*pit, "")) {
text += link.toHtml() + " ";
}
}
ui.toText->setText(text);
if (msgInfo.msgcc.size() > 0) {
ui.cclabel->setVisible(true);
ui.ccText->setVisible(true);
text.clear();
for(pit = msgInfo.msgcc.begin(); pit != msgInfo.msgcc.end(); pit++) {
if (link.createMessage(*pit, "")) {
text += link.toHtml() + " ";
}
}
ui.ccText->setText(text);
} else {
ui.cclabel->setVisible(false);
ui.ccText->setVisible(false);
ui.ccText->clear();
}
if (msgInfo.msgbcc.size() > 0) {
ui.bcclabel->setVisible(true);
ui.bccText->setVisible(true);
text.clear();
for(pit = msgInfo.msgbcc.begin(); pit != msgInfo.msgbcc.end(); pit++) {
if (link.createMessage(*pit, "")) {
text += link.toHtml() + " ";
}
}
ui.bccText->setText(text);
} else {
ui.bcclabel->setVisible(false);
ui.bccText->setVisible(false);
ui.bccText->clear();
}
{
QDateTime qtime;
qtime.setTime_t(msgInfo.ts);
QString timestamp = qtime.toString("dd.MM.yyyy hh:mm:ss");
ui.dateText->setText(timestamp);
}
std::string srcId;
if ((msgInfo.msgflags & RS_MSG_BOXMASK) == RS_MSG_OUTBOX) {
// outgoing message are from me
srcId = rsPeers->getOwnId();
} else {
srcId = msgInfo.srcId;
}
link.createMessage(srcId, "");
ui.fromText->setText(link.toHtml());
ui.fromText->setToolTip(PeerDefs::rsidFromId(srcId));
ui.subjectText->setText(QString::fromStdWString(msgInfo.title));
text = RsHtml::formatText(QString::fromStdWString(msgInfo.msg), RSHTML_FORMATTEXT_EMBED_SMILEYS | RSHTML_FORMATTEXT_EMBED_LINKS);
ui.msgText->setHtml(text);
ui.filesText->setText(QString("(%1 %2)").arg(msgInfo.count).arg(msgInfo.count == 1 ? tr("File") : tr("Files")));
showTagLabels();
}
void MessageWidget::remove()
{
MessageInfo msgInfo;
if (rsMsgs->getMessage(currMsgId, msgInfo) == false) {
std::cerr << "MessageWidget::fill() Couldn't find Msg" << std::endl;
return;
}
bool deleteReal = false;
if (msgInfo.msgflags & RS_MSG_TRASH) {
deleteReal = true;
} else {
if (QApplication::keyboardModifiers() & Qt::ShiftModifier) {
deleteReal = true;
}
}
if (deleteReal) {
rsMsgs->MessageDelete(currMsgId);
} else {
rsMsgs->MessageToTrash(currMsgId, true);
}
if (isWindow) {
window()->close();
} else {
deleteLater();
}
}
void MessageWidget::print()
{
#ifndef QT_NO_PRINTER
QPrinter printer(QPrinter::HighResolution);
printer.setFullPage(true);
QPrintDialog *dlg = new QPrintDialog(&printer, this);
if (ui.msgText->textCursor().hasSelection())
dlg->addEnabledOption(QAbstractPrintDialog::PrintSelection);
dlg->setWindowTitle(tr("Print Document"));
if (dlg->exec() == QDialog::Accepted) {
ui.msgText->print(&printer);
}
delete dlg;
#endif
}
void MessageWidget::printPreview()
{
PrintPreview *preview = new PrintPreview(ui.msgText->document(), this);
preview->setWindowModality(Qt::WindowModal);
preview->setAttribute(Qt::WA_DeleteOnClose);
preview->show();
/* window will destroy itself! */
}
void MessageWidget::saveAs()
{
QString filename;
if (misc::getSaveFileName(window(), RshareSettings::LASTDIR_MESSAGES, tr("Save as..."), tr("HTML-Files (*.htm *.html);;All Files (*)"), filename)) {
QFile file(filename);
if (!file.open(QFile::WriteOnly))
return;
QTextStream ts(&file);
ts.setCodec(QTextCodec::codecForName("UTF-8"));
ts << ui.msgText->document()->toHtml("UTF-8");
ui.msgText->document()->setModified(false);
}
}
void MessageWidget::reply()
{
/* put msg on msgBoard, and switch to it. */
if (currMsgId.empty()) {
return;
}
MessageComposer *msgComposer = MessageComposer::replyMsg(currMsgId, false);
if (msgComposer == NULL) {
return;
}
msgComposer->show();
msgComposer->activateWindow();
/* window will destroy itself! */
}
void MessageWidget::replyAll()
{
/* put msg on msgBoard, and switch to it. */
if (currMsgId.empty()) {
return;
}
MessageComposer *msgComposer = MessageComposer::replyMsg(currMsgId, true);
if (msgComposer == NULL) {
return;
}
msgComposer->show();
msgComposer->activateWindow();
/* window will destroy itself! */
}
void MessageWidget::forward()
{
/* put msg on msgBoard, and switch to it. */
if (currMsgId.empty()) {
return;
}
MessageComposer *msgComposer = MessageComposer::forwardMsg(currMsgId);
if (msgComposer == NULL) {
return;
}
msgComposer->show();
msgComposer->activateWindow();
/* window will destroy itself! */
}

View File

@ -0,0 +1,93 @@
/****************************************************************
* RetroShare is distributed under the following license:
*
* Copyright (C) 2006 - 2011, RetroShare Team
*
* 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., 51 Franklin Street, Fifth Floor,
* Boston, MA 02110-1301, USA.
****************************************************************/
#ifndef _MESSAGEWIDGET_H
#define _MESSAGEWIDGET_H
#include <QWidget>
#include "ui_MessageWidget.h"
class QToolButton;
class QAction;
class QTextEdit;
class MessageWidget : public QWidget
{
Q_OBJECT
public:
enum enumActionType {
ACTION_REMOVE,
ACTION_REPLY,
ACTION_REPLY_ALL,
ACTION_FORWARD,
ACTION_PRINT,
ACTION_PRINT_PREVIEW,
ACTION_SAVE_AS
};
public:
MessageWidget(bool controlled, QWidget *parent = 0, Qt::WFlags flags = 0);
~MessageWidget();
static MessageWidget *openMsg(const std::string &msgId, bool window);
std::string msgId() { return currMsgId; }
void connectAction(enumActionType actionType, QToolButton* button);
void connectAction(enumActionType actionType, QAction* action);
void fill(const std::string &msgId);
void processSettings(const QString &settingsGroup, bool load);
QString subject(bool noEmpty);
private slots:
void reply();
void replyAll();
void forward();
void remove();
void print();
void printPreview();
void saveAs();
void msgfilelistWidgetCostumPopupMenu(QPoint);
void messagesTagsChanged();
void messagesChanged();
void togglefileview();
void getcurrentrecommended();
void getallrecommended();
private:
void clearTagLabels();
void showTagLabels();
bool isControlled;
bool isWindow;
std::string currMsgId;
QList<QLabel*> tagLabels;
/** Qt Designer generated object */
Ui::MessageWidget ui;
};
#endif

View File

@ -0,0 +1,502 @@
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>MessageWidget</class>
<widget class="QWidget" name="MessageWidget">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>698</width>
<height>539</height>
</rect>
</property>
<property name="windowIcon">
<iconset resource="../images.qrc">
<normaloff>:/images/rstray3.png</normaloff>:/images/rstray3.png</iconset>
</property>
<layout class="QGridLayout" name="gridLayout">
<property name="leftMargin">
<number>0</number>
</property>
<property name="topMargin">
<number>2</number>
</property>
<property name="rightMargin">
<number>0</number>
</property>
<property name="bottomMargin">
<number>0</number>
</property>
<item row="0" column="0">
<widget class="QSplitter" name="msgSplitter">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<widget class="QSplitter" name="msgSplitter_2">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<widget class="QWidget" name="layoutWidget">
<layout class="QGridLayout" name="gridLayout_2">
<item row="1" column="0">
<widget class="QTextBrowser" name="msgText">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
<property name="openLinks">
<bool>true</bool>
</property>
</widget>
</item>
<item row="2" column="0">
<layout class="QHBoxLayout" name="_2">
<item>
<layout class="QGridLayout" name="_3">
<property name="margin">
<number>0</number>
</property>
<property name="spacing">
<number>6</number>
</property>
<item row="0" column="2">
<widget class="QLabel" name="label_6">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../images.qrc">:/images/attachment.png</pixmap>
</property>
</widget>
</item>
<item row="0" column="3">
<widget class="QLabel" name="label_2">
<property name="text">
<string>&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
p, li { white-space: pre-wrap; }
&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:'Arial'; font-size:8pt; font-weight:400; font-style:normal; text-decoration:none;&quot;&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-size:10pt; font-weight:600;&quot;&gt;Recommended Files&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
</widget>
</item>
<item row="0" column="4">
<widget class="QLabel" name="filesText">
<property name="font">
<font>
<pointsize>10</pointsize>
<italic>true</italic>
</font>
</property>
<property name="text">
<string/>
</property>
</widget>
</item>
</layout>
</item>
<item>
<spacer>
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>351</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QPushButton" name="downloadButton">
<property name="focusPolicy">
<enum>Qt::NoFocus</enum>
</property>
<property name="toolTip">
<string>Download all Recommended Files</string>
</property>
<property name="icon">
<iconset resource="../images.qrc">
<normaloff>:/images/down.png</normaloff>:/images/down.png</iconset>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="expandFilesButton">
<property name="focusPolicy">
<enum>Qt::NoFocus</enum>
</property>
<property name="text">
<string/>
</property>
<property name="icon">
<iconset resource="../images.qrc">
<normaloff>:/images/edit_remove24.png</normaloff>:/images/edit_remove24.png</iconset>
</property>
<property name="checkable">
<bool>true</bool>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item row="0" column="0">
<layout class="QHBoxLayout" name="_4">
<property name="leftMargin">
<number>6</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>6</number>
</property>
<property name="bottomMargin">
<number>0</number>
</property>
<item>
<layout class="QGridLayout" name="_5">
<property name="horizontalSpacing">
<number>6</number>
</property>
<property name="verticalSpacing">
<number>3</number>
</property>
<item row="0" column="0">
<widget class="QLabel" name="subjectlabel">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="font">
<font>
<pointsize>9</pointsize>
<weight>50</weight>
<bold>false</bold>
</font>
</property>
<property name="text">
<string>Subject:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="fromlabel">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="font">
<font>
<pointsize>9</pointsize>
<weight>50</weight>
<bold>false</bold>
</font>
</property>
<property name="text">
<string>From:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="1" column="2" colspan="2">
<widget class="QLabel" name="fromText">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>2</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>16777215</height>
</size>
</property>
<property name="font">
<font>
<pointsize>9</pointsize>
</font>
</property>
<property name="scaledContents">
<bool>true</bool>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="tolabel">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="font">
<font>
<pointsize>9</pointsize>
<weight>50</weight>
<bold>false</bold>
</font>
</property>
<property name="text">
<string>To:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="2" column="2" colspan="2">
<widget class="QLabel" name="toText">
<property name="wordWrap">
<bool>true</bool>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
</widget>
</item>
<item row="3" column="0">
<widget class="QLabel" name="cclabel">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="font">
<font>
<pointsize>9</pointsize>
<weight>50</weight>
<bold>false</bold>
</font>
</property>
<property name="text">
<string>Cc:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item row="4" column="0">
<widget class="QLabel" name="bcclabel">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="font">
<font>
<pointsize>9</pointsize>
<weight>50</weight>
<bold>false</bold>
</font>
</property>
<property name="text">
<string>Bcc:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="3" column="2" colspan="2">
<widget class="QLabel" name="ccText">
<property name="wordWrap">
<bool>true</bool>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
</widget>
</item>
<item row="4" column="2" colspan="2">
<widget class="QLabel" name="bccText">
<property name="wordWrap">
<bool>true</bool>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
</widget>
</item>
<item row="5" column="0">
<widget class="QLabel" name="tagsLabel">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="font">
<font>
<pointsize>9</pointsize>
<weight>50</weight>
<bold>false</bold>
</font>
</property>
<property name="text">
<string>Tags:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="5" column="2" colspan="2">
<layout class="QHBoxLayout" name="tagLayout"/>
</item>
<item row="0" column="2" colspan="2">
<layout class="QHBoxLayout" name="horizontalLayout_3">
<item>
<widget class="QLabel" name="subjectText">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="font">
<font>
<pointsize>9</pointsize>
</font>
</property>
<property name="wordWrap">
<bool>true</bool>
</property>
<property name="textInteractionFlags">
<set>Qt::LinksAccessibleByMouse|Qt::TextSelectableByMouse</set>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="dateText">
<property name="sizePolicy">
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="font">
<font>
<pointsize>9</pointsize>
</font>
</property>
<property name="layoutDirection">
<enum>Qt::LeftToRight</enum>
</property>
<property name="text">
<string notr="true">Date</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
<property name="textInteractionFlags">
<set>Qt::LinksAccessibleByMouse|Qt::TextSelectableByMouse</set>
</property>
</widget>
</item>
</layout>
</item>
</layout>
</item>
</layout>
</item>
</layout>
</widget>
</widget>
<widget class="QTreeWidget" name="msgList">
<property name="font">
<font>
<pointsize>9</pointsize>
</font>
</property>
<property name="contextMenuPolicy">
<enum>Qt::CustomContextMenu</enum>
</property>
<property name="sortingEnabled">
<bool>true</bool>
</property>
<column>
<property name="text">
<string>File Name</string>
</property>
</column>
<column>
<property name="text">
<string>Size</string>
</property>
</column>
<column>
<property name="text">
<string>Hash</string>
</property>
</column>
</widget>
</widget>
</item>
</layout>
<action name="actionPrint">
<property name="text">
<string>Print</string>
</property>
</action>
<action name="actionPrint_Preview">
<property name="text">
<string>Print Preview</string>
</property>
</action>
</widget>
<resources>
<include location="../images.qrc"/>
</resources>
<connections>
<connection>
<sender>expandFilesButton</sender>
<signal>clicked(bool)</signal>
<receiver>msgList</receiver>
<slot>setVisible(bool)</slot>
<hints>
<hint type="sourcelabel">
<x>672</x>
<y>334</y>
</hint>
<hint type="destinationlabel">
<x>348</x>
<y>432</y>
</hint>
</hints>
</connection>
</connections>
</ui>

View File

@ -0,0 +1,229 @@
/****************************************************************
* RetroShare is distributed under the following license:
*
* Copyright (C) 2006 - 2011 RetroShare Team
*
* 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., 51 Franklin Street, Fifth Floor,
* Boston, MA 02110-1301, USA.
****************************************************************/
#include "MessageWindow.h"
#include "MessageWidget.h"
#include "MessageComposer.h"
#include "TagsMenu.h"
#include "gui/settings/rsharesettings.h"
#include <retroshare/rsmsgs.h>
/** Constructor */
MessageWindow::MessageWindow(QWidget *parent, Qt::WFlags flags)
: RWindow("MessageWindow", parent, flags)
{
/* Invoke the Qt Designer generated object setup routine */
ui.setupUi(this);
setAttribute ( Qt::WA_DeleteOnClose, true );
actionSaveAs = NULL;
actionPrint = NULL;
actionPrintPreview = NULL;
setupFileActions();
connect(ui.newmessageButton, SIGNAL(clicked()), this, SLOT(newmessage()));
connect(ui.actionTextBesideIcon, SIGNAL(triggered()), this, SLOT(buttonStyle()));
connect(ui.actionIconOnly, SIGNAL(triggered()), this, SLOT(buttonStyle()));
connect(ui.actionTextUnderIcon, SIGNAL(triggered()), this, SLOT(buttonStyle()));
ui.actionTextBesideIcon->setData(Qt::ToolButtonTextBesideIcon);
ui.actionIconOnly->setData(Qt::ToolButtonIconOnly);
ui.actionTextUnderIcon->setData(Qt::ToolButtonTextUnderIcon);
msgWidget = NULL;
// create tag menu
TagsMenu *menu = new TagsMenu (tr("Tags"), this);
connect(menu, SIGNAL(aboutToShow()), this, SLOT(tagAboutToShow()));
connect(menu, SIGNAL(tagSet(int, bool)), this, SLOT(tagSet(int, bool)));
connect(menu, SIGNAL(tagRemoveAll()), this, SLOT(tagRemoveAll()));
ui.tagButton->setMenu(menu);
// create print menu
QMenu *printmenu = new QMenu();
printmenu->addAction(ui.actionPrint);
printmenu->addAction(ui.actionPrint_Preview);
ui.printbutton->setMenu(printmenu);
// create view menu
QMenu *viewmenu = new QMenu();
viewmenu->addAction(ui.actionTextBesideIcon);
viewmenu->addAction(ui.actionIconOnly);
//viewmenu->addAction(ui.actionTextUnderIcon);
ui.viewtoolButton->setMenu(viewmenu);
processSettings(true);
/* Hide platform specific features */
#ifdef Q_WS_WIN
#endif
}
MessageWindow::~MessageWindow()
{
processSettings(false);
}
void MessageWindow::processSettings(bool load)
{
Settings->beginGroup(QString("MessageDialog"));
if (load) {
// load settings
/* toolbar button style */
Qt::ToolButtonStyle style = (Qt::ToolButtonStyle) Settings->value("ToolButon_Stlye", Qt::ToolButtonIconOnly).toInt();
setToolbarButtonStyle(style);
} else {
// save settings
/* toolbar button style */
Settings->setValue("ToolButon_Stlye", ui.newmessageButton->toolButtonStyle());
}
Settings->endGroup();
}
void MessageWindow::addWidget(MessageWidget *widget)
{
if (msgWidget) {
delete(msgWidget);
}
msgWidget = widget;
if (msgWidget) {
ui.msgLayout->addWidget(msgWidget);
setWindowTitle(msgWidget->subject(true));
msgWidget->connectAction(MessageWidget::ACTION_REMOVE, ui.removemessageButton);
msgWidget->connectAction(MessageWidget::ACTION_REPLY, ui.replymessageButton);
msgWidget->connectAction(MessageWidget::ACTION_REPLY_ALL, ui.replyallmessageButton);
msgWidget->connectAction(MessageWidget::ACTION_FORWARD, ui.forwardmessageButton);
msgWidget->connectAction(MessageWidget::ACTION_PRINT, ui.printbutton);
msgWidget->connectAction(MessageWidget::ACTION_PRINT, ui.actionPrint);
msgWidget->connectAction(MessageWidget::ACTION_PRINT, actionPrint);
msgWidget->connectAction(MessageWidget::ACTION_PRINT_PREVIEW, ui.actionPrint_Preview);
msgWidget->connectAction(MessageWidget::ACTION_PRINT_PREVIEW, actionPrintPreview);
// msgWidget->connectAction(ACTION_SAVE,
msgWidget->connectAction(MessageWidget::ACTION_SAVE_AS, actionSaveAs);
} else {
setWindowTitle("");
}
}
void MessageWindow::newmessage()
{
MessageComposer *msgComposer = MessageComposer::newMsg();
if (msgComposer == NULL) {
return;
}
/* fill it in */
msgComposer->show();
msgComposer->activateWindow();
/* window will destroy itself! */
}
void MessageWindow::tagAboutToShow()
{
if (msgWidget == NULL) {
return;
}
TagsMenu *menu = dynamic_cast<TagsMenu*>(ui.tagButton->menu());
if (menu == NULL) {
return;
}
// activate actions
MsgTagInfo tagInfo;
rsMsgs->getMessageTag(msgWidget->msgId(), tagInfo);
menu->activateActions(tagInfo.tagIds);
}
void MessageWindow::tagRemoveAll()
{
if (msgWidget == NULL) {
return;
}
rsMsgs->setMessageTag(msgWidget->msgId(), 0, false);
}
void MessageWindow::tagSet(int tagId, bool set)
{
if (msgWidget == NULL) {
return;
}
if (tagId == 0) {
return;
}
rsMsgs->setMessageTag(msgWidget->msgId(), tagId, set);
}
void MessageWindow::setupFileActions()
{
QMenu *menu = new QMenu(tr("&File"), this);
menuBar()->addMenu(menu);
actionSaveAs = menu->addAction(tr("Save &As File"));
actionPrint = menu->addAction(QIcon(":/images/textedit/fileprint.png"), tr("&Print..."));
actionPrint->setShortcut(QKeySequence::Print);
actionPrintPreview = menu->addAction(QIcon(":/images/textedit/fileprint.png"), tr("Print Preview..."));
// a = new QAction(QIcon(":/images/textedit/exportpdf.png"), tr("&Export PDF..."), this);
// a->setShortcut(Qt::CTRL + Qt::Key_D);
// connect(a, SIGNAL(triggered()), this, SLOT(filePrintPdf()));
// menu->addAction(a);
menu->addSeparator();
QAction *action = menu->addAction(tr("&Quit"), this, SLOT(close()));
action->setShortcut(Qt::CTRL + Qt::Key_Q);
}
void MessageWindow::setToolbarButtonStyle(Qt::ToolButtonStyle style)
{
ui.newmessageButton->setToolButtonStyle(style);
ui.removemessageButton->setToolButtonStyle(style);
ui.replymessageButton->setToolButtonStyle(style);
ui.replyallmessageButton->setToolButtonStyle(style);
ui.forwardmessageButton->setToolButtonStyle(style);
ui.tagButton->setToolButtonStyle(style);
ui.printbutton->setToolButtonStyle(style);
ui.viewtoolButton->setToolButtonStyle(style);
}
void MessageWindow::buttonStyle()
{
setToolbarButtonStyle((Qt::ToolButtonStyle) dynamic_cast<QAction*>(sender())->data().toInt());
}

View File

@ -0,0 +1,64 @@
/****************************************************************
* RetroShare is distributed under the following license:
*
* Copyright (C) 2006 - 2011, RetroShare Team
*
* 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., 51 Franklin Street, Fifth Floor,
* Boston, MA 02110-1301, USA.
****************************************************************/
#ifndef _MESSAGEWINDOW_H
#define _MESSAGEWINDOW_H
#include "gui/common/rwindow.h"
#include "ui_MessageWindow.h"
class MessageWidget;
class MessageWindow : public RWindow
{
Q_OBJECT
public:
/** Default Constructor */
MessageWindow(QWidget *parent = 0, Qt::WFlags flags = 0);
~MessageWindow();
void addWidget(MessageWidget *widget);
private slots:
void newmessage();
void tagAboutToShow();
void tagSet(int tagId, bool set);
void tagRemoveAll();
void buttonStyle();
private:
void setupFileActions();
void processSettings(bool load);
void setToolbarButtonStyle(Qt::ToolButtonStyle style);
MessageWidget *msgWidget;
QAction *actionSaveAs;
QAction *actionPrint;
QAction *actionPrintPreview;
/** Qt Designer generated object */
Ui::MessageWindow ui;
};
#endif

View File

@ -0,0 +1,400 @@
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>MessageWindow</class>
<widget class="QMainWindow" name="MessageWindow">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>698</width>
<height>539</height>
</rect>
</property>
<property name="windowIcon">
<iconset resource="../images.qrc">
<normaloff>:/images/rstray3.png</normaloff>:/images/rstray3.png</iconset>
</property>
<widget class="QWidget" name="centralwidget">
<layout class="QGridLayout" name="gridLayout">
<property name="verticalSpacing">
<number>0</number>
</property>
<property name="margin">
<number>0</number>
</property>
<item row="0" column="0">
<widget class="QFrame" name="frame">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>36</height>
</size>
</property>
<property name="baseSize">
<size>
<width>0</width>
<height>68</height>
</size>
</property>
<property name="styleSheet">
<string notr="true">QFrame#frame{
background-color: qlineargradient(x1:0, y1:0, x2:0, y2:1,
stop:0 #FEFEFE, stop:1 #E8E8E8);
border: 1px solid #CCCCCC;}</string>
</property>
<property name="frameShape">
<enum>QFrame::StyledPanel</enum>
</property>
<property name="frameShadow">
<enum>QFrame::Raised</enum>
</property>
<layout class="QGridLayout" name="gridLayout_3">
<property name="margin">
<number>2</number>
</property>
<property name="horizontalSpacing">
<number>6</number>
</property>
<item row="0" column="0">
<widget class="QToolButton" name="newmessageButton">
<property name="focusPolicy">
<enum>Qt::NoFocus</enum>
</property>
<property name="toolTip">
<string>New Message</string>
</property>
<property name="text">
<string>Compose</string>
</property>
<property name="icon">
<iconset resource="../images.qrc">
<normaloff>:/images/folder-draft24.png</normaloff>:/images/folder-draft24.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonIconOnly</enum>
</property>
<property name="autoRaise">
<bool>true</bool>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="Line" name="line">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
</widget>
</item>
<item row="0" column="2">
<widget class="QToolButton" name="replymessageButton">
<property name="focusPolicy">
<enum>Qt::NoFocus</enum>
</property>
<property name="toolTip">
<string>Reply to selected message</string>
</property>
<property name="text">
<string>Reply</string>
</property>
<property name="icon">
<iconset resource="../images.qrc">
<normaloff>:/images/replymail-pressed.png</normaloff>:/images/replymail-pressed.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonIconOnly</enum>
</property>
<property name="autoRaise">
<bool>true</bool>
</property>
</widget>
</item>
<item row="0" column="3">
<widget class="QToolButton" name="replyallmessageButton">
<property name="focusPolicy">
<enum>Qt::NoFocus</enum>
</property>
<property name="toolTip">
<string>Reply all to selected message</string>
</property>
<property name="text">
<string>Reply all</string>
</property>
<property name="icon">
<iconset resource="../images.qrc">
<normaloff>:/images/replymailall24-hover.png</normaloff>:/images/replymailall24-hover.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonIconOnly</enum>
</property>
<property name="autoRaise">
<bool>true</bool>
</property>
</widget>
</item>
<item row="0" column="4">
<widget class="QToolButton" name="forwardmessageButton">
<property name="minimumSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>16777</width>
<height>16777</height>
</size>
</property>
<property name="focusPolicy">
<enum>Qt::NoFocus</enum>
</property>
<property name="toolTip">
<string>Forward selected message</string>
</property>
<property name="text">
<string>Foward</string>
</property>
<property name="icon">
<iconset resource="../images.qrc">
<normaloff>:/images/mailforward24-hover.png</normaloff>:/images/mailforward24-hover.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonIconOnly</enum>
</property>
<property name="autoRaise">
<bool>true</bool>
</property>
</widget>
</item>
<item row="0" column="5">
<widget class="Line" name="line_2">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
</widget>
</item>
<item row="0" column="7">
<widget class="QToolButton" name="removemessageButton">
<property name="focusPolicy">
<enum>Qt::NoFocus</enum>
</property>
<property name="toolTip">
<string>Remove selected message</string>
</property>
<property name="text">
<string>Delete</string>
</property>
<property name="icon">
<iconset resource="../images.qrc">
<normaloff>:/images/deletemail24.png</normaloff>:/images/deletemail24.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonIconOnly</enum>
</property>
<property name="autoRaise">
<bool>true</bool>
</property>
</widget>
</item>
<item row="0" column="8">
<widget class="QToolButton" name="printbutton">
<property name="focusPolicy">
<enum>Qt::NoFocus</enum>
</property>
<property name="toolTip">
<string>Print selected message</string>
</property>
<property name="text">
<string>Print</string>
</property>
<property name="icon">
<iconset resource="../images.qrc">
<normaloff>:/images/print24.png</normaloff>:/images/print24.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
<property name="popupMode">
<enum>QToolButton::MenuButtonPopup</enum>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonIconOnly</enum>
</property>
<property name="autoRaise">
<bool>true</bool>
</property>
</widget>
</item>
<item row="0" column="9">
<widget class="QToolButton" name="viewtoolButton">
<property name="focusPolicy">
<enum>Qt::NoFocus</enum>
</property>
<property name="text">
<string>Display</string>
</property>
<property name="icon">
<iconset resource="../images.qrc">
<normaloff>:/images/looknfeel.png</normaloff>:/images/looknfeel.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
<property name="popupMode">
<enum>QToolButton::MenuButtonPopup</enum>
</property>
<property name="autoRaise">
<bool>true</bool>
</property>
</widget>
</item>
<item row="0" column="10">
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="0" column="6">
<widget class="QToolButton" name="tagButton">
<property name="focusPolicy">
<enum>Qt::NoFocus</enum>
</property>
<property name="toolTip">
<string>Tags</string>
</property>
<property name="text">
<string>Tags</string>
</property>
<property name="icon">
<iconset resource="../images.qrc">
<normaloff>:/images/tag24.png</normaloff>:/images/tag24.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
<property name="popupMode">
<enum>QToolButton::MenuButtonPopup</enum>
</property>
<property name="autoRaise">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item row="1" column="0">
<layout class="QGridLayout" name="msgLayout"/>
</item>
</layout>
</widget>
<widget class="QStatusBar" name="statusbar"/>
<widget class="QMenuBar" name="menuBar">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>698</width>
<height>20</height>
</rect>
</property>
</widget>
<action name="actionPrint">
<property name="text">
<string>Print</string>
</property>
</action>
<action name="actionPrint_Preview">
<property name="text">
<string>Print Preview</string>
</property>
</action>
<action name="actionIconOnly">
<property name="text">
<string>Buttons Icon Only</string>
</property>
<property name="toolTip">
<string>Buttons Icon Only</string>
</property>
</action>
<action name="actionTextBesideIcon">
<property name="text">
<string>Buttons Text Beside Icon</string>
</property>
<property name="toolTip">
<string>Buttons with Text</string>
</property>
</action>
<action name="actionTextUnderIcon">
<property name="text">
<string>Buttons Text Under Icon</string>
</property>
<property name="toolTip">
<string>Set Text Under Icon</string>
</property>
</action>
</widget>
<resources>
<include location="../images.qrc"/>
</resources>
<connections/>
</ui>

View File

@ -47,6 +47,9 @@ MessagePage::MessagePage(QWidget * parent, Qt::WFlags flags)
ui.editpushButton->setEnabled(false);
ui.deletepushButton->setEnabled(false);
ui.openComboBox->addItem(tr("A new tab"), RshareSettings::MSG_OPEN_TAB);
ui.openComboBox->addItem(tr("A new window"), RshareSettings::MSG_OPEN_WINDOW);
}
MessagePage::~MessagePage()
@ -65,6 +68,7 @@ bool
MessagePage::save(QString &errmsg)
{
Settings->setMsgSetToReadOnActivate(ui.setMsgToReadOnActivate->isChecked());
Settings->setMsgOpen((RshareSettings::enumMsgOpen) ui.openComboBox->itemData(ui.openComboBox->currentIndex()).toInt());
std::map<uint32_t, std::pair<std::string, uint32_t> >::iterator Tag;
for (Tag = m_pTags->types.begin(); Tag != m_pTags->types.end(); Tag++) {
@ -92,6 +96,7 @@ void
MessagePage::load()
{
ui.setMsgToReadOnActivate->setChecked(Settings->getMsgSetToReadOnActivate());
ui.openComboBox->setCurrentIndex(ui.openComboBox->findData(Settings->getMsgOpen()));
// fill items
rsMsgs->getMessageTagTypes(*m_pTags);

View File

@ -503,7 +503,7 @@
<item row="0" column="0">
<widget class="QGroupBox" name="groupBox">
<property name="title">
<string>Misc</string>
<string>Reading</string>
</property>
<layout class="QGridLayout" name="gridLayout_2">
<item row="0" column="0">
@ -513,6 +513,20 @@
</property>
</widget>
</item>
<item row="2" column="0">
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<widget class="QLabel" name="openLabel">
<property name="text">
<string>Open messages in</string>
</property>
</widget>
</item>
<item>
<widget class="QComboBox" name="openComboBox"/>
</item>
</layout>
</item>
</layout>
</widget>
</item>

View File

@ -627,6 +627,32 @@ void RshareSettings::setMsgSetToReadOnActivate (bool bValue)
setValueToGroup("MessageDialog", "SetMsgToReadOnActivate", bValue);
}
RshareSettings::enumMsgOpen RshareSettings::getMsgOpen()
{
enumMsgOpen value = (enumMsgOpen) valueFromGroup("MessageDialog", "msgOpen", MSG_OPEN_TAB).toInt();
switch (value) {
case MSG_OPEN_TAB:
case MSG_OPEN_WINDOW:
return value;
}
return MSG_OPEN_TAB;
}
void RshareSettings::setMsgOpen(enumMsgOpen value)
{
switch (value) {
case MSG_OPEN_TAB:
case MSG_OPEN_WINDOW:
break;
default:
value = MSG_OPEN_TAB;
}
setValueToGroup("MessageDialog", "msgOpen", value);
}
/* Forums */
bool RshareSettings::getForumMsgSetToReadOnActivate ()
{

View File

@ -75,6 +75,12 @@ public:
TOASTERPOS_BOTTOMRIGHT
};
enum enumMsgOpen
{
MSG_OPEN_TAB,
MSG_OPEN_WINDOW
};
public:
/* create settings object */
static void Create ();
@ -210,6 +216,9 @@ public:
bool getMsgSetToReadOnActivate ();
void setMsgSetToReadOnActivate (bool bValue);
enumMsgOpen getMsgOpen();
void setMsgOpen(enumMsgOpen value);
/* Forums */
bool getForumMsgSetToReadOnActivate ();
void setForumMsgSetToReadOnActivate (bool bValue);

View File

@ -4370,7 +4370,7 @@ p, li { white-space: pre-wrap; }
<translation type="unfinished">Willst du diesen Freund entfernen?</translation>
</message>
<message>
<location line="+85"/>
<location line="+84"/>
<source>is typing...</source>
<translation type="unfinished">tippt...</translation>
</message>
@ -6604,9 +6604,13 @@ Willst Du die Nachricht speichern ?</translation>
<context>
<name>MessagePage</name>
<message>
<location filename="../gui/settings/MessagePage.ui" line="+506"/>
<source>Misc</source>
<translation>Verschiedenes</translation>
<translation type="obsolete">Verschiedenes</translation>
</message>
<message>
<location filename="../gui/settings/MessagePage.ui" line="+506"/>
<source>Reading</source>
<translation>Lesen</translation>
</message>
<message>
<location line="+6"/>
@ -6614,7 +6618,12 @@ Willst Du die Nachricht speichern ?</translation>
<translation>Setze Nachricht beim Aktivieren als gelesen</translation>
</message>
<message>
<location line="+10"/>
<location line="+9"/>
<source>Open messages in</source>
<translation>Nachricht durch Doppelklick öffnen in</translation>
</message>
<message>
<location line="+15"/>
<source>Tags</source>
<translation>Schlagwörter</translation>
</message>
@ -6644,7 +6653,17 @@ Willst Du die Nachricht speichern ?</translation>
<translation>Standard</translation>
</message>
<message>
<location filename="../gui/settings/MessagePage.cpp" line="+147"/>
<location filename="../gui/settings/MessagePage.cpp" line="+51"/>
<source>A new tab</source>
<translation>Neuem Tab</translation>
</message>
<message>
<location line="+1"/>
<source>A new window</source>
<translation>Neuem Fenster</translation>
</message>
<message>
<location line="+100"/>
<source>Edit Tag</source>
<translation>Schlagwort bearbeiten</translation>
</message>
@ -6673,43 +6692,13 @@ Willst Du die Nachricht speichern ?</translation>
</message>
</context>
<context>
<name>MessagesDialog</name>
<name>MessageWidget</name>
<message>
<location filename="../gui/MessagesDialog.ui" line="+576"/>
<location filename="../gui/MessagesDialog.cpp" line="+614"/>
<source>New Message</source>
<translation>Neue Nachricht</translation>
<source>MainWindow</source>
<translation type="obsolete">Hauptfenster</translation>
</message>
<message>
<location filename="../gui/MessagesDialog.cpp" line="-59"/>
<source>Reply to Message</source>
<translation>Antworten nur an Absender</translation>
</message>
<message>
<location line="+41"/>
<source>Remove Message</source>
<translation>Nachricht entfernen</translation>
</message>
<message>
<location filename="../gui/MessagesDialog.ui" line="+393"/>
<location filename="../gui/MessagesDialog.cpp" line="-382"/>
<source>Date</source>
<translation>Datum</translation>
</message>
<message>
<location line="-5"/>
<location filename="../gui/MessagesDialog.cpp" line="-1"/>
<location line="+829"/>
<source>From</source>
<translation>Von</translation>
</message>
<message>
<location line="+778"/>
<source>Size</source>
<translation>Grösse</translation>
</message>
<message>
<location line="-381"/>
<location filename="../gui/msgs/MessageWidget.ui" line="+80"/>
<source>&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
p, li { white-space: pre-wrap; }
&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:&apos;Arial&apos;; font-size:8pt; font-weight:400; font-style:normal; text-decoration:none;&quot;&gt;
@ -6717,7 +6706,306 @@ p, li { white-space: pre-wrap; }
<translation>&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;p, li { white-space: pre-wrap; }&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:&apos;Arial&apos;; font-size:8pt; font-weight:400; font-style:normal; text-decoration:none;&quot;&gt;&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-size:10pt; font-weight:600;&quot;&gt;Empfohlene Dateien&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</translation>
</message>
<message>
<location line="-722"/>
<location line="+41"/>
<source>Download all Recommended Files</source>
<translation>Alle Dateien runterladen</translation>
</message>
<message>
<location line="+68"/>
<source>Subject:</source>
<translation>Betreff:</translation>
</message>
<message>
<location line="+23"/>
<source>From:</source>
<translation>Von:</translation>
</message>
<message>
<location line="+56"/>
<source>To:</source>
<translation>An:</translation>
</message>
<message>
<location line="+33"/>
<source>Cc:</source>
<translation>Cc:</translation>
</message>
<message>
<location line="+26"/>
<source>Bcc:</source>
<translation>Bcc:</translation>
</message>
<message>
<location line="+43"/>
<source>Tags:</source>
<translation>Schlagwörter:</translation>
</message>
<message>
<location line="+83"/>
<source>File Name</source>
<translation>Dateiname</translation>
</message>
<message>
<location line="+5"/>
<source>Size</source>
<translation>Grösse</translation>
</message>
<message>
<location line="+5"/>
<source>Hash</source>
<translation>Prüfsumme</translation>
</message>
<message>
<location line="+9"/>
<source>Print</source>
<translation>Drucken</translation>
</message>
<message>
<location line="+5"/>
<source>Print Preview</source>
<translation>Druckvorschau</translation>
</message>
<message>
<location filename="../gui/msgs/MessageWidget.cpp" line="+223"/>
<source>No subject</source>
<translation>Kein Betreff</translation>
</message>
<message>
<location line="+10"/>
<source>Download</source>
<translation>Herunterladen</translation>
</message>
<message>
<location line="+1"/>
<source>Download all</source>
<translation>Alle herunterladen</translation>
</message>
<message>
<location line="+13"/>
<source>Hide</source>
<translation>Verbergen</translation>
</message>
<message>
<location line="+3"/>
<source>Expand</source>
<translation>Erweitern</translation>
</message>
<message>
<location line="+271"/>
<source>File</source>
<translation>Datei</translation>
</message>
<message>
<location line="+0"/>
<source>Files</source>
<translation>Dateien</translation>
</message>
<message>
<location line="+43"/>
<source>Print Document</source>
<translation>Dokument drucken</translation>
</message>
<message>
<location line="+21"/>
<source>Save as...</source>
<translation>Speichern unter...</translation>
</message>
<message>
<location line="+0"/>
<source>HTML-Files (*.htm *.html);;All Files (*)</source>
<translation>HTML-Dateien (*.htm *.html);;Alle Dateien (*)</translation>
</message>
</context>
<context>
<name>MessageWindow</name>
<message>
<source>MainWindow</source>
<translation type="obsolete">Hauptfenster</translation>
</message>
<message>
<location filename="../gui/msgs/MessageWindow.ui" line="+77"/>
<source>New Message</source>
<translation>Neue Nachricht</translation>
</message>
<message>
<location line="+3"/>
<source>Compose</source>
<translation>Verfassen</translation>
</message>
<message>
<location line="+33"/>
<source>Reply to selected message</source>
<translation>Auf gewählte Nachricht antworten</translation>
</message>
<message>
<location line="+3"/>
<source>Reply</source>
<translation>Antwort</translation>
</message>
<message>
<location line="+26"/>
<source>Reply all to selected message</source>
<translation>Auf gewählte Nachricht an alle Empfänger antworten</translation>
</message>
<message>
<location line="+3"/>
<source>Reply all</source>
<translation>Allen antworten</translation>
</message>
<message>
<location line="+38"/>
<source>Forward selected message</source>
<translation>Gewählte Nachricht weiterleiten</translation>
</message>
<message>
<location line="+3"/>
<source>Foward</source>
<translation>Weiterleiten</translation>
</message>
<message>
<location line="+33"/>
<source>Remove selected message</source>
<translation>Gewählte Nachricht entfernen</translation>
</message>
<message>
<location line="+3"/>
<source>Delete</source>
<translation>Löschen</translation>
</message>
<message>
<location line="+26"/>
<source>Print selected message</source>
<translation>Gewählte Nachricht drucken</translation>
</message>
<message>
<location line="+3"/>
<location line="+112"/>
<source>Print</source>
<translation>Drucken</translation>
</message>
<message>
<location line="-83"/>
<source>Display</source>
<translation>Anzeige</translation>
</message>
<message>
<location line="+39"/>
<location line="+3"/>
<location filename="../gui/msgs/MessageWindow.cpp" line="+58"/>
<source>Tags</source>
<translation>Schlagwörter</translation>
</message>
<message>
<location line="+46"/>
<source>Print Preview</source>
<translation>Druckvorschau</translation>
</message>
<message>
<location line="+5"/>
<location line="+3"/>
<source>Buttons Icon Only</source>
<translation>Buttons nur mit Icon</translation>
</message>
<message>
<location line="+5"/>
<source>Buttons Text Beside Icon</source>
<translation>Button Text neben Icon</translation>
</message>
<message>
<location line="+3"/>
<source>Buttons with Text</source>
<translation>Buttons mit Text</translation>
</message>
<message>
<location line="+5"/>
<source>Buttons Text Under Icon</source>
<translation>Buttons Text unter dem Icon</translation>
</message>
<message>
<location line="+3"/>
<source>Set Text Under Icon</source>
<translation>Text unter dem Icon</translation>
</message>
<message>
<location filename="../gui/msgs/MessageWindow.cpp" line="+136"/>
<source>&amp;File</source>
<translation>&amp;Datei</translation>
</message>
<message>
<location line="+3"/>
<source>Save &amp;As File</source>
<translation>Speichern &amp;unter</translation>
</message>
<message>
<location line="+1"/>
<source>&amp;Print...</source>
<translation>&amp;Drucken...</translation>
</message>
<message>
<location line="+3"/>
<source>Print Preview...</source>
<translation>Druckvorschau...</translation>
</message>
<message>
<location line="+9"/>
<source>&amp;Quit</source>
<translation>&amp;Schliessen</translation>
</message>
</context>
<context>
<name>MessagesDialog</name>
<message>
<location filename="../gui/MessagesDialog.ui" line="+576"/>
<location filename="../gui/MessagesDialog.cpp" line="+603"/>
<source>New Message</source>
<translation>Neue Nachricht</translation>
</message>
<message>
<location filename="../gui/MessagesDialog.cpp" line="-65"/>
<source>Reply to Message</source>
<translation>Antworten nur an Absender</translation>
</message>
<message>
<location line="-12"/>
<source>Open in a new window</source>
<translation>In neuem Fenster öffnen</translation>
</message>
<message>
<location line="+5"/>
<source>Open in a new tab</source>
<translation>In neuem Tab öffnen</translation>
</message>
<message>
<location line="+54"/>
<source>Remove Message</source>
<translation>Nachricht entfernen</translation>
</message>
<message>
<location filename="../gui/MessagesDialog.ui" line="+393"/>
<location filename="../gui/MessagesDialog.cpp" line="-397"/>
<source>Date</source>
<translation>Datum</translation>
</message>
<message>
<location line="-5"/>
<location filename="../gui/MessagesDialog.cpp" line="-1"/>
<location line="+705"/>
<source>From</source>
<translation>Von</translation>
</message>
<message>
<source>Size</source>
<translation type="obsolete">Grösse</translation>
</message>
<message>
<source>&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
p, li { white-space: pre-wrap; }
&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:&apos;Arial&apos;; font-size:8pt; font-weight:400; font-style:normal; text-decoration:none;&quot;&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-size:10pt; font-weight:600;&quot;&gt;Recommended Files&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</source>
<translation type="obsolete">&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;p, li { white-space: pre-wrap; }&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:&apos;Arial&apos;; font-size:8pt; font-weight:400; font-style:normal; text-decoration:none;&quot;&gt;&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-size:10pt; font-weight:600;&quot;&gt;Empfohlene Dateien&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</translation>
</message>
<message>
<location line="-325"/>
<source>Reply</source>
<translation>Antworten</translation>
</message>
@ -6783,16 +7071,16 @@ p, li { white-space: pre-wrap; }
</message>
<message>
<location line="+180"/>
<location filename="../gui/MessagesDialog.cpp" line="-44"/>
<location line="+1041"/>
<location filename="../gui/MessagesDialog.cpp" line="-46"/>
<location line="+806"/>
<location line="+10"/>
<source>Inbox</source>
<translation>Posteingang</translation>
</message>
<message>
<location line="+9"/>
<location filename="../gui/MessagesDialog.cpp" line="-1046"/>
<location line="+1059"/>
<location filename="../gui/MessagesDialog.cpp" line="-812"/>
<location line="+825"/>
<location line="+8"/>
<source>Outbox</source>
<translation>Postausgang</translation>
@ -6804,32 +7092,28 @@ p, li { white-space: pre-wrap; }
</message>
<message>
<location line="+9"/>
<location filename="../gui/MessagesDialog.cpp" line="-1057"/>
<location filename="../gui/MessagesDialog.cpp" line="-825"/>
<source>Sent</source>
<translation>Gesendet</translation>
</message>
<message>
<location line="+241"/>
<source>Download all Recommended Files</source>
<translation>Alle Dateien runterladen</translation>
<translation type="obsolete">Alle Dateien runterladen</translation>
</message>
<message>
<location line="+180"/>
<source>Cc:</source>
<translation>Cc:</translation>
<translation type="obsolete">Cc:</translation>
</message>
<message>
<location line="+26"/>
<source>Bcc:</source>
<translation>Bcc:</translation>
<translation type="obsolete">Bcc:</translation>
</message>
<message>
<location line="+43"/>
<source>Tags:</source>
<translation>Schlagwörter:</translation>
<translation type="obsolete">Schlagwörter:</translation>
</message>
<message>
<location line="+110"/>
<location line="+173"/>
<location line="+3"/>
<source>Print...</source>
<translation>Drucken...</translation>
@ -6871,63 +7155,67 @@ p, li { white-space: pre-wrap; }
<translation>Speichern unter...</translation>
</message>
<message>
<location filename="../gui/MessagesDialog.cpp" line="+813"/>
<source>Print Document</source>
<translation>Dokument drucken</translation>
<translation type="obsolete">Dokument drucken</translation>
</message>
<message>
<location filename="../gui/MessagesDialog.ui" line="-839"/>
<location filename="../gui/MessagesDialog.cpp" line="-1615"/>
<location line="-412"/>
<location filename="../gui/MessagesDialog.cpp" line="-673"/>
<source>Subject</source>
<translation>Betreff</translation>
</message>
<message>
<location line="+511"/>
<source>Subject:</source>
<translation>Betreff:</translation>
<translation type="obsolete">Betreff:</translation>
</message>
<message>
<location line="+23"/>
<source>From:</source>
<translation>Von:</translation>
<translation type="obsolete">Von:</translation>
</message>
<message>
<location line="+56"/>
<source>To:</source>
<translation>An:</translation>
<translation type="obsolete">An:</translation>
</message>
<message>
<location line="+188"/>
<source>File Name</source>
<translation>Dateiname</translation>
<translation type="obsolete">Dateiname</translation>
</message>
<message>
<location line="+10"/>
<source>Hash</source>
<translation>Prüfsumme</translation>
<translation type="obsolete">Prüfsumme</translation>
</message>
<message>
<location line="-928"/>
<location line="-140"/>
<source>Print</source>
<translation>Drucken</translation>
</message>
<message>
<location filename="../gui/MessagesDialog.cpp" line="+70"/>
<location filename="../gui/MessagesDialog.cpp" line="+57"/>
<source>Forward selected Message</source>
<translation>Gewählte Nachricht weiterleiten</translation>
</message>
<message>
<location line="+315"/>
<location line="+311"/>
<source>Edit</source>
<translation>Bearbeiten</translation>
</message>
<message>
<location line="+2"/>
<source>Edit as new</source>
<translation>Als neu bearbeiten</translation>
</message>
<message>
<location line="+30"/>
<source>Remove Messages</source>
<translation>Nachrichten entfernen</translation>
</message>
<message>
<location line="-33"/>
<location line="-39"/>
<source>Forward Message</source>
<translation>Weiterleiten</translation>
</message>
<message>
<location line="-344"/>
<location line="-353"/>
<source>Click to sort by attachments</source>
<translation>Klicken, um nach Anhang zu sortieren</translation>
</message>
@ -6943,12 +7231,12 @@ p, li { white-space: pre-wrap; }
</message>
<message>
<location line="+1"/>
<location line="+821"/>
<location line="+697"/>
<source>Click to sort by from</source>
<translation>Klicken, um nach Von zu sortieren</translation>
</message>
<message>
<location line="-820"/>
<location line="-696"/>
<source>Click to sort by date</source>
<translation>Klicken, um nach Datum zu sortieren</translation>
</message>
@ -6962,48 +7250,41 @@ p, li { white-space: pre-wrap; }
<translation type="obsolete">Klicken, um nach Kennzeichnung zu sortieren</translation>
</message>
<message>
<location line="+400"/>
<source>Download</source>
<translation>Herunterladen</translation>
<translation type="obsolete">Herunterladen</translation>
</message>
<message>
<location line="+140"/>
<source>Hide</source>
<translation>Empfohlene Dateien ausblenden</translation>
<translation type="obsolete">Empfohlene Dateien ausblenden</translation>
</message>
<message>
<location line="+3"/>
<source>Expand</source>
<translation>Empfohlene Dateien einblenden</translation>
<translation type="obsolete">Empfohlene Dateien einblenden</translation>
</message>
<message>
<location line="+279"/>
<location line="+698"/>
<source>Click to sort by to</source>
<translation>Klicken, um nach Empfänger zu sortieren</translation>
</message>
<message>
<location line="+676"/>
<source>File</source>
<translation>Datei</translation>
<translation type="obsolete">Datei</translation>
</message>
<message>
<location line="+0"/>
<source>Files</source>
<translation>Dateien</translation>
<translation type="obsolete">Dateien</translation>
</message>
<message>
<location line="+137"/>
<source>Save as...</source>
<translation>Speichern unter...</translation>
<translation type="obsolete">Speichern unter...</translation>
</message>
<message>
<location line="+1"/>
<source>HTML-Files (*.htm *.html);;All Files (*)</source>
<translation>HTML-Dateien (*.htm *.html);;Alle Dateien (*)</translation>
<translation type="obsolete">HTML-Dateien (*.htm *.html);;Alle Dateien (*)</translation>
</message>
<message>
<location line="-1578"/>
<location line="+277"/>
<location line="-653"/>
<location line="+299"/>
<source>Reply to All</source>
<translation>Allen antworten</translation>
</message>
@ -7021,27 +7302,27 @@ p, li { white-space: pre-wrap; }
</message>
<message>
<location line="-277"/>
<location filename="../gui/MessagesDialog.cpp" line="-343"/>
<location filename="../gui/MessagesDialog.cpp" line="-352"/>
<source>Content</source>
<translation>Inhalt</translation>
</message>
<message>
<location line="+5"/>
<location line="+11"/>
<location line="+3"/>
<location filename="../gui/MessagesDialog.cpp" line="-1"/>
<location line="+113"/>
<location line="+90"/>
<source>Tags</source>
<translation>Schlagwörter</translation>
</message>
<message>
<location line="+3"/>
<source>Tag</source>
<translation>Schlagwort</translation>
<translation type="obsolete">Schlagwort</translation>
</message>
<message>
<location line="+177"/>
<location filename="../gui/MessagesDialog.cpp" line="+690"/>
<location line="+1083"/>
<location filename="../gui/MessagesDialog.cpp" line="+583"/>
<location line="+852"/>
<location line="+5"/>
<source>Trash</source>
<translation>Papierkorb</translation>
@ -7065,7 +7346,7 @@ p, li { white-space: pre-wrap; }
<translation type="obsolete">Neues Schlagwort...</translation>
</message>
<message>
<location filename="../gui/MessagesDialog.cpp" line="-1531"/>
<location filename="../gui/MessagesDialog.cpp" line="-1155"/>
<source>Mark as read</source>
<translation>Als gelesen markieren</translation>
</message>
@ -7085,34 +7366,33 @@ p, li { white-space: pre-wrap; }
<translation>Wiederherstellen</translation>
</message>
<message>
<location line="+41"/>
<location line="+25"/>
<source>Empty trash</source>
<translation>Papierkorb leeren</translation>
</message>
<message>
<location line="+364"/>
<location line="+1074"/>
<location line="+237"/>
<location line="+841"/>
<location line="+8"/>
<source>Drafts</source>
<translation>Entwürfe</translation>
</message>
<message>
<location line="-1045"/>
<location line="-808"/>
<source>To</source>
<translation>An</translation>
</message>
<message>
<location line="-477"/>
<source>Edit...</source>
<translation>Editieren...</translation>
<translation type="obsolete">Editieren...</translation>
</message>
<message>
<location line="-343"/>
<location line="-696"/>
<source>Click to sort by star</source>
<translation>Klicken, um nach Kennzeichnung zu sortieren</translation>
</message>
<message>
<location line="+1785"/>
<location line="+1424"/>
<location line="+4"/>
<location line="+4"/>
<location line="+4"/>
@ -9411,13 +9691,13 @@ Lockdatei:
<translation>Die Datei wurde zur Downloadliste hinzugefügt.</translation>
</message>
<message>
<location filename="../gui/MessagesDialog.cpp" line="-1207"/>
<location filename="../gui/RetroShareLink.cpp" line="+8"/>
<location line="+8"/>
<location filename="../gui/msgs/MessageWidget.cpp" line="-295"/>
<source>File Request canceled</source>
<translation>Dateianforderung abgebrochen</translation>
</message>
<message>
<location line="+0"/>
<location filename="../gui/msgs/MessageWidget.cpp" line="+0"/>
<source>The following has not been added to your download list, because you already have it:
</source>
<translation>Die folgende Datei wurde nicht zur Downloadliste hinzugefügt, da Du diese schon hast:
@ -9564,6 +9844,26 @@ Lockdatei:
<source>Start with a RetroShare link is only supported for Windows.</source>
<translation>Der Start mit einem RetroShare Link wird nur unter Windows unterstützt.</translation>
</message>
<message>
<location filename="../gui/TurtleRouterDialog.cpp" line="+108"/>
<source>(Age in seconds)</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+1"/>
<source>(Depth)</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+215"/>
<source>Evolution of search requests:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+1"/>
<source>Evolution of tunnel requests:</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>QuickStartWizard</name>
@ -12532,14 +12832,14 @@ p, li { white-space: pre-wrap; }
<context>
<name>TurtleRouterDialog</name>
<message>
<location filename="../gui/TurtleRouterDialog.cpp" line="+19"/>
<location line="+64"/>
<location filename="../gui/TurtleRouterDialog.cpp" line="-183"/>
<location line="+94"/>
<source>Search requests</source>
<translation>Suchanfragen</translation>
</message>
<message>
<location line="-59"/>
<location line="+81"/>
<location line="-89"/>
<location line="+109"/>
<source>Tunnel requests</source>
<translation>Tunnelanfragen</translation>
</message>
@ -12552,11 +12852,44 @@ p, li { white-space: pre-wrap; }
<translation>Router Statistiken</translation>
</message>
<message>
<location line="+14"/>
<location line="+18"/>
<source>F2F router information</source>
<translation>F2F Routerinformationen</translation>
</message>
</context>
<context>
<name>TurtleRouterStatisticsWidget</name>
<message>
<location filename="../gui/TurtleRouterDialog.cpp" line="+79"/>
<source>Turtle router traffic:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+1"/>
<source>Tunnel requests Up</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+1"/>
<source>Tunnel requests Dn</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+1"/>
<source>Incoming file data</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+1"/>
<source>Outgoing file data</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+1"/>
<source>Forwarded data </source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>ULListDelegate</name>
<message>