diff --git a/ankiqt/ui/main.py b/ankiqt/ui/main.py index 54b2f28d6..657ce6291 100644 --- a/ankiqt/ui/main.py +++ b/ankiqt/ui/main.py @@ -1913,7 +1913,8 @@ day = :d""", d=yesterday) def setupSound(self): anki.sound.noiseProfile = os.path.join( - self.config.configPath, "noise.profile") + self.config.configPath, "noise.profile").\ + encode(sys.getfilesystemencoding()) anki.sound.checkForNoiseProfile() def onRepeatAudio(self): diff --git a/ankiqt/ui/sound.py b/ankiqt/ui/sound.py index 860d15326..c4acdc642 100644 --- a/ankiqt/ui/sound.py +++ b/ankiqt/ui/sound.py @@ -52,5 +52,5 @@ def recordNoiseProfile(parent): QApplication.instance().processEvents() time.sleep(0.1) r.stop() - generateNoiseProfile(r.wavFile()) + generateNoiseProfile() mb.deleteLater() diff --git a/designer/main.ui b/designer/main.ui index 779fe17d0..16adfed3b 100644 --- a/designer/main.ui +++ b/designer/main.ui @@ -1865,6 +1865,10 @@ + + + :/icons/media-record.png:/icons/media-record.png + &Record Noise Profile...