--- a/eric6/Cooperation/ChatWidget.py Thu Sep 19 19:39:04 2019 +0200 +++ b/eric6/Cooperation/ChatWidget.py Sat Sep 21 13:03:17 2019 +0200 @@ -401,8 +401,8 @@ self.editorCommand.emit(hashStr, fileName, message) from QScintilla.Editor import Editor - if message.startswith(Editor.StartEditToken + Editor.Separator) or \ - message.startswith(Editor.EndEditToken + Editor.Separator): + if (message.startswith(Editor.StartEditToken + Editor.Separator) or + message.startswith(Editor.EndEditToken + Editor.Separator)): vm = e5App().getObject("ViewManager") aw = vm.activeWindow() if aw: @@ -494,29 +494,24 @@ Private slot to initialize the chat edit context menu. """ self.__chatMenu = QMenu(self) - self.__copyChatAct = \ - self.__chatMenu.addAction( - UI.PixmapCache.getIcon("editCopy.png"), - self.tr("Copy"), self.__copyChat) + self.__copyChatAct = self.__chatMenu.addAction( + UI.PixmapCache.getIcon("editCopy.png"), + self.tr("Copy"), self.__copyChat) self.__chatMenu.addSeparator() - self.__cutAllChatAct = \ - self.__chatMenu.addAction( - UI.PixmapCache.getIcon("editCut.png"), - self.tr("Cut all"), self.__cutAllChat) - self.__copyAllChatAct = \ - self.__chatMenu.addAction( - UI.PixmapCache.getIcon("editCopy.png"), - self.tr("Copy all"), self.__copyAllChat) + self.__cutAllChatAct = self.__chatMenu.addAction( + UI.PixmapCache.getIcon("editCut.png"), + self.tr("Cut all"), self.__cutAllChat) + self.__copyAllChatAct = self.__chatMenu.addAction( + UI.PixmapCache.getIcon("editCopy.png"), + self.tr("Copy all"), self.__copyAllChat) self.__chatMenu.addSeparator() - self.__clearChatAct = \ - self.__chatMenu.addAction( - UI.PixmapCache.getIcon("editDelete.png"), - self.tr("Clear"), self.__clearChat) + self.__clearChatAct = self.__chatMenu.addAction( + UI.PixmapCache.getIcon("editDelete.png"), + self.tr("Clear"), self.__clearChat) self.__chatMenu.addSeparator() - self.__saveChatAct = \ - self.__chatMenu.addAction( - UI.PixmapCache.getIcon("fileSave.png"), - self.tr("Save"), self.__saveChat) + self.__saveChatAct = self.__chatMenu.addAction( + UI.PixmapCache.getIcon("fileSave.png"), + self.tr("Save"), self.__saveChat) self.on_chatEdit_copyAvailable(False) @@ -621,18 +616,15 @@ Private slot to initialize the users list context menu. """ self.__usersMenu = QMenu(self) - self.__kickUserAct = \ - self.__usersMenu.addAction( - UI.PixmapCache.getIcon("chatKickUser.png"), - self.tr("Kick User"), self.__kickUser) - self.__banUserAct = \ - self.__usersMenu.addAction( - UI.PixmapCache.getIcon("chatBanUser.png"), - self.tr("Ban User"), self.__banUser) - self.__banKickUserAct = \ - self.__usersMenu.addAction( - UI.PixmapCache.getIcon("chatBanKickUser.png"), - self.tr("Ban and Kick User"), self.__banKickUser) + self.__kickUserAct = self.__usersMenu.addAction( + UI.PixmapCache.getIcon("chatKickUser.png"), + self.tr("Kick User"), self.__kickUser) + self.__banUserAct = self.__usersMenu.addAction( + UI.PixmapCache.getIcon("chatBanUser.png"), + self.tr("Ban User"), self.__banUser) + self.__banKickUserAct = self.__usersMenu.addAction( + UI.PixmapCache.getIcon("chatBanKickUser.png"), + self.tr("Ban and Kick User"), self.__banKickUser) @pyqtSlot(QPoint) def on_usersList_customContextMenuRequested(self, pos):