Hello community, here is the log from the commit of package reco for openSUSE:Factory checked in at 2019-08-15 12:29:37 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/reco (Old) and /work/SRC/openSUSE:Factory/.reco.new.9556 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "reco" Thu Aug 15 12:29:37 2019 rev:2 rq:723389 version:2.1.0 Changes: -------- --- /work/SRC/openSUSE:Factory/reco/reco.changes 2019-07-11 13:16:43.662798877 +0200 +++ /work/SRC/openSUSE:Factory/.reco.new.9556/reco.changes 2019-08-15 12:29:44.242473634 +0200 @@ -1,0 +2,14 @@ +Wed Aug 7 20:33:07 UTC 2019 - Alexei Podvalsky <[email protected]> + +- Update to 2.1.0: + * Update screenshots + * Fix the app freezes on closing an error dialog + * Save recordings when the app window is destroyed (#35) + * Use GLib methods for debug instead of printf + * Allow to cancel/pause countdown before recording (#36) + * Lessen scope if possible + * Use 'meson.project_name()' instead of hardcoding + * Use Granite constants for text styles + * Avoid emulating click signals + +------------------------------------------------------------------- Old: ---- reco-2.0.0.tar.gz New: ---- reco-2.1.0.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ reco.spec ++++++ --- /var/tmp/diff_new_pack.915DCp/_old 2019-08-15 12:29:44.814473104 +0200 +++ /var/tmp/diff_new_pack.915DCp/_new 2019-08-15 12:29:44.818473100 +0200 @@ -17,7 +17,7 @@ Name: reco -Version: 2.0.0 +Version: 2.1.0 Release: 0 Summary: Audio Recording App License: GPL-3.0-or-later ++++++ reco-2.0.0.tar.gz -> reco-2.1.0.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/reco-2.0.0/data/com.github.ryonakano.reco.appdata.xml.in new/reco-2.1.0/data/com.github.ryonakano.reco.appdata.xml.in --- old/reco-2.0.0/data/com.github.ryonakano.reco.appdata.xml.in 2019-06-01 13:44:54.000000000 +0200 +++ new/reco-2.1.0/data/com.github.ryonakano.reco.appdata.xml.in 2019-08-03 02:36:52.000000000 +0200 @@ -76,12 +76,12 @@ </content_rating> <releases> - <release version="2.0.0" date="2019-06-01"> + <release version="2.1.0" date="2019-08-03"> <description> <ul> - <li>Allow to record system sound</li> - <li>Fix the timer does not stop in accordance with the recording</li> - <li>Update Japanese translation</li> + <li>Allow to cancel/pause countdown before recording</li> + <li>Save recordings when the app window is destroyed</li> + <li>Fix the app freezes on closing an error dialog</li> </ul> </description> </release> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/reco-2.0.0/data/meson.build new/reco-2.1.0/data/meson.build --- old/reco-2.0.0/data/meson.build 2019-06-01 13:44:54.000000000 +0200 +++ new/reco-2.1.0/data/meson.build 2019-08-03 02:36:52.000000000 +0200 @@ -13,8 +13,8 @@ ) i18n.merge_file( - input: 'com.github.ryonakano.reco.desktop.in', - output: 'com.github.ryonakano.reco.desktop', + input: meson.project_name() + '.desktop.in', + output: meson.project_name() + '.desktop', po_dir: join_paths(meson.source_root(), 'po', 'extra'), type: 'desktop', install: true, @@ -22,14 +22,14 @@ ) i18n.merge_file( - input: 'com.github.ryonakano.reco.appdata.xml.in', - output: 'com.github.ryonakano.reco.appdata.xml', + input: meson.project_name() + '.appdata.xml.in', + output: meson.project_name() + '.appdata.xml', po_dir: join_paths(meson.source_root(), 'po', 'extra'), install: true, install_dir: join_paths(get_option('datadir'), 'metainfo') ) install_data( - 'com.github.ryonakano.reco.gschema.xml', + meson.project_name() + '.gschema.xml', install_dir: join_paths(get_option('datadir'), 'glib-2.0', 'schemas') ) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/reco-2.0.0/meson.build new/reco-2.1.0/meson.build --- old/reco-2.0.0/meson.build 2019-06-01 13:44:54.000000000 +0200 +++ new/reco-2.1.0/meson.build 2019-08-03 02:36:52.000000000 +0200 @@ -1,4 +1,4 @@ -project('com.github.ryonakano.reco', 'vala', 'c', version: '2.0.0') +project('com.github.ryonakano.reco', 'vala', 'c', version: '2.1.0') gnome = import('gnome') i18n = import('i18n') diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/reco-2.0.0/po/com.github.ryonakano.reco.pot new/reco-2.1.0/po/com.github.ryonakano.reco.pot --- old/reco-2.0.0/po/com.github.ryonakano.reco.pot 2019-06-01 13:44:54.000000000 +0200 +++ new/reco-2.1.0/po/com.github.ryonakano.reco.pot 2019-08-03 02:36:52.000000000 +0200 @@ -8,7 +8,7 @@ msgstr "" "Project-Id-Version: com.github.ryonakano.reco\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-06-01 20:05+0900\n" +"POT-Creation-Date: 2019-08-03 09:32+0900\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" "Language-Team: LANGUAGE <[email protected]>\n" @@ -17,68 +17,68 @@ "Content-Type: text/plain; charset=CHARSET\n" "Content-Transfer-Encoding: 8bit\n" -#: src/Views/WelcomeView.vala:32 +#: src/Views/WelcomeView.vala:33 msgid "Recording" msgstr "" -#: src/Views/WelcomeView.vala:34 +#: src/Views/WelcomeView.vala:35 msgid "Delay in seconds:" msgstr "" -#: src/Views/WelcomeView.vala:40 +#: src/Views/WelcomeView.vala:41 msgid "Length in seconds:" msgstr "" -#: src/Views/WelcomeView.vala:46 +#: src/Views/WelcomeView.vala:47 msgid "Record system sound:" msgstr "" -#: src/Views/WelcomeView.vala:52 +#: src/Views/WelcomeView.vala:53 msgid "Saving" msgstr "" -#: src/Views/WelcomeView.vala:54 +#: src/Views/WelcomeView.vala:55 msgid "Format:" msgstr "" -#: src/Views/WelcomeView.vala:59 +#: src/Views/WelcomeView.vala:60 msgid "AAC" msgstr "" -#: src/Views/WelcomeView.vala:60 +#: src/Views/WelcomeView.vala:61 msgid "FLAC" msgstr "" -#: src/Views/WelcomeView.vala:61 +#: src/Views/WelcomeView.vala:62 msgid "MP3" msgstr "" -#: src/Views/WelcomeView.vala:62 +#: src/Views/WelcomeView.vala:63 msgid "Ogg Vorbis" msgstr "" -#: src/Views/WelcomeView.vala:63 +#: src/Views/WelcomeView.vala:64 msgid "Opus" msgstr "" -#: src/Views/WelcomeView.vala:64 +#: src/Views/WelcomeView.vala:65 msgid "WAV" msgstr "" -#: src/Views/WelcomeView.vala:67 +#: src/Views/WelcomeView.vala:68 msgid "Automatically save files:" msgstr "" -#: src/Views/WelcomeView.vala:75 +#: src/Views/WelcomeView.vala:76 msgid "Choose a default destination" msgstr "" -#: src/Views/WelcomeView.vala:101 +#: src/Views/WelcomeView.vala:102 msgid "Start recording" msgstr "" #. TRANSLATORS: The name of the folder which recordings are saved -#: src/Views/WelcomeView.vala:150 +#: src/Views/WelcomeView.vala:147 msgid "Recordings" msgstr "" @@ -90,51 +90,39 @@ msgid "Finish recording" msgstr "" -#: src/Views/RecordView.vala:83 src/Views/RecordView.vala:320 -#: src/Views/RecordView.vala:350 +#: src/Views/RecordView.vala:83 src/Views/RecordView.vala:327 +#: src/Views/RecordView.vala:362 msgid "Pause recording" msgstr "" -#: src/Views/RecordView.vala:127 +#: src/Views/RecordView.vala:126 msgid "Unable to Create an Audio File" msgstr "" -#: src/Views/RecordView.vala:128 +#: src/Views/RecordView.vala:127 msgid "" "A GStreamer error happened while recording, the following error message may " "be helpful:" msgstr "" #. TRANSLATORS: %s represents a timestamp here -#: src/Views/RecordView.vala:145 +#: src/Views/RecordView.vala:154 #, c-format msgid "Recording from %s" msgstr "" -#: src/Views/RecordView.vala:161 +#: src/Views/RecordView.vala:169 msgid "Save your recording" msgstr "" -#: src/Views/RecordView.vala:162 +#: src/Views/RecordView.vala:170 msgid "Save" msgstr "" -#: src/Views/RecordView.vala:162 src/Application.vala:68 +#: src/Views/RecordView.vala:170 msgid "Cancel" msgstr "" -#: src/Views/RecordView.vala:339 +#: src/Views/RecordView.vala:351 msgid "Resume recording" msgstr "" - -#: src/Application.vala:63 -msgid "Are you sure you want to quit Reco?" -msgstr "" - -#: src/Application.vala:64 -msgid "If you quit Reco, the recording in progress will end." -msgstr "" - -#: src/Application.vala:70 -msgid "Quit Reco" -msgstr "" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/reco-2.0.0/po/fr.po new/reco-2.1.0/po/fr.po --- old/reco-2.0.0/po/fr.po 2019-06-01 13:44:54.000000000 +0200 +++ new/reco-2.1.0/po/fr.po 2019-08-03 02:36:52.000000000 +0200 @@ -7,7 +7,7 @@ msgstr "" "Project-Id-Version: com.github.ryonakano.reco\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-06-01 20:05+0900\n" +"POT-Creation-Date: 2019-08-03 09:32+0900\n" "PO-Revision-Date: 2019-01-16 22:17+0100\n" "Last-Translator: NathanBnm\n" "Language-Team: Français\n" @@ -16,69 +16,69 @@ "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -#: src/Views/WelcomeView.vala:32 +#: src/Views/WelcomeView.vala:33 #, fuzzy msgid "Recording" msgstr "Enregistrements" -#: src/Views/WelcomeView.vala:34 +#: src/Views/WelcomeView.vala:35 msgid "Delay in seconds:" msgstr "Délai en secondes :" -#: src/Views/WelcomeView.vala:40 +#: src/Views/WelcomeView.vala:41 msgid "Length in seconds:" msgstr "Longueur en secondes :" -#: src/Views/WelcomeView.vala:46 +#: src/Views/WelcomeView.vala:47 msgid "Record system sound:" msgstr "" -#: src/Views/WelcomeView.vala:52 +#: src/Views/WelcomeView.vala:53 msgid "Saving" msgstr "" -#: src/Views/WelcomeView.vala:54 +#: src/Views/WelcomeView.vala:55 msgid "Format:" msgstr "Format :" -#: src/Views/WelcomeView.vala:59 +#: src/Views/WelcomeView.vala:60 msgid "AAC" msgstr "AAC" -#: src/Views/WelcomeView.vala:60 +#: src/Views/WelcomeView.vala:61 msgid "FLAC" msgstr "FLAC" -#: src/Views/WelcomeView.vala:61 +#: src/Views/WelcomeView.vala:62 msgid "MP3" msgstr "MP3" -#: src/Views/WelcomeView.vala:62 +#: src/Views/WelcomeView.vala:63 msgid "Ogg Vorbis" msgstr "Ogg Vorbis" -#: src/Views/WelcomeView.vala:63 +#: src/Views/WelcomeView.vala:64 msgid "Opus" msgstr "Opus" -#: src/Views/WelcomeView.vala:64 +#: src/Views/WelcomeView.vala:65 msgid "WAV" msgstr "" -#: src/Views/WelcomeView.vala:67 +#: src/Views/WelcomeView.vala:68 msgid "Automatically save files:" msgstr "" -#: src/Views/WelcomeView.vala:75 +#: src/Views/WelcomeView.vala:76 msgid "Choose a default destination" msgstr "" -#: src/Views/WelcomeView.vala:101 +#: src/Views/WelcomeView.vala:102 msgid "Start recording" msgstr "Démarrer l'enregistrement" #. TRANSLATORS: The name of the folder which recordings are saved -#: src/Views/WelcomeView.vala:150 +#: src/Views/WelcomeView.vala:147 msgid "Recordings" msgstr "Enregistrements" @@ -92,17 +92,17 @@ msgid "Finish recording" msgstr "Arrêter l'enregistrement" -#: src/Views/RecordView.vala:83 src/Views/RecordView.vala:320 -#: src/Views/RecordView.vala:350 +#: src/Views/RecordView.vala:83 src/Views/RecordView.vala:327 +#: src/Views/RecordView.vala:362 #, fuzzy msgid "Pause recording" msgstr "Démarrer l'enregistrement" -#: src/Views/RecordView.vala:127 +#: src/Views/RecordView.vala:126 msgid "Unable to Create an Audio File" msgstr "Impossible de créer un fichier audio" -#: src/Views/RecordView.vala:128 +#: src/Views/RecordView.vala:127 #, fuzzy msgid "" "A GStreamer error happened while recording, the following error message may " @@ -110,41 +110,29 @@ msgstr "Une erreur GStreamer est survenue pendant l'enregistrement :" #. TRANSLATORS: %s represents a timestamp here -#: src/Views/RecordView.vala:145 +#: src/Views/RecordView.vala:154 #, c-format msgid "Recording from %s" msgstr "Enregistré depuis %s" -#: src/Views/RecordView.vala:161 +#: src/Views/RecordView.vala:169 #, fuzzy msgid "Save your recording" msgstr "Démarrer l'enregistrement" -#: src/Views/RecordView.vala:162 +#: src/Views/RecordView.vala:170 msgid "Save" msgstr "" -#: src/Views/RecordView.vala:162 src/Application.vala:68 +#: src/Views/RecordView.vala:170 msgid "Cancel" msgstr "" -#: src/Views/RecordView.vala:339 +#: src/Views/RecordView.vala:351 #, fuzzy msgid "Resume recording" msgstr "Enregistrements" -#: src/Application.vala:63 -msgid "Are you sure you want to quit Reco?" -msgstr "" - -#: src/Application.vala:64 -msgid "If you quit Reco, the recording in progress will end." -msgstr "" - -#: src/Application.vala:70 -msgid "Quit Reco" -msgstr "" - #~ msgid "Wav" #~ msgstr "Wav" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/reco-2.0.0/po/ja.po new/reco-2.1.0/po/ja.po --- old/reco-2.0.0/po/ja.po 2019-06-01 13:44:54.000000000 +0200 +++ new/reco-2.1.0/po/ja.po 2019-08-03 02:36:52.000000000 +0200 @@ -7,7 +7,7 @@ msgstr "" "Project-Id-Version: com.github.ryonakano.reco\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-06-01 20:05+0900\n" +"POT-Creation-Date: 2019-08-03 09:32+0900\n" "PO-Revision-Date: 2019-06-01 20:42+0900\n" "Last-Translator: Ryo Nakano <[email protected]>\n" "Language-Team: none\n" @@ -18,68 +18,68 @@ "Plural-Forms: nplurals=1; plural=0;\n" "X-Generator: Poedit 2.2.3\n" -#: src/Views/WelcomeView.vala:32 +#: src/Views/WelcomeView.vala:33 msgid "Recording" msgstr "録音" -#: src/Views/WelcomeView.vala:34 +#: src/Views/WelcomeView.vala:35 msgid "Delay in seconds:" msgstr "遅延する秒数:" -#: src/Views/WelcomeView.vala:40 +#: src/Views/WelcomeView.vala:41 msgid "Length in seconds:" msgstr "録音する秒数:" -#: src/Views/WelcomeView.vala:46 +#: src/Views/WelcomeView.vala:47 msgid "Record system sound:" msgstr "システムサウンドを録音:" -#: src/Views/WelcomeView.vala:52 +#: src/Views/WelcomeView.vala:53 msgid "Saving" msgstr "保存" -#: src/Views/WelcomeView.vala:54 +#: src/Views/WelcomeView.vala:55 msgid "Format:" msgstr "形式:" -#: src/Views/WelcomeView.vala:59 +#: src/Views/WelcomeView.vala:60 msgid "AAC" msgstr "AAC" -#: src/Views/WelcomeView.vala:60 +#: src/Views/WelcomeView.vala:61 msgid "FLAC" msgstr "FLAC" -#: src/Views/WelcomeView.vala:61 +#: src/Views/WelcomeView.vala:62 msgid "MP3" msgstr "MP3" -#: src/Views/WelcomeView.vala:62 +#: src/Views/WelcomeView.vala:63 msgid "Ogg Vorbis" msgstr "Ogg Vorbis" -#: src/Views/WelcomeView.vala:63 +#: src/Views/WelcomeView.vala:64 msgid "Opus" msgstr "Opus" -#: src/Views/WelcomeView.vala:64 +#: src/Views/WelcomeView.vala:65 msgid "WAV" msgstr "WAV" -#: src/Views/WelcomeView.vala:67 +#: src/Views/WelcomeView.vala:68 msgid "Automatically save files:" msgstr "ファイルを自動的に保存:" -#: src/Views/WelcomeView.vala:75 +#: src/Views/WelcomeView.vala:76 msgid "Choose a default destination" msgstr "デフォルトの保存先を選択" -#: src/Views/WelcomeView.vala:101 +#: src/Views/WelcomeView.vala:102 msgid "Start recording" msgstr "録音を開始します" #. TRANSLATORS: The name of the folder which recordings are saved -#: src/Views/WelcomeView.vala:150 +#: src/Views/WelcomeView.vala:147 msgid "Recordings" msgstr "レコーディング" @@ -91,56 +91,53 @@ msgid "Finish recording" msgstr "録音を終了します" -#: src/Views/RecordView.vala:83 src/Views/RecordView.vala:320 -#: src/Views/RecordView.vala:350 +#: src/Views/RecordView.vala:83 src/Views/RecordView.vala:327 +#: src/Views/RecordView.vala:362 msgid "Pause recording" msgstr "録音を一時停止します" -#: src/Views/RecordView.vala:127 +#: src/Views/RecordView.vala:126 msgid "Unable to Create an Audio File" msgstr "オーディオファイルを作成できません" -#: src/Views/RecordView.vala:128 +#: src/Views/RecordView.vala:127 msgid "" "A GStreamer error happened while recording, the following error message may " "be helpful:" msgstr "" -"録音中に Gstreamer エラーが発生しました。以下のエラーメッセージが役に立つ可" -"能性があります:" +"録音中に Gstreamer エラーが発生しました。以下のエラーメッセージが役に立つ可能" +"性があります:" #. TRANSLATORS: %s represents a timestamp here -#: src/Views/RecordView.vala:145 +#: src/Views/RecordView.vala:154 #, c-format msgid "Recording from %s" msgstr "録音 %s" -#: src/Views/RecordView.vala:161 +#: src/Views/RecordView.vala:169 msgid "Save your recording" msgstr "録音したものを保存" -#: src/Views/RecordView.vala:162 +#: src/Views/RecordView.vala:170 msgid "Save" msgstr "保存" -#: src/Views/RecordView.vala:162 src/Application.vala:68 +#: src/Views/RecordView.vala:170 msgid "Cancel" msgstr "キャンセル" -#: src/Views/RecordView.vala:339 +#: src/Views/RecordView.vala:351 msgid "Resume recording" msgstr "録音を再開します" -#: src/Application.vala:63 -msgid "Are you sure you want to quit Reco?" -msgstr "Reco を終了してもよろしいですか?" - -#: src/Application.vala:64 -msgid "If you quit Reco, the recording in progress will end." -msgstr "Reco を終了すると、進行中の録音は終了します。" - -#: src/Application.vala:70 -msgid "Quit Reco" -msgstr "Reco を終了" +#~ msgid "Are you sure you want to quit Reco?" +#~ msgstr "Reco を終了してもよろしいですか?" + +#~ msgid "If you quit Reco, the recording in progress will end." +#~ msgstr "Reco を終了すると、進行中の録音は終了します。" + +#~ msgid "Quit Reco" +#~ msgstr "Reco を終了" #~ msgid "Wav" #~ msgstr "Wav" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/reco-2.0.0/po/lt.po new/reco-2.1.0/po/lt.po --- old/reco-2.0.0/po/lt.po 2019-06-01 13:44:54.000000000 +0200 +++ new/reco-2.1.0/po/lt.po 2019-08-03 02:36:52.000000000 +0200 @@ -7,7 +7,7 @@ msgstr "" "Project-Id-Version: com.github.ryonakano.reco\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-06-01 20:05+0900\n" +"POT-Creation-Date: 2019-08-03 09:32+0900\n" "PO-Revision-Date: 2019-02-18 14:35+0200\n" "Last-Translator: Moo\n" "Language-Team: \n" @@ -19,68 +19,68 @@ "Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && (n" "%100<10 || n%100>=20) ? 1 : 2);\n" -#: src/Views/WelcomeView.vala:32 +#: src/Views/WelcomeView.vala:33 msgid "Recording" msgstr "Įrašinėjimas" -#: src/Views/WelcomeView.vala:34 +#: src/Views/WelcomeView.vala:35 msgid "Delay in seconds:" msgstr "Delsa sekundėmis:" -#: src/Views/WelcomeView.vala:40 +#: src/Views/WelcomeView.vala:41 msgid "Length in seconds:" msgstr "Trukmė sekundėmis:" -#: src/Views/WelcomeView.vala:46 +#: src/Views/WelcomeView.vala:47 msgid "Record system sound:" msgstr "" -#: src/Views/WelcomeView.vala:52 +#: src/Views/WelcomeView.vala:53 msgid "Saving" msgstr "Išsaugojimas" -#: src/Views/WelcomeView.vala:54 +#: src/Views/WelcomeView.vala:55 msgid "Format:" msgstr "Formatas:" -#: src/Views/WelcomeView.vala:59 +#: src/Views/WelcomeView.vala:60 msgid "AAC" msgstr "AAC" -#: src/Views/WelcomeView.vala:60 +#: src/Views/WelcomeView.vala:61 msgid "FLAC" msgstr "FLAC" -#: src/Views/WelcomeView.vala:61 +#: src/Views/WelcomeView.vala:62 msgid "MP3" msgstr "MP3" -#: src/Views/WelcomeView.vala:62 +#: src/Views/WelcomeView.vala:63 msgid "Ogg Vorbis" msgstr "Ogg Vorbis" -#: src/Views/WelcomeView.vala:63 +#: src/Views/WelcomeView.vala:64 msgid "Opus" msgstr "Opus" -#: src/Views/WelcomeView.vala:64 +#: src/Views/WelcomeView.vala:65 msgid "WAV" msgstr "" -#: src/Views/WelcomeView.vala:67 +#: src/Views/WelcomeView.vala:68 msgid "Automatically save files:" msgstr "Automatiškai išsaugoti failus:" -#: src/Views/WelcomeView.vala:75 +#: src/Views/WelcomeView.vala:76 msgid "Choose a default destination" msgstr "Pasirinkite numatytąją vietą" -#: src/Views/WelcomeView.vala:101 +#: src/Views/WelcomeView.vala:102 msgid "Start recording" msgstr "Pradėti įrašinėjimą" #. TRANSLATORS: The name of the folder which recordings are saved -#: src/Views/WelcomeView.vala:150 +#: src/Views/WelcomeView.vala:147 msgid "Recordings" msgstr "Įrašinėjimai" @@ -94,17 +94,17 @@ msgid "Finish recording" msgstr "Stabdyti įrašinėjimą" -#: src/Views/RecordView.vala:83 src/Views/RecordView.vala:320 -#: src/Views/RecordView.vala:350 +#: src/Views/RecordView.vala:83 src/Views/RecordView.vala:327 +#: src/Views/RecordView.vala:362 #, fuzzy msgid "Pause recording" msgstr "Pradėti įrašinėjimą" -#: src/Views/RecordView.vala:127 +#: src/Views/RecordView.vala:126 msgid "Unable to Create an Audio File" msgstr "Nepavyko sukurti garso failą" -#: src/Views/RecordView.vala:128 +#: src/Views/RecordView.vala:127 #, fuzzy msgid "" "A GStreamer error happened while recording, the following error message may " @@ -112,39 +112,36 @@ msgstr "Įrašanėjant, įvyko GStreamer klaida:" #. TRANSLATORS: %s represents a timestamp here -#: src/Views/RecordView.vala:145 +#: src/Views/RecordView.vala:154 #, c-format msgid "Recording from %s" msgstr "Įrašinėjimas iš %s" -#: src/Views/RecordView.vala:161 +#: src/Views/RecordView.vala:169 msgid "Save your recording" msgstr "Išsaugokite savo įrašinėjimą" -#: src/Views/RecordView.vala:162 +#: src/Views/RecordView.vala:170 msgid "Save" msgstr "Išsaugoti" -#: src/Views/RecordView.vala:162 src/Application.vala:68 +#: src/Views/RecordView.vala:170 msgid "Cancel" msgstr "Atsisakyti" -#: src/Views/RecordView.vala:339 +#: src/Views/RecordView.vala:351 #, fuzzy msgid "Resume recording" msgstr "Įrašinėjimas" -#: src/Application.vala:63 -msgid "Are you sure you want to quit Reco?" -msgstr "Ar tikrai norite išeiti iš Reco?" - -#: src/Application.vala:64 -msgid "If you quit Reco, the recording in progress will end." -msgstr "Jeigu išeisite iš Reco, dabartinis įrašinėjimas bus užbaigtas." - -#: src/Application.vala:70 -msgid "Quit Reco" -msgstr "Išeiti iš Reco" +#~ msgid "Are you sure you want to quit Reco?" +#~ msgstr "Ar tikrai norite išeiti iš Reco?" + +#~ msgid "If you quit Reco, the recording in progress will end." +#~ msgstr "Jeigu išeisite iš Reco, dabartinis įrašinėjimas bus užbaigtas." + +#~ msgid "Quit Reco" +#~ msgstr "Išeiti iš Reco" #~ msgid "Wav" #~ msgstr "Wav" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/reco-2.0.0/po/nl.po new/reco-2.1.0/po/nl.po --- old/reco-2.0.0/po/nl.po 2019-06-01 13:44:54.000000000 +0200 +++ new/reco-2.1.0/po/nl.po 2019-08-03 02:36:52.000000000 +0200 @@ -7,7 +7,7 @@ msgstr "" "Project-Id-Version: com.github.ryonakano.reco\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-06-01 20:05+0900\n" +"POT-Creation-Date: 2019-08-03 09:32+0900\n" "PO-Revision-Date: 2019-03-29 14:04+0100\n" "Last-Translator: Heimen Stoffels <[email protected]>\n" "Language-Team: Dutch <[email protected]>\n" @@ -18,68 +18,68 @@ "X-Generator: Poedit 2.1.1\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" -#: src/Views/WelcomeView.vala:32 +#: src/Views/WelcomeView.vala:33 msgid "Recording" msgstr "Opname" -#: src/Views/WelcomeView.vala:34 +#: src/Views/WelcomeView.vala:35 msgid "Delay in seconds:" msgstr "Vertraging, in seconden:" -#: src/Views/WelcomeView.vala:40 +#: src/Views/WelcomeView.vala:41 msgid "Length in seconds:" msgstr "Duur, in seconden:" -#: src/Views/WelcomeView.vala:46 +#: src/Views/WelcomeView.vala:47 msgid "Record system sound:" msgstr "" -#: src/Views/WelcomeView.vala:52 +#: src/Views/WelcomeView.vala:53 msgid "Saving" msgstr "Opslaan" -#: src/Views/WelcomeView.vala:54 +#: src/Views/WelcomeView.vala:55 msgid "Format:" msgstr "Formaat:" -#: src/Views/WelcomeView.vala:59 +#: src/Views/WelcomeView.vala:60 msgid "AAC" msgstr "AAC" -#: src/Views/WelcomeView.vala:60 +#: src/Views/WelcomeView.vala:61 msgid "FLAC" msgstr "FLAC" -#: src/Views/WelcomeView.vala:61 +#: src/Views/WelcomeView.vala:62 msgid "MP3" msgstr "MP3" -#: src/Views/WelcomeView.vala:62 +#: src/Views/WelcomeView.vala:63 msgid "Ogg Vorbis" msgstr "Ogg Vorbis" -#: src/Views/WelcomeView.vala:63 +#: src/Views/WelcomeView.vala:64 msgid "Opus" msgstr "Opus" -#: src/Views/WelcomeView.vala:64 +#: src/Views/WelcomeView.vala:65 msgid "WAV" msgstr "WAV" -#: src/Views/WelcomeView.vala:67 +#: src/Views/WelcomeView.vala:68 msgid "Automatically save files:" msgstr "Bestanden automatisch opslaan:" -#: src/Views/WelcomeView.vala:75 +#: src/Views/WelcomeView.vala:76 msgid "Choose a default destination" msgstr "Kies een standaard opslagmap" -#: src/Views/WelcomeView.vala:101 +#: src/Views/WelcomeView.vala:102 msgid "Start recording" msgstr "Opname starten" #. TRANSLATORS: The name of the folder which recordings are saved -#: src/Views/WelcomeView.vala:150 +#: src/Views/WelcomeView.vala:147 msgid "Recordings" msgstr "Opnamen" @@ -91,16 +91,16 @@ msgid "Finish recording" msgstr "Opname afronden" -#: src/Views/RecordView.vala:83 src/Views/RecordView.vala:320 -#: src/Views/RecordView.vala:350 +#: src/Views/RecordView.vala:83 src/Views/RecordView.vala:327 +#: src/Views/RecordView.vala:362 msgid "Pause recording" msgstr "Opname pauzeren" -#: src/Views/RecordView.vala:127 +#: src/Views/RecordView.vala:126 msgid "Unable to Create an Audio File" msgstr "Kan geen audiobestand creëren" -#: src/Views/RecordView.vala:128 +#: src/Views/RecordView.vala:127 msgid "" "A GStreamer error happened while recording, the following error message may " "be helpful:" @@ -109,35 +109,32 @@ "foutmelding kan nuttig zijn:" #. TRANSLATORS: %s represents a timestamp here -#: src/Views/RecordView.vala:145 +#: src/Views/RecordView.vala:154 #, c-format msgid "Recording from %s" msgstr "Opnemen van %s" -#: src/Views/RecordView.vala:161 +#: src/Views/RecordView.vala:169 msgid "Save your recording" msgstr "Sla je opname op" -#: src/Views/RecordView.vala:162 +#: src/Views/RecordView.vala:170 msgid "Save" msgstr "Opslaan" -#: src/Views/RecordView.vala:162 src/Application.vala:68 +#: src/Views/RecordView.vala:170 msgid "Cancel" msgstr "Afbreken" -#: src/Views/RecordView.vala:339 +#: src/Views/RecordView.vala:351 msgid "Resume recording" msgstr "Opname hervatten" -#: src/Application.vala:63 -msgid "Are you sure you want to quit Reco?" -msgstr "Weet je zeker dat je Reco wilt afsluiten?" - -#: src/Application.vala:64 -msgid "If you quit Reco, the recording in progress will end." -msgstr "Als je Reco afsluit, dan wordt de opname stopgezet." - -#: src/Application.vala:70 -msgid "Quit Reco" -msgstr "Reco afsluiten" +#~ msgid "Are you sure you want to quit Reco?" +#~ msgstr "Weet je zeker dat je Reco wilt afsluiten?" + +#~ msgid "If you quit Reco, the recording in progress will end." +#~ msgstr "Als je Reco afsluit, dan wordt de opname stopgezet." + +#~ msgid "Quit Reco" +#~ msgstr "Reco afsluiten" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/reco-2.0.0/src/Application.vala new/reco-2.1.0/src/Application.vala --- old/reco-2.0.0/src/Application.vala 2019-06-01 13:44:54.000000000 +0200 +++ new/reco-2.1.0/src/Application.vala 2019-08-03 02:36:52.000000000 +0200 @@ -56,32 +56,15 @@ add_action (quit_action); set_accels_for_action ("app.quit", {"<Control>q"}); quit_action.activate.connect (() => { - if (!window.record_view.is_recording) { - window.destroy (); - } else { - var warning_dialog = new Granite.MessageDialog.with_image_from_icon_name ( - _("Are you sure you want to quit Reco?"), - _("If you quit Reco, the recording in progress will end."), - "dialog-warning", Gtk.ButtonsType.NONE); - warning_dialog.transient_for = window; - warning_dialog.modal = true; - warning_dialog.add_button (_("Cancel"), Gtk.ButtonsType.CANCEL); - - var quit_button = new Gtk.Button.with_label (_("Quit Reco")); - quit_button.get_style_context ().add_class (Gtk.STYLE_CLASS_DESTRUCTIVE_ACTION); - warning_dialog.add_action_widget (quit_button, Gtk.ResponseType.YES); - - warning_dialog.show_all (); - - warning_dialog.response.connect ((response_id) => { - if (response_id == Gtk.ResponseType.YES) { - window.record_view.cancel_recording (); - window.destroy (); - } - - warning_dialog.destroy (); + if (window.record_view.is_recording) { + var loop = new MainLoop (); + window.record_view.stop_recording.begin ((obj, res) => { + loop.quit (); }); + loop.run (); } + + window.destroy (); }); var toggle_recording_action = new SimpleAction ("toggle_recording", null); @@ -89,9 +72,13 @@ set_accels_for_action ("app.toggle_recording", {"<Control><Shift>R"}); toggle_recording_action.activate.connect (() => { if (window.stack.visible_child_name == "welcome") { - window.welcome_view.record_button.clicked (); + window.welcome_view.trigger_recording (); } else if (window.stack.visible_child_name == "record") { - window.record_view.stop_button.clicked (); + var loop = new MainLoop (); + window.record_view.stop_recording.begin ((obj, res) => { + loop.quit (); + }); + loop.run (); } }); } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/reco-2.0.0/src/MainWindow.vala new/reco-2.1.0/src/MainWindow.vala --- old/reco-2.0.0/src/MainWindow.vala 2019-06-01 13:44:54.000000000 +0200 +++ new/reco-2.1.0/src/MainWindow.vala 2019-08-03 02:36:52.000000000 +0200 @@ -17,11 +17,10 @@ public class MainWindow : Gtk.ApplicationWindow { public Application app { get; construct; } - private Gtk.HeaderBar headerbar; - public Gtk.Stack stack { get; private set; } public WelcomeView welcome_view { get; private set; } - public CountDownView countdown_view { get; private set; } + private CountDownView countdown_view; public RecordView record_view { get; private set; } + public Gtk.Stack stack { get; private set; } public MainWindow (Application app) { Object ( @@ -41,16 +40,20 @@ cssprovider, Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION); - headerbar = new Gtk.HeaderBar (); - headerbar.get_style_context ().add_class (Gtk.STYLE_CLASS_FLAT); - headerbar.get_style_context ().add_class ("default-decoration"); + var headerbar = new Gtk.HeaderBar (); headerbar.title = ""; headerbar.has_subtitle = false; + headerbar.show_close_button = true; + + var headerbar_style_context = headerbar.get_style_context (); + headerbar_style_context.add_class (Gtk.STYLE_CLASS_FLAT); + headerbar_style_context.add_class ("default-decoration"); - stack = new Gtk.Stack (); welcome_view = new WelcomeView (this); countdown_view = new CountDownView (this); record_view = new RecordView (this, app); + + stack = new Gtk.Stack (); stack.add_named (welcome_view, "welcome"); stack.add_named (countdown_view, "count"); stack.add_named (record_view, "record"); @@ -59,22 +62,32 @@ get_style_context ().add_class ("rounded"); add (stack); show_welcome (); + + delete_event.connect ((event) => { + if (record_view.is_recording) { + var loop = new MainLoop (); + record_view.stop_recording.begin ((obj, res) => { + loop.quit (); + }); + loop.run (); + } + + return false; + }); } public void show_welcome () { stack.visible_child_name = "welcome"; - headerbar.show_close_button = true; } public void show_countdown () { stack.visible_child_name = "count"; - countdown_view.start_count (); + countdown_view.start_countdown (); } public void show_record () { stack.visible_child_name = "record"; record_view.start_recording (); - headerbar.show_close_button = false; } // Save window position when changed diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/reco-2.0.0/src/Views/CountDownView.vala new/reco-2.1.0/src/Views/CountDownView.vala --- old/reco-2.0.0/src/Views/CountDownView.vala 2019-06-01 13:44:54.000000000 +0200 +++ new/reco-2.1.0/src/Views/CountDownView.vala 2019-08-03 02:36:52.000000000 +0200 @@ -17,7 +17,12 @@ public class CountDownView : Gtk.Box { public MainWindow window { get; construct; } - private Gtk.Label recording_label; + private Gtk.Label delay_remaining_label; + private Gtk.Button pause_button; + private int paused_time; + private int delay_remaining_time; + private uint countdown; + private bool is_paused; public CountDownView (MainWindow window) { Object ( @@ -29,38 +34,108 @@ } construct { - recording_label = new Gtk.Label (null); - recording_label.get_style_context ().add_class ("h2"); + delay_remaining_label = new Gtk.Label (null); + delay_remaining_label.get_style_context ().add_class (Granite.STYLE_CLASS_H2_LABEL); var label_grid = new Gtk.Grid (); label_grid.column_spacing = 6; label_grid.row_spacing = 6; label_grid.halign = Gtk.Align.CENTER; - label_grid.attach (recording_label, 0, 1, 1, 1); + label_grid.attach (delay_remaining_label, 0, 1, 1, 1); + + var cancel_button = new Gtk.Button (); + cancel_button.image = new Gtk.Image.from_icon_name ("user-trash-symbolic", Gtk.IconSize.BUTTON); + cancel_button.tooltip_text = _("Cancel the countdown"); + cancel_button.get_style_context ().add_class ("buttons-without-border"); + cancel_button.halign = Gtk.Align.START; + + pause_button = new Gtk.Button (); + pause_button.image = new Gtk.Image.from_icon_name ("media-playback-pause-symbolic", Gtk.IconSize.BUTTON); + pause_button.tooltip_text = _("Pause the countdown"); + pause_button.get_style_context ().add_class ("buttons-without-border"); + pause_button.halign = Gtk.Align.END; + + var buttons_grid = new Gtk.Grid (); + buttons_grid.column_spacing = 30; + buttons_grid.row_spacing = 6; + buttons_grid.margin_top = 12; + buttons_grid.halign = Gtk.Align.CENTER; + buttons_grid.attach (cancel_button, 0, 0, 1, 1); + buttons_grid.attach (pause_button, 1, 0, 1, 1); pack_start (label_grid, false, false); - } + pack_end (buttons_grid, false, false); - public void start_count () { - int remaining_time = Application.settings.get_int ("delay"); + cancel_button.clicked.connect (() => { + paused_time = 0; + cancel_countdown (); + }); - // Show initial remaining_time - recording_label.label = remaining_time.to_string (); + pause_button.clicked.connect (() => { + pause_countdown (); + }); + } - // Decrease remaining_time per seconds - Timeout.add (1000, () => { - remaining_time--; + public void start_countdown () { + is_paused = false; + delay_remaining_time = init_delay_remaining_time (); + + // Show initial delay_remaining_time + delay_remaining_label.label = delay_remaining_time.to_string (); + + // Decrease delay_remaining_time per seconds + countdown = Timeout.add (1000, () => { + delay_remaining_time--; + paused_time = delay_remaining_time + 1; - // Show the decreased remaining_time - recording_label.label = remaining_time.to_string (); + // Show the decreased delay_remaining_time + delay_remaining_label.label = delay_remaining_time.to_string (); - // Start recording when remaining_time turns 0 - if (remaining_time == 0) { + // Start recording when delay_remaining_time turns 0 + if (delay_remaining_time == 0) { window.show_record (); + delay_remaining_label.label = null; return false; } - return true; + return is_paused? false : true; }); } + + private void cancel_countdown () { + is_paused = true; + + if (countdown != 0) { + countdown = 0; + delay_remaining_time = init_delay_remaining_time (); + delay_remaining_label.label = null; + } + + pause_button.image = new Gtk.Image.from_icon_name ("media-playback-pause-symbolic", Gtk.IconSize.BUTTON); + pause_button.tooltip_text = _("Pause the countdown"); + + window.show_welcome (); + } + + private void pause_countdown () { + if (!is_paused) { + is_paused = true; + + pause_button.image = new Gtk.Image.from_icon_name ("media-playback-start-symbolic", Gtk.IconSize.BUTTON); + pause_button.tooltip_text = _("Resume the countdown"); + } else { + is_paused = false; + + if (paused_time != 0) { + start_countdown (); + } + + pause_button.image = new Gtk.Image.from_icon_name ("media-playback-pause-symbolic", Gtk.IconSize.BUTTON); + pause_button.tooltip_text = _("Pause the countdown"); + } + } + + private int init_delay_remaining_time () { + return paused_time != 0 ? paused_time : Application.settings.get_int ("delay"); + } } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/reco-2.0.0/src/Views/RecordView.vala new/reco-2.1.0/src/Views/RecordView.vala --- old/reco-2.0.0/src/Views/RecordView.vala 2019-06-01 13:44:54.000000000 +0200 +++ new/reco-2.1.0/src/Views/RecordView.vala 2019-08-03 02:36:52.000000000 +0200 @@ -22,7 +22,7 @@ public Application app { get; construct; } private Gtk.Label time_label; private Gtk.Label remaining_time_label; - public Gtk.Button stop_button { get; private set; } + private Gtk.Button stop_button; private Gtk.Button pause_button; public bool is_recording { get; private set; } private string suffix; @@ -52,10 +52,10 @@ construct { time_label = new Gtk.Label (null); - time_label.get_style_context ().add_class ("h2"); + time_label.get_style_context ().add_class (Granite.STYLE_CLASS_H2_LABEL); remaining_time_label = new Gtk.Label (null); - remaining_time_label.get_style_context ().add_class ("h3"); + remaining_time_label.get_style_context ().add_class (Granite.STYLE_CLASS_H3_LABEL); var label_grid = new Gtk.Grid (); label_grid.column_spacing = 6; @@ -103,9 +103,11 @@ }); stop_button.clicked.connect (() => { - stop_recording (); - window.show_welcome (); - is_recording = false; + var loop = new MainLoop (); + window.record_view.stop_recording.begin ((obj, res) => { + loop.quit (); + }); + loop.run (); }); pause_button.clicked.connect (() => { @@ -117,12 +119,9 @@ switch (msg.type) { case Gst.MessageType.ERROR: Error err; - string debug; - msg.parse_error (out err, out debug); - is_recording = false; var error_dialog = new Granite.MessageDialog.with_image_from_icon_name ( _("Unable to Create an Audio File"), _("A GStreamer error happened while recording, the following error message may be helpful:"), @@ -131,8 +130,18 @@ error_dialog.show_error_details ("%s\n%s".printf (err.message, debug)); error_dialog.run (); error_dialog.destroy (); - stop_recording (); + + if (count != 0) { + count = 0; + } + + if (countdown != 0) { + countdown = 0; + remaining_time_label.label = null; + } + window.show_welcome (); + is_recording = false; pipeline.set_state (Gst.State.NULL); break; @@ -152,9 +161,8 @@ try { var uri = File.new_for_path (destination + "/" + filename + suffix); tmp_source.move (uri, FileCopyFlags.OVERWRITE); - window.welcome_view.show_success_button (); } catch (Error e) { - stderr.printf ("Error: %s\n", e.message); + warning (e.message); } } else { // The app asks destination and filename each time var filechooser = new Gtk.FileChooserNative ( @@ -168,15 +176,14 @@ try { var uri = File.new_for_path (filechooser.get_filename ()); tmp_source.move (uri, FileCopyFlags.OVERWRITE); - window.welcome_view.show_success_button (); } catch (Error e) { - stderr.printf ("Error: %s\n", e.message); + warning (e.message); } } else { try { tmp_source.delete (); } catch (Error e) { - stderr.printf ("Error: %s", e.message); + warning (e.message); } } @@ -201,11 +208,11 @@ var sink = Gst.ElementFactory.make ("filesink", "sink"); if (pipeline == null) { - stderr.printf ("Error: Gstreamer sink was not created correctly!\n"); + error ("Gstreamer sink was not created correctly!"); } else if (audiobin == null) { - stderr.printf ("Error: Gstreamer pipeline was not created correctly!\n"); + error ("Gstreamer pipeline was not created correctly!"); } else if (sink == null) { - stderr.printf ("Error: Gstreamer audiobin was not created correctly!\n"); + error ("Gstreamer audiobin was not created correctly!"); } string command = Application.settings.get_boolean ("system-sound") ? "pacmd list-sinks" : "pacmd list-sources"; @@ -261,12 +268,12 @@ break; } } catch (Error e) { - stderr.printf ("Error: %s\n", e.message); + error ("Could not set the audio format correctly: %s", e.message); } tmp_full_path = tmp_destination + "/%s%s".printf (tmp_filename, suffix); sink.set ("location", tmp_full_path); - stdout.printf ("Audio is stored as %s temporary\n".printf (tmp_full_path)); + debug ("The recording is stored at %s temporary".printf (tmp_full_path)); pipeline.add_many (audiobin, sink); audiobin.link (sink); @@ -298,11 +305,11 @@ try { File.new_for_path (tmp_full_path).delete (); } catch (Error e) { - stderr.printf ("Error: %s\n", e.message); + warning (e.message); } } - private void stop_recording () { + public async void stop_recording () { if (count != 0) { count = 0; } @@ -320,7 +327,12 @@ pause_button.tooltip_text = _("Pause recording"); } - pipeline.send_event (new Gst.Event.eos ()); + if (pipeline.send_event (new Gst.Event.eos ())) { + window.welcome_view.show_success_button (); + } + + window.show_welcome (); + is_recording = false; } private void pause_recording () { @@ -442,9 +454,11 @@ show_timer_label (remaining_time_label, remain_minutes_10, remain_minutes_1, remain_seconds_10, remain_seconds_1); if (remain_minutes_10 == 0 && remain_minutes_1 == 0 && remain_seconds_10 == 0 && remain_seconds_1 == 0) { - stop_recording (); - window.show_welcome (); - is_recording = false; + var loop = new MainLoop (); + window.record_view.stop_recording.begin ((obj, res) => { + loop.quit (); + }); + loop.run (); return false; } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/reco-2.0.0/src/Views/WelcomeView.vala new/reco-2.1.0/src/Views/WelcomeView.vala --- old/reco-2.0.0/src/Views/WelcomeView.vala 2019-06-01 13:44:54.000000000 +0200 +++ new/reco-2.1.0/src/Views/WelcomeView.vala 2019-08-03 02:36:52.000000000 +0200 @@ -17,7 +17,8 @@ public class WelcomeView : Gtk.Box { public MainWindow window { get; construct; } - public Gtk.Button record_button { get; private set; } + private Gtk.SpinButton delay_spin; + private Gtk.Button record_button; public WelcomeView (MainWindow window) { Object ( @@ -33,7 +34,7 @@ var delay_label = new Gtk.Label (_("Delay in seconds:")); delay_label.halign = Gtk.Align.END; - var delay_spin = new Gtk.SpinButton.with_range (0, 15, 1); + delay_spin = new Gtk.SpinButton.with_range (0, 15, 1); delay_spin.halign = Gtk.Align.START; delay_spin.value = Application.settings.get_int ("delay"); @@ -134,11 +135,7 @@ }); record_button.clicked.connect (() => { - if (delay_spin.value != 0) { - window.show_countdown (); - } else { - window.show_record (); - } + trigger_recording (); }); } @@ -172,4 +169,12 @@ }); timeout_button_icon = 0; } + + public void trigger_recording () { + if (delay_spin.value != 0) { + window.show_countdown (); + } else { + window.show_record (); + } + } }
