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]
|
* Toast Notifications - Kiooeht [evacipatedBox]
|
||||||
* Disable randomEncounter options when it's offline - Kiooeht [evacipatedBox] (Idea: Lexi [lexicalNuance])
|
* 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])
|
* Sort list of memos alphabetically or by number of users - Kiooeht [evacipatedBox] (Idea: [lostGash])
|
||||||
|
* Low-bandwidth mode - Kiooeht [evacipatedBox] (Idea: [canLover])
|
||||||
* Bug fixes
|
* Bug fixes
|
||||||
* Don't delete random chum when blocking someone not on chumroll - Kiooeht [evacipatedBox]
|
* 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]
|
* 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
|
* Closing a timeclone doesn't actually cease for everyone else
|
||||||
* Kill Zalgo
|
* Kill Zalgo
|
||||||
* Random invisible, tiny links to last link at end of every message
|
* Random invisible, tiny links to last link at end of every message
|
||||||
|
* Profiles using themes you don't have break everything
|
||||||
|
|
||||||
Windows Bugs
|
Windows Bugs
|
||||||
------------
|
------------
|
||||||
|
|
8
irc.py
8
irc.py
|
@ -229,6 +229,7 @@ class PesterIRC(QtCore.QThread):
|
||||||
c = unicode(channel)
|
c = unicode(channel)
|
||||||
try:
|
try:
|
||||||
helpers.part(self.cli, c)
|
helpers.part(self.cli, c)
|
||||||
|
self.cli.command_handler.joined = False
|
||||||
except socket.error:
|
except socket.error:
|
||||||
self.setConnectionBroken()
|
self.setConnectionBroken()
|
||||||
@QtCore.pyqtSlot(QtCore.QString, QtCore.QString)
|
@QtCore.pyqtSlot(QtCore.QString, QtCore.QString)
|
||||||
|
@ -390,10 +391,11 @@ class PesterHandler(DefaultCommandHandler):
|
||||||
|
|
||||||
def welcome(self, server, nick, msg):
|
def welcome(self, server, nick, msg):
|
||||||
self.parent.setConnected()
|
self.parent.setConnected()
|
||||||
helpers.join(self.client, "#pesterchum")
|
|
||||||
mychumhandle = self.mainwindow.profile().handle
|
mychumhandle = self.mainwindow.profile().handle
|
||||||
mymood = self.mainwindow.profile().mood.value()
|
mymood = self.mainwindow.profile().mood.value()
|
||||||
helpers.msg(self.client, "#pesterchum", "MOOD >%d" % (mymood))
|
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):
|
def nicknameinuse(self, server, cmd, nick, msg):
|
||||||
newnick = "pesterClient%d" % (random.randint(100,999))
|
newnick = "pesterClient%d" % (random.randint(100,999))
|
||||||
|
@ -484,7 +486,7 @@ class PesterHandler(DefaultCommandHandler):
|
||||||
pl = PesterList(namelist)
|
pl = PesterList(namelist)
|
||||||
del self.channelnames[channel]
|
del self.channelnames[channel]
|
||||||
self.parent.namesReceived.emit(channel, pl)
|
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.joined = True
|
||||||
self.parent.mainwindow.randhandler.setRunning(self.parent.mainwindow.randhandler.randNick in namelist)
|
self.parent.mainwindow.randhandler.setRunning(self.parent.mainwindow.randhandler.randNick in namelist)
|
||||||
chums = self.mainwindow.chumList.chums
|
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.tabs.button(-2).setChecked(True)
|
||||||
self.pages = QtGui.QStackedWidget(self)
|
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)
|
self.tabcheck = QtGui.QCheckBox("Tabbed Conversations", self)
|
||||||
if self.config.tabs():
|
if self.config.tabs():
|
||||||
self.tabcheck.setChecked(True)
|
self.tabcheck.setChecked(True)
|
||||||
|
@ -1234,6 +1243,8 @@ class PesterOptions(QtGui.QDialog):
|
||||||
layout_chumlist.addWidget(self.showemptycheck)
|
layout_chumlist.addWidget(self.showemptycheck)
|
||||||
layout_chumlist.addWidget(self.showonlinenumbers)
|
layout_chumlist.addWidget(self.showonlinenumbers)
|
||||||
layout_chumlist.addLayout(layout_3)
|
layout_chumlist.addLayout(layout_3)
|
||||||
|
layout_chumlist.addWidget(self.bandwidthcheck)
|
||||||
|
layout_chumlist.addWidget(bandwidthLabel)
|
||||||
self.pages.addWidget(widget)
|
self.pages.addWidget(widget)
|
||||||
|
|
||||||
# Conversations
|
# Conversations
|
||||||
|
|
|
@ -2362,6 +2362,15 @@ class PesterWindow(MovingWindow):
|
||||||
curnotify = self.config.notifyOptions()
|
curnotify = self.config.notifyOptions()
|
||||||
if notifysetting != curnotify:
|
if notifysetting != curnotify:
|
||||||
self.config.set('notifyOptions', notifysetting)
|
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
|
# advanced
|
||||||
## user mode
|
## user mode
|
||||||
if self.advanced:
|
if self.advanced:
|
||||||
|
|
|
@ -197,6 +197,8 @@ class userConfig(object):
|
||||||
return self.config.get('notifyType', "default")
|
return self.config.get('notifyType', "default")
|
||||||
def notifyOptions(self):
|
def notifyOptions(self):
|
||||||
return self.config.get('notifyOptions', self.SIGNIN | self.NEWMSG | self.NEWCONVO | self.INITIALS)
|
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):
|
def addChum(self, chum):
|
||||||
if chum.handle not in self.chums():
|
if chum.handle not in self.chums():
|
||||||
fp = open(self.filename) # what if we have two clients open??
|
fp = open(self.filename) # what if we have two clients open??
|
||||||
|
|
Loading…
Reference in a new issue