--- a/eric7/Snapshot/SnapWidget.py Sat Sep 25 18:08:10 2021 +0200 +++ b/eric7/Snapshot/SnapWidget.py Sat Sep 25 18:12:48 2021 +0200 @@ -84,18 +84,18 @@ if SnapshotModes.FREEHAND in supportedModes: self.modeCombo.addItem(self.tr("Freehand Selection"), SnapshotModes.FREEHAND) - mode = int(Preferences.Prefs.settings.value("Snapshot/Mode", 0)) + mode = int(Preferences.getSettings().value("Snapshot/Mode", 0)) index = self.modeCombo.findData(SnapshotModes(mode)) if index == -1: index = 0 self.modeCombo.setCurrentIndex(index) - delay = int(Preferences.Prefs.settings.value("Snapshot/Delay", 0)) + delay = int(Preferences.getSettings().value("Snapshot/Delay", 0)) self.delaySpin.setValue(delay) picturesLocation = QStandardPaths.writableLocation( QStandardPaths.StandardLocation.PicturesLocation) - self.__filename = Preferences.Prefs.settings.value( + self.__filename = Preferences.getSettings().value( "Snapshot/Filename", os.path.join(picturesLocation, self.tr("snapshot") + "1.png")) @@ -403,16 +403,16 @@ elif res == EricMessageBox.Save: self.on_saveButton_clicked() - Preferences.Prefs.settings.setValue( + Preferences.getSettings().setValue( "Snapshot/Delay", self.delaySpin.value()) modeData = self.modeCombo.itemData(self.modeCombo.currentIndex()) if modeData is not None: - Preferences.Prefs.settings.setValue( + Preferences.getSettings().setValue( "Snapshot/Mode", modeData.value) - Preferences.Prefs.settings.setValue( + Preferences.getSettings().setValue( "Snapshot/Filename", self.__filename) - Preferences.Prefs.settings.sync() + Preferences.getSettings().sync() def __updateCaption(self): """