Combine Wim Hof time signals in one dropdown
This commit is contained in:
1 parent
0904848f1d
commit
b9cdf450bf
17 files changed
+234
-81
No files matched your search
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
+16
-4
@@ -463,11 +463,23 @@ Znovu inicializovat zvuk
|
||||
[music_volume_label]
|
||||
Hlasitost hudby
|
||||
---
|
||||
[retention_marker_label]
|
||||
Značka retence po 30 s
|
||||
[whm_time_signals_label]
|
||||
Časové signály
|
||||
---
|
||||
[minute_bell_label]
|
||||
Zvonek každou minutu
|
||||
[whm_time_signals_off]
|
||||
Vypnuto
|
||||
---
|
||||
[whm_time_signals_minute]
|
||||
Každou minutu
|
||||
---
|
||||
[whm_time_signals_retention]
|
||||
Každých 30 sekund
|
||||
---
|
||||
[whm_time_signals_both]
|
||||
Oba
|
||||
---
|
||||
[whm_time_signals_hint]
|
||||
Třicetisekundové signály zaznívají při zadržování dechu. Minutové signály odměřují aktivní čas relace.
|
||||
---
|
||||
[reset_to_defaults_label]
|
||||
Obnovit výchozí
|
||||
|
||||
+16
-4
@@ -463,11 +463,23 @@ Ausgabepegel
|
||||
[music_volume_label]
|
||||
Musiklautstärke
|
||||
---
|
||||
[retention_marker_label]
|
||||
30-s-Retentionsmarkierung
|
||||
[whm_time_signals_label]
|
||||
Zeitsignale
|
||||
---
|
||||
[minute_bell_label]
|
||||
Glocke jede Minute
|
||||
[whm_time_signals_off]
|
||||
Aus
|
||||
---
|
||||
[whm_time_signals_minute]
|
||||
Jede Minute
|
||||
---
|
||||
[whm_time_signals_retention]
|
||||
Alle 30 Sekunden
|
||||
---
|
||||
[whm_time_signals_both]
|
||||
Beide
|
||||
---
|
||||
[whm_time_signals_hint]
|
||||
Die 30-Sekunden-Signale ertönen beim Atemanhalten. Minutensignale zählen die aktive Übungszeit.
|
||||
---
|
||||
[reset_to_defaults_label]
|
||||
Auf Standard zurücksetzen
|
||||
|
||||
+16
-4
@@ -580,11 +580,23 @@ Remove
|
||||
[music_volume_label]
|
||||
Music volume
|
||||
---
|
||||
[retention_marker_label]
|
||||
Retention 30s marker
|
||||
[whm_time_signals_label]
|
||||
Time signals
|
||||
---
|
||||
[minute_bell_label]
|
||||
Bell every minute
|
||||
[whm_time_signals_off]
|
||||
Off
|
||||
---
|
||||
[whm_time_signals_minute]
|
||||
Every minute
|
||||
---
|
||||
[whm_time_signals_retention]
|
||||
Every 30 seconds
|
||||
---
|
||||
[whm_time_signals_both]
|
||||
Both
|
||||
---
|
||||
[whm_time_signals_hint]
|
||||
30-second signals play during breath holds. Minute signals count active session time.
|
||||
---
|
||||
[reset_to_defaults_label]
|
||||
Reset to defaults
|
||||
|
||||
+16
-4
@@ -463,11 +463,23 @@ Nivel de salida
|
||||
[music_volume_label]
|
||||
Volumen de música
|
||||
---
|
||||
[retention_marker_label]
|
||||
Marcador de retención cada 30 s
|
||||
[whm_time_signals_label]
|
||||
Señales de tiempo
|
||||
---
|
||||
[minute_bell_label]
|
||||
Campana cada minuto
|
||||
[whm_time_signals_off]
|
||||
Desactivadas
|
||||
---
|
||||
[whm_time_signals_minute]
|
||||
Cada minuto
|
||||
---
|
||||
[whm_time_signals_retention]
|
||||
Cada 30 segundos
|
||||
---
|
||||
[whm_time_signals_both]
|
||||
Ambas
|
||||
---
|
||||
[whm_time_signals_hint]
|
||||
Las señales de 30 segundos suenan durante las retenciones. Las señales de un minuto cuentan el tiempo activo de la sesión.
|
||||
---
|
||||
[reset_to_defaults_label]
|
||||
Restablecer valores predeterminados
|
||||
|
||||
+16
-4
@@ -463,11 +463,23 @@ Niveau de sortie
|
||||
[music_volume_label]
|
||||
Volume de la musique
|
||||
---
|
||||
[retention_marker_label]
|
||||
Repère de rétention 30 s
|
||||
[whm_time_signals_label]
|
||||
Signaux de temps
|
||||
---
|
||||
[minute_bell_label]
|
||||
Cloche chaque minute
|
||||
[whm_time_signals_off]
|
||||
Désactivés
|
||||
---
|
||||
[whm_time_signals_minute]
|
||||
Toutes les minutes
|
||||
---
|
||||
[whm_time_signals_retention]
|
||||
Toutes les 30 secondes
|
||||
---
|
||||
[whm_time_signals_both]
|
||||
Les deux
|
||||
---
|
||||
[whm_time_signals_hint]
|
||||
Les signaux de 30 secondes rythment les rétentions. Les signaux d’une minute comptent le temps actif de la séance.
|
||||
---
|
||||
[reset_to_defaults_label]
|
||||
Réinitialiser
|
||||
|
||||
+16
-4
@@ -463,11 +463,23 @@ Level keluaran
|
||||
[music_volume_label]
|
||||
Volume musik
|
||||
---
|
||||
[retention_marker_label]
|
||||
Penanda retensi 30 dtk
|
||||
[whm_time_signals_label]
|
||||
Sinyal waktu
|
||||
---
|
||||
[minute_bell_label]
|
||||
Lonceng tiap menit
|
||||
[whm_time_signals_off]
|
||||
Nonaktif
|
||||
---
|
||||
[whm_time_signals_minute]
|
||||
Setiap menit
|
||||
---
|
||||
[whm_time_signals_retention]
|
||||
Setiap 30 detik
|
||||
---
|
||||
[whm_time_signals_both]
|
||||
Keduanya
|
||||
---
|
||||
[whm_time_signals_hint]
|
||||
Sinyal 30 detik berbunyi saat menahan napas. Sinyal menit menghitung waktu aktif sesi.
|
||||
---
|
||||
[reset_to_defaults_label]
|
||||
Reset ke default
|
||||
|
||||
+16
-4
@@ -487,11 +487,23 @@ Livello uscita
|
||||
[music_volume_label]
|
||||
Volume musica
|
||||
---
|
||||
[retention_marker_label]
|
||||
Indicatore ritenzione 30 s
|
||||
[whm_time_signals_label]
|
||||
Segnali di tempo
|
||||
---
|
||||
[minute_bell_label]
|
||||
Campana ogni minuto
|
||||
[whm_time_signals_off]
|
||||
Disattivati
|
||||
---
|
||||
[whm_time_signals_minute]
|
||||
Ogni minuto
|
||||
---
|
||||
[whm_time_signals_retention]
|
||||
Ogni 30 secondi
|
||||
---
|
||||
[whm_time_signals_both]
|
||||
Entrambi
|
||||
---
|
||||
[whm_time_signals_hint]
|
||||
I segnali di 30 secondi accompagnano le ritenzioni. I segnali di un minuto contano il tempo attivo della sessione.
|
||||
---
|
||||
[reset_to_defaults_label]
|
||||
Ripristina predefiniti
|
||||
|
||||
+16
-4
@@ -463,11 +463,23 @@ OK
|
||||
[music_volume_label]
|
||||
音楽の音量
|
||||
---
|
||||
[retention_marker_label]
|
||||
リテンション30秒マーカー
|
||||
[whm_time_signals_label]
|
||||
時間の合図
|
||||
---
|
||||
[minute_bell_label]
|
||||
1分ごとのベル
|
||||
[whm_time_signals_off]
|
||||
オフ
|
||||
---
|
||||
[whm_time_signals_minute]
|
||||
1分ごと
|
||||
---
|
||||
[whm_time_signals_retention]
|
||||
30秒ごと
|
||||
---
|
||||
[whm_time_signals_both]
|
||||
両方
|
||||
---
|
||||
[whm_time_signals_hint]
|
||||
30秒ごとの合図は息を止めている間に鳴ります。1分ごとの合図は一時停止を除くセッション全体の時間を刻みます。
|
||||
---
|
||||
[reset_to_defaults_label]
|
||||
デフォルトに戻す
|
||||
|
||||
+16
-4
@@ -487,11 +487,23 @@ PIP 모드
|
||||
[music_volume_label]
|
||||
음악 음량
|
||||
---
|
||||
[retention_marker_label]
|
||||
보유 30초 표시음
|
||||
[whm_time_signals_label]
|
||||
시간 알림
|
||||
---
|
||||
[minute_bell_label]
|
||||
1분마다 종소리
|
||||
[whm_time_signals_off]
|
||||
끄기
|
||||
---
|
||||
[whm_time_signals_minute]
|
||||
1분마다
|
||||
---
|
||||
[whm_time_signals_retention]
|
||||
30초마다
|
||||
---
|
||||
[whm_time_signals_both]
|
||||
둘 다
|
||||
---
|
||||
[whm_time_signals_hint]
|
||||
30초 알림은 숨을 참는 동안 울립니다. 1분 알림은 일시 정지를 제외한 전체 세션 시간을 기준으로 울립니다.
|
||||
---
|
||||
[reset_to_defaults_label]
|
||||
기본값으로 재설정
|
||||
|
||||
+16
-4
@@ -463,11 +463,23 @@ Nível de saída
|
||||
[music_volume_label]
|
||||
Volume da música
|
||||
---
|
||||
[retention_marker_label]
|
||||
Marcador de retenção 30 s
|
||||
[whm_time_signals_label]
|
||||
Sinais de tempo
|
||||
---
|
||||
[minute_bell_label]
|
||||
Sino a cada minuto
|
||||
[whm_time_signals_off]
|
||||
Desativados
|
||||
---
|
||||
[whm_time_signals_minute]
|
||||
A cada minuto
|
||||
---
|
||||
[whm_time_signals_retention]
|
||||
A cada 30 segundos
|
||||
---
|
||||
[whm_time_signals_both]
|
||||
Ambos
|
||||
---
|
||||
[whm_time_signals_hint]
|
||||
Os sinais de 30 segundos soam durante as retenções. Os sinais de um minuto contam o tempo ativo da sessão.
|
||||
---
|
||||
[reset_to_defaults_label]
|
||||
Restaurar padrões
|
||||
|
||||
+16
-4
@@ -490,11 +490,23 @@ OK
|
||||
[music_volume_label]
|
||||
Громкость музыки
|
||||
---
|
||||
[retention_marker_label]
|
||||
Метка задержки 30 с
|
||||
[whm_time_signals_label]
|
||||
Сигналы времени
|
||||
---
|
||||
[minute_bell_label]
|
||||
Колокольчик каждую минуту
|
||||
[whm_time_signals_off]
|
||||
Выключены
|
||||
---
|
||||
[whm_time_signals_minute]
|
||||
Каждую минуту
|
||||
---
|
||||
[whm_time_signals_retention]
|
||||
Каждые 30 секунд
|
||||
---
|
||||
[whm_time_signals_both]
|
||||
Оба
|
||||
---
|
||||
[whm_time_signals_hint]
|
||||
30-секундные сигналы звучат во время задержки дыхания. Минутные сигналы отсчитывают время всей практики без пауз.
|
||||
---
|
||||
[reset_to_defaults_label]
|
||||
Сбросить настройки
|
||||
|
||||
+16
-4
@@ -463,11 +463,23 @@ Wim Hof 呼吸
|
||||
[music_volume_label]
|
||||
音乐音量
|
||||
---
|
||||
[retention_marker_label]
|
||||
屏息 30 秒标记
|
||||
[whm_time_signals_label]
|
||||
计时提示
|
||||
---
|
||||
[minute_bell_label]
|
||||
每分钟铃声
|
||||
[whm_time_signals_off]
|
||||
关闭
|
||||
---
|
||||
[whm_time_signals_minute]
|
||||
每分钟
|
||||
---
|
||||
[whm_time_signals_retention]
|
||||
每30秒
|
||||
---
|
||||
[whm_time_signals_both]
|
||||
两者
|
||||
---
|
||||
[whm_time_signals_hint]
|
||||
30秒提示在屏息时响起,分钟提示按整个练习的有效时间响起。
|
||||
---
|
||||
[reset_to_defaults_label]
|
||||
恢复默认
|
||||
|
||||
@@ -37,6 +37,7 @@ GetFrameTime :: () -> float32 #foreign c;
|
||||
#import "modal_frame_widget"
|
||||
#import "modal_props"
|
||||
#import "text_widget"
|
||||
#import "text_measure"
|
||||
#import "toggle_widget"
|
||||
#import "drawing_props"
|
||||
#import "session"
|
||||
@@ -225,8 +226,14 @@ whm_config_session_card_height :: () -> s32 {
|
||||
return AppScale(82) * 3 + AppScale(24)
|
||||
}
|
||||
|
||||
whm_config_options_card_height :: () -> s32 {
|
||||
return AppScale(88) * 4
|
||||
whm_config_options_card_height :: (content_w: s32) -> s32 {
|
||||
hint_height := TextHeight(CurrentApp().ui.session, TextProps.{
|
||||
.bounds = Rectangle.{0.0, 0.0,
|
||||
cast(float32)(content_w - AppScale(44)), 0.0},
|
||||
.text = LocaleText("whm_time_signals_hint"),
|
||||
.font = AppScale(14)})
|
||||
return AppScale(22) * 2 + AppScale(88) * 2 +
|
||||
AppScale(26 + 48 + 12) + cast(s32)hint_height
|
||||
}
|
||||
|
||||
whm_config_draw_breath_card :: (app: *InnerBreeze, content_x: s32, content_w: s32,
|
||||
@@ -426,8 +433,19 @@ whm_config_draw_options_card :: (app: *InnerBreeze, content_x: s32, content_w: s
|
||||
double_tap_to_breathe := app.double_tap_to_breathe
|
||||
advanced_session_controls := app.advanced_session_controls
|
||||
retention_marker_enabled := app.retention_marker_enabled
|
||||
minute_bell_enabled := app.minute_bell_enabled
|
||||
card_h := whm_config_options_card_height()
|
||||
signal_index: s32 = 0
|
||||
if app.minute_bell_enabled != 0 {
|
||||
signal_index += 1
|
||||
}
|
||||
if retention_marker_enabled != 0 {
|
||||
signal_index += 2
|
||||
}
|
||||
signal_options: [4]DropdownOption
|
||||
signal_options[0] = DropdownOption.{.label = LocaleText("whm_time_signals_off")}
|
||||
signal_options[1] = DropdownOption.{.label = LocaleText("whm_time_signals_minute")}
|
||||
signal_options[2] = DropdownOption.{.label = LocaleText("whm_time_signals_retention")}
|
||||
signal_options[3] = DropdownOption.{.label = LocaleText("whm_time_signals_both")}
|
||||
card_h := whm_config_options_card_height(content_w)
|
||||
card_pad := AppScale(22)
|
||||
inner_x := content_x + card_pad
|
||||
inner_w := content_w - card_pad * 2
|
||||
@@ -482,39 +500,30 @@ whm_config_draw_options_card :: (app: *InnerBreeze, content_x: s32, content_w: s
|
||||
|
||||
Text(CurrentApp().ui.session, TextProps.{
|
||||
.bounds = Rectangle.{cast(float32)(inner_x), cast(float32)(inner_y), 0, 0},
|
||||
.text = (LocaleText("retention_marker_label")),
|
||||
.text = LocaleText("whm_time_signals_label"),
|
||||
.wrap = cast(TextWrap)TextWrapNone
|
||||
})
|
||||
marker_toggle := Toggle(CurrentApp().ui.session, ToggleProps.{.id = 1203,
|
||||
.bounds = Rectangle.{cast(float32)(inner_x + inner_w - toggle_w),
|
||||
cast(float32)(inner_y + (AppScale(60) - toggle_h) / 2),
|
||||
cast(float32)toggle_w, cast(float32)toggle_h},
|
||||
.value = retention_marker_enabled != 0,
|
||||
.off_label = LocaleText("toggle_off"),
|
||||
.on_label = LocaleText("toggle_on")})
|
||||
if marker_toggle.changed {
|
||||
app.retention_marker_enabled = ifx (marker_toggle.value) then (1) else (0)
|
||||
app.retention_marker_last_bucket = 0
|
||||
signal_pick := Dropdown(CurrentApp().ui.session, DropdownProps.{.id = 1203,
|
||||
.bounds = Rectangle.{cast(float32)inner_x,
|
||||
cast(float32)(inner_y + AppScale(26)),
|
||||
cast(float32)inner_w, cast(float32)AppScale(48)},
|
||||
.selected_index = signal_index}, signal_options[:])
|
||||
if signal_pick.changed {
|
||||
app.minute_bell_enabled = ifx (signal_pick.selected_index == 1 ||
|
||||
signal_pick.selected_index == 3) then (1) else (0)
|
||||
app.retention_marker_enabled = ifx (signal_pick.selected_index == 2 ||
|
||||
signal_pick.selected_index == 3) then (1) else (0)
|
||||
if app.retention_marker_enabled != retention_marker_enabled {
|
||||
app.retention_marker_last_bucket = 0
|
||||
}
|
||||
app.settings_dirty = 1
|
||||
}
|
||||
inner_y += AppScale(88)
|
||||
|
||||
Text(CurrentApp().ui.session, TextProps.{
|
||||
.bounds = Rectangle.{cast(float32)(inner_x), cast(float32)(inner_y), 0, 0},
|
||||
.text = (LocaleText("minute_bell_label")),
|
||||
.wrap = cast(TextWrap)TextWrapNone
|
||||
})
|
||||
minute_bell_toggle := Toggle(CurrentApp().ui.session, ToggleProps.{.id = 1204,
|
||||
.bounds = Rectangle.{cast(float32)(inner_x + inner_w - toggle_w),
|
||||
cast(float32)(inner_y + (AppScale(60) - toggle_h) / 2),
|
||||
cast(float32)toggle_w, cast(float32)toggle_h},
|
||||
.value = minute_bell_enabled != 0,
|
||||
.off_label = LocaleText("toggle_off"),
|
||||
.on_label = LocaleText("toggle_on")})
|
||||
if minute_bell_toggle.changed {
|
||||
app.minute_bell_enabled = ifx (minute_bell_toggle.value) then (1) else (0)
|
||||
app.settings_dirty = 1
|
||||
}
|
||||
.bounds = Rectangle.{cast(float32)inner_x,
|
||||
cast(float32)(inner_y + AppScale(86)),
|
||||
cast(float32)inner_w, 0.0},
|
||||
.text = LocaleText("whm_time_signals_hint"),
|
||||
.font = AppScale(14)})
|
||||
|
||||
return y + card_h + AppScale(16)
|
||||
}
|
||||
@@ -578,7 +587,7 @@ whm_config_content_height :: (app: *InnerBreeze, content_w: s32) -> s32 {
|
||||
app.modal.type != cast(ModalType)ModalPracticeConfig
|
||||
bottom_padding := (ifx (integrated) then (app_content_bottom_reserved(app)) else (0)) + AppScale(24)
|
||||
|
||||
return whm_config_breath_card_height(app) + AppScale(16) + whm_config_session_card_height() + AppScale(16) + whm_config_options_card_height() + AppScale(40) + meditation_music_measure_practice_settings(app, EXERCISE_WIM_HOF,
|
||||
return whm_config_breath_card_height(app) + AppScale(16) + whm_config_session_card_height() + AppScale(16) + whm_config_options_card_height(content_w) + AppScale(40) + meditation_music_measure_practice_settings(app, EXERCISE_WIM_HOF,
|
||||
content_w, 0, 1) + AppScale(12) + AppScale(48) + AppScale(24) + bottom_padding
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user