Low-bandwidth mode
This commit is contained in:
parent
311594d356
commit
dc2eaf7ce8
6 changed files with 29 additions and 3 deletions
|
@ -32,6 +32,7 @@ CHANGELOG
|
|||
* Toast Notifications - Kiooeht [evacipatedBox]
|
||||
* Disable randomEncounter options when it's offline - Kiooeht [evacipatedBox] (Idea: Lexi [lexicalNuance])
|
||||
* Sort list of memos alphabetically or by number of users - Kiooeht [evacipatedBox] (Idea: [lostGash])
|
||||
* Low-bandwidth mode - Kiooeht [evacipatedBox] (Idea: [canLover])
|
||||
* Bug fixes
|
||||
* Don't delete random chum when blocking someone not on chumroll - Kiooeht [evacipatedBox]
|
||||
* Openning global userlist doesn't reset OP status of memo users - Kiooeht [evacipatedBox]
|
||||
|
|
|
@ -33,6 +33,7 @@ Bugs
|
|||
* Closing a timeclone doesn't actually cease for everyone else
|
||||
* Kill Zalgo
|
||||
* Random invisible, tiny links to last link at end of every message
|
||||
* Profiles using themes you don't have break everything
|
||||
|
||||
Windows Bugs
|
||||
------------
|
||||
|
|
6
irc.py
6
irc.py
|
@ -229,6 +229,7 @@ class PesterIRC(QtCore.QThread):
|
|||
c = unicode(channel)
|
||||
try:
|
||||
helpers.part(self.cli, c)
|
||||
self.cli.command_handler.joined = False
|
||||
except socket.error:
|
||||
self.setConnectionBroken()
|
||||
@QtCore.pyqtSlot(QtCore.QString, QtCore.QString)
|
||||
|
@ -390,9 +391,10 @@ class PesterHandler(DefaultCommandHandler):
|
|||
|
||||
def welcome(self, server, nick, msg):
|
||||
self.parent.setConnected()
|
||||
helpers.join(self.client, "#pesterchum")
|
||||
mychumhandle = self.mainwindow.profile().handle
|
||||
mymood = self.mainwindow.profile().mood.value()
|
||||
if not self.mainwindow.config.lowBandwidth():
|
||||
helpers.join(self.client, "#pesterchum")
|
||||
helpers.msg(self.client, "#pesterchum", "MOOD >%d" % (mymood))
|
||||
|
||||
def nicknameinuse(self, server, cmd, nick, msg):
|
||||
|
@ -484,7 +486,7 @@ class PesterHandler(DefaultCommandHandler):
|
|||
pl = PesterList(namelist)
|
||||
del self.channelnames[channel]
|
||||
self.parent.namesReceived.emit(channel, pl)
|
||||
if channel == "#pesterchum" and not hasattr(self, "joined"):
|
||||
if channel == "#pesterchum" and (not hasattr(self, "joined") or not self.joined):
|
||||
self.joined = True
|
||||
self.parent.mainwindow.randhandler.setRunning(self.parent.mainwindow.randhandler.randNick in namelist)
|
||||
chums = self.mainwindow.chumList.chums
|
||||
|
|
11
menus.py
11
menus.py
|
@ -1006,6 +1006,15 @@ class PesterOptions(QtGui.QDialog):
|
|||
self.tabs.button(-2).setChecked(True)
|
||||
self.pages = QtGui.QStackedWidget(self)
|
||||
|
||||
self.bandwidthcheck = QtGui.QCheckBox("Low Bandwidth", self)
|
||||
if self.config.lowBandwidth():
|
||||
self.bandwidthcheck.setChecked(True)
|
||||
bandwidthLabel = QtGui.QLabel("(Stops you for receiving the flood of MOODS,\n"
|
||||
" though stops chumlist from working properly)")
|
||||
font = bandwidthLabel.font()
|
||||
font.setPointSize(8)
|
||||
bandwidthLabel.setFont(font)
|
||||
|
||||
self.tabcheck = QtGui.QCheckBox("Tabbed Conversations", self)
|
||||
if self.config.tabs():
|
||||
self.tabcheck.setChecked(True)
|
||||
|
@ -1234,6 +1243,8 @@ class PesterOptions(QtGui.QDialog):
|
|||
layout_chumlist.addWidget(self.showemptycheck)
|
||||
layout_chumlist.addWidget(self.showonlinenumbers)
|
||||
layout_chumlist.addLayout(layout_3)
|
||||
layout_chumlist.addWidget(self.bandwidthcheck)
|
||||
layout_chumlist.addWidget(bandwidthLabel)
|
||||
self.pages.addWidget(widget)
|
||||
|
||||
# Conversations
|
||||
|
|
|
@ -2362,6 +2362,15 @@ class PesterWindow(MovingWindow):
|
|||
curnotify = self.config.notifyOptions()
|
||||
if notifysetting != curnotify:
|
||||
self.config.set('notifyOptions', notifysetting)
|
||||
# low bandwidth
|
||||
bandwidthsetting = self.optionmenu.bandwidthcheck.isChecked()
|
||||
curbandwidth = self.config.lowBandwidth()
|
||||
if bandwidthsetting != curbandwidth:
|
||||
self.config.set('lowBandwidth', bandwidthsetting)
|
||||
if bandwidthsetting:
|
||||
self.leftChannel.emit("#pesterchum")
|
||||
else:
|
||||
self.joinChannel.emit("#pesterchum")
|
||||
# advanced
|
||||
## user mode
|
||||
if self.advanced:
|
||||
|
|
|
@ -197,6 +197,8 @@ class userConfig(object):
|
|||
return self.config.get('notifyType', "default")
|
||||
def notifyOptions(self):
|
||||
return self.config.get('notifyOptions', self.SIGNIN | self.NEWMSG | self.NEWCONVO | self.INITIALS)
|
||||
def lowBandwidth(self):
|
||||
return self.config.get('lowBandwidth', True)
|
||||
def addChum(self, chum):
|
||||
if chum.handle not in self.chums():
|
||||
fp = open(self.filename) # what if we have two clients open??
|
||||
|
|
Loading…
Reference in a new issue