Daniel Brötzmann pushed to branch master at gajim / gajim
Commits:
634db69d by wurstsalat at 2024-06-05T19:59:41+02:00
cfix: VoiceMessageRecorder: Make error strings translatable
- - - - -
1 changed file:
- gajim/gtk/voice_message_recorder.py
Changes:
=====================================
gajim/gtk/voice_message_recorder.py
=====================================
@@ -17,6 +17,7 @@
from pathlib import Path
from gajim.common import app
+from gajim.common.i18n import _
try:
from gi.repository import Gst
@@ -305,7 +306,7 @@ def _handle_error_on_start(self, message: Gst.Message) ->
None:
# used when resource fails to open for reading.
self._error_callback(
GST_ERROR_ON_START,
- 'Is a microphone plugged in and accessible?'
+ _('Is a microphone plugged in and accessible?')
)
def _handle_error_on_recording(self, message: Gst.Message | None):
@@ -321,7 +322,8 @@ def _handle_error_on_recording(self, message: Gst.Message |
None):
# used when the resource can't be read from.
self._error_callback(
GST_ERROR_ON_RECORDING,
- 'Is a microphone plugged in and accessible?')
+ _('Is a microphone plugged in and accessible?')
+ )
if domain == 'gst-stream-error-quark':
if code == 1:
@@ -330,7 +332,8 @@ def _handle_error_on_recording(self, message: Gst.Message |
None):
# Make sure you add a custom message to the error call.
self._error_callback(
GST_ERROR_ON_RECORDING,
- 'General Stream Error.')
+ _('Error in audio data stream.')
+ )
def _handle_error_on_stop(self, message: Gst.Message | None) -> None:
if message is not None and not self._is_error(message):
View it on GitLab:
https://dev.gajim.org/gajim/gajim/-/commit/634db69db311e32358258c34be8394fc5fd4ceca
--
View it on GitLab:
https://dev.gajim.org/gajim/gajim/-/commit/634db69db311e32358258c34be8394fc5fd4ceca
You're receiving this email because of your account on dev.gajim.org.
_______________________________________________
Commits mailing list -- [email protected]
To unsubscribe send an email to [email protected]