Skip to content

Commit

Permalink
Merge pull request #1078 from Ordisoftware/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
Ordisoftware authored Feb 22, 2022
2 parents c2dd2a3 + 746f837 commit 1d1f7b0
Show file tree
Hide file tree
Showing 8 changed files with 7,318 additions and 4,241 deletions.
4 changes: 1 addition & 3 deletions Project/Source/Forms/Config/PreferencesForm.Load.cs
Original file line number Diff line number Diff line change
Expand Up @@ -123,9 +123,7 @@ private void LoadSettings()
SystemManager.TryCatch(() => EditReminderShabatShowParashah.Checked = Settings.ReminderShabatShowParashah);
SystemManager.TryCatch(() => EditWeeklyParashahShowAtStartup.Checked = Settings.WeeklyParashahShowAtStartup);
SystemManager.TryCatch(() => EditWeeklyParashahShowAtNewWeek.Checked = Settings.WeeklyParashahShowAtNewWeek);

// TODO add custom web search to preferences

SystemManager.TryCatch(() => EditCustomWebSearch.Text = Settings.CustomWebSearch);
// Assigned by the form on user action
SystemManager.TryCatch(() => EditMonthViewFontSize.Value = Settings.MonthViewFontSize);
SystemManager.TryCatch(() => EditDateBookmarksCount.Value = Settings.DateBookmarksCount);
Expand Down
1 change: 1 addition & 0 deletions Project/Source/Forms/Config/PreferencesForm.Save.cs
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,7 @@ private void SaveSettings()
Settings.ReminderShabatShowParashah = EditReminderShabatShowParashah.Checked;
Settings.WeeklyParashahShowAtStartup = EditWeeklyParashahShowAtStartup.Checked;
Settings.WeeklyParashahShowAtNewWeek = EditWeeklyParashahShowAtNewWeek.Checked;
Settings.CustomWebSearch = EditCustomWebSearch.Text;
// Moon/Sun/Sod
Settings.UseSodHaibour = SelectUseSodHaibour.Checked;
Settings.TorahEventsCountAsMoon = SelectOmerMoon.Checked;
Expand Down
2 changes: 2 additions & 0 deletions Project/Source/Forms/Config/PreferencesForm.Static.cs
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ partial class PreferencesForm
static public int TabIndexTextReport { get; private set; }
static public int TabIndexTrayIcon { get; private set; }
static public int TabIndexParashah { get; private set; }
static public int TabIndexWeather { get; private set; }

// Mono spaced fonts list
static private readonly string[] MonoSpacedFonts =
Expand Down Expand Up @@ -93,6 +94,7 @@ static PreferencesForm()
TabIndexTextReport = form.TabControl.TabPages.IndexOf(form.TabPageTextReport);
TabIndexTrayIcon = form.TabControl.TabPages.IndexOf(form.TabPageTrayIcon);
TabIndexParashah = form.TabControl.TabPages.IndexOf(form.TabPageParashah);
TabIndexWeather = form.TabControl.TabPages.IndexOf(form.TabPageWeather);
}
var filter1 = new Regex("(^F[0-9]{1,2}$)");
var filter2 = new Regex("(^[A-Z]$)");
Expand Down
6 changes: 6 additions & 0 deletions Project/Source/Forms/Config/PreferencesForm.cs
Original file line number Diff line number Diff line change
Expand Up @@ -677,6 +677,12 @@ private void ActionResetHebrewWordsPath_Click(object sender, EventArgs e)
EditHebrewWordsPath.Text = (string)Settings.Properties[nameof(Settings.HebrewWordsExe)].DefaultValue;
}

private void ActionResetCustomWebSearch_Click(object sender, EventArgs e)
{
if ( DisplayManager.QueryYesNo(SysTranslations.AskToResetParameter.GetLang()) )
EditCustomWebSearch.Text = (string)Settings.Properties[nameof(Settings.CustomWebSearch)].DefaultValue;
}

private void SelectWeatherOnlineMeteoblueDotCom_CheckedChanged(object sender, EventArgs e)
{
Settings.WeatherOnlineProvider = WeatherProvider.MeteoblueDotCom;
Expand Down
330 changes: 186 additions & 144 deletions Project/Source/Forms/Config/PreferencesForm.designer.cs

Large diffs are not rendered by default.

6 changes: 6 additions & 0 deletions Project/Source/Forms/Config/PreferencesForm.fr.resx
Original file line number Diff line number Diff line change
Expand Up @@ -919,4 +919,10 @@
<data name="SelectUseSodHaibour.Text" xml:space="preserve">
<value>Utiliser le sod ha'ibour avec le omer du soleil</value>
</data>
<data name="TabPageWeather.Text" xml:space="preserve">
<value>Météo</value>
</data>
<data name="LabelCustomWebSearch.Text" xml:space="preserve">
<value>Recherche web personnalisée</value>
</data>
</root>
Loading

0 comments on commit 1d1f7b0

Please sign in to comment.