mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-02-25 17:21:27 -05:00
added systray notifications for chat lobbies.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@5357 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
bbae97b88d
commit
a2b6b97ef9
@ -588,6 +588,15 @@ void MainWindow::createNotifyIcons()
|
||||
|
||||
#undef DELETE_OBJECT
|
||||
}
|
||||
/*static*/ void MainWindow::displayLobbySystrayMsg(const QString& title,const QString& msg)
|
||||
{
|
||||
if (_instance == NULL)
|
||||
return;
|
||||
|
||||
if(Settings->getDisplayTrayChatLobby())
|
||||
_instance->displaySystrayMsg(title,msg) ;
|
||||
}
|
||||
|
||||
|
||||
/*static*/ void MainWindow::installGroupChatNotifier()
|
||||
{
|
||||
|
@ -133,6 +133,7 @@ public:
|
||||
|
||||
static void installGroupChatNotifier();
|
||||
static void installNotifyIcons();
|
||||
static void displayLobbySystrayMsg(const QString&,const QString&);
|
||||
|
||||
/* initialize widget with status informations, status constant stored in data or in Qt::UserRole */
|
||||
void initializeStatusObject(QObject *pObject, bool bConnect);
|
||||
|
@ -61,6 +61,7 @@ void ChatLobbyDialog::init(const std::string &peerId, const QString &title)
|
||||
if (rsMsgs->getVirtualPeerId(lobbyIt->lobby_id, vpid)) {
|
||||
if (vpid == peerId) {
|
||||
QString msg = tr("Welcome to lobby %1").arg(QString::fromUtf8(lobbyIt->lobby_name.c_str()));
|
||||
_lobby_name = QString(lobbyIt->lobby_name.c_str()) ;
|
||||
if (!lobbyIt->lobby_topic.empty()) {
|
||||
msg += "\n" + tr("Topic: %1").arg(QString::fromUtf8(lobbyIt->lobby_topic.c_str()));
|
||||
}
|
||||
@ -179,13 +180,19 @@ void ChatLobbyDialog::addIncomingChatMsg(const ChatInfo& info)
|
||||
|
||||
std::cerr << "message from rsid " << info.rsid.c_str() << std::endl;
|
||||
|
||||
if (!isParticipantMuted(name)) {
|
||||
// ui.chatWidget->addChatMsg(true, name.append(" ").append(rsid), sendTime, recvTime, message, ChatWidget::TYPE_NORMAL);
|
||||
if(!isParticipantMuted(name))
|
||||
ui.chatWidget->addChatMsg(true, name, sendTime, recvTime, message, ChatWidget::TYPE_NORMAL);
|
||||
} else {
|
||||
// ui.chatWidget->addChatMsg(true, name, sendTime, recvTime, message.append(" (BLOCKED)"), ChatWidget::TYPE_NORMAL);
|
||||
}
|
||||
|
||||
// This is a trick to translate HTML into text.
|
||||
QTextEdit editor;
|
||||
editor.setHtml(message);
|
||||
QString notifyMsg = name + ": " + editor.toPlainText();
|
||||
|
||||
if(notifyMsg.length() > 30)
|
||||
MainWindow::displayLobbySystrayMsg(tr("Lobby chat") + ": " + _lobby_name, notifyMsg.left(30) + QString("..."));
|
||||
else
|
||||
MainWindow::displayLobbySystrayMsg(tr("Lobby chat") + ": " + _lobby_name, notifyMsg);
|
||||
|
||||
// also update peer list.
|
||||
|
||||
time_t now = time(NULL);
|
||||
|
@ -69,6 +69,7 @@ private:
|
||||
bool isNicknameInLobby(const QString &nickname);
|
||||
|
||||
ChatLobbyId lobbyId;
|
||||
QString _lobby_name ;
|
||||
time_t lastUpdateListTime;
|
||||
|
||||
/** Qt Designer generated object */
|
||||
|
@ -134,6 +134,7 @@ NotifyPage::save(QString &/*errmsg*/)
|
||||
Settings->setChatFlags(chatflags);
|
||||
Settings->setMessageFlags(messageflags);
|
||||
|
||||
Settings->setDisplayTrayChatLobby(ui.systray_ChatLobby->isChecked());
|
||||
Settings->setDisplayTrayGroupChat(ui.systray_GroupChat->isChecked());
|
||||
MainWindow::installGroupChatNotifier();
|
||||
MainWindow::installNotifyIcons();
|
||||
@ -186,6 +187,7 @@ void NotifyPage::load()
|
||||
ui.message_ConnectAttempt->setChecked(messageflags & RS_MESSAGE_CONNECT_ATTEMPT);
|
||||
|
||||
ui.systray_GroupChat->setChecked(Settings->getDisplayTrayGroupChat());
|
||||
ui.systray_ChatLobby->setChecked(Settings->getDisplayTrayChatLobby());
|
||||
|
||||
ui.trayNotify_PrivateChat->setChecked(traynotifyflags & TRAYNOTIFY_PRIVATECHAT);
|
||||
ui.trayNotify_Messages->setChecked(traynotifyflags & TRAYNOTIFY_MESSAGES);
|
||||
|
@ -6,8 +6,8 @@
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>516</width>
|
||||
<height>474</height>
|
||||
<width>569</width>
|
||||
<height>512</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="sizePolicy">
|
||||
@ -499,410 +499,400 @@
|
||||
<property name="contextMenuPolicy">
|
||||
<enum>Qt::NoContextMenu</enum>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_4">
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<layout class="QVBoxLayout" name="verticalLayout_4">
|
||||
<item>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_3">
|
||||
<item>
|
||||
<widget class="QGroupBox" name="notify_ForumNewMsg">
|
||||
<property name="title">
|
||||
<string>News Feed</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout">
|
||||
<property name="spacing">
|
||||
<number>0</number>
|
||||
<widget class="QGroupBox" name="notify_ForumNewMsg">
|
||||
<property name="title">
|
||||
<string>News Feed</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout">
|
||||
<property name="spacing">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="margin">
|
||||
<number>6</number>
|
||||
</property>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="notify_Peers">
|
||||
<property name="text">
|
||||
<string>Peers</string>
|
||||
</property>
|
||||
<property name="margin">
|
||||
<number>6</number>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="notify_Channels">
|
||||
<property name="text">
|
||||
<string>Channels</string>
|
||||
</property>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="notify_Peers">
|
||||
<property name="text">
|
||||
<string>Peers</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="notify_Channels">
|
||||
<property name="text">
|
||||
<string>Channels</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="notify_Forums">
|
||||
<property name="text">
|
||||
<string>Forums</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="notify_Blogs">
|
||||
<property name="text">
|
||||
<string>Blogs</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="notify_Messages">
|
||||
<property name="text">
|
||||
<string>Messages</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="notify_Chat">
|
||||
<property name="text">
|
||||
<string>Chat</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="notify_Security">
|
||||
<property name="text">
|
||||
<string>Security</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="Line" name="line">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="addFeedsAtEnd">
|
||||
<property name="text">
|
||||
<string>Add feeds at end</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QGroupBox" name="trayNotifyGroupBox">
|
||||
<property name="title">
|
||||
<string>Systray Icon</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_5">
|
||||
<item>
|
||||
<layout class="QGridLayout" name="gridLayout_2">
|
||||
<item row="0" column="0">
|
||||
<widget class="QCheckBox" name="trayNotify_PrivateChat">
|
||||
<property name="text">
|
||||
<string>Private Chat</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QCheckBox" name="trayNotify_Messages">
|
||||
<property name="text">
|
||||
<string>Message</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QCheckBox" name="trayNotify_Channels">
|
||||
<property name="text">
|
||||
<string>Channel Post</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="0">
|
||||
<widget class="QCheckBox" name="trayNotify_Forums">
|
||||
<property name="text">
|
||||
<string>Forum Post</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="0">
|
||||
<widget class="QCheckBox" name="trayNotify_Transfer">
|
||||
<property name="text">
|
||||
<string>Download completed</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="1">
|
||||
<widget class="QCheckBox" name="trayNotify_PrivateChatCombined">
|
||||
<property name="text">
|
||||
<string>Combined</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="1">
|
||||
<widget class="QCheckBox" name="trayNotify_MessagesCombined">
|
||||
<property name="text">
|
||||
<string>Combined</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="1">
|
||||
<widget class="QCheckBox" name="trayNotify_ChannelsCombined">
|
||||
<property name="text">
|
||||
<string>Combined</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="1">
|
||||
<widget class="QCheckBox" name="trayNotify_ForumsCombined">
|
||||
<property name="text">
|
||||
<string>Combined</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="1">
|
||||
<widget class="QCheckBox" name="trayNotify_TransferCombined">
|
||||
<property name="text">
|
||||
<string>Combined</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QGroupBox" name="messageGroupBox">
|
||||
<property name="title">
|
||||
<string>Message</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_6">
|
||||
<item>
|
||||
<widget class="QCheckBox" name="message_ConnectAttempt">
|
||||
<property name="text">
|
||||
<string>Connect attempt</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="verticalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Vertical</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>20</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="notify_Forums">
|
||||
<property name="text">
|
||||
<string>Forums</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="notify_Blogs">
|
||||
<property name="text">
|
||||
<string>Blogs</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="notify_Messages">
|
||||
<property name="text">
|
||||
<string>Messages</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="notify_Chat">
|
||||
<property name="text">
|
||||
<string>Chat</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="notify_Security">
|
||||
<property name="text">
|
||||
<string>Security</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="Line" name="line">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="addFeedsAtEnd">
|
||||
<property name="text">
|
||||
<string>Add feeds at end</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<widget class="QGroupBox" name="groupBox">
|
||||
<property name="title">
|
||||
<string>Toasters</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout">
|
||||
<property name="leftMargin">
|
||||
<number>9</number>
|
||||
</property>
|
||||
<property name="topMargin">
|
||||
<number>9</number>
|
||||
</property>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="popup_Connect">
|
||||
<property name="text">
|
||||
<string>Friend Connect</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="popup_NewMsg">
|
||||
<property name="text">
|
||||
<string>New Message</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="popup_DownloadFinished">
|
||||
<property name="text">
|
||||
<string>Download completed</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="popup_PrivateChat">
|
||||
<widget class="QGroupBox" name="trayNotifyGroupBox">
|
||||
<property name="title">
|
||||
<string>Systray Icon</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_5">
|
||||
<item>
|
||||
<layout class="QGridLayout" name="gridLayout_2">
|
||||
<item row="0" column="0">
|
||||
<widget class="QCheckBox" name="trayNotify_PrivateChat">
|
||||
<property name="text">
|
||||
<string>Private Chat</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="popup_GroupChat">
|
||||
<item row="1" column="0">
|
||||
<widget class="QCheckBox" name="trayNotify_Messages">
|
||||
<property name="text">
|
||||
<string>Group Chat</string>
|
||||
<string>Message</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="popup_ChatLobby">
|
||||
<item row="2" column="0">
|
||||
<widget class="QCheckBox" name="trayNotify_Channels">
|
||||
<property name="text">
|
||||
<string>Chat Lobby</string>
|
||||
<string>Channel Post</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="popup_ConnectAttempt">
|
||||
<item row="3" column="0">
|
||||
<widget class="QCheckBox" name="trayNotify_Forums">
|
||||
<property name="text">
|
||||
<string>Connect attempt</string>
|
||||
<string>Forum Post</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QGridLayout" name="gridLayout">
|
||||
<item row="1" column="0">
|
||||
<widget class="QLabel" name="labelToasterPosition">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Position</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="1" colspan="3">
|
||||
<widget class="QComboBox" name="comboBoxToasterPosition">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QLabel" name="labelToasterXMargin">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>X Margin</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="1">
|
||||
<widget class="QSpinBox" name="spinBoxToasterXMargin">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>20</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="2">
|
||||
<widget class="QLabel" name="labelToasterYMargin">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Y Margin</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="3">
|
||||
<widget class="QSpinBox" name="spinBoxToasterYMargin">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>20</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QGroupBox" name="groupBox_2">
|
||||
<property name="title">
|
||||
<string>Private Chat</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout">
|
||||
<item>
|
||||
<widget class="QCheckBox" name="chat_NewWindow">
|
||||
<item row="4" column="0">
|
||||
<widget class="QCheckBox" name="trayNotify_Transfer">
|
||||
<property name="text">
|
||||
<string>Open Window for new chat</string>
|
||||
<string>Download completed</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="chat_Focus">
|
||||
<item row="0" column="1">
|
||||
<widget class="QCheckBox" name="trayNotify_PrivateChatCombined">
|
||||
<property name="text">
|
||||
<string>Grab Focus when chat arrives</string>
|
||||
<string>Combined</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="chat_tabbedWindow">
|
||||
<item row="1" column="1">
|
||||
<widget class="QCheckBox" name="trayNotify_MessagesCombined">
|
||||
<property name="text">
|
||||
<string>Use a single tabbed window</string>
|
||||
<string>Combined</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="1">
|
||||
<widget class="QCheckBox" name="trayNotify_ChannelsCombined">
|
||||
<property name="text">
|
||||
<string>Combined</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="1">
|
||||
<widget class="QCheckBox" name="trayNotify_ForumsCombined">
|
||||
<property name="text">
|
||||
<string>Combined</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="1">
|
||||
<widget class="QCheckBox" name="trayNotify_TransferCombined">
|
||||
<property name="text">
|
||||
<string>Combined</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QGroupBox" name="groupBox_3">
|
||||
<property name="title">
|
||||
<string>Group chat</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||
<item>
|
||||
<widget class="QCheckBox" name="systray_GroupChat">
|
||||
<property name="text">
|
||||
<string>Display systray message</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QGroupBox" name="messageGroupBox">
|
||||
<property name="title">
|
||||
<string>Message</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_6">
|
||||
<item>
|
||||
<widget class="QCheckBox" name="message_ConnectAttempt">
|
||||
<property name="text">
|
||||
<string>Connect attempt</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="verticalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Vertical</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>20</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="verticalSpacer_2">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Vertical</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>20</width>
|
||||
<height>130</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<widget class="QGroupBox" name="groupBox">
|
||||
<property name="title">
|
||||
<string>Toasters</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout">
|
||||
<property name="leftMargin">
|
||||
<number>9</number>
|
||||
</property>
|
||||
<property name="topMargin">
|
||||
<number>9</number>
|
||||
</property>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="popup_Connect">
|
||||
<property name="text">
|
||||
<string>Friend Connect</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="popup_NewMsg">
|
||||
<property name="text">
|
||||
<string>New Message</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="popup_DownloadFinished">
|
||||
<property name="text">
|
||||
<string>Download completed</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="popup_PrivateChat">
|
||||
<property name="text">
|
||||
<string>Private Chat</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="popup_GroupChat">
|
||||
<property name="text">
|
||||
<string>Group Chat</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="popup_ChatLobby">
|
||||
<property name="text">
|
||||
<string>Chat Lobby</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="popup_ConnectAttempt">
|
||||
<property name="text">
|
||||
<string>Connect attempt</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QGridLayout" name="gridLayout">
|
||||
<item row="1" column="0">
|
||||
<widget class="QLabel" name="labelToasterPosition">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Position</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="1" colspan="3">
|
||||
<widget class="QComboBox" name="comboBoxToasterPosition">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QLabel" name="labelToasterXMargin">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>X Margin</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="1">
|
||||
<widget class="QSpinBox" name="spinBoxToasterXMargin">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>20</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="2">
|
||||
<widget class="QLabel" name="labelToasterYMargin">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Y Margin</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="3">
|
||||
<widget class="QSpinBox" name="spinBoxToasterYMargin">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>20</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QGroupBox" name="groupBox_3">
|
||||
<property name="title">
|
||||
<string>Systray message</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||
<item>
|
||||
<widget class="QCheckBox" name="systray_GroupChat">
|
||||
<property name="text">
|
||||
<string>Group chat</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="systray_ChatLobby">
|
||||
<property name="text">
|
||||
<string>Chat lobbies</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QGroupBox" name="groupBox_2">
|
||||
<property name="title">
|
||||
<string>Private Chat</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout">
|
||||
<item>
|
||||
<widget class="QCheckBox" name="chat_NewWindow">
|
||||
<property name="text">
|
||||
<string>Open Window for new chat</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="chat_Focus">
|
||||
<property name="text">
|
||||
<string>Grab Focus when chat arrives</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="chat_tabbedWindow">
|
||||
<property name="text">
|
||||
<string>Use a single tabbed window</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
|
@ -325,11 +325,21 @@ void RshareSettings::setMessageFlags(uint flags)
|
||||
setValue("MessageFlags", flags);
|
||||
}
|
||||
|
||||
bool RshareSettings::getDisplayTrayChatLobby()
|
||||
{
|
||||
return value("DisplayTrayChatLobby").toBool();
|
||||
}
|
||||
|
||||
bool RshareSettings::getDisplayTrayGroupChat()
|
||||
{
|
||||
return value("DisplayTrayGroupChat").toBool();
|
||||
}
|
||||
|
||||
void RshareSettings::setDisplayTrayChatLobby(bool bValue)
|
||||
{
|
||||
setValue("DisplayTrayChatLobby", bValue);
|
||||
}
|
||||
|
||||
void RshareSettings::setDisplayTrayGroupChat(bool bValue)
|
||||
{
|
||||
setValue("DisplayTrayGroupChat", bValue);
|
||||
|
@ -164,6 +164,8 @@ public:
|
||||
uint getMessageFlags();
|
||||
void setMessageFlags(uint flags);
|
||||
|
||||
bool getDisplayTrayChatLobby();
|
||||
void setDisplayTrayChatLobby(bool bValue);
|
||||
bool getDisplayTrayGroupChat();
|
||||
void setDisplayTrayGroupChat(bool bValue);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user