MessagelistControl widget
This commit is contained in:
parent
45d3dbc0ec
commit
8e99226fee
|
@ -155,23 +155,22 @@ class MainWindow(Window):
|
|||
j += 1
|
||||
widget.setUnreadCount(unread)
|
||||
i += 1
|
||||
|
||||
treeWidget.setSortingEnabled(True)
|
||||
|
||||
treeWidget.setSortingEnabled(True)
|
||||
|
||||
def rerenderTabTreeMessages(self):
|
||||
self.rerenderTabTree('messages')
|
||||
|
||||
def rerenderTabTreeChans(self):
|
||||
self.rerenderTabTree('chan')
|
||||
|
||||
|
||||
def rerenderTabTree(self, tab):
|
||||
if tab == 'messages':
|
||||
treeWidget = self.treeWidgetYourIdentities
|
||||
elif tab == 'chan':
|
||||
treeWidget = self.treeWidgetChans
|
||||
if tab != 'chan':
|
||||
return
|
||||
|
||||
treeWidget = self.treeWidgetChans
|
||||
folders = Ui_FolderWidget.folderWeight.keys()
|
||||
|
||||
|
||||
# sort ascending when creating
|
||||
if treeWidget.topLevelItemCount() == 0:
|
||||
treeWidget.header().setSortIndicator(
|
||||
|
@ -179,7 +178,7 @@ class MainWindow(Window):
|
|||
# init dictionary
|
||||
db = {}
|
||||
enabled = {}
|
||||
|
||||
|
||||
for toAddress in getSortedAccounts():
|
||||
isEnabled = BMConfigParser().getboolean(
|
||||
toAddress, 'enabled')
|
||||
|
@ -188,17 +187,14 @@ class MainWindow(Window):
|
|||
isMaillinglist = BMConfigParser().safeGetBoolean(
|
||||
toAddress, 'mailinglist')
|
||||
|
||||
if treeWidget == self.treeWidgetYourIdentities:
|
||||
if isChan:
|
||||
continue
|
||||
elif treeWidget == self.treeWidgetChans:
|
||||
if treeWidget == self.treeWidgetChans:
|
||||
if not isChan:
|
||||
continue
|
||||
|
||||
db[toAddress] = {}
|
||||
for folder in folders:
|
||||
db[toAddress][folder] = 0
|
||||
|
||||
|
||||
enabled[toAddress] = isEnabled
|
||||
|
||||
# get number of (unread) messages
|
||||
|
@ -209,17 +205,17 @@ class MainWindow(Window):
|
|||
total += cnt
|
||||
if toaddress in db and folder in db[toaddress]:
|
||||
db[toaddress][folder] = cnt
|
||||
if treeWidget == self.treeWidgetYourIdentities:
|
||||
db[None] = {}
|
||||
db[None]["inbox"] = total
|
||||
db[None]["new"] = total
|
||||
db[None]["sent"] = 0
|
||||
db[None]["trash"] = 0
|
||||
enabled[None] = True
|
||||
|
||||
# if treeWidget == self.treeWidgetYourIdentities:
|
||||
# db[None] = {}
|
||||
# db[None]["inbox"] = total
|
||||
# db[None]["new"] = total
|
||||
# db[None]["sent"] = 0
|
||||
# db[None]["trash"] = 0
|
||||
# enabled[None] = True
|
||||
|
||||
if treeWidget.isSortingEnabled():
|
||||
treeWidget.setSortingEnabled(False)
|
||||
|
||||
|
||||
widgets = {}
|
||||
i = 0
|
||||
while i < treeWidget.topLevelItemCount():
|
||||
|
@ -367,17 +363,17 @@ class MainWindow(Window):
|
|||
self.UISignalThread.start()
|
||||
|
||||
# Key press in tree view
|
||||
self.treeWidgetYourIdentities.keyPressEvent = self.treeWidgetKeyPressEvent
|
||||
# self.treeWidgetYourIdentities.keyPressEvent = self.treeWidgetKeyPressEvent
|
||||
self.treeWidgetSubscriptions.keyPressEvent = self.treeWidgetKeyPressEvent
|
||||
self.treeWidgetChans.keyPressEvent = self.treeWidgetKeyPressEvent
|
||||
|
||||
# Key press in messagelist
|
||||
self.messagelistInbox.keyPressEvent = self.tableWidgetKeyPressEvent
|
||||
# self.messagelistInbox.keyPressEvent = self.tableWidgetKeyPressEvent
|
||||
self.tableWidgetInboxSubscriptions.keyPressEvent = self.tableWidgetKeyPressEvent
|
||||
self.tableWidgetInboxChans.keyPressEvent = self.tableWidgetKeyPressEvent
|
||||
|
||||
# Key press in messageview
|
||||
self.textEditInboxMessage.keyPressEvent = self.textEditKeyPressEvent
|
||||
# self.textEditInboxMessage.keyPressEvent = self.textEditKeyPressEvent
|
||||
self.textEditInboxMessageSubscriptions.keyPressEvent = self.textEditKeyPressEvent
|
||||
self.textEditInboxMessageChans.keyPressEvent = self.textEditKeyPressEvent
|
||||
|
||||
|
@ -544,7 +540,7 @@ class MainWindow(Window):
|
|||
widget.item(row, col).setUnread(not status)
|
||||
|
||||
def propagateUnreadCount(self, address = None, folder = "inbox", widget = None, type = 1):
|
||||
widgets = [self.treeWidgetYourIdentities, self.treeWidgetSubscriptions, self.treeWidgetChans]
|
||||
widgets = [self.treeWidgetSubscriptions, self.treeWidgetChans]
|
||||
queryReturn = sqlQuery("SELECT toaddress, folder, COUNT(msgid) AS cnt FROM inbox WHERE read = 0 GROUP BY toaddress, folder")
|
||||
totalUnread = {}
|
||||
normalUnread = {}
|
||||
|
@ -1076,9 +1072,9 @@ class MainWindow(Window):
|
|||
self.rerenderTabTreeMessages()
|
||||
self.rerenderTabTreeSubscriptions()
|
||||
self.rerenderTabTreeChans()
|
||||
if self.getCurrentFolder(self.treeWidgetYourIdentities) == "trash":
|
||||
self.loadMessagelist(self.tableWidgetInbox, self.getCurrentAccount(self.treeWidgetYourIdentities), "trash")
|
||||
elif self.getCurrentFolder(self.treeWidgetSubscriptions) == "trash":
|
||||
# if self.getCurrentFolder(self.treeWidgetYourIdentities) == "trash":
|
||||
# self.loadMessagelist(self.tableWidgetInbox, self.getCurrentAccount(self.treeWidgetYourIdentities), "trash")
|
||||
if self.getCurrentFolder(self.treeWidgetSubscriptions) == "trash":
|
||||
self.loadMessagelist(self.tableWidgetInboxSubscriptions, self.getCurrentAccount(self.treeWidgetSubscriptions), "trash")
|
||||
elif self.getCurrentFolder(self.treeWidgetChans) == "trash":
|
||||
self.loadMessagelist(self.tableWidgetInboxChans, self.getCurrentAccount(self.treeWidgetChans), "trash")
|
||||
|
@ -1829,12 +1825,12 @@ class MainWindow(Window):
|
|||
treeWidget = self.widgetConvert(sent)
|
||||
if self.getCurrentFolder(treeWidget) != "sent":
|
||||
continue
|
||||
if (
|
||||
treeWidget == self.treeWidgetYourIdentities and
|
||||
self.getCurrentAccount(treeWidget)
|
||||
not in (fromAddress, None, False)
|
||||
):
|
||||
continue
|
||||
# if (
|
||||
# treeWidget == self.treeWidgetYourIdentities and
|
||||
# self.getCurrentAccount(treeWidget)
|
||||
# not in (fromAddress, None, False)
|
||||
# ):
|
||||
# continue
|
||||
elif treeWidget in [self.treeWidgetSubscriptions, self.treeWidgetChans] and self.getCurrentAccount(treeWidget) != toAddress:
|
||||
continue
|
||||
elif not helper_search.check_match(toAddress, fromAddress, subject, message, self.getCurrentSearchOption(tab), self.getCurrentSearchLine(tab)):
|
||||
|
@ -1852,7 +1848,7 @@ class MainWindow(Window):
|
|||
inbox = self.getAccountMessagelist(acct)
|
||||
ret = None
|
||||
tab = -1
|
||||
for treeWidget in [self.treeWidgetYourIdentities, self.treeWidgetSubscriptions, self.treeWidgetChans]:
|
||||
for treeWidget in [self.treeWidgetSubscriptions, self.treeWidgetChans]:
|
||||
tab += 1
|
||||
if tab == 1:
|
||||
tab = 2
|
||||
|
@ -1861,12 +1857,12 @@ class MainWindow(Window):
|
|||
continue
|
||||
if tableWidget == inbox and self.getCurrentAccount(treeWidget) == acct.address and self.getCurrentFolder(treeWidget) in ["inbox", None]:
|
||||
ret = self.addMessageListItemInbox(inbox, "inbox", inventoryHash, toAddress, fromAddress, subject, time.time(), 0)
|
||||
elif (
|
||||
treeWidget == self.treeWidgetYourIdentities and
|
||||
self.getCurrentAccount(treeWidget) is None and
|
||||
self.getCurrentFolder(treeWidget) in ("inbox", "new", None)
|
||||
):
|
||||
ret = self.addMessageListItemInbox(tableWidget, "inbox", inventoryHash, toAddress, fromAddress, subject, time.time(), 0)
|
||||
# elif (
|
||||
# treeWidget == self.treeWidgetYourIdentities and
|
||||
# self.getCurrentAccount(treeWidget) is None and
|
||||
# self.getCurrentFolder(treeWidget) in ("inbox", "new", None)
|
||||
# ):
|
||||
# ret = self.addMessageListItemInbox(tableWidget, "inbox", inventoryHash, toAddress, fromAddress, subject, time.time(), 0)
|
||||
if ret is None:
|
||||
acct.parseMessage(toAddress, fromAddress, subject, "")
|
||||
else:
|
||||
|
@ -2855,14 +2851,10 @@ class MainWindow(Window):
|
|||
self.treeWidgetSubscriptions.mapToGlobal(point))
|
||||
|
||||
def widgetConvert(self, widget):
|
||||
# if widget == self.tableWidgetInbox:
|
||||
# return self.treeWidgetYourIdentities
|
||||
if widget == self.tableWidgetInboxSubscriptions:
|
||||
return self.treeWidgetSubscriptions
|
||||
elif widget == self.tableWidgetInboxChans:
|
||||
return self.treeWidgetChans
|
||||
elif widget == self.treeWidgetYourIdentities:
|
||||
return self.messagelistInbox
|
||||
elif widget == self.treeWidgetSubscriptions:
|
||||
return self.tableWidgetInboxSubscriptions
|
||||
elif widget == self.treeWidgetChans:
|
||||
|
@ -2871,26 +2863,17 @@ class MainWindow(Window):
|
|||
def getCurrentTreeWidget(self):
|
||||
currentIndex = self.tabWidget.currentIndex()
|
||||
treeWidgetList = [
|
||||
self.treeWidgetYourIdentities,
|
||||
False,
|
||||
self.treeWidgetSubscriptions,
|
||||
self.treeWidgetChans
|
||||
]
|
||||
if currentIndex >= 0 and currentIndex < len(treeWidgetList):
|
||||
if currentIndex >= 2 and currentIndex - 2 < len(treeWidgetList):
|
||||
return treeWidgetList[currentIndex]
|
||||
else:
|
||||
return False
|
||||
|
||||
def getAccountTreeWidget(self, account):
|
||||
try:
|
||||
if account.type == AccountMixin.CHAN:
|
||||
return self.treeWidgetChans
|
||||
elif account.type == AccountMixin.SUBSCRIPTION:
|
||||
return self.treeWidgetSubscriptions
|
||||
else:
|
||||
return self.treeWidgetYourIdentities
|
||||
except:
|
||||
return self.treeWidgetYourIdentities
|
||||
if account.type == AccountMixin.CHAN:
|
||||
return self.treeWidgetChans
|
||||
elif account.type == AccountMixin.SUBSCRIPTION:
|
||||
return self.treeWidgetSubscriptions
|
||||
|
||||
def getCurrentMessagelist(self):
|
||||
currentIndex = self.tabWidget.currentIndex()
|
||||
|
@ -2900,8 +2883,6 @@ class MainWindow(Window):
|
|||
)
|
||||
if currentIndex >= 2 and currentIndex - 2 < len(messagelistList):
|
||||
return messagelistList[currentIndex - 2]
|
||||
else:
|
||||
return False
|
||||
|
||||
def getAccountMessagelist(self, account):
|
||||
try:
|
||||
|
@ -2928,15 +2909,11 @@ class MainWindow(Window):
|
|||
def getCurrentMessageTextedit(self):
|
||||
currentIndex = self.tabWidget.currentIndex()
|
||||
messagelistList = [
|
||||
self.textEditInboxMessage,
|
||||
False,
|
||||
self.textEditInboxMessageSubscriptions,
|
||||
self.textEditInboxMessageChans,
|
||||
]
|
||||
if currentIndex >= 0 and currentIndex < len(messagelistList):
|
||||
if currentIndex >= 2 and currentIndex - 2 < len(messagelistList):
|
||||
return messagelistList[currentIndex]
|
||||
else:
|
||||
return False
|
||||
|
||||
def getAccountTextedit(self, account):
|
||||
try:
|
||||
|
@ -2953,32 +2930,24 @@ class MainWindow(Window):
|
|||
if currentIndex is None:
|
||||
currentIndex = self.tabWidget.currentIndex()
|
||||
messagelistList = [
|
||||
self.inboxSearchLineEdit,
|
||||
False,
|
||||
self.inboxSearchLineEditSubscriptions,
|
||||
self.inboxSearchLineEditChans,
|
||||
]
|
||||
if currentIndex >= 0 and currentIndex < len(messagelistList):
|
||||
if currentIndex >= 2 and currentIndex - 2 < len(messagelistList):
|
||||
if retObj:
|
||||
return messagelistList[currentIndex]
|
||||
else:
|
||||
return messagelistList[currentIndex].text().toUtf8().data()
|
||||
else:
|
||||
return None
|
||||
|
||||
def getCurrentSearchOption(self, currentIndex=None):
|
||||
if currentIndex is None:
|
||||
currentIndex = self.tabWidget.currentIndex()
|
||||
messagelistList = [
|
||||
self.inboxSearchOption,
|
||||
False,
|
||||
self.inboxSearchOptionSubscriptions,
|
||||
self.inboxSearchOptionChans,
|
||||
]
|
||||
if currentIndex >= 0 and currentIndex < len(messagelistList):
|
||||
if currentIndex >= 2 and currentIndex - 2 < len(messagelistList):
|
||||
return messagelistList[currentIndex].currentText().toUtf8().data()
|
||||
else:
|
||||
return None
|
||||
|
||||
# Group of functions for the Your Identities dialog box
|
||||
def getCurrentItem(self, treeWidget=None):
|
||||
|
@ -2989,7 +2958,7 @@ class MainWindow(Window):
|
|||
if currentItem:
|
||||
return currentItem
|
||||
return False
|
||||
|
||||
|
||||
def getCurrentAccount(self, treeWidget=None):
|
||||
currentItem = self.getCurrentItem(treeWidget)
|
||||
if currentItem:
|
||||
|
@ -3473,11 +3442,11 @@ class MainWindow(Window):
|
|||
messageTextedit.setTextColor(QtGui.QColor())
|
||||
messageTextedit.setContent(message)
|
||||
|
||||
def messagelistSelect(self, msg):
|
||||
messageTextedit = self.getCurrentMessageTextedit()
|
||||
if not messageTextedit:
|
||||
return
|
||||
messageTextedit.setContent(msg)
|
||||
# def messagelistSelect(self, msg):
|
||||
# messageTextedit = self.getCurrentMessageTextedit()
|
||||
# if not messageTextedit:
|
||||
# return
|
||||
# messageTextedit.setContent(msg)
|
||||
|
||||
def tableWidgetAddressBookItemChanged(self, item):
|
||||
if item.type == AccountMixin.CHAN:
|
||||
|
|
|
@ -52,7 +52,7 @@ class Window(settingsmixin.SMainWindow):
|
|||
|
||||
# splitters
|
||||
for splitter in (
|
||||
self.inboxHorizontalSplitter,
|
||||
# self.inboxHorizontalSplitter,
|
||||
self.sendHorizontalSplitter,
|
||||
self.subscriptionsHorizontalSplitter,
|
||||
self.chansHorizontalSplitter
|
||||
|
@ -63,7 +63,7 @@ class Window(settingsmixin.SMainWindow):
|
|||
splitter.setCollapsible(1, False)
|
||||
|
||||
for splitter in (
|
||||
self.inboxMessagecontrolSplitter,
|
||||
# self.inboxMessagecontrolSplitter,
|
||||
self.subscriptionsMessagecontrolSplitter,
|
||||
self.chansMessagecontrolSplitter
|
||||
):
|
||||
|
|
|
@ -68,7 +68,7 @@
|
|||
<property name="currentIndex">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<widget class="QWidget" name="inbox">
|
||||
<widget class="MessagelistControl" name="inbox">
|
||||
<attribute name="icon">
|
||||
<iconset resource="bitmessage_icons.qrc">
|
||||
<normaloff>:/newPrefix/images/inbox.png</normaloff>:/newPrefix/images/inbox.png</iconset>
|
||||
|
@ -76,178 +76,6 @@
|
|||
<attribute name="title">
|
||||
<string>Messages</string>
|
||||
</attribute>
|
||||
<layout class="QVBoxLayout" name="inboxLayout">
|
||||
<property name="leftMargin">
|
||||
<number>8</number>
|
||||
</property>
|
||||
<property name="topMargin">
|
||||
<number>8</number>
|
||||
</property>
|
||||
<property name="rightMargin">
|
||||
<number>8</number>
|
||||
</property>
|
||||
<property name="bottomMargin">
|
||||
<number>8</number>
|
||||
</property>
|
||||
<item>
|
||||
<widget class="SSplitter" name="inboxHorizontalSplitter">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<widget class="QWidget" name="inboxIdentitiesWidget">
|
||||
<layout class="QVBoxLayout">
|
||||
<item>
|
||||
<widget class="STreeWidget" name="treeWidgetYourIdentities">
|
||||
<property name="baseSize">
|
||||
<size>
|
||||
<width>200</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="contextMenuPolicy">
|
||||
<enum>Qt::CustomContextMenu</enum>
|
||||
</property>
|
||||
<column>
|
||||
<property name="text">
|
||||
<string>Identities</string>
|
||||
</property>
|
||||
<property name="icon">
|
||||
<iconset>
|
||||
<selectedoff>:/newPrefix/images/identities.png</selectedoff>
|
||||
</iconset>
|
||||
</property>
|
||||
</column>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="pushButtonNewAddress">
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>200</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>New Indentitiy</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="SSplitter" name="inboxMessagecontrolSplitter">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Vertical</enum>
|
||||
</property>
|
||||
<widget class="QWidget" name="searchWidget">
|
||||
<layout class="QHBoxLayout" name="searchLayout">
|
||||
<item>
|
||||
<widget class="QLineEdit" name="inboxSearchLineEdit">
|
||||
<property name="placeholderText">
|
||||
<string>Search</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QComboBox" name="inboxSearchOption">
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>All</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>To</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>From</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Subject</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Message</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="InboxMessagelist" name="messagelistInbox">
|
||||
<property name="contextMenuPolicy">
|
||||
<enum>Qt::CustomContextMenu</enum>
|
||||
</property>
|
||||
<property name="editTriggers">
|
||||
<set>QAbstractItemView::NoEditTriggers</set>
|
||||
</property>
|
||||
<property name="alternatingRowColors">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="selectionMode">
|
||||
<enum>QAbstractItemView::ExtendedSelection</enum>
|
||||
</property>
|
||||
<property name="selectionBehavior">
|
||||
<enum>QAbstractItemView::SelectRows</enum>
|
||||
</property>
|
||||
<property name="sortingEnabled">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="wordWrap">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<attribute name="horizontalHeaderCascadingSectionResizes">
|
||||
<bool>true</bool>
|
||||
</attribute>
|
||||
<attribute name="horizontalHeaderDefaultSectionSize">
|
||||
<number>200</number>
|
||||
</attribute>
|
||||
<attribute name="horizontalHeaderHighlightSections">
|
||||
<bool>false</bool>
|
||||
</attribute>
|
||||
<attribute name="horizontalHeaderMinimumSectionSize">
|
||||
<number>27</number>
|
||||
</attribute>
|
||||
<attribute name="horizontalHeaderShowSortIndicator" stdset="0">
|
||||
<bool>false</bool>
|
||||
</attribute>
|
||||
<attribute name="horizontalHeaderStretchLastSection">
|
||||
<bool>true</bool>
|
||||
</attribute>
|
||||
<attribute name="verticalHeaderVisible">
|
||||
<bool>false</bool>
|
||||
</attribute>
|
||||
<attribute name="verticalHeaderDefaultSectionSize">
|
||||
<number>26</number>
|
||||
</attribute>
|
||||
</widget>
|
||||
<widget class="MessageView" name="textEditInboxMessage">
|
||||
<property name="baseSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
<height>500</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="readOnly">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="plainText">
|
||||
<string>
|
||||
Welcome to easy and secure Bitmessage
|
||||
* send messages to other people
|
||||
* send broadcast messages like twitter or
|
||||
* discuss in chan(nel)s with other people
|
||||
</string>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="QWidget" name="send">
|
||||
<attribute name="icon">
|
||||
|
@ -1585,8 +1413,8 @@ p, li { white-space: pre-wrap; }
|
|||
<header>bitmessageqt.settingsmixin</header>
|
||||
</customwidget>
|
||||
<customwidget>
|
||||
<class>InboxMessagelist</class>
|
||||
<extends>QTableView</extends>
|
||||
<class>MessagelistControl</class>
|
||||
<extends>QWidget</extends>
|
||||
<header>bitmessageqt.messagelist</header>
|
||||
</customwidget>
|
||||
<customwidget>
|
||||
|
@ -1602,8 +1430,6 @@ p, li { white-space: pre-wrap; }
|
|||
</customwidget>
|
||||
</customwidgets>
|
||||
<tabstops>
|
||||
<tabstop>messagelistInbox</tabstop>
|
||||
<tabstop>textEditInboxMessage</tabstop>
|
||||
<tabstop>comboBoxSendFrom</tabstop>
|
||||
<tabstop>lineEditTo</tabstop>
|
||||
<tabstop>lineEditSubject</tabstop>
|
||||
|
@ -1759,22 +1585,6 @@ p, li { white-space: pre-wrap; }
|
|||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>pushButtonNewAddress</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>MainWindow</receiver>
|
||||
<slot>click_NewAddressDialog</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>20</x>
|
||||
<y>20</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>20</x>
|
||||
<y>20</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>pushButtonAddAddressBook</sender>
|
||||
<signal>clicked()</signal>
|
||||
|
@ -1903,22 +1713,6 @@ p, li { white-space: pre-wrap; }
|
|||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>messagelistInbox</sender>
|
||||
<signal>customContextMenuRequested(QPoint)</signal>
|
||||
<receiver>MainWindow</receiver>
|
||||
<slot>on_context_menuInbox()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>656</x>
|
||||
<y>366</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>442</x>
|
||||
<y>289</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>tableWidgetInboxSubscriptions</sender>
|
||||
<signal>customContextMenuRequested(QPoint)</signal>
|
||||
|
@ -1951,22 +1745,6 @@ p, li { white-space: pre-wrap; }
|
|||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>treeWidgetYourIdentities</sender>
|
||||
<signal>customContextMenuRequested(QPoint)</signal>
|
||||
<receiver>MainWindow</receiver>
|
||||
<slot>on_context_menuYourIdentities()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>20</x>
|
||||
<y>20</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>20</x>
|
||||
<y>20</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>tableWidgetAddressBook</sender>
|
||||
<signal>customContextMenuRequested(QPoint)</signal>
|
||||
|
@ -2655,22 +2433,6 @@ p, li { white-space: pre-wrap; }
|
|||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>inboxSearchLineEdit</sender>
|
||||
<signal>returnPressed()</signal>
|
||||
<receiver>MainWindow</receiver>
|
||||
<slot>inboxSearchLineEditReturnPressed</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>20</x>
|
||||
<y>20</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>20</x>
|
||||
<y>20</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>inboxSearchLineEditSubscriptions</sender>
|
||||
<signal>returnPressed()</signal>
|
||||
|
@ -2703,22 +2465,6 @@ p, li { white-space: pre-wrap; }
|
|||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>inboxSearchLineEdit</sender>
|
||||
<signal>textChanged(QString)</signal>
|
||||
<receiver>MainWindow</receiver>
|
||||
<slot>inboxSearchLineEditUpdated</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>20</x>
|
||||
<y>20</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>20</x>
|
||||
<y>20</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>inboxSearchLineEditSubscriptions</sender>
|
||||
<signal>textChanged(QString)</signal>
|
||||
|
@ -2767,22 +2513,6 @@ p, li { white-space: pre-wrap; }
|
|||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>messagelistInbox</sender>
|
||||
<signal>messageSelected(QString)</signal>
|
||||
<receiver>MainWindow</receiver>
|
||||
<slot>messagelistSelect</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>20</x>
|
||||
<y>20</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>20</x>
|
||||
<y>20</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>tableWidgetInboxSubscriptions</sender>
|
||||
<signal>itemSelectionChanged()</signal>
|
||||
|
@ -2815,22 +2545,6 @@ p, li { white-space: pre-wrap; }
|
|||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>treeWidgetYourIdentities</sender>
|
||||
<signal>itemSelectionChanged()</signal>
|
||||
<receiver>MainWindow</receiver>
|
||||
<slot>treeWidgetItemClicked</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>20</x>
|
||||
<y>20</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>20</x>
|
||||
<y>20</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>treeWidgetSubscriptions</sender>
|
||||
<signal>itemSelectionChanged()</signal>
|
||||
|
@ -2863,22 +2577,6 @@ p, li { white-space: pre-wrap; }
|
|||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>treeWidgetYourIdentities</sender>
|
||||
<signal>itemChanged(QTreeWidgetItem*,int)</signal>
|
||||
<receiver>MainWindow</receiver>
|
||||
<slot>treeWidgetItemChanged</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>20</x>
|
||||
<y>20</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>20</x>
|
||||
<y>20</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>treeWidgetSubscriptions</sender>
|
||||
<signal>itemChanged(QTreeWidgetItem*,int)</signal>
|
||||
|
|
|
@ -2,7 +2,10 @@ from collections import OrderedDict
|
|||
|
||||
from PyQt4 import QtCore, QtGui
|
||||
|
||||
import account
|
||||
import foldertree
|
||||
import l10n
|
||||
import widgets
|
||||
from bmconfigparser import BMConfigParser
|
||||
from debug import logger
|
||||
from helper_sql import sqlQuery, sqlExecute
|
||||
|
@ -93,7 +96,8 @@ class InboxTableModel(QtCore.QAbstractTableModel):
|
|||
|
||||
def __init__(self, parent=None):
|
||||
super(InboxTableModel, self).__init__()
|
||||
self.filter = InboxFilter(fields=self.fields)
|
||||
# folder='*' gives empty set
|
||||
self.filter = InboxFilter(folder='*', fields=self.fields)
|
||||
self.fields = ','.join(self.fields)
|
||||
self.query = 'SELECT %%s FROM %s ' % self.table
|
||||
self.sort = ' ORDER BY received DESC'
|
||||
|
@ -159,8 +163,10 @@ class InboxTableModel(QtCore.QAbstractTableModel):
|
|||
)[0][0]
|
||||
|
||||
def updateFilter(self, *args, **kwargs):
|
||||
prev = self.filter.__str__()
|
||||
self.filter.update(*args, **kwargs)
|
||||
self.emit(QtCore.SIGNAL("layoutChanged()"))
|
||||
if prev != self.filter.__str__():
|
||||
self.emit(QtCore.SIGNAL("layoutChanged()"))
|
||||
|
||||
|
||||
class InboxMessagelist(QtGui.QTableView):
|
||||
|
@ -170,8 +176,80 @@ class InboxMessagelist(QtGui.QTableView):
|
|||
|
||||
def currentChanged(self, cur_id, prev_id):
|
||||
row = cur_id.row()
|
||||
if row == prev_id.row():
|
||||
if row and row == prev_id.row():
|
||||
return
|
||||
# what if folder changed?
|
||||
self.model().setRead(row)
|
||||
msg = self.model().getMessage(row)
|
||||
self.emit(QtCore.SIGNAL("messageSelected(QString)"), msg)
|
||||
|
||||
def folderChanged(self, cur_folder, prev_folder):
|
||||
if cur_folder == prev_folder:
|
||||
return
|
||||
try:
|
||||
folder = cur_folder.folderName
|
||||
except AttributeError:
|
||||
folder = 'inbox'
|
||||
update = {'folder': folder}
|
||||
if cur_folder.address:
|
||||
update['toaddress'] = cur_folder.address
|
||||
self.model().updateFilter(update)
|
||||
self.selectRow(0)
|
||||
|
||||
|
||||
class TreeWidgetIdentities(QtGui.QTreeWidget):
|
||||
def __init__(self, parent):
|
||||
super(TreeWidgetIdentities, self).__init__(parent)
|
||||
folders = ('inbox', 'new', 'sent', 'trash')
|
||||
accounts = account.getSortedAccounts() + account.getSortedSubscriptions().keys()
|
||||
top = foldertree.Ui_AddressWidget(self, 0, None, 0, True)
|
||||
for i, folder in enumerate(folders):
|
||||
foldertree.Ui_FolderWidget(top, i, None, folder, 0)
|
||||
for i, addr in enumerate(accounts):
|
||||
top = foldertree.Ui_AddressWidget(
|
||||
self, i, addr, 0,
|
||||
BMConfigParser().safeGetBoolean(addr, 'enabled'))
|
||||
for j, folder in enumerate(folders):
|
||||
foldertree.Ui_FolderWidget(top, j, addr, folder, 0)
|
||||
self.header().setSortIndicator(0, QtCore.Qt.AscendingOrder)
|
||||
|
||||
def filterAccountType(self, account_type):
|
||||
header = self.headerItem()
|
||||
if account_type == foldertree.AccountMixin.CHAN:
|
||||
header.setText(0, _translate("MainWindow", "Chans"))
|
||||
header.setIcon(0, QtGui.QIcon(":/newPrefix/images/can-icon-16px.png"))
|
||||
elif account_type == foldertree.AccountMixin.SUBSCRIPTION:
|
||||
header.setText(0, _translate("MainWindow", "Subscriptions"))
|
||||
header.setIcon(0, QtGui.QIcon(":/newPrefix/images/subscriptions.png"))
|
||||
for i in xrange(self.topLevelItemCount()):
|
||||
item = self.topLevelItem(i)
|
||||
if item.type != account_type:
|
||||
self.setItemHidden(item, True)
|
||||
|
||||
|
||||
class MessagelistControl(QtGui.QWidget):
|
||||
@QtCore.pyqtProperty(int)
|
||||
def AccountType(self):
|
||||
return self._account_type
|
||||
|
||||
def setAccountType(self, value):
|
||||
self._account_type = value
|
||||
|
||||
def __init__(self, parent=None):
|
||||
super(MessagelistControl, self).__init__(parent)
|
||||
widgets.load('messagelistcontrol.ui', self)
|
||||
|
||||
self.horizontalSplitter.setStretchFactor(0, 0)
|
||||
self.horizontalSplitter.setStretchFactor(1, 1)
|
||||
self.horizontalSplitter.setCollapsible(0, False)
|
||||
self.horizontalSplitter.setCollapsible(1, False)
|
||||
|
||||
self.verticalSplitter.setStretchFactor(0, 0)
|
||||
self.verticalSplitter.setStretchFactor(1, 1)
|
||||
self.verticalSplitter.setStretchFactor(2, 2)
|
||||
self.verticalSplitter.setCollapsible(0, False)
|
||||
self.verticalSplitter.setCollapsible(1, False)
|
||||
self.verticalSplitter.setCollapsible(2, False)
|
||||
self.verticalSplitter.handle(1).setEnabled(False)
|
||||
|
||||
self.treeWidget.filterAccountType(self.AccountType)
|
||||
|
|
343
src/bitmessageqt/messagelistcontrol.ui
Normal file
343
src/bitmessageqt/messagelistcontrol.ui
Normal file
|
@ -0,0 +1,343 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>MessagelistControl</class>
|
||||
<widget class="QWidget" name="MessagelistControl">
|
||||
<property name="AccountType">
|
||||
<number>1</number>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>819</width>
|
||||
<height>295</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="inboxLayout">
|
||||
<property name="leftMargin">
|
||||
<number>8</number>
|
||||
</property>
|
||||
<property name="topMargin">
|
||||
<number>8</number>
|
||||
</property>
|
||||
<property name="rightMargin">
|
||||
<number>8</number>
|
||||
</property>
|
||||
<property name="bottomMargin">
|
||||
<number>8</number>
|
||||
</property>
|
||||
<item>
|
||||
<widget class="SSplitter" name="horizontalSplitter">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<widget class="QWidget" name="inboxIdentitiesWidget">
|
||||
<layout class="QVBoxLayout">
|
||||
<item>
|
||||
<widget class="TreeWidgetIdentities" name="treeWidget">
|
||||
<property name="baseSize">
|
||||
<size>
|
||||
<width>200</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="contextMenuPolicy">
|
||||
<enum>Qt::CustomContextMenu</enum>
|
||||
</property>
|
||||
<property name="sortingEnabled">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<column>
|
||||
<property name="text">
|
||||
<string>Identities</string>
|
||||
</property>
|
||||
<property name="icon">
|
||||
<iconset>
|
||||
<selectedoff>:/newPrefix/images/identities.png</selectedoff>
|
||||
</iconset>
|
||||
</property>
|
||||
</column>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="buttonNew">
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>200</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string notr="true">New</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="SSplitter" name="verticalSplitter">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Vertical</enum>
|
||||
</property>
|
||||
<widget class="QWidget" name="searchWidget">
|
||||
<layout class="QHBoxLayout" name="searchLayout">
|
||||
<item>
|
||||
<widget class="QLineEdit" name="searchLineEdit">
|
||||
<property name="placeholderText">
|
||||
<string>Search</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QComboBox" name="searchOption">
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>All</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>To</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>From</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Subject</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Message</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="InboxMessagelist" name="messagelistInbox">
|
||||
<property name="contextMenuPolicy">
|
||||
<enum>Qt::CustomContextMenu</enum>
|
||||
</property>
|
||||
<property name="editTriggers">
|
||||
<set>QAbstractItemView::NoEditTriggers</set>
|
||||
</property>
|
||||
<property name="alternatingRowColors">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="selectionMode">
|
||||
<enum>QAbstractItemView::ExtendedSelection</enum>
|
||||
</property>
|
||||
<property name="selectionBehavior">
|
||||
<enum>QAbstractItemView::SelectRows</enum>
|
||||
</property>
|
||||
<property name="sortingEnabled">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="wordWrap">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<attribute name="horizontalHeaderCascadingSectionResizes">
|
||||
<bool>true</bool>
|
||||
</attribute>
|
||||
<attribute name="horizontalHeaderDefaultSectionSize">
|
||||
<number>200</number>
|
||||
</attribute>
|
||||
<attribute name="horizontalHeaderHighlightSections">
|
||||
<bool>false</bool>
|
||||
</attribute>
|
||||
<attribute name="horizontalHeaderMinimumSectionSize">
|
||||
<number>27</number>
|
||||
</attribute>
|
||||
<attribute name="horizontalHeaderShowSortIndicator" stdset="0">
|
||||
<bool>false</bool>
|
||||
</attribute>
|
||||
<attribute name="horizontalHeaderStretchLastSection">
|
||||
<bool>true</bool>
|
||||
</attribute>
|
||||
<attribute name="verticalHeaderVisible">
|
||||
<bool>false</bool>
|
||||
</attribute>
|
||||
<attribute name="verticalHeaderDefaultSectionSize">
|
||||
<number>26</number>
|
||||
</attribute>
|
||||
</widget>
|
||||
<widget class="MessageView" name="messageView">
|
||||
<property name="baseSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
<height>500</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="readOnly">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="plainText">
|
||||
<string>
|
||||
Welcome to easy and secure Bitmessage
|
||||
* send messages to other people
|
||||
* send broadcast messages like twitter or
|
||||
* discuss in chan(nel)s with other people
|
||||
</string>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<customwidgets>
|
||||
<customwidget>
|
||||
<class>MessageView</class>
|
||||
<extends>QTextEdit</extends>
|
||||
<header>bitmessageqt.messageview</header>
|
||||
</customwidget>
|
||||
<customwidget>
|
||||
<class>STreeWidget</class>
|
||||
<extends>QTreeWidget</extends>
|
||||
<header>bitmessageqt.settingsmixin</header>
|
||||
</customwidget>
|
||||
<customwidget>
|
||||
<class>SSplitter</class>
|
||||
<extends>QSplitter</extends>
|
||||
<header>bitmessageqt.settingsmixin</header>
|
||||
<container>1</container>
|
||||
</customwidget>
|
||||
<customwidget>
|
||||
<class>InboxMessagelist</class>
|
||||
<extends>QTableView</extends>
|
||||
<header>bitmessageqt.messagelist</header>
|
||||
</customwidget>
|
||||
<customwidget>
|
||||
<class>TreeWidgetIdentities</class>
|
||||
<extends>QTreeWidget</extends>
|
||||
<header>bitmessageqt.messagelist</header>
|
||||
</customwidget>
|
||||
</customwidgets>
|
||||
<resources>
|
||||
<include location="bitmessage_icons.qrc"/>
|
||||
</resources>
|
||||
<connections>
|
||||
<!-- <connection> -->
|
||||
<!-- <sender>messagelistInbox</sender> -->
|
||||
<!-- <signal>customContextMenuRequested(QPoint)</signal> -->
|
||||
<!-- <receiver>MainWindow</receiver> -->
|
||||
<!-- <slot>on_context_menuInbox()</slot> -->
|
||||
<!-- <hints> -->
|
||||
<!-- <hint type="sourcelabel"> -->
|
||||
<!-- <x>656</x> -->
|
||||
<!-- <y>366</y> -->
|
||||
<!-- </hint> -->
|
||||
<!-- <hint type="destinationlabel"> -->
|
||||
<!-- <x>442</x> -->
|
||||
<!-- <y>289</y> -->
|
||||
<!-- </hint> -->
|
||||
<!-- </hints> -->
|
||||
<!-- </connection> -->
|
||||
<!-- <connection> -->
|
||||
<!-- <sender>pushButtonNewAddress</sender> -->
|
||||
<!-- <signal>clicked()</signal> -->
|
||||
<!-- <receiver>MainWindow</receiver> -->
|
||||
<!-- <slot>click_NewAddressDialog</slot> -->
|
||||
<!-- <hints> -->
|
||||
<!-- <hint type="sourcelabel"> -->
|
||||
<!-- <x>20</x> -->
|
||||
<!-- <y>20</y> -->
|
||||
<!-- </hint> -->
|
||||
<!-- <hint type="destinationlabel"> -->
|
||||
<!-- <x>20</x> -->
|
||||
<!-- <y>20</y> -->
|
||||
<!-- </hint> -->
|
||||
<!-- </hints> -->
|
||||
<!-- </connection> -->
|
||||
<!-- <connection> -->
|
||||
<!-- <sender>treeWidgetYourIdentities</sender> -->
|
||||
<!-- <signal>customContextMenuRequested(QPoint)</signal> -->
|
||||
<!-- <receiver>MainWindow</receiver> -->
|
||||
<!-- <slot>on_context_menuYourIdentities()</slot> -->
|
||||
<!-- <hints> -->
|
||||
<!-- <hint type="sourcelabel"> -->
|
||||
<!-- <x>20</x> -->
|
||||
<!-- <y>20</y> -->
|
||||
<!-- </hint> -->
|
||||
<!-- <hint type="destinationlabel"> -->
|
||||
<!-- <x>20</x> -->
|
||||
<!-- <y>20</y> -->
|
||||
<!-- </hint> -->
|
||||
<!-- </hints> -->
|
||||
<!-- </connection> -->
|
||||
<!-- <connection> -->
|
||||
<!-- <sender>inboxSearchLineEdit</sender> -->
|
||||
<!-- <signal>returnPressed()</signal> -->
|
||||
<!-- <receiver>MainWindow</receiver> -->
|
||||
<!-- <slot>inboxSearchLineEditReturnPressed</slot> -->
|
||||
<!-- <hints> -->
|
||||
<!-- <hint type="sourcelabel"> -->
|
||||
<!-- <x>20</x> -->
|
||||
<!-- <y>20</y> -->
|
||||
<!-- </hint> -->
|
||||
<!-- <hint type="destinationlabel"> -->
|
||||
<!-- <x>20</x> -->
|
||||
<!-- <y>20</y> -->
|
||||
<!-- </hint> -->
|
||||
<!-- </hints> -->
|
||||
<!-- </connection> -->
|
||||
<!-- <connection> -->
|
||||
<!-- <sender>inboxSearchLineEdit</sender> -->
|
||||
<!-- <signal>textChanged(QString)</signal> -->
|
||||
<!-- <receiver>MainWindow</receiver> -->
|
||||
<!-- <slot>inboxSearchLineEditUpdated</slot> -->
|
||||
<!-- <hints> -->
|
||||
<!-- <hint type="sourcelabel"> -->
|
||||
<!-- <x>20</x> -->
|
||||
<!-- <y>20</y> -->
|
||||
<!-- </hint> -->
|
||||
<!-- <hint type="destinationlabel"> -->
|
||||
<!-- <x>20</x> -->
|
||||
<!-- <y>20</y> -->
|
||||
<!-- </hint> -->
|
||||
<!-- </hints> -->
|
||||
<!-- </connection> -->
|
||||
<connection>
|
||||
<sender>treeWidget</sender>
|
||||
<signal>currentItemChanged(QTreeWidgetItem*, QTreeWidgetItem*)</signal>
|
||||
<receiver>messagelistInbox</receiver>
|
||||
<slot>folderChanged</slot>
|
||||
</connection>
|
||||
<!-- <connection> -->
|
||||
<!-- <sender>treeWidgetYourIdentities</sender> -->
|
||||
<!-- <signal>itemChanged(QTreeWidgetItem*,int)</signal> -->
|
||||
<!-- <receiver>MainWindow</receiver> -->
|
||||
<!-- <slot>treeWidgetItemChanged</slot> -->
|
||||
<!-- <hints> -->
|
||||
<!-- <hint type="sourcelabel"> -->
|
||||
<!-- <x>20</x> -->
|
||||
<!-- <y>20</y> -->
|
||||
<!-- </hint> -->
|
||||
<!-- <hint type="destinationlabel"> -->
|
||||
<!-- <x>20</x> -->
|
||||
<!-- <y>20</y> -->
|
||||
<!-- </hint> -->
|
||||
<!-- </hints> -->
|
||||
<!-- </connection> -->
|
||||
<connection>
|
||||
<sender>messagelistInbox</sender>
|
||||
<signal>messageSelected(QString)</signal>
|
||||
<receiver>messageView</receiver>
|
||||
<slot>setContent</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>20</x>
|
||||
<y>20</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>20</x>
|
||||
<y>20</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
</ui>
|
Reference in New Issue
Block a user