204 ) |
204 ) |
205 Preferences.syncPreferences() |
205 Preferences.syncPreferences() |
206 if bannedName in Preferences.getCooperation("BannedUsers"): |
206 if bannedName in Preferences.getCooperation("BannedUsers"): |
207 self.rejected.emit(self.trUtf8( |
207 self.rejected.emit(self.trUtf8( |
208 "* Connection attempted by banned user '{0}'.") |
208 "* Connection attempted by banned user '{0}'.") |
209 .format(bannedName)) |
209 .format(bannedName)) |
210 self.abort() |
210 self.abort() |
211 return |
211 return |
212 |
212 |
213 if self.__serverPort != self.peerPort() and \ |
213 if self.__serverPort != self.peerPort() and \ |
214 not Preferences.getCooperation("AutoAcceptConnections"): |
214 not Preferences.getCooperation("AutoAcceptConnections"): |
215 # don't ask for reverse connections or |
215 # don't ask for reverse connections or |
216 # if we shall accept automatically |
216 # if we shall accept automatically |
217 res = E5MessageBox.yesNo(None, |
217 res = E5MessageBox.yesNo( |
|
218 None, |
218 self.trUtf8("New Connection"), |
219 self.trUtf8("New Connection"), |
219 self.trUtf8("""<p>Accept connection from """ |
220 self.trUtf8("""<p>Accept connection from """ |
220 """<strong>{0}@{1}</strong>?</p>""").format( |
221 """<strong>{0}@{1}</strong>?</p>""").format( |
221 user, hostInfo.hostName()), |
222 user, hostInfo.hostName()), |
222 yesDefault=True) |
223 yesDefault=True) |