CHORE: Improve consistency in string and function names #1

This commit is contained in:
GithubAnon0000 2025-09-29 23:24:17 +02:00
parent 6b2aa2c5db
commit 7b52687c42
3 changed files with 5 additions and 5 deletions

View file

@ -120,7 +120,7 @@ message Preferences {
uint32 time_limit_secs = 5; uint32 time_limit_secs = 5;
bool load_balancer_enabled = 6; bool load_balancer_enabled = 6;
bool fsrs_short_term_with_steps_enabled = 7; bool fsrs_short_term_with_steps_enabled = 7;
bool hide_colored_buttons = 8; bool show_colored_buttons = 8;
} }
message Editing { message Editing {
bool adding_defaults_to_current_deck = 1; bool adding_defaults_to_current_deck = 1;

View file

@ -137,7 +137,7 @@ class Preferences(QDialog):
form.showEstimates.setChecked(reviewing.show_intervals_on_buttons) form.showEstimates.setChecked(reviewing.show_intervals_on_buttons)
form.showProgress.setChecked(reviewing.show_remaining_due_counts) form.showProgress.setChecked(reviewing.show_remaining_due_counts)
form.showPlayButtons.setChecked(not reviewing.hide_audio_play_buttons) form.showPlayButtons.setChecked(not reviewing.hide_audio_play_buttons)
form.hideColoredButtons.setChecked(not reviewing.hide_colored_buttons) form.hideColoredButtons.setChecked(not reviewing.show_colored_buttons)
form.interrupt_audio.setChecked(reviewing.interrupt_audio_when_answering) form.interrupt_audio.setChecked(reviewing.interrupt_audio_when_answering)
editing = self.prefs.editing editing = self.prefs.editing
@ -173,7 +173,7 @@ class Preferences(QDialog):
reviewing.show_intervals_on_buttons = form.showEstimates.isChecked() reviewing.show_intervals_on_buttons = form.showEstimates.isChecked()
reviewing.time_limit_secs = form.timeLimit.value() * 60 reviewing.time_limit_secs = form.timeLimit.value() * 60
reviewing.hide_audio_play_buttons = not self.form.showPlayButtons.isChecked() reviewing.hide_audio_play_buttons = not self.form.showPlayButtons.isChecked()
reviewing.hide_colored_buttons = not self.form.hideColoredButtons.isChecked() reviewing.show_colored_buttons = not self.form.hideColoredButtons.isChecked()
reviewing.interrupt_audio_when_answering = self.form.interrupt_audio.isChecked() reviewing.interrupt_audio_when_answering = self.form.interrupt_audio.isChecked()
editing = self.prefs.editing editing = self.prefs.editing

View file

@ -97,7 +97,7 @@ impl Collection {
show_remaining_due_counts: self.get_config_bool(BoolKey::ShowRemainingDueCountsInStudy), show_remaining_due_counts: self.get_config_bool(BoolKey::ShowRemainingDueCountsInStudy),
show_intervals_on_buttons: self show_intervals_on_buttons: self
.get_config_bool(BoolKey::ShowIntervalsAboveAnswerButtons), .get_config_bool(BoolKey::ShowIntervalsAboveAnswerButtons),
hide_colored_buttons: self.get_config_bool(BoolKey::HideColoredButtons), show_colored_buttons: self.get_config_bool(BoolKey::HideColoredButtons),
time_limit_secs: self.get_answer_time_limit_secs(), time_limit_secs: self.get_answer_time_limit_secs(),
load_balancer_enabled: self.get_config_bool(BoolKey::LoadBalancerEnabled), load_balancer_enabled: self.get_config_bool(BoolKey::LoadBalancerEnabled),
fsrs_short_term_with_steps_enabled: self fsrs_short_term_with_steps_enabled: self
@ -120,7 +120,7 @@ impl Collection {
BoolKey::ShowIntervalsAboveAnswerButtons, BoolKey::ShowIntervalsAboveAnswerButtons,
s.show_intervals_on_buttons, s.show_intervals_on_buttons,
)?; )?;
self.set_config_bool_inner(BoolKey::HideColoredButtons, s.hide_colored_buttons)?; self.set_config_bool_inner(BoolKey::HideColoredButtons, s.show_colored_buttons)?;
self.set_answer_time_limit_secs(s.time_limit_secs)?; self.set_answer_time_limit_secs(s.time_limit_secs)?;
self.set_config_bool_inner(BoolKey::LoadBalancerEnabled, s.load_balancer_enabled)?; self.set_config_bool_inner(BoolKey::LoadBalancerEnabled, s.load_balancer_enabled)?;
self.set_config_bool_inner( self.set_config_bool_inner(