New tab "Adjusting time period for resending messages" was added

This commit is contained in:
ikarakatsanis 2013-09-27 02:14:24 +04:00
parent 2293253d38
commit 234081cc17
2 changed files with 119 additions and 3 deletions

View File

@ -318,7 +318,49 @@ class Ui_settingsDialog(object):
self.gridLayout_8.addLayout(self.horizontalLayout, 1, 0, 1, 3) self.gridLayout_8.addLayout(self.horizontalLayout, 1, 0, 1, 3)
self.tabWidgetSettings.addTab(self.tabNamecoin, _fromUtf8("")) self.tabWidgetSettings.addTab(self.tabNamecoin, _fromUtf8(""))
self.gridLayout.addWidget(self.tabWidgetSettings, 0, 0, 1, 1) self.gridLayout.addWidget(self.tabWidgetSettings, 0, 0, 1, 1)
#this line existed before
#my new implementation starts here
self.tabResendingMessagesAdjustment=QtGui.QWidget()
self.tabResendingMessagesAdjustment.setObjectName(_fromUtf8("tabResendingMessagesAdjustment"))
self.gridLayout_9 = QtGui.QGridLayout(self.tabResendingMessagesAdjustment)
self.gridLayout_9.setObjectName(_fromUtf8("gridLayout_9"))
self.label_19 = QtGui.QLabel(self.tabResendingMessagesAdjustment)
self.label_19.setWordWrap(True)
self.label_19.setObjectName(_fromUtf8("label_19"))
self.gridLayout_9.addWidget(self.label_19, 0, 0, 1, 0)
spacerItem13 = QtGui.QSpacerItem(102, 20, QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Minimum)
self.gridLayout_9.addItem(spacerItem13, 1, 0, 1, 1)
self.horizontalLayout = QtGui.QHBoxLayout()
self.horizontalLayout.setObjectName(_fromUtf8("horizontalLayout"))
self.label_20 = QtGui.QLabel(self.tabResendingMessagesAdjustment)
self.label_20.setLayoutDirection(QtCore.Qt.LeftToRight)
self.label_20.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
self.label_20.setObjectName(_fromUtf8("label_20"))
self.gridLayout_9.addWidget(self.label_20, 2, 0, 1, 1)
self.lineEditHours = QtGui.QLineEdit(self.tabResendingMessagesAdjustment)
self.lineEditHours.setMaximumSize(QtCore.QSize(33, 16777))
self.lineEditHours.setObjectName(_fromUtf8("lineEditHours"))
self.gridLayout_9.addWidget(self.lineEditHours, 2, 1, 1, 1)
self.label_22 = QtGui.QLabel(self.tabResendingMessagesAdjustment)
self.label_22.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
self.label_22.setObjectName(_fromUtf8("label_22"))
self.gridLayout_9.addWidget(self.label_22, 2, 2, 1, 1)
self.lineEditDays = QtGui.QLineEdit(self.tabResendingMessagesAdjustment)
self.lineEditDays.setMaximumSize(QtCore.QSize(33, 16777))
self.lineEditDays.setObjectName(_fromUtf8("lineEditDays"))
self.gridLayout_9.addWidget(self.lineEditDays, 2, 3, 1, 1)
self.label_23 = QtGui.QLabel(self.tabResendingMessagesAdjustment)
self.label_23.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
self.label_23.setObjectName(_fromUtf8("label_23"))
self.gridLayout_9.addWidget(self.label_23, 2, 4, 1, 1)
self.lineEditMonths = QtGui.QLineEdit(self.tabResendingMessagesAdjustment)
self.lineEditMonths.setMaximumSize(QtCore.QSize(33, 16777))
self.lineEditMonths.setObjectName(_fromUtf8("lineEditMonths"))
self.gridLayout_9.addWidget(self.lineEditMonths, 2, 5, 1, 1)
spacerItem15 = QtGui.QSpacerItem(20, 147, QtGui.QSizePolicy.Minimum, QtGui.QSizePolicy.Expanding)
self.gridLayout_9.addItem(spacerItem15, 3, 1, 1, 1)
self.tabWidgetSettings.addTab(self.tabResendingMessagesAdjustment, _fromUtf8(""))
#my new implementation stops here, it wasn't line here
self.retranslateUi(settingsDialog) self.retranslateUi(settingsDialog)
self.tabWidgetSettings.setCurrentIndex(0) self.tabWidgetSettings.setCurrentIndex(0)
QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("accepted()")), settingsDialog.accept) QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL(_fromUtf8("accepted()")), settingsDialog.accept)
@ -382,6 +424,13 @@ class Ui_settingsDialog(object):
self.tabWidgetSettings.setTabText(self.tabWidgetSettings.indexOf(self.tab), _translate("settingsDialog", "Demanded difficulty", None)) self.tabWidgetSettings.setTabText(self.tabWidgetSettings.indexOf(self.tab), _translate("settingsDialog", "Demanded difficulty", None))
self.label_15.setText(_translate("settingsDialog", "Here you may set the maximum amount of work you are willing to do to send a message to another person. Setting these values to 0 means that any value is acceptable.", None)) self.label_15.setText(_translate("settingsDialog", "Here you may set the maximum amount of work you are willing to do to send a message to another person. Setting these values to 0 means that any value is acceptable.", None))
self.label_13.setText(_translate("settingsDialog", "Maximum acceptable total difficulty:", None)) self.label_13.setText(_translate("settingsDialog", "Maximum acceptable total difficulty:", None))
#my new implementation starts here,it wasn't line here
self.tabWidgetSettings.setTabText(self.tabWidgetSettings.indexOf(self.tabResendingMessagesAdjustment), _translate("settingsDialog", "Adjusting time period for resending messages", None))
self.label_19.setText(_translate("settingsDialog", "<html><head/><body><p>If you send a message to someone and he is offline for more than two days, Bitmessage will send the message again after an additional two days. This will be continued with exponential backoff forever. Messages will continue to be sent after 4, 8,16 days and so on until the receiver get them. </p><p> Here you can adjust Bitmessage to stop trying to send messages after X hours/days/months. This time period needs to be longer than 5 days.</p></body></html>", None))
self.label_20.setText(_translate("settingsDialog", "Time in hours/days/months:", None))
self.label_22.setText(_translate("settingsDialog", "/", None))
self.label_23.setText(_translate("settingsDialog", "/", None))
#my new implementation stops here, it wasn't line here
self.label_14.setText(_translate("settingsDialog", "Maximum acceptable small message difficulty:", None)) self.label_14.setText(_translate("settingsDialog", "Maximum acceptable small message difficulty:", None))
self.tabWidgetSettings.setTabText(self.tabWidgetSettings.indexOf(self.tab_2), _translate("settingsDialog", "Max acceptable difficulty", None)) self.tabWidgetSettings.setTabText(self.tabWidgetSettings.indexOf(self.tab_2), _translate("settingsDialog", "Max acceptable difficulty", None))
self.label_16.setText(_translate("settingsDialog", "<html><head/><body><p>Bitmessage can utilize a different Bitcoin-based program called Namecoin to make addresses human-friendly. For example, instead of having to tell your friend your long Bitmessage address, you can simply tell him to send a message to <span style=\" font-style:italic;\">test. </span></p><p>(Getting your own Bitmessage address into Namecoin is still rather difficult).</p><p>Bitmessage can use either namecoind directly or a running nmcontrol instance.</p></body></html>", None)) self.label_16.setText(_translate("settingsDialog", "<html><head/><body><p>Bitmessage can utilize a different Bitcoin-based program called Namecoin to make addresses human-friendly. For example, instead of having to tell your friend your long Bitmessage address, you can simply tell him to send a message to <span style=\" font-style:italic;\">test. </span></p><p>(Getting your own Bitmessage address into Namecoin is still rather difficult).</p><p>Bitmessage can use either namecoind directly or a running nmcontrol instance.</p></body></html>", None))
@ -395,4 +444,3 @@ class Ui_settingsDialog(object):
self.radioButtonNamecoinNmcontrol.setText(_translate("settingsDialog", "NMControl", None)) self.radioButtonNamecoinNmcontrol.setText(_translate("settingsDialog", "NMControl", None))
self.tabWidgetSettings.setTabText(self.tabWidgetSettings.indexOf(self.tabNamecoin), _translate("settingsDialog", "Namecoin integration", None)) self.tabWidgetSettings.setTabText(self.tabWidgetSettings.indexOf(self.tabNamecoin), _translate("settingsDialog", "Namecoin integration", None))
#just test

View File

@ -756,6 +756,74 @@
</item> </item>
</layout> </layout>
</widget> </widget>
<widget class="QWidget" name="tabResendingMessagesAdjustment">
<attribute name="title">
<string>Adjusting time period for resending messages</string>
</attribute>
<layout class="QGridLayout" name="gridLayout_9">
<item row="0" column="0" colspan="5">
<widget class="QLabel" name="label_19">
<property name="text">
<string> If you send a message to someone and he is offline for more than two days, Bitmessage will send the message again after an additional two days. This will be continued with exponential backoff forever. Μessages will continue to be sent after 4, 8,16 days etc. until the receiver get them. Here you can adjust Bitmessage to stop trying to send messages after X hours/days/months. This time period needs to be longer than 5 days./p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="wordWrap">
<bool>true</bool>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_20">
<property name="layoutDirection">
<enum>Qt::LeftToRight</enum>
</property>
<property name="text">
<string>Time in hours/days/months:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QLineEdit" name="lineEditHours">
<property name="maximumSize">
<size>
<width>33</width>
<height>16777215</height>
</size>
</property>
</widget>
</item>
<item row="1" column="2">
<widget class="QLabel" name="label_22">
<property name="text">
<string>/</string>
</property>
</widget>
<item row="1" column="3">
<widget class="QLineEdit" name="lineEditDays"/>
</item>
<item row="1" column="4">
<widget class="QLabel" name="label_23">
<property name="text">
<string>/</string>
</property>
</widget>
<item row="1" column="5">
<widget class="QLineEdit" name="lineEditMonths"/>
</item>
<property name="maximumSize">
<size>
<width>33</width>
<height>16777215</height>
</size>
</property>
</widget>
</item>
</item>
</layout>
</widget>
<tabstops> <tabstops>
<tabstop>tabWidgetSettings</tabstop> <tabstop>tabWidgetSettings</tabstop>
<tabstop>checkBoxStartOnLogon</tabstop> <tabstop>checkBoxStartOnLogon</tabstop>
@ -792,7 +860,7 @@
</connection> </connection>
<connection> <connection>
<sender>buttonBox</sender> <sender>buttonBox</sender>
<signal>rejected()</signal> <signal>rejected)</signal>
<receiver>settingsDialog</receiver> <receiver>settingsDialog</receiver>
<slot>reject()</slot> <slot>reject()</slot>
<hints> <hints>