From 3f2899e97ed455d244571bc73885777081948e26 Mon Sep 17 00:00:00 2001 From: Robert McRackan Date: Wed, 25 May 2022 10:09:27 -0400 Subject: [PATCH 1/4] * New event SearchEngineCommands.SearchEngineUpdated * Clean up redundant event notifications --- Source/AppScaffolding/AppScaffolding.csproj | 1 + Source/AppScaffolding/LibationScaffolding.cs | 11 ++- Source/ApplicationServices/LibraryCommands.cs | 65 ++++++++----- .../SearchEngineCommands.cs | 94 ++++++++++++++----- Source/FileLiberator/DownloadDecryptBook.cs | 4 +- Source/FileLiberator/DownloadPdf.cs | 4 +- Source/LibationCli/LibationCli.csproj | 1 - Source/LibationCli/Program.cs | 1 - Source/LibationCli/Setup.cs | 5 - Source/LibationWinForms/Form1.VisibleBooks.cs | 2 +- .../GridView/LibraryBookEntry.cs | 31 ++---- .../ProcessQueue/ProcessBook.cs | 14 +-- .../ProcessQueue/ProcessQueueControl.cs | 6 +- 13 files changed, 147 insertions(+), 92 deletions(-) diff --git a/Source/AppScaffolding/AppScaffolding.csproj b/Source/AppScaffolding/AppScaffolding.csproj index 83008a3a..b1f58b39 100644 --- a/Source/AppScaffolding/AppScaffolding.csproj +++ b/Source/AppScaffolding/AppScaffolding.csproj @@ -15,6 +15,7 @@ + diff --git a/Source/AppScaffolding/LibationScaffolding.cs b/Source/AppScaffolding/LibationScaffolding.cs index f12046bc..39cdd508 100644 --- a/Source/AppScaffolding/LibationScaffolding.cs +++ b/Source/AppScaffolding/LibationScaffolding.cs @@ -3,6 +3,7 @@ using System.Collections.Generic; using System.IO; using System.Linq; using System.Reflection; +using ApplicationServices; using AudibleUtilities; using Dinah.Core; using Dinah.Core.IO; @@ -139,12 +140,14 @@ namespace AppScaffolding config.DownloadCoverArt = true; } - /// Initialize logging. Run after migration + /// Initialize logging. Wire-up events. Run after migration public static void RunPostMigrationScaffolding(Configuration config) { ensureSerilogConfig(config); configureLogging(config); logStartupState(config); + + wireUpSystemEvents(config); } private static void ensureSerilogConfig(Configuration config) @@ -282,6 +285,12 @@ namespace AppScaffolding }); } + private static void wireUpSystemEvents(Configuration configuration) + { + LibraryCommands.LibrarySizeChanged += (_, __) => SearchEngineCommands.FullReIndex(); + LibraryCommands.BookUserDefinedItemCommitted += (_, books) => SearchEngineCommands.UpdateBooks(books); + } + public static UpgradeProperties GetLatestRelease() { // timed out diff --git a/Source/ApplicationServices/LibraryCommands.cs b/Source/ApplicationServices/LibraryCommands.cs index 773a3567..7f8133e3 100644 --- a/Source/ApplicationServices/LibraryCommands.cs +++ b/Source/ApplicationServices/LibraryCommands.cs @@ -253,11 +253,7 @@ namespace ApplicationServices #endregion // call this whenever books are added or removed from library - private static void finalizeLibrarySizeChange() - { - SearchEngineCommands.FullReIndex(); - LibrarySizeChanged?.Invoke(null, null); - } + private static void finalizeLibrarySizeChange() => LibrarySizeChanged?.Invoke(null, null); /// Occurs when the size of the library changes. ie: books are added or removed public static event EventHandler LibrarySizeChanged; @@ -265,9 +261,47 @@ namespace ApplicationServices /// /// Occurs when the size of the library does not change but book(s) details do. Especially when , , or changed values are successfully persisted. /// - public static event EventHandler BookUserDefinedItemCommitted; + public static event EventHandler> BookUserDefinedItemCommitted; #region Update book details + public static int UpdateBookStatus(this Book book, LiberatedStatus bookStatus) + { + book.UserDefinedItem.BookStatus = bookStatus; + return UpdateUserDefinedItem(book); + } + public static int UpdatePdfStatus(this Book book, LiberatedStatus pdfStatus) + { + book.UserDefinedItem.PdfStatus = pdfStatus; + return UpdateUserDefinedItem(book); + } + public static int UpdateBook( + this Book book, + string tags = null, + LiberatedStatus? bookStatus = null, + LiberatedStatus? pdfStatus = null) + => UpdateBooks(tags, bookStatus, pdfStatus, book); + public static int UpdateBooks( + string tags = null, + LiberatedStatus? bookStatus = null, + LiberatedStatus? pdfStatus = null, + params Book[] books) + { + foreach (var book in books) + { + // blank tags are expected. null tags are not + if (tags is not null && book.UserDefinedItem.Tags != tags) + book.UserDefinedItem.Tags = tags; + + if (bookStatus is not null && book.UserDefinedItem.BookStatus != bookStatus.Value) + book.UserDefinedItem.BookStatus = bookStatus.Value; + + // even though PdfStatus is nullable, there's no case where we'd actually overwrite with null + if (pdfStatus is not null && book.UserDefinedItem.PdfStatus != pdfStatus.Value) + book.UserDefinedItem.PdfStatus = pdfStatus.Value; + } + + return UpdateUserDefinedItem(books); + } public static int UpdateUserDefinedItem(params Book[] books) => UpdateUserDefinedItem(books.ToList()); public static int UpdateUserDefinedItem(IEnumerable books) { @@ -283,23 +317,8 @@ namespace ApplicationServices context.Attach(book.UserDefinedItem).State = Microsoft.EntityFrameworkCore.EntityState.Modified; var qtyChanges = context.SaveChanges(); - if (qtyChanges == 0) - return 0; - - // semi-arbitrary. At some point it's more worth it to do a full re-index than to do one offs. - // I did not benchmark before choosing the number here - if (qtyChanges > 15) - SearchEngineCommands.FullReIndex(); - else - { - foreach (var book in books) - { - SearchEngineCommands.UpdateLiberatedStatus(book); - SearchEngineCommands.UpdateBookTags(book); - } - } - - BookUserDefinedItemCommitted?.Invoke(null, null); + if (qtyChanges > 0) + BookUserDefinedItemCommitted?.Invoke(null, books); return qtyChanges; } diff --git a/Source/ApplicationServices/SearchEngineCommands.cs b/Source/ApplicationServices/SearchEngineCommands.cs index 9d871969..7a0e2219 100644 --- a/Source/ApplicationServices/SearchEngineCommands.cs +++ b/Source/ApplicationServices/SearchEngineCommands.cs @@ -1,5 +1,7 @@ using System; +using System.Collections.Generic; using System.IO; +using System.Linq; using DataLayer; using LibationSearchEngine; @@ -7,51 +9,99 @@ namespace ApplicationServices { public static class SearchEngineCommands { - public static void FullReIndex(SearchEngine engine = null) - { - engine ??= new SearchEngine(); - var library = DbContexts.GetLibrary_Flat_NoTracking(); - engine.CreateNewIndex(library); - } - - public static SearchResultSet Search(string searchString) => performSearchEngineFunc_safe(e => + #region Search + public static SearchResultSet Search(string searchString) => performSafeQuery(e => e.Search(searchString) ); - public static void UpdateBookTags(Book book) => performSearchEngineAction_safe(e => - e.UpdateTags(book.AudibleProductId, book.UserDefinedItem.Tags) + private static T performSafeQuery(Func func) + { + var engine = new SearchEngine(); + try + { + return func(engine); + } + catch (FileNotFoundException) + { + fullReIndex(engine); + return func(engine); + } + } + #endregion + + public static EventHandler SearchEngineUpdated; + + #region Update + private static bool isUpdating; + + public static void UpdateBooks(IEnumerable books) + { + // Semi-arbitrary. At some point it's more worth it to do a full re-index than to do one offs. + // I did not benchmark before choosing the number here + if (books.Count() > 15) + FullReIndex(); + else + { + foreach (var book in books) + { + UpdateLiberatedStatus(book); + UpdateBookTags(book); + } + } + } + + public static void FullReIndex() => performSafeCommand(e => + fullReIndex(e) ); - public static void UpdateLiberatedStatus(Book book) => performSearchEngineAction_safe(e => + internal static void UpdateLiberatedStatus(Book book) => performSafeCommand(e => e.UpdateLiberatedStatus(book) ); - private static void performSearchEngineAction_safe(Action action) + internal static void UpdateBookTags(Book book) => performSafeCommand(e => + e.UpdateTags(book.AudibleProductId, book.UserDefinedItem.Tags) + ); + + private static void performSafeCommand(Action action) { - var engine = new SearchEngine(); try { - action(engine); + update(action); } catch (FileNotFoundException) { - FullReIndex(engine); - action(engine); + fullReIndex(new SearchEngine()); + update(action); } } - private static T performSearchEngineFunc_safe(Func func) + private static void update(Action action) { - var engine = new SearchEngine(); + if (action is null) + return; + + // support nesting incl recursion + var prevIsUpdating = isUpdating; try { - return func(engine); + isUpdating = true; + + action(new SearchEngine()); + + if (!prevIsUpdating) + SearchEngineUpdated?.Invoke(null, null); } - catch (FileNotFoundException) + finally { - FullReIndex(engine); - return func(engine); + isUpdating = prevIsUpdating; } } + + private static void fullReIndex(SearchEngine engine) + { + var library = DbContexts.GetLibrary_Flat_NoTracking(); + engine.CreateNewIndex(library); + } + #endregion } } diff --git a/Source/FileLiberator/DownloadDecryptBook.cs b/Source/FileLiberator/DownloadDecryptBook.cs index 1236c7a5..20e55e39 100644 --- a/Source/FileLiberator/DownloadDecryptBook.cs +++ b/Source/FileLiberator/DownloadDecryptBook.cs @@ -4,6 +4,7 @@ using System.IO; using System.Linq; using System.Threading.Tasks; using AaxDecrypter; +using ApplicationServices; using AudibleApi; using DataLayer; using Dinah.Core; @@ -82,8 +83,7 @@ namespace FileLiberator if (Configuration.Instance.DownloadCoverArt) DownloadCoverArt(libraryBook); - libraryBook.Book.UserDefinedItem.BookStatus = LiberatedStatus.Liberated; - ApplicationServices.LibraryCommands.UpdateUserDefinedItem(libraryBook.Book); + libraryBook.Book.UpdateBookStatus(LiberatedStatus.Liberated); return new StatusHandler(); } diff --git a/Source/FileLiberator/DownloadPdf.cs b/Source/FileLiberator/DownloadPdf.cs index 5bc61f7c..fd87d455 100644 --- a/Source/FileLiberator/DownloadPdf.cs +++ b/Source/FileLiberator/DownloadPdf.cs @@ -4,6 +4,7 @@ using System.IO; using System.Linq; using System.Net.Http; using System.Threading.Tasks; +using ApplicationServices; using DataLayer; using Dinah.Core.ErrorHandling; using Dinah.Core.Net.Http; @@ -29,8 +30,7 @@ namespace FileLiberator var actualDownloadedFilePath = await downloadPdfAsync(libraryBook, proposedDownloadFilePath); var result = verifyDownload(actualDownloadedFilePath); - libraryBook.Book.UserDefinedItem.PdfStatus = result.IsSuccess ? LiberatedStatus.Liberated : LiberatedStatus.NotLiberated; - ApplicationServices.LibraryCommands.UpdateUserDefinedItem(libraryBook.Book); + libraryBook.Book.UpdatePdfStatus(result.IsSuccess ? LiberatedStatus.Liberated : LiberatedStatus.NotLiberated); return result; } diff --git a/Source/LibationCli/LibationCli.csproj b/Source/LibationCli/LibationCli.csproj index 4822e11c..ccc959aa 100644 --- a/Source/LibationCli/LibationCli.csproj +++ b/Source/LibationCli/LibationCli.csproj @@ -33,7 +33,6 @@ - diff --git a/Source/LibationCli/Program.cs b/Source/LibationCli/Program.cs index 2681d195..e1d2c32f 100644 --- a/Source/LibationCli/Program.cs +++ b/Source/LibationCli/Program.cs @@ -27,7 +27,6 @@ namespace LibationCli // // //***********************************************// Setup.Initialize(); - Setup.SubscribeToDatabaseEvents(); var types = Setup.LoadVerbs(); diff --git a/Source/LibationCli/Setup.cs b/Source/LibationCli/Setup.cs index dec0fff7..fc9e35ea 100644 --- a/Source/LibationCli/Setup.cs +++ b/Source/LibationCli/Setup.cs @@ -50,11 +50,6 @@ namespace LibationCli } } - public static void SubscribeToDatabaseEvents() - { - DataLayer.UserDefinedItem.ItemChanged += (sender, e) => ApplicationServices.LibraryCommands.UpdateUserDefinedItem(((DataLayer.UserDefinedItem)sender).Book); - } - public static Type[] LoadVerbs() => Assembly.GetExecutingAssembly() .GetTypes() .Where(t => t.GetCustomAttribute() is not null) diff --git a/Source/LibationWinForms/Form1.VisibleBooks.cs b/Source/LibationWinForms/Form1.VisibleBooks.cs index 5f29172d..e44cadec 100644 --- a/Source/LibationWinForms/Form1.VisibleBooks.cs +++ b/Source/LibationWinForms/Form1.VisibleBooks.cs @@ -22,7 +22,7 @@ namespace LibationWinForms LibraryCommands.BookUserDefinedItemCommitted += setLiberatedVisibleMenuItemAsync; } - private async void setLiberatedVisibleMenuItemAsync(object _, EventArgs __) + private async void setLiberatedVisibleMenuItemAsync(object _, object __) => await Task.Run(setLiberatedVisibleMenuItem); void setLiberatedVisibleMenuItem() { diff --git a/Source/LibationWinForms/GridView/LibraryBookEntry.cs b/Source/LibationWinForms/GridView/LibraryBookEntry.cs index 848c9e4f..be6836a8 100644 --- a/Source/LibationWinForms/GridView/LibraryBookEntry.cs +++ b/Source/LibationWinForms/GridView/LibraryBookEntry.cs @@ -25,6 +25,7 @@ namespace LibationWinForms.GridView #endregion protected override Book Book => LibraryBook.Book; + #region Model properties exposed to the view private DateTime lastStatusUpdate = default; @@ -75,6 +76,7 @@ namespace LibationWinForms.GridView if (AudibleProductId != libraryBook.Book.AudibleProductId) throw new Exception("Invalid grid entry update. IDs must match"); + UserDefinedItem.ItemChanged -= UserDefinedItem_ItemChanged; setLibraryBook(libraryBook); NotifyPropertyChanged(); @@ -84,8 +86,6 @@ namespace LibationWinForms.GridView { LibraryBook = libraryBook; - UserDefinedItem.ItemChanged -= UserDefinedItem_ItemChanged; - // Immutable properties { Title = Book.Title; @@ -110,7 +110,7 @@ namespace LibationWinForms.GridView /// /// This event handler receives notifications from the model that it has changed. - /// Save to the database and notify the view that it's changed. + /// Notify the view that it's changed. /// private void UserDefinedItem_ItemChanged(object sender, string itemName) { @@ -119,23 +119,23 @@ namespace LibationWinForms.GridView if (udi.Book.AudibleProductId != Book.AudibleProductId) return; + // UDI changed, possibly in a different context/view. Update this viewmodel. Call NotifyPropertyChanged to notify view. + // - This method responds to tons of incidental changes. Do not persist to db from here. Committing to db must be a volitional action by the caller, not incidental. Otherwise batch changes would be impossible; we would only have slow one-offs + // - Don't restrict notifying view to 'only if property changed'. This same book instance can get passed to a different view, then changed there. When the chain of events makes its way back here, the property is unchanged (because it's the same instance), but this view is out of sync. NotifyPropertyChanged will then update this view. switch (itemName) { case nameof(udi.Tags): Book.UserDefinedItem.Tags = udi.Tags; - SearchEngineCommands.UpdateBookTags(Book); NotifyPropertyChanged(nameof(DisplayTags)); break; case nameof(udi.BookStatus): Book.UserDefinedItem.BookStatus = udi.BookStatus; _bookStatus = udi.BookStatus; - SearchEngineCommands.UpdateLiberatedStatus(Book); NotifyPropertyChanged(nameof(Liberate)); break; case nameof(udi.PdfStatus): Book.UserDefinedItem.PdfStatus = udi.PdfStatus; _pdfStatus = udi.PdfStatus; - SearchEngineCommands.UpdateLiberatedStatus(Book); NotifyPropertyChanged(nameof(Liberate)); break; } @@ -143,23 +143,8 @@ namespace LibationWinForms.GridView /// Save edits to the database public void Commit(string newTags, LiberatedStatus bookStatus, LiberatedStatus? pdfStatus) - { - // validate - if (DisplayTags.EqualsInsensitive(newTags) && - Liberate.BookStatus == bookStatus && - Liberate.PdfStatus == pdfStatus) - return; - - // update cache - _bookStatus = bookStatus; - _pdfStatus = pdfStatus; - - // set + save - Book.UserDefinedItem.Tags = newTags; - Book.UserDefinedItem.BookStatus = bookStatus; - Book.UserDefinedItem.PdfStatus = pdfStatus; - LibraryCommands.UpdateUserDefinedItem(Book); - } + // MVVM pass-through + => Book.UpdateBook(newTags, bookStatus: bookStatus, pdfStatus: pdfStatus); #endregion diff --git a/Source/LibationWinForms/ProcessQueue/ProcessBook.cs b/Source/LibationWinForms/ProcessQueue/ProcessBook.cs index 7c9778a5..9891e68b 100644 --- a/Source/LibationWinForms/ProcessQueue/ProcessBook.cs +++ b/Source/LibationWinForms/ProcessQueue/ProcessBook.cs @@ -1,8 +1,4 @@ -using DataLayer; -using Dinah.Core; -using FileLiberator; -using LibationFileManager; -using System; +using System; using System.Collections.Generic; using System.ComponentModel; using System.Drawing; @@ -10,6 +6,11 @@ using System.Linq; using System.Runtime.CompilerServices; using System.Threading.Tasks; using System.Windows.Forms; +using ApplicationServices; +using DataLayer; +using Dinah.Core; +using FileLiberator; +using LibationFileManager; namespace LibationWinForms.ProcessQueue { @@ -353,8 +354,7 @@ $@" Title: {libraryBook.Book.Title} if (dialogResult == SkipResult) { - libraryBook.Book.UserDefinedItem.BookStatus = LiberatedStatus.Error; - ApplicationServices.LibraryCommands.UpdateUserDefinedItem(libraryBook.Book); + libraryBook.Book.UpdateBookStatus(LiberatedStatus.Error); Logger.Info($"Error. Skip: [{libraryBook.Book.AudibleProductId}] {libraryBook.Book.Title}"); diff --git a/Source/LibationWinForms/ProcessQueue/ProcessQueueControl.cs b/Source/LibationWinForms/ProcessQueue/ProcessQueueControl.cs index a55dc071..d6b9d322 100644 --- a/Source/LibationWinForms/ProcessQueue/ProcessQueueControl.cs +++ b/Source/LibationWinForms/ProcessQueue/ProcessQueueControl.cs @@ -4,6 +4,7 @@ using System.ComponentModel; using System.Linq; using System.Threading.Tasks; using System.Windows.Forms; +using ApplicationServices; namespace LibationWinForms.ProcessQueue { @@ -156,10 +157,7 @@ namespace LibationWinForms.ProcessQueue else if (result == ProcessBookResult.FailedAbort) Queue.ClearQueue(); else if (result == ProcessBookResult.FailedSkip) - { - nextBook.LibraryBook.Book.UserDefinedItem.BookStatus = DataLayer.LiberatedStatus.Error; - ApplicationServices.LibraryCommands.UpdateUserDefinedItem(nextBook.LibraryBook.Book); - } + nextBook.LibraryBook.Book.UpdateBookStatus(DataLayer.LiberatedStatus.Error); } Queue_CompletedCountChanged(this, 0); counterTimer.Stop(); From 3408b4637c0458d1829bed1b2f7b572b1ded79ff Mon Sep 17 00:00:00 2001 From: Robert McRackan Date: Wed, 25 May 2022 12:49:24 -0400 Subject: [PATCH 2/4] search engine cleanup --- Source/LibationSearchEngine/SearchEngine.cs | 29 ++++++--------------- 1 file changed, 8 insertions(+), 21 deletions(-) diff --git a/Source/LibationSearchEngine/SearchEngine.cs b/Source/LibationSearchEngine/SearchEngine.cs index bcef08c2..5af93080 100644 --- a/Source/LibationSearchEngine/SearchEngine.cs +++ b/Source/LibationSearchEngine/SearchEngine.cs @@ -18,18 +18,11 @@ namespace LibationSearchEngine { public const Lucene.Net.Util.Version Version = Lucene.Net.Util.Version.LUCENE_30; - // not customizable. don't move to config - private static string SearchEngineDirectory { get; } - = new System.IO.DirectoryInfo(Configuration.Instance.LibationFiles).CreateSubdirectory("SearchEngine").FullName; - public const string _ID_ = "_ID_"; public const string TAGS = "tags"; // special field for each book which includes all major parts of the book's metadata. enables non-targetting searching public const string ALL = "all"; - // the workaround which allows displaying all books when query is empty - public const string ALL_QUERY = "*:*"; - #region index rules // common fields used in the "all" default search field public const string ALL_AUDIBLE_PRODUCT_ID = nameof(Book.AudibleProductId); @@ -124,7 +117,6 @@ namespace LibationSearchEngine [nameof(Book.IsAbridged)] = lb => lb.Book.IsAbridged, ["Abridged"] = lb => lb.Book.IsAbridged, - // this will only be evaluated at time of re-index. ie: state of files moved later will be out of sync until next re-index ["IsLiberated"] = lb => isLiberated(lb.Book), ["Liberated"] = lb => isLiberated(lb.Book), ["LiberatedError"] = lb => liberatedError(lb.Book), @@ -184,18 +176,6 @@ namespace LibationSearchEngine foreach (var key in numberIndexRules.Keys) yield return key; } - - public static IEnumerable GetSearchFields() - { - foreach (var key in idIndexRules.Keys) - yield return key; - foreach (var key in stringIndexRules.Keys) - yield return key; - foreach (var key in boolIndexRules.Keys) - yield return key; - foreach (var key in numberIndexRules.Keys) - yield return key; - } #endregion #region create and update index @@ -333,6 +313,9 @@ namespace LibationSearchEngine } #endregion + // the workaround which allows displaying all books when query is empty + public const string ALL_QUERY = "*:*"; + #region search public SearchResultSet Search(string searchString) { @@ -347,7 +330,7 @@ namespace LibationSearchEngine return results; } - public static string FormatSearchQuery(string searchString) + internal static string FormatSearchQuery(string searchString) { if (string.IsNullOrWhiteSpace(searchString)) return ALL_QUERY; @@ -493,5 +476,9 @@ namespace LibationSearchEngine #endregion private static Directory getIndex() => FSDirectory.Open(SearchEngineDirectory); + + // not customizable. don't move to config + private static string SearchEngineDirectory { get; } + = new System.IO.DirectoryInfo(Configuration.Instance.LibationFiles).CreateSubdirectory("SearchEngine").FullName; } } From 99527453a7492f96feecc4c84683a94096a3a743 Mon Sep 17 00:00:00 2001 From: Robert McRackan Date: Wed, 25 May 2022 12:56:34 -0400 Subject: [PATCH 3/4] add TODO --- Source/LibationSearchEngine/SearchEngine.cs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Source/LibationSearchEngine/SearchEngine.cs b/Source/LibationSearchEngine/SearchEngine.cs index 5af93080..a3c86867 100644 --- a/Source/LibationSearchEngine/SearchEngine.cs +++ b/Source/LibationSearchEngine/SearchEngine.cs @@ -272,6 +272,10 @@ namespace LibationSearchEngine book.AudibleProductId, d => { + // + // TODO: better synonym handling. This is too easy to mess up + // + // fields are key value pairs. MULTIPLE FIELDS CAN POTENTIALLY HAVE THE SAME KEY. // ie: must remove old before adding new else will create unwanted duplicates. var v1 = isLiberated(book); From f7a482659cebefd478130ff41463c6eb9120cd5f Mon Sep 17 00:00:00 2001 From: Robert McRackan Date: Wed, 25 May 2022 15:21:28 -0400 Subject: [PATCH 4/4] New feature #241 : Auto download episodes after scanning. Setting is on Import Library tab --- Source/AppScaffolding/AppScaffolding.csproj | 2 +- Source/AppScaffolding/LibationScaffolding.cs | 3 + Source/ApplicationServices/LibraryCommands.cs | 9 +- Source/LibationFileManager/Configuration.cs | 7 + .../Dialogs/SettingsDialog.Designer.cs | 1927 +++++++++-------- .../Dialogs/SettingsDialog.cs | 3 + Source/LibationWinForms/Form1.BackupCounts.cs | 144 +- Source/LibationWinForms/Form1.Liberate.cs | 2 +- .../LibationWinForms/Form1.PictureStorage.cs | 18 - Source/LibationWinForms/Form1._NonUI.cs | 37 + Source/LibationWinForms/Form1.cs | 3 +- 11 files changed, 1101 insertions(+), 1054 deletions(-) delete mode 100644 Source/LibationWinForms/Form1.PictureStorage.cs create mode 100644 Source/LibationWinForms/Form1._NonUI.cs diff --git a/Source/AppScaffolding/AppScaffolding.csproj b/Source/AppScaffolding/AppScaffolding.csproj index b1f58b39..0e6811ba 100644 --- a/Source/AppScaffolding/AppScaffolding.csproj +++ b/Source/AppScaffolding/AppScaffolding.csproj @@ -3,7 +3,7 @@ net6.0-windows - 7.8.1.1 + 7.9.0.1 diff --git a/Source/AppScaffolding/LibationScaffolding.cs b/Source/AppScaffolding/LibationScaffolding.cs index 39cdd508..251a05e4 100644 --- a/Source/AppScaffolding/LibationScaffolding.cs +++ b/Source/AppScaffolding/LibationScaffolding.cs @@ -138,6 +138,9 @@ namespace AppScaffolding if (!config.Exists(nameof(config.DownloadCoverArt))) config.DownloadCoverArt = true; + + if (!config.Exists(nameof(config.AutoDownloadEpisodes))) + config.AutoDownloadEpisodes = false; } /// Initialize logging. Wire-up events. Run after migration diff --git a/Source/ApplicationServices/LibraryCommands.cs b/Source/ApplicationServices/LibraryCommands.cs index 7f8133e3..745e8a8f 100644 --- a/Source/ApplicationServices/LibraryCommands.cs +++ b/Source/ApplicationServices/LibraryCommands.cs @@ -341,7 +341,14 @@ namespace ApplicationServices // below are queries, not commands. maybe I should make a LibraryQueries. except there's already one of those... - public record LibraryStats(int booksFullyBackedUp, int booksDownloadedOnly, int booksNoProgress, int booksError, int pdfsDownloaded, int pdfsNotDownloaded) { } + public record LibraryStats(int booksFullyBackedUp, int booksDownloadedOnly, int booksNoProgress, int booksError, int pdfsDownloaded, int pdfsNotDownloaded) + { + public int PendingBooks => booksNoProgress + booksDownloadedOnly; + public bool HasPendingBooks => PendingBooks > 0; + + public bool HasBookResults => 0 < (booksFullyBackedUp + booksDownloadedOnly + booksNoProgress + booksError); + public bool HasPdfResults => 0 < (pdfsNotDownloaded + pdfsDownloaded); + } public static LibraryStats GetCounts() { var libraryBooks = DbContexts.GetLibrary_Flat_NoTracking(); diff --git a/Source/LibationFileManager/Configuration.cs b/Source/LibationFileManager/Configuration.cs index a291daa5..9899567e 100644 --- a/Source/LibationFileManager/Configuration.cs +++ b/Source/LibationFileManager/Configuration.cs @@ -268,6 +268,13 @@ namespace LibationFileManager } } + [Description("Auto download episodes? Efter scan, download new books in 'checked' accounts.")] + public bool AutoDownloadEpisodes + { + get => persistentDictionary.GetNonString(nameof(AutoDownloadEpisodes)); + set => persistentDictionary.SetNonString(nameof(AutoDownloadEpisodes), value); + } + #region templates: custom file naming [Description("How to format the folders in which files will be saved")] diff --git a/Source/LibationWinForms/Dialogs/SettingsDialog.Designer.cs b/Source/LibationWinForms/Dialogs/SettingsDialog.Designer.cs index a66c8f04..afe150a5 100644 --- a/Source/LibationWinForms/Dialogs/SettingsDialog.Designer.cs +++ b/Source/LibationWinForms/Dialogs/SettingsDialog.Designer.cs @@ -28,972 +28,984 @@ /// private void InitializeComponent() { - this.booksLocationDescLbl = new System.Windows.Forms.Label(); - this.inProgressDescLbl = new System.Windows.Forms.Label(); - this.saveBtn = new System.Windows.Forms.Button(); - this.cancelBtn = new System.Windows.Forms.Button(); - this.importEpisodesCb = new System.Windows.Forms.CheckBox(); - this.downloadEpisodesCb = new System.Windows.Forms.CheckBox(); - this.badBookGb = new System.Windows.Forms.GroupBox(); - this.badBookIgnoreRb = new System.Windows.Forms.RadioButton(); - this.badBookRetryRb = new System.Windows.Forms.RadioButton(); - this.badBookAbortRb = new System.Windows.Forms.RadioButton(); - this.badBookAskRb = new System.Windows.Forms.RadioButton(); - this.stripAudibleBrandingCbox = new System.Windows.Forms.CheckBox(); - this.splitFilesByChapterCbox = new System.Windows.Forms.CheckBox(); - this.allowLibationFixupCbox = new System.Windows.Forms.CheckBox(); - this.convertLossyRb = new System.Windows.Forms.RadioButton(); - this.convertLosslessRb = new System.Windows.Forms.RadioButton(); - this.inProgressSelectControl = new LibationWinForms.Dialogs.DirectorySelectControl(); - this.logsBtn = new System.Windows.Forms.Button(); - this.booksSelectControl = new LibationWinForms.Dialogs.DirectoryOrCustomSelectControl(); - this.loggingLevelLbl = new System.Windows.Forms.Label(); - this.loggingLevelCb = new System.Windows.Forms.ComboBox(); - this.tabControl = new System.Windows.Forms.TabControl(); - this.tab1ImportantSettings = new System.Windows.Forms.TabPage(); - this.booksGb = new System.Windows.Forms.GroupBox(); - this.tab2ImportLibrary = new System.Windows.Forms.TabPage(); - this.autoScanCb = new System.Windows.Forms.CheckBox(); - this.showImportedStatsCb = new System.Windows.Forms.CheckBox(); - this.tab3DownloadDecrypt = new System.Windows.Forms.TabPage(); - this.inProgressFilesGb = new System.Windows.Forms.GroupBox(); - this.customFileNamingGb = new System.Windows.Forms.GroupBox(); - this.chapterFileTemplateBtn = new System.Windows.Forms.Button(); - this.chapterFileTemplateTb = new System.Windows.Forms.TextBox(); - this.chapterFileTemplateLbl = new System.Windows.Forms.Label(); - this.fileTemplateBtn = new System.Windows.Forms.Button(); - this.fileTemplateTb = new System.Windows.Forms.TextBox(); - this.fileTemplateLbl = new System.Windows.Forms.Label(); - this.folderTemplateBtn = new System.Windows.Forms.Button(); - this.folderTemplateTb = new System.Windows.Forms.TextBox(); - this.folderTemplateLbl = new System.Windows.Forms.Label(); - this.tab4AudioFileOptions = new System.Windows.Forms.TabPage(); - this.lameOptionsGb = new System.Windows.Forms.GroupBox(); - this.lameDownsampleMonoCbox = new System.Windows.Forms.CheckBox(); - this.lameBitrateGb = new System.Windows.Forms.GroupBox(); - this.LameMatchSourceBRCbox = new System.Windows.Forms.CheckBox(); - this.lameConstantBitrateCbox = new System.Windows.Forms.CheckBox(); - this.label7 = new System.Windows.Forms.Label(); - this.label6 = new System.Windows.Forms.Label(); - this.label5 = new System.Windows.Forms.Label(); - this.label4 = new System.Windows.Forms.Label(); - this.label11 = new System.Windows.Forms.Label(); - this.label3 = new System.Windows.Forms.Label(); - this.lameBitrateTb = new System.Windows.Forms.TrackBar(); - this.label1 = new System.Windows.Forms.Label(); - this.lameQualityGb = new System.Windows.Forms.GroupBox(); - this.label19 = new System.Windows.Forms.Label(); - this.label18 = new System.Windows.Forms.Label(); - this.label17 = new System.Windows.Forms.Label(); - this.label16 = new System.Windows.Forms.Label(); - this.label12 = new System.Windows.Forms.Label(); - this.label15 = new System.Windows.Forms.Label(); - this.label9 = new System.Windows.Forms.Label(); - this.label8 = new System.Windows.Forms.Label(); - this.label13 = new System.Windows.Forms.Label(); - this.label10 = new System.Windows.Forms.Label(); - this.label14 = new System.Windows.Forms.Label(); - this.label2 = new System.Windows.Forms.Label(); - this.lameVBRQualityTb = new System.Windows.Forms.TrackBar(); - this.groupBox2 = new System.Windows.Forms.GroupBox(); - this.lameTargetQualityRb = new System.Windows.Forms.RadioButton(); - this.lameTargetBitrateRb = new System.Windows.Forms.RadioButton(); - this.stripUnabridgedCbox = new System.Windows.Forms.CheckBox(); - this.retainAaxFileCbox = new System.Windows.Forms.CheckBox(); - this.createCueSheetCbox = new System.Windows.Forms.CheckBox(); - this.downloadCoverArtCbox = new System.Windows.Forms.CheckBox(); - this.badBookGb.SuspendLayout(); - this.tabControl.SuspendLayout(); - this.tab1ImportantSettings.SuspendLayout(); - this.booksGb.SuspendLayout(); - this.tab2ImportLibrary.SuspendLayout(); - this.tab3DownloadDecrypt.SuspendLayout(); - this.inProgressFilesGb.SuspendLayout(); - this.customFileNamingGb.SuspendLayout(); - this.tab4AudioFileOptions.SuspendLayout(); - this.lameOptionsGb.SuspendLayout(); - this.lameBitrateGb.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.lameBitrateTb)).BeginInit(); - this.lameQualityGb.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.lameVBRQualityTb)).BeginInit(); - this.groupBox2.SuspendLayout(); - this.SuspendLayout(); - // - // booksLocationDescLbl - // - this.booksLocationDescLbl.AutoSize = true; - this.booksLocationDescLbl.Location = new System.Drawing.Point(7, 19); - this.booksLocationDescLbl.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); - this.booksLocationDescLbl.Name = "booksLocationDescLbl"; - this.booksLocationDescLbl.Size = new System.Drawing.Size(69, 15); - this.booksLocationDescLbl.TabIndex = 1; - this.booksLocationDescLbl.Text = "[book desc]"; - // - // inProgressDescLbl - // - this.inProgressDescLbl.AutoSize = true; - this.inProgressDescLbl.Location = new System.Drawing.Point(7, 19); - this.inProgressDescLbl.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); - this.inProgressDescLbl.Name = "inProgressDescLbl"; - this.inProgressDescLbl.Size = new System.Drawing.Size(100, 45); - this.inProgressDescLbl.TabIndex = 18; - this.inProgressDescLbl.Text = "[in progress desc]\r\n[line 2]\r\n[line 3]"; - // - // saveBtn - // - this.saveBtn.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); - this.saveBtn.Location = new System.Drawing.Point(667, 441); - this.saveBtn.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3); - this.saveBtn.Name = "saveBtn"; - this.saveBtn.Size = new System.Drawing.Size(88, 27); - this.saveBtn.TabIndex = 98; - this.saveBtn.Text = "Save"; - this.saveBtn.UseVisualStyleBackColor = true; - this.saveBtn.Click += new System.EventHandler(this.saveBtn_Click); - // - // cancelBtn - // - this.cancelBtn.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); - this.cancelBtn.DialogResult = System.Windows.Forms.DialogResult.Cancel; - this.cancelBtn.Location = new System.Drawing.Point(785, 441); - this.cancelBtn.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3); - this.cancelBtn.Name = "cancelBtn"; - this.cancelBtn.Size = new System.Drawing.Size(88, 27); - this.cancelBtn.TabIndex = 99; - this.cancelBtn.Text = "Cancel"; - this.cancelBtn.UseVisualStyleBackColor = true; - this.cancelBtn.Click += new System.EventHandler(this.cancelBtn_Click); - // - // importEpisodesCb - // - this.importEpisodesCb.AutoSize = true; - this.importEpisodesCb.Location = new System.Drawing.Point(6, 56); - this.importEpisodesCb.Name = "importEpisodesCb"; - this.importEpisodesCb.Size = new System.Drawing.Size(146, 19); - this.importEpisodesCb.TabIndex = 3; - this.importEpisodesCb.Text = "[import episodes desc]"; - this.importEpisodesCb.UseVisualStyleBackColor = true; - // - // downloadEpisodesCb - // - this.downloadEpisodesCb.AutoSize = true; - this.downloadEpisodesCb.Location = new System.Drawing.Point(6, 81); - this.downloadEpisodesCb.Name = "downloadEpisodesCb"; - this.downloadEpisodesCb.Size = new System.Drawing.Size(163, 19); - this.downloadEpisodesCb.TabIndex = 4; - this.downloadEpisodesCb.Text = "[download episodes desc]"; - this.downloadEpisodesCb.UseVisualStyleBackColor = true; - // - // badBookGb - // - this.badBookGb.Controls.Add(this.badBookIgnoreRb); - this.badBookGb.Controls.Add(this.badBookRetryRb); - this.badBookGb.Controls.Add(this.badBookAbortRb); - this.badBookGb.Controls.Add(this.badBookAskRb); - this.badBookGb.Location = new System.Drawing.Point(7, 6); - this.badBookGb.Name = "badBookGb"; - this.badBookGb.Size = new System.Drawing.Size(888, 76); - this.badBookGb.TabIndex = 13; - this.badBookGb.TabStop = false; - this.badBookGb.Text = "[bad book desc]"; - // - // badBookIgnoreRb - // - this.badBookIgnoreRb.AutoSize = true; - this.badBookIgnoreRb.Location = new System.Drawing.Point(384, 47); - this.badBookIgnoreRb.Name = "badBookIgnoreRb"; - this.badBookIgnoreRb.Size = new System.Drawing.Size(94, 19); - this.badBookIgnoreRb.TabIndex = 17; - this.badBookIgnoreRb.TabStop = true; - this.badBookIgnoreRb.Text = "[ignore desc]"; - this.badBookIgnoreRb.UseVisualStyleBackColor = true; - // - // badBookRetryRb - // - this.badBookRetryRb.AutoSize = true; - this.badBookRetryRb.Location = new System.Drawing.Point(5, 47); - this.badBookRetryRb.Name = "badBookRetryRb"; - this.badBookRetryRb.Size = new System.Drawing.Size(84, 19); - this.badBookRetryRb.TabIndex = 16; - this.badBookRetryRb.TabStop = true; - this.badBookRetryRb.Text = "[retry desc]"; - this.badBookRetryRb.UseVisualStyleBackColor = true; - // - // badBookAbortRb - // - this.badBookAbortRb.AutoSize = true; - this.badBookAbortRb.Location = new System.Drawing.Point(384, 22); - this.badBookAbortRb.Name = "badBookAbortRb"; - this.badBookAbortRb.Size = new System.Drawing.Size(88, 19); - this.badBookAbortRb.TabIndex = 15; - this.badBookAbortRb.TabStop = true; - this.badBookAbortRb.Text = "[abort desc]"; - this.badBookAbortRb.UseVisualStyleBackColor = true; - // - // badBookAskRb - // - this.badBookAskRb.AutoSize = true; - this.badBookAskRb.Location = new System.Drawing.Point(6, 22); - this.badBookAskRb.Name = "badBookAskRb"; - this.badBookAskRb.Size = new System.Drawing.Size(77, 19); - this.badBookAskRb.TabIndex = 14; - this.badBookAskRb.TabStop = true; - this.badBookAskRb.Text = "[ask desc]"; - this.badBookAskRb.UseVisualStyleBackColor = true; - // - // stripAudibleBrandingCbox - // - this.stripAudibleBrandingCbox.AutoSize = true; - this.stripAudibleBrandingCbox.Location = new System.Drawing.Point(19, 168); - this.stripAudibleBrandingCbox.Name = "stripAudibleBrandingCbox"; - this.stripAudibleBrandingCbox.Size = new System.Drawing.Size(143, 34); - this.stripAudibleBrandingCbox.TabIndex = 13; - this.stripAudibleBrandingCbox.Text = "[StripAudibleBranding\r\ndesc]"; - this.stripAudibleBrandingCbox.UseVisualStyleBackColor = true; - // - // splitFilesByChapterCbox - // - this.splitFilesByChapterCbox.AutoSize = true; - this.splitFilesByChapterCbox.Location = new System.Drawing.Point(19, 118); - this.splitFilesByChapterCbox.Name = "splitFilesByChapterCbox"; - this.splitFilesByChapterCbox.Size = new System.Drawing.Size(162, 19); - this.splitFilesByChapterCbox.TabIndex = 13; - this.splitFilesByChapterCbox.Text = "[SplitFilesByChapter desc]"; - this.splitFilesByChapterCbox.UseVisualStyleBackColor = true; - // - // allowLibationFixupCbox - // - this.allowLibationFixupCbox.AutoSize = true; - this.allowLibationFixupCbox.Checked = true; - this.allowLibationFixupCbox.CheckState = System.Windows.Forms.CheckState.Checked; - this.allowLibationFixupCbox.Location = new System.Drawing.Point(19, 18); - this.allowLibationFixupCbox.Name = "allowLibationFixupCbox"; - this.allowLibationFixupCbox.Size = new System.Drawing.Size(163, 19); - this.allowLibationFixupCbox.TabIndex = 10; - this.allowLibationFixupCbox.Text = "[AllowLibationFixup desc]"; - this.allowLibationFixupCbox.UseVisualStyleBackColor = true; - this.allowLibationFixupCbox.CheckedChanged += new System.EventHandler(this.allowLibationFixupCbox_CheckedChanged); - // - // convertLossyRb - // - this.convertLossyRb.AutoSize = true; - this.convertLossyRb.Location = new System.Drawing.Point(19, 232); - this.convertLossyRb.Name = "convertLossyRb"; - this.convertLossyRb.Size = new System.Drawing.Size(329, 19); - this.convertLossyRb.TabIndex = 12; - this.convertLossyRb.Text = "Download my books as .MP3 files (transcode if necessary)"; - this.convertLossyRb.UseVisualStyleBackColor = true; - this.convertLossyRb.CheckedChanged += new System.EventHandler(this.convertFormatRb_CheckedChanged); - // - // convertLosslessRb - // - this.convertLosslessRb.AutoSize = true; - this.convertLosslessRb.Checked = true; - this.convertLosslessRb.Location = new System.Drawing.Point(19, 207); - this.convertLosslessRb.Name = "convertLosslessRb"; - this.convertLosslessRb.Size = new System.Drawing.Size(335, 19); - this.convertLosslessRb.TabIndex = 11; - this.convertLosslessRb.TabStop = true; - this.convertLosslessRb.Text = "Download my books in the original audio format (Lossless)"; - this.convertLosslessRb.UseVisualStyleBackColor = true; - this.convertLosslessRb.CheckedChanged += new System.EventHandler(this.convertFormatRb_CheckedChanged); - // - // inProgressSelectControl - // - this.inProgressSelectControl.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) + this.booksLocationDescLbl = new System.Windows.Forms.Label(); + this.inProgressDescLbl = new System.Windows.Forms.Label(); + this.saveBtn = new System.Windows.Forms.Button(); + this.cancelBtn = new System.Windows.Forms.Button(); + this.importEpisodesCb = new System.Windows.Forms.CheckBox(); + this.downloadEpisodesCb = new System.Windows.Forms.CheckBox(); + this.badBookGb = new System.Windows.Forms.GroupBox(); + this.badBookIgnoreRb = new System.Windows.Forms.RadioButton(); + this.badBookRetryRb = new System.Windows.Forms.RadioButton(); + this.badBookAbortRb = new System.Windows.Forms.RadioButton(); + this.badBookAskRb = new System.Windows.Forms.RadioButton(); + this.stripAudibleBrandingCbox = new System.Windows.Forms.CheckBox(); + this.splitFilesByChapterCbox = new System.Windows.Forms.CheckBox(); + this.allowLibationFixupCbox = new System.Windows.Forms.CheckBox(); + this.convertLossyRb = new System.Windows.Forms.RadioButton(); + this.convertLosslessRb = new System.Windows.Forms.RadioButton(); + this.inProgressSelectControl = new LibationWinForms.Dialogs.DirectorySelectControl(); + this.logsBtn = new System.Windows.Forms.Button(); + this.booksSelectControl = new LibationWinForms.Dialogs.DirectoryOrCustomSelectControl(); + this.loggingLevelLbl = new System.Windows.Forms.Label(); + this.loggingLevelCb = new System.Windows.Forms.ComboBox(); + this.tabControl = new System.Windows.Forms.TabControl(); + this.tab1ImportantSettings = new System.Windows.Forms.TabPage(); + this.booksGb = new System.Windows.Forms.GroupBox(); + this.tab2ImportLibrary = new System.Windows.Forms.TabPage(); + this.autoDownloadEpisodesCb = new System.Windows.Forms.CheckBox(); + this.autoScanCb = new System.Windows.Forms.CheckBox(); + this.showImportedStatsCb = new System.Windows.Forms.CheckBox(); + this.tab3DownloadDecrypt = new System.Windows.Forms.TabPage(); + this.inProgressFilesGb = new System.Windows.Forms.GroupBox(); + this.customFileNamingGb = new System.Windows.Forms.GroupBox(); + this.chapterFileTemplateBtn = new System.Windows.Forms.Button(); + this.chapterFileTemplateTb = new System.Windows.Forms.TextBox(); + this.chapterFileTemplateLbl = new System.Windows.Forms.Label(); + this.fileTemplateBtn = new System.Windows.Forms.Button(); + this.fileTemplateTb = new System.Windows.Forms.TextBox(); + this.fileTemplateLbl = new System.Windows.Forms.Label(); + this.folderTemplateBtn = new System.Windows.Forms.Button(); + this.folderTemplateTb = new System.Windows.Forms.TextBox(); + this.folderTemplateLbl = new System.Windows.Forms.Label(); + this.tab4AudioFileOptions = new System.Windows.Forms.TabPage(); + this.lameOptionsGb = new System.Windows.Forms.GroupBox(); + this.lameDownsampleMonoCbox = new System.Windows.Forms.CheckBox(); + this.lameBitrateGb = new System.Windows.Forms.GroupBox(); + this.LameMatchSourceBRCbox = new System.Windows.Forms.CheckBox(); + this.lameConstantBitrateCbox = new System.Windows.Forms.CheckBox(); + this.label7 = new System.Windows.Forms.Label(); + this.label6 = new System.Windows.Forms.Label(); + this.label5 = new System.Windows.Forms.Label(); + this.label4 = new System.Windows.Forms.Label(); + this.label11 = new System.Windows.Forms.Label(); + this.label3 = new System.Windows.Forms.Label(); + this.lameBitrateTb = new System.Windows.Forms.TrackBar(); + this.label1 = new System.Windows.Forms.Label(); + this.lameQualityGb = new System.Windows.Forms.GroupBox(); + this.label19 = new System.Windows.Forms.Label(); + this.label18 = new System.Windows.Forms.Label(); + this.label17 = new System.Windows.Forms.Label(); + this.label16 = new System.Windows.Forms.Label(); + this.label12 = new System.Windows.Forms.Label(); + this.label15 = new System.Windows.Forms.Label(); + this.label9 = new System.Windows.Forms.Label(); + this.label8 = new System.Windows.Forms.Label(); + this.label13 = new System.Windows.Forms.Label(); + this.label10 = new System.Windows.Forms.Label(); + this.label14 = new System.Windows.Forms.Label(); + this.label2 = new System.Windows.Forms.Label(); + this.lameVBRQualityTb = new System.Windows.Forms.TrackBar(); + this.groupBox2 = new System.Windows.Forms.GroupBox(); + this.lameTargetQualityRb = new System.Windows.Forms.RadioButton(); + this.lameTargetBitrateRb = new System.Windows.Forms.RadioButton(); + this.stripUnabridgedCbox = new System.Windows.Forms.CheckBox(); + this.retainAaxFileCbox = new System.Windows.Forms.CheckBox(); + this.downloadCoverArtCbox = new System.Windows.Forms.CheckBox(); + this.createCueSheetCbox = new System.Windows.Forms.CheckBox(); + this.badBookGb.SuspendLayout(); + this.tabControl.SuspendLayout(); + this.tab1ImportantSettings.SuspendLayout(); + this.booksGb.SuspendLayout(); + this.tab2ImportLibrary.SuspendLayout(); + this.tab3DownloadDecrypt.SuspendLayout(); + this.inProgressFilesGb.SuspendLayout(); + this.customFileNamingGb.SuspendLayout(); + this.tab4AudioFileOptions.SuspendLayout(); + this.lameOptionsGb.SuspendLayout(); + this.lameBitrateGb.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.lameBitrateTb)).BeginInit(); + this.lameQualityGb.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.lameVBRQualityTb)).BeginInit(); + this.groupBox2.SuspendLayout(); + this.SuspendLayout(); + // + // booksLocationDescLbl + // + this.booksLocationDescLbl.AutoSize = true; + this.booksLocationDescLbl.Location = new System.Drawing.Point(7, 19); + this.booksLocationDescLbl.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); + this.booksLocationDescLbl.Name = "booksLocationDescLbl"; + this.booksLocationDescLbl.Size = new System.Drawing.Size(69, 15); + this.booksLocationDescLbl.TabIndex = 1; + this.booksLocationDescLbl.Text = "[book desc]"; + // + // inProgressDescLbl + // + this.inProgressDescLbl.AutoSize = true; + this.inProgressDescLbl.Location = new System.Drawing.Point(7, 19); + this.inProgressDescLbl.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); + this.inProgressDescLbl.Name = "inProgressDescLbl"; + this.inProgressDescLbl.Size = new System.Drawing.Size(100, 45); + this.inProgressDescLbl.TabIndex = 18; + this.inProgressDescLbl.Text = "[in progress desc]\r\n[line 2]\r\n[line 3]"; + // + // saveBtn + // + this.saveBtn.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.saveBtn.Location = new System.Drawing.Point(667, 441); + this.saveBtn.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3); + this.saveBtn.Name = "saveBtn"; + this.saveBtn.Size = new System.Drawing.Size(88, 27); + this.saveBtn.TabIndex = 98; + this.saveBtn.Text = "Save"; + this.saveBtn.UseVisualStyleBackColor = true; + this.saveBtn.Click += new System.EventHandler(this.saveBtn_Click); + // + // cancelBtn + // + this.cancelBtn.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.cancelBtn.DialogResult = System.Windows.Forms.DialogResult.Cancel; + this.cancelBtn.Location = new System.Drawing.Point(785, 441); + this.cancelBtn.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3); + this.cancelBtn.Name = "cancelBtn"; + this.cancelBtn.Size = new System.Drawing.Size(88, 27); + this.cancelBtn.TabIndex = 99; + this.cancelBtn.Text = "Cancel"; + this.cancelBtn.UseVisualStyleBackColor = true; + this.cancelBtn.Click += new System.EventHandler(this.cancelBtn_Click); + // + // importEpisodesCb + // + this.importEpisodesCb.AutoSize = true; + this.importEpisodesCb.Location = new System.Drawing.Point(6, 56); + this.importEpisodesCb.Name = "importEpisodesCb"; + this.importEpisodesCb.Size = new System.Drawing.Size(146, 19); + this.importEpisodesCb.TabIndex = 3; + this.importEpisodesCb.Text = "[import episodes desc]"; + this.importEpisodesCb.UseVisualStyleBackColor = true; + // + // downloadEpisodesCb + // + this.downloadEpisodesCb.AutoSize = true; + this.downloadEpisodesCb.Location = new System.Drawing.Point(6, 81); + this.downloadEpisodesCb.Name = "downloadEpisodesCb"; + this.downloadEpisodesCb.Size = new System.Drawing.Size(163, 19); + this.downloadEpisodesCb.TabIndex = 4; + this.downloadEpisodesCb.Text = "[download episodes desc]"; + this.downloadEpisodesCb.UseVisualStyleBackColor = true; + // + // badBookGb + // + this.badBookGb.Controls.Add(this.badBookIgnoreRb); + this.badBookGb.Controls.Add(this.badBookRetryRb); + this.badBookGb.Controls.Add(this.badBookAbortRb); + this.badBookGb.Controls.Add(this.badBookAskRb); + this.badBookGb.Location = new System.Drawing.Point(7, 6); + this.badBookGb.Name = "badBookGb"; + this.badBookGb.Size = new System.Drawing.Size(888, 76); + this.badBookGb.TabIndex = 13; + this.badBookGb.TabStop = false; + this.badBookGb.Text = "[bad book desc]"; + // + // badBookIgnoreRb + // + this.badBookIgnoreRb.AutoSize = true; + this.badBookIgnoreRb.Location = new System.Drawing.Point(384, 47); + this.badBookIgnoreRb.Name = "badBookIgnoreRb"; + this.badBookIgnoreRb.Size = new System.Drawing.Size(94, 19); + this.badBookIgnoreRb.TabIndex = 17; + this.badBookIgnoreRb.TabStop = true; + this.badBookIgnoreRb.Text = "[ignore desc]"; + this.badBookIgnoreRb.UseVisualStyleBackColor = true; + // + // badBookRetryRb + // + this.badBookRetryRb.AutoSize = true; + this.badBookRetryRb.Location = new System.Drawing.Point(5, 47); + this.badBookRetryRb.Name = "badBookRetryRb"; + this.badBookRetryRb.Size = new System.Drawing.Size(84, 19); + this.badBookRetryRb.TabIndex = 16; + this.badBookRetryRb.TabStop = true; + this.badBookRetryRb.Text = "[retry desc]"; + this.badBookRetryRb.UseVisualStyleBackColor = true; + // + // badBookAbortRb + // + this.badBookAbortRb.AutoSize = true; + this.badBookAbortRb.Location = new System.Drawing.Point(384, 22); + this.badBookAbortRb.Name = "badBookAbortRb"; + this.badBookAbortRb.Size = new System.Drawing.Size(88, 19); + this.badBookAbortRb.TabIndex = 15; + this.badBookAbortRb.TabStop = true; + this.badBookAbortRb.Text = "[abort desc]"; + this.badBookAbortRb.UseVisualStyleBackColor = true; + // + // badBookAskRb + // + this.badBookAskRb.AutoSize = true; + this.badBookAskRb.Location = new System.Drawing.Point(6, 22); + this.badBookAskRb.Name = "badBookAskRb"; + this.badBookAskRb.Size = new System.Drawing.Size(77, 19); + this.badBookAskRb.TabIndex = 14; + this.badBookAskRb.TabStop = true; + this.badBookAskRb.Text = "[ask desc]"; + this.badBookAskRb.UseVisualStyleBackColor = true; + // + // stripAudibleBrandingCbox + // + this.stripAudibleBrandingCbox.AutoSize = true; + this.stripAudibleBrandingCbox.Location = new System.Drawing.Point(19, 168); + this.stripAudibleBrandingCbox.Name = "stripAudibleBrandingCbox"; + this.stripAudibleBrandingCbox.Size = new System.Drawing.Size(143, 34); + this.stripAudibleBrandingCbox.TabIndex = 13; + this.stripAudibleBrandingCbox.Text = "[StripAudibleBranding\r\ndesc]"; + this.stripAudibleBrandingCbox.UseVisualStyleBackColor = true; + // + // splitFilesByChapterCbox + // + this.splitFilesByChapterCbox.AutoSize = true; + this.splitFilesByChapterCbox.Location = new System.Drawing.Point(19, 118); + this.splitFilesByChapterCbox.Name = "splitFilesByChapterCbox"; + this.splitFilesByChapterCbox.Size = new System.Drawing.Size(162, 19); + this.splitFilesByChapterCbox.TabIndex = 13; + this.splitFilesByChapterCbox.Text = "[SplitFilesByChapter desc]"; + this.splitFilesByChapterCbox.UseVisualStyleBackColor = true; + // + // allowLibationFixupCbox + // + this.allowLibationFixupCbox.AutoSize = true; + this.allowLibationFixupCbox.Checked = true; + this.allowLibationFixupCbox.CheckState = System.Windows.Forms.CheckState.Checked; + this.allowLibationFixupCbox.Location = new System.Drawing.Point(19, 18); + this.allowLibationFixupCbox.Name = "allowLibationFixupCbox"; + this.allowLibationFixupCbox.Size = new System.Drawing.Size(163, 19); + this.allowLibationFixupCbox.TabIndex = 10; + this.allowLibationFixupCbox.Text = "[AllowLibationFixup desc]"; + this.allowLibationFixupCbox.UseVisualStyleBackColor = true; + this.allowLibationFixupCbox.CheckedChanged += new System.EventHandler(this.allowLibationFixupCbox_CheckedChanged); + // + // convertLossyRb + // + this.convertLossyRb.AutoSize = true; + this.convertLossyRb.Location = new System.Drawing.Point(19, 232); + this.convertLossyRb.Name = "convertLossyRb"; + this.convertLossyRb.Size = new System.Drawing.Size(329, 19); + this.convertLossyRb.TabIndex = 12; + this.convertLossyRb.Text = "Download my books as .MP3 files (transcode if necessary)"; + this.convertLossyRb.UseVisualStyleBackColor = true; + this.convertLossyRb.CheckedChanged += new System.EventHandler(this.convertFormatRb_CheckedChanged); + // + // convertLosslessRb + // + this.convertLosslessRb.AutoSize = true; + this.convertLosslessRb.Checked = true; + this.convertLosslessRb.Location = new System.Drawing.Point(19, 207); + this.convertLosslessRb.Name = "convertLosslessRb"; + this.convertLosslessRb.Size = new System.Drawing.Size(335, 19); + this.convertLosslessRb.TabIndex = 11; + this.convertLosslessRb.TabStop = true; + this.convertLosslessRb.Text = "Download my books in the original audio format (Lossless)"; + this.convertLosslessRb.UseVisualStyleBackColor = true; + this.convertLosslessRb.CheckedChanged += new System.EventHandler(this.convertFormatRb_CheckedChanged); + // + // inProgressSelectControl + // + this.inProgressSelectControl.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); - this.inProgressSelectControl.Location = new System.Drawing.Point(7, 68); - this.inProgressSelectControl.Margin = new System.Windows.Forms.Padding(3, 4, 3, 4); - this.inProgressSelectControl.Name = "inProgressSelectControl"; - this.inProgressSelectControl.Size = new System.Drawing.Size(828, 52); - this.inProgressSelectControl.TabIndex = 19; - // - // logsBtn - // - this.logsBtn.Location = new System.Drawing.Point(256, 169); - this.logsBtn.Name = "logsBtn"; - this.logsBtn.Size = new System.Drawing.Size(132, 23); - this.logsBtn.TabIndex = 5; - this.logsBtn.Text = "Open log folder"; - this.logsBtn.UseVisualStyleBackColor = true; - this.logsBtn.Click += new System.EventHandler(this.logsBtn_Click); - // - // booksSelectControl - // - this.booksSelectControl.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) + this.inProgressSelectControl.Location = new System.Drawing.Point(7, 68); + this.inProgressSelectControl.Margin = new System.Windows.Forms.Padding(3, 4, 3, 4); + this.inProgressSelectControl.Name = "inProgressSelectControl"; + this.inProgressSelectControl.Size = new System.Drawing.Size(828, 52); + this.inProgressSelectControl.TabIndex = 19; + // + // logsBtn + // + this.logsBtn.Location = new System.Drawing.Point(256, 169); + this.logsBtn.Name = "logsBtn"; + this.logsBtn.Size = new System.Drawing.Size(132, 23); + this.logsBtn.TabIndex = 5; + this.logsBtn.Text = "Open log folder"; + this.logsBtn.UseVisualStyleBackColor = true; + this.logsBtn.Click += new System.EventHandler(this.logsBtn_Click); + // + // booksSelectControl + // + this.booksSelectControl.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); - this.booksSelectControl.Location = new System.Drawing.Point(7, 37); - this.booksSelectControl.Margin = new System.Windows.Forms.Padding(3, 4, 3, 4); - this.booksSelectControl.Name = "booksSelectControl"; - this.booksSelectControl.Size = new System.Drawing.Size(829, 87); - this.booksSelectControl.TabIndex = 2; - // - // loggingLevelLbl - // - this.loggingLevelLbl.AutoSize = true; - this.loggingLevelLbl.Location = new System.Drawing.Point(6, 172); - this.loggingLevelLbl.Name = "loggingLevelLbl"; - this.loggingLevelLbl.Size = new System.Drawing.Size(78, 15); - this.loggingLevelLbl.TabIndex = 3; - this.loggingLevelLbl.Text = "Logging level"; - // - // loggingLevelCb - // - this.loggingLevelCb.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; - this.loggingLevelCb.FormattingEnabled = true; - this.loggingLevelCb.Location = new System.Drawing.Point(90, 169); - this.loggingLevelCb.Name = "loggingLevelCb"; - this.loggingLevelCb.Size = new System.Drawing.Size(129, 23); - this.loggingLevelCb.TabIndex = 4; - // - // tabControl - // - this.tabControl.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) + this.booksSelectControl.Location = new System.Drawing.Point(7, 37); + this.booksSelectControl.Margin = new System.Windows.Forms.Padding(3, 4, 3, 4); + this.booksSelectControl.Name = "booksSelectControl"; + this.booksSelectControl.Size = new System.Drawing.Size(829, 87); + this.booksSelectControl.TabIndex = 2; + // + // loggingLevelLbl + // + this.loggingLevelLbl.AutoSize = true; + this.loggingLevelLbl.Location = new System.Drawing.Point(6, 172); + this.loggingLevelLbl.Name = "loggingLevelLbl"; + this.loggingLevelLbl.Size = new System.Drawing.Size(78, 15); + this.loggingLevelLbl.TabIndex = 3; + this.loggingLevelLbl.Text = "Logging level"; + // + // loggingLevelCb + // + this.loggingLevelCb.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; + this.loggingLevelCb.FormattingEnabled = true; + this.loggingLevelCb.Location = new System.Drawing.Point(90, 169); + this.loggingLevelCb.Name = "loggingLevelCb"; + this.loggingLevelCb.Size = new System.Drawing.Size(129, 23); + this.loggingLevelCb.TabIndex = 4; + // + // tabControl + // + this.tabControl.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); - this.tabControl.Controls.Add(this.tab1ImportantSettings); - this.tabControl.Controls.Add(this.tab2ImportLibrary); - this.tabControl.Controls.Add(this.tab3DownloadDecrypt); - this.tabControl.Controls.Add(this.tab4AudioFileOptions); - this.tabControl.Location = new System.Drawing.Point(12, 12); - this.tabControl.Name = "tabControl"; - this.tabControl.SelectedIndex = 0; - this.tabControl.Size = new System.Drawing.Size(862, 423); - this.tabControl.TabIndex = 100; - // - // tab1ImportantSettings - // - this.tab1ImportantSettings.Controls.Add(this.booksGb); - this.tab1ImportantSettings.Controls.Add(this.logsBtn); - this.tab1ImportantSettings.Controls.Add(this.loggingLevelCb); - this.tab1ImportantSettings.Controls.Add(this.loggingLevelLbl); - this.tab1ImportantSettings.Location = new System.Drawing.Point(4, 24); - this.tab1ImportantSettings.Name = "tab1ImportantSettings"; - this.tab1ImportantSettings.Padding = new System.Windows.Forms.Padding(3); - this.tab1ImportantSettings.Size = new System.Drawing.Size(854, 395); - this.tab1ImportantSettings.TabIndex = 0; - this.tab1ImportantSettings.Text = "Important settings"; - this.tab1ImportantSettings.UseVisualStyleBackColor = true; - // - // booksGb - // - this.booksGb.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) + this.tabControl.Controls.Add(this.tab1ImportantSettings); + this.tabControl.Controls.Add(this.tab2ImportLibrary); + this.tabControl.Controls.Add(this.tab3DownloadDecrypt); + this.tabControl.Controls.Add(this.tab4AudioFileOptions); + this.tabControl.Location = new System.Drawing.Point(12, 12); + this.tabControl.Name = "tabControl"; + this.tabControl.SelectedIndex = 0; + this.tabControl.Size = new System.Drawing.Size(862, 423); + this.tabControl.TabIndex = 100; + // + // tab1ImportantSettings + // + this.tab1ImportantSettings.Controls.Add(this.booksGb); + this.tab1ImportantSettings.Controls.Add(this.logsBtn); + this.tab1ImportantSettings.Controls.Add(this.loggingLevelCb); + this.tab1ImportantSettings.Controls.Add(this.loggingLevelLbl); + this.tab1ImportantSettings.Location = new System.Drawing.Point(4, 24); + this.tab1ImportantSettings.Name = "tab1ImportantSettings"; + this.tab1ImportantSettings.Padding = new System.Windows.Forms.Padding(3); + this.tab1ImportantSettings.Size = new System.Drawing.Size(854, 395); + this.tab1ImportantSettings.TabIndex = 0; + this.tab1ImportantSettings.Text = "Important settings"; + this.tab1ImportantSettings.UseVisualStyleBackColor = true; + // + // booksGb + // + this.booksGb.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); - this.booksGb.Controls.Add(this.booksSelectControl); - this.booksGb.Controls.Add(this.booksLocationDescLbl); - this.booksGb.Location = new System.Drawing.Point(6, 6); - this.booksGb.Name = "booksGb"; - this.booksGb.Size = new System.Drawing.Size(842, 129); - this.booksGb.TabIndex = 0; - this.booksGb.TabStop = false; - this.booksGb.Text = "Books location"; - // - // tab2ImportLibrary - // - this.tab2ImportLibrary.Controls.Add(this.autoScanCb); - this.tab2ImportLibrary.Controls.Add(this.showImportedStatsCb); - this.tab2ImportLibrary.Controls.Add(this.importEpisodesCb); - this.tab2ImportLibrary.Controls.Add(this.downloadEpisodesCb); - this.tab2ImportLibrary.Location = new System.Drawing.Point(4, 24); - this.tab2ImportLibrary.Name = "tab2ImportLibrary"; - this.tab2ImportLibrary.Padding = new System.Windows.Forms.Padding(3); - this.tab2ImportLibrary.Size = new System.Drawing.Size(854, 395); - this.tab2ImportLibrary.TabIndex = 1; - this.tab2ImportLibrary.Text = "Import library"; - this.tab2ImportLibrary.UseVisualStyleBackColor = true; - // - // autoScanCb - // - this.autoScanCb.AutoSize = true; - this.autoScanCb.Location = new System.Drawing.Point(6, 6); - this.autoScanCb.Name = "autoScanCb"; - this.autoScanCb.Size = new System.Drawing.Size(112, 19); - this.autoScanCb.TabIndex = 1; - this.autoScanCb.Text = "[auto scan desc]"; - this.autoScanCb.UseVisualStyleBackColor = true; - // - // showImportedStatsCb - // - this.showImportedStatsCb.AutoSize = true; - this.showImportedStatsCb.Location = new System.Drawing.Point(6, 31); - this.showImportedStatsCb.Name = "showImportedStatsCb"; - this.showImportedStatsCb.Size = new System.Drawing.Size(168, 19); - this.showImportedStatsCb.TabIndex = 2; - this.showImportedStatsCb.Text = "[show imported stats desc]"; - this.showImportedStatsCb.UseVisualStyleBackColor = true; - // - // tab3DownloadDecrypt - // - this.tab3DownloadDecrypt.Controls.Add(this.inProgressFilesGb); - this.tab3DownloadDecrypt.Controls.Add(this.customFileNamingGb); - this.tab3DownloadDecrypt.Controls.Add(this.badBookGb); - this.tab3DownloadDecrypt.Location = new System.Drawing.Point(4, 24); - this.tab3DownloadDecrypt.Name = "tab3DownloadDecrypt"; - this.tab3DownloadDecrypt.Padding = new System.Windows.Forms.Padding(3); - this.tab3DownloadDecrypt.Size = new System.Drawing.Size(854, 395); - this.tab3DownloadDecrypt.TabIndex = 2; - this.tab3DownloadDecrypt.Text = "Download/Decrypt"; - this.tab3DownloadDecrypt.UseVisualStyleBackColor = true; - // - // inProgressFilesGb - // - this.inProgressFilesGb.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) + this.booksGb.Controls.Add(this.booksSelectControl); + this.booksGb.Controls.Add(this.booksLocationDescLbl); + this.booksGb.Location = new System.Drawing.Point(6, 6); + this.booksGb.Name = "booksGb"; + this.booksGb.Size = new System.Drawing.Size(842, 129); + this.booksGb.TabIndex = 0; + this.booksGb.TabStop = false; + this.booksGb.Text = "Books location"; + // + // tab2ImportLibrary + // + this.tab2ImportLibrary.Controls.Add(this.autoDownloadEpisodesCb); + this.tab2ImportLibrary.Controls.Add(this.autoScanCb); + this.tab2ImportLibrary.Controls.Add(this.showImportedStatsCb); + this.tab2ImportLibrary.Controls.Add(this.importEpisodesCb); + this.tab2ImportLibrary.Controls.Add(this.downloadEpisodesCb); + this.tab2ImportLibrary.Location = new System.Drawing.Point(4, 24); + this.tab2ImportLibrary.Name = "tab2ImportLibrary"; + this.tab2ImportLibrary.Padding = new System.Windows.Forms.Padding(3); + this.tab2ImportLibrary.Size = new System.Drawing.Size(854, 395); + this.tab2ImportLibrary.TabIndex = 1; + this.tab2ImportLibrary.Text = "Import library"; + this.tab2ImportLibrary.UseVisualStyleBackColor = true; + // + // autoDownloadEpisodesCb + // + this.autoDownloadEpisodesCb.AutoSize = true; + this.autoDownloadEpisodesCb.Location = new System.Drawing.Point(6, 106); + this.autoDownloadEpisodesCb.Name = "autoDownloadEpisodesCb"; + this.autoDownloadEpisodesCb.Size = new System.Drawing.Size(190, 19); + this.autoDownloadEpisodesCb.TabIndex = 5; + this.autoDownloadEpisodesCb.Text = "[auto download episodes desc]"; + this.autoDownloadEpisodesCb.UseVisualStyleBackColor = true; + // + // autoScanCb + // + this.autoScanCb.AutoSize = true; + this.autoScanCb.Location = new System.Drawing.Point(6, 6); + this.autoScanCb.Name = "autoScanCb"; + this.autoScanCb.Size = new System.Drawing.Size(112, 19); + this.autoScanCb.TabIndex = 1; + this.autoScanCb.Text = "[auto scan desc]"; + this.autoScanCb.UseVisualStyleBackColor = true; + // + // showImportedStatsCb + // + this.showImportedStatsCb.AutoSize = true; + this.showImportedStatsCb.Location = new System.Drawing.Point(6, 31); + this.showImportedStatsCb.Name = "showImportedStatsCb"; + this.showImportedStatsCb.Size = new System.Drawing.Size(168, 19); + this.showImportedStatsCb.TabIndex = 2; + this.showImportedStatsCb.Text = "[show imported stats desc]"; + this.showImportedStatsCb.UseVisualStyleBackColor = true; + // + // tab3DownloadDecrypt + // + this.tab3DownloadDecrypt.Controls.Add(this.inProgressFilesGb); + this.tab3DownloadDecrypt.Controls.Add(this.customFileNamingGb); + this.tab3DownloadDecrypt.Controls.Add(this.badBookGb); + this.tab3DownloadDecrypt.Location = new System.Drawing.Point(4, 24); + this.tab3DownloadDecrypt.Name = "tab3DownloadDecrypt"; + this.tab3DownloadDecrypt.Padding = new System.Windows.Forms.Padding(3); + this.tab3DownloadDecrypt.Size = new System.Drawing.Size(854, 395); + this.tab3DownloadDecrypt.TabIndex = 2; + this.tab3DownloadDecrypt.Text = "Download/Decrypt"; + this.tab3DownloadDecrypt.UseVisualStyleBackColor = true; + // + // inProgressFilesGb + // + this.inProgressFilesGb.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); - this.inProgressFilesGb.Controls.Add(this.inProgressDescLbl); - this.inProgressFilesGb.Controls.Add(this.inProgressSelectControl); - this.inProgressFilesGb.Location = new System.Drawing.Point(7, 251); - this.inProgressFilesGb.Name = "inProgressFilesGb"; - this.inProgressFilesGb.Size = new System.Drawing.Size(841, 128); - this.inProgressFilesGb.TabIndex = 21; - this.inProgressFilesGb.TabStop = false; - this.inProgressFilesGb.Text = "In progress files"; - // - // customFileNamingGb - // - this.customFileNamingGb.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) + this.inProgressFilesGb.Controls.Add(this.inProgressDescLbl); + this.inProgressFilesGb.Controls.Add(this.inProgressSelectControl); + this.inProgressFilesGb.Location = new System.Drawing.Point(7, 251); + this.inProgressFilesGb.Name = "inProgressFilesGb"; + this.inProgressFilesGb.Size = new System.Drawing.Size(841, 128); + this.inProgressFilesGb.TabIndex = 21; + this.inProgressFilesGb.TabStop = false; + this.inProgressFilesGb.Text = "In progress files"; + // + // customFileNamingGb + // + this.customFileNamingGb.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); - this.customFileNamingGb.Controls.Add(this.chapterFileTemplateBtn); - this.customFileNamingGb.Controls.Add(this.chapterFileTemplateTb); - this.customFileNamingGb.Controls.Add(this.chapterFileTemplateLbl); - this.customFileNamingGb.Controls.Add(this.fileTemplateBtn); - this.customFileNamingGb.Controls.Add(this.fileTemplateTb); - this.customFileNamingGb.Controls.Add(this.fileTemplateLbl); - this.customFileNamingGb.Controls.Add(this.folderTemplateBtn); - this.customFileNamingGb.Controls.Add(this.folderTemplateTb); - this.customFileNamingGb.Controls.Add(this.folderTemplateLbl); - this.customFileNamingGb.Location = new System.Drawing.Point(7, 88); - this.customFileNamingGb.Name = "customFileNamingGb"; - this.customFileNamingGb.Size = new System.Drawing.Size(841, 157); - this.customFileNamingGb.TabIndex = 20; - this.customFileNamingGb.TabStop = false; - this.customFileNamingGb.Text = "Custom file naming"; - // - // chapterFileTemplateBtn - // - this.chapterFileTemplateBtn.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); - this.chapterFileTemplateBtn.Location = new System.Drawing.Point(761, 124); - this.chapterFileTemplateBtn.Name = "chapterFileTemplateBtn"; - this.chapterFileTemplateBtn.Size = new System.Drawing.Size(75, 23); - this.chapterFileTemplateBtn.TabIndex = 8; - this.chapterFileTemplateBtn.Text = "Edit..."; - this.chapterFileTemplateBtn.UseVisualStyleBackColor = true; - this.chapterFileTemplateBtn.Click += new System.EventHandler(this.chapterFileTemplateBtn_Click); - // - // chapterFileTemplateTb - // - this.chapterFileTemplateTb.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) + this.customFileNamingGb.Controls.Add(this.chapterFileTemplateBtn); + this.customFileNamingGb.Controls.Add(this.chapterFileTemplateTb); + this.customFileNamingGb.Controls.Add(this.chapterFileTemplateLbl); + this.customFileNamingGb.Controls.Add(this.fileTemplateBtn); + this.customFileNamingGb.Controls.Add(this.fileTemplateTb); + this.customFileNamingGb.Controls.Add(this.fileTemplateLbl); + this.customFileNamingGb.Controls.Add(this.folderTemplateBtn); + this.customFileNamingGb.Controls.Add(this.folderTemplateTb); + this.customFileNamingGb.Controls.Add(this.folderTemplateLbl); + this.customFileNamingGb.Location = new System.Drawing.Point(7, 88); + this.customFileNamingGb.Name = "customFileNamingGb"; + this.customFileNamingGb.Size = new System.Drawing.Size(841, 157); + this.customFileNamingGb.TabIndex = 20; + this.customFileNamingGb.TabStop = false; + this.customFileNamingGb.Text = "Custom file naming"; + // + // chapterFileTemplateBtn + // + this.chapterFileTemplateBtn.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); + this.chapterFileTemplateBtn.Location = new System.Drawing.Point(761, 124); + this.chapterFileTemplateBtn.Name = "chapterFileTemplateBtn"; + this.chapterFileTemplateBtn.Size = new System.Drawing.Size(75, 23); + this.chapterFileTemplateBtn.TabIndex = 8; + this.chapterFileTemplateBtn.Text = "Edit..."; + this.chapterFileTemplateBtn.UseVisualStyleBackColor = true; + this.chapterFileTemplateBtn.Click += new System.EventHandler(this.chapterFileTemplateBtn_Click); + // + // chapterFileTemplateTb + // + this.chapterFileTemplateTb.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); - this.chapterFileTemplateTb.Location = new System.Drawing.Point(6, 125); - this.chapterFileTemplateTb.Name = "chapterFileTemplateTb"; - this.chapterFileTemplateTb.ReadOnly = true; - this.chapterFileTemplateTb.Size = new System.Drawing.Size(749, 23); - this.chapterFileTemplateTb.TabIndex = 7; - // - // chapterFileTemplateLbl - // - this.chapterFileTemplateLbl.AutoSize = true; - this.chapterFileTemplateLbl.Location = new System.Drawing.Point(6, 107); - this.chapterFileTemplateLbl.Name = "chapterFileTemplateLbl"; - this.chapterFileTemplateLbl.Size = new System.Drawing.Size(123, 15); - this.chapterFileTemplateLbl.TabIndex = 6; - this.chapterFileTemplateLbl.Text = "[folder template desc]"; - // - // fileTemplateBtn - // - this.fileTemplateBtn.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); - this.fileTemplateBtn.Location = new System.Drawing.Point(761, 80); - this.fileTemplateBtn.Name = "fileTemplateBtn"; - this.fileTemplateBtn.Size = new System.Drawing.Size(75, 23); - this.fileTemplateBtn.TabIndex = 5; - this.fileTemplateBtn.Text = "Edit..."; - this.fileTemplateBtn.UseVisualStyleBackColor = true; - this.fileTemplateBtn.Click += new System.EventHandler(this.fileTemplateBtn_Click); - // - // fileTemplateTb - // - this.fileTemplateTb.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) + this.chapterFileTemplateTb.Location = new System.Drawing.Point(6, 125); + this.chapterFileTemplateTb.Name = "chapterFileTemplateTb"; + this.chapterFileTemplateTb.ReadOnly = true; + this.chapterFileTemplateTb.Size = new System.Drawing.Size(749, 23); + this.chapterFileTemplateTb.TabIndex = 7; + // + // chapterFileTemplateLbl + // + this.chapterFileTemplateLbl.AutoSize = true; + this.chapterFileTemplateLbl.Location = new System.Drawing.Point(6, 107); + this.chapterFileTemplateLbl.Name = "chapterFileTemplateLbl"; + this.chapterFileTemplateLbl.Size = new System.Drawing.Size(123, 15); + this.chapterFileTemplateLbl.TabIndex = 6; + this.chapterFileTemplateLbl.Text = "[folder template desc]"; + // + // fileTemplateBtn + // + this.fileTemplateBtn.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); + this.fileTemplateBtn.Location = new System.Drawing.Point(761, 80); + this.fileTemplateBtn.Name = "fileTemplateBtn"; + this.fileTemplateBtn.Size = new System.Drawing.Size(75, 23); + this.fileTemplateBtn.TabIndex = 5; + this.fileTemplateBtn.Text = "Edit..."; + this.fileTemplateBtn.UseVisualStyleBackColor = true; + this.fileTemplateBtn.Click += new System.EventHandler(this.fileTemplateBtn_Click); + // + // fileTemplateTb + // + this.fileTemplateTb.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); - this.fileTemplateTb.Location = new System.Drawing.Point(6, 81); - this.fileTemplateTb.Name = "fileTemplateTb"; - this.fileTemplateTb.ReadOnly = true; - this.fileTemplateTb.Size = new System.Drawing.Size(749, 23); - this.fileTemplateTb.TabIndex = 4; - // - // fileTemplateLbl - // - this.fileTemplateLbl.AutoSize = true; - this.fileTemplateLbl.Location = new System.Drawing.Point(6, 63); - this.fileTemplateLbl.Name = "fileTemplateLbl"; - this.fileTemplateLbl.Size = new System.Drawing.Size(123, 15); - this.fileTemplateLbl.TabIndex = 3; - this.fileTemplateLbl.Text = "[folder template desc]"; - // - // folderTemplateBtn - // - this.folderTemplateBtn.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); - this.folderTemplateBtn.Location = new System.Drawing.Point(760, 36); - this.folderTemplateBtn.Name = "folderTemplateBtn"; - this.folderTemplateBtn.Size = new System.Drawing.Size(75, 23); - this.folderTemplateBtn.TabIndex = 2; - this.folderTemplateBtn.Text = "Edit..."; - this.folderTemplateBtn.UseVisualStyleBackColor = true; - this.folderTemplateBtn.Click += new System.EventHandler(this.folderTemplateBtn_Click); - // - // folderTemplateTb - // - this.folderTemplateTb.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) + this.fileTemplateTb.Location = new System.Drawing.Point(6, 81); + this.fileTemplateTb.Name = "fileTemplateTb"; + this.fileTemplateTb.ReadOnly = true; + this.fileTemplateTb.Size = new System.Drawing.Size(749, 23); + this.fileTemplateTb.TabIndex = 4; + // + // fileTemplateLbl + // + this.fileTemplateLbl.AutoSize = true; + this.fileTemplateLbl.Location = new System.Drawing.Point(6, 63); + this.fileTemplateLbl.Name = "fileTemplateLbl"; + this.fileTemplateLbl.Size = new System.Drawing.Size(123, 15); + this.fileTemplateLbl.TabIndex = 3; + this.fileTemplateLbl.Text = "[folder template desc]"; + // + // folderTemplateBtn + // + this.folderTemplateBtn.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); + this.folderTemplateBtn.Location = new System.Drawing.Point(760, 36); + this.folderTemplateBtn.Name = "folderTemplateBtn"; + this.folderTemplateBtn.Size = new System.Drawing.Size(75, 23); + this.folderTemplateBtn.TabIndex = 2; + this.folderTemplateBtn.Text = "Edit..."; + this.folderTemplateBtn.UseVisualStyleBackColor = true; + this.folderTemplateBtn.Click += new System.EventHandler(this.folderTemplateBtn_Click); + // + // folderTemplateTb + // + this.folderTemplateTb.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); - this.folderTemplateTb.Location = new System.Drawing.Point(5, 37); - this.folderTemplateTb.Name = "folderTemplateTb"; - this.folderTemplateTb.ReadOnly = true; - this.folderTemplateTb.Size = new System.Drawing.Size(749, 23); - this.folderTemplateTb.TabIndex = 1; - // - // folderTemplateLbl - // - this.folderTemplateLbl.AutoSize = true; - this.folderTemplateLbl.Location = new System.Drawing.Point(5, 19); - this.folderTemplateLbl.Name = "folderTemplateLbl"; - this.folderTemplateLbl.Size = new System.Drawing.Size(123, 15); - this.folderTemplateLbl.TabIndex = 0; - this.folderTemplateLbl.Text = "[folder template desc]"; - // - // tab4AudioFileOptions - // - this.tab4AudioFileOptions.Controls.Add(this.lameOptionsGb); - this.tab4AudioFileOptions.Controls.Add(this.convertLossyRb); - this.tab4AudioFileOptions.Controls.Add(this.stripAudibleBrandingCbox); - this.tab4AudioFileOptions.Controls.Add(this.convertLosslessRb); - this.tab4AudioFileOptions.Controls.Add(this.stripUnabridgedCbox); - this.tab4AudioFileOptions.Controls.Add(this.splitFilesByChapterCbox); - this.tab4AudioFileOptions.Controls.Add(this.retainAaxFileCbox); - this.tab4AudioFileOptions.Controls.Add(this.downloadCoverArtCbox); - this.tab4AudioFileOptions.Controls.Add(this.createCueSheetCbox); - this.tab4AudioFileOptions.Controls.Add(this.allowLibationFixupCbox); - this.tab4AudioFileOptions.Location = new System.Drawing.Point(4, 24); - this.tab4AudioFileOptions.Name = "tab4AudioFileOptions"; - this.tab4AudioFileOptions.Padding = new System.Windows.Forms.Padding(3); - this.tab4AudioFileOptions.Size = new System.Drawing.Size(854, 395); - this.tab4AudioFileOptions.TabIndex = 3; - this.tab4AudioFileOptions.Text = "Audio File Options"; - this.tab4AudioFileOptions.UseVisualStyleBackColor = true; - // - // lameOptionsGb - // - this.lameOptionsGb.Controls.Add(this.lameDownsampleMonoCbox); - this.lameOptionsGb.Controls.Add(this.lameBitrateGb); - this.lameOptionsGb.Controls.Add(this.label1); - this.lameOptionsGb.Controls.Add(this.lameQualityGb); - this.lameOptionsGb.Controls.Add(this.groupBox2); - this.lameOptionsGb.Location = new System.Drawing.Point(415, 18); - this.lameOptionsGb.Name = "lameOptionsGb"; - this.lameOptionsGb.Size = new System.Drawing.Size(433, 371); - this.lameOptionsGb.TabIndex = 14; - this.lameOptionsGb.TabStop = false; - this.lameOptionsGb.Text = "Mp3 Encoding Options"; - // - // lameDownsampleMonoCbox - // - this.lameDownsampleMonoCbox.AutoSize = true; - this.lameDownsampleMonoCbox.Location = new System.Drawing.Point(234, 35); - this.lameDownsampleMonoCbox.Name = "lameDownsampleMonoCbox"; - this.lameDownsampleMonoCbox.Size = new System.Drawing.Size(184, 34); - this.lameDownsampleMonoCbox.TabIndex = 1; - this.lameDownsampleMonoCbox.Text = "Downsample stereo to mono?\r\n(Recommended)\r\n"; - this.lameDownsampleMonoCbox.UseVisualStyleBackColor = true; - // - // lameBitrateGb - // - this.lameBitrateGb.Controls.Add(this.LameMatchSourceBRCbox); - this.lameBitrateGb.Controls.Add(this.lameConstantBitrateCbox); - this.lameBitrateGb.Controls.Add(this.label7); - this.lameBitrateGb.Controls.Add(this.label6); - this.lameBitrateGb.Controls.Add(this.label5); - this.lameBitrateGb.Controls.Add(this.label4); - this.lameBitrateGb.Controls.Add(this.label11); - this.lameBitrateGb.Controls.Add(this.label3); - this.lameBitrateGb.Controls.Add(this.lameBitrateTb); - this.lameBitrateGb.Location = new System.Drawing.Point(6, 84); - this.lameBitrateGb.Name = "lameBitrateGb"; - this.lameBitrateGb.Size = new System.Drawing.Size(421, 112); - this.lameBitrateGb.TabIndex = 0; - this.lameBitrateGb.TabStop = false; - this.lameBitrateGb.Text = "Bitrate"; - // - // LameMatchSourceBRCbox - // - this.LameMatchSourceBRCbox.AutoSize = true; - this.LameMatchSourceBRCbox.Location = new System.Drawing.Point(260, 87); - this.LameMatchSourceBRCbox.Name = "LameMatchSourceBRCbox"; - this.LameMatchSourceBRCbox.Size = new System.Drawing.Size(140, 19); - this.LameMatchSourceBRCbox.TabIndex = 3; - this.LameMatchSourceBRCbox.Text = "Match source bitrate?"; - this.LameMatchSourceBRCbox.UseVisualStyleBackColor = true; - this.LameMatchSourceBRCbox.CheckedChanged += new System.EventHandler(this.LameMatchSourceBRCbox_CheckedChanged); - // - // lameConstantBitrateCbox - // - this.lameConstantBitrateCbox.AutoSize = true; - this.lameConstantBitrateCbox.Location = new System.Drawing.Point(6, 87); - this.lameConstantBitrateCbox.Name = "lameConstantBitrateCbox"; - this.lameConstantBitrateCbox.Size = new System.Drawing.Size(216, 19); - this.lameConstantBitrateCbox.TabIndex = 2; - this.lameConstantBitrateCbox.Text = "Restrict encoder to constant bitrate?"; - this.lameConstantBitrateCbox.UseVisualStyleBackColor = true; - // - // label7 - // - this.label7.AutoSize = true; - this.label7.BackColor = System.Drawing.SystemColors.ControlLightLight; - this.label7.Location = new System.Drawing.Point(390, 52); - this.label7.Name = "label7"; - this.label7.Size = new System.Drawing.Size(25, 15); - this.label7.TabIndex = 1; - this.label7.Text = "320"; - // - // label6 - // - this.label6.AutoSize = true; - this.label6.BackColor = System.Drawing.SystemColors.ControlLightLight; - this.label6.Location = new System.Drawing.Point(309, 52); - this.label6.Name = "label6"; - this.label6.Size = new System.Drawing.Size(25, 15); - this.label6.TabIndex = 1; - this.label6.Text = "256"; - // - // label5 - // - this.label5.AutoSize = true; - this.label5.BackColor = System.Drawing.SystemColors.ControlLightLight; - this.label5.Location = new System.Drawing.Point(228, 52); - this.label5.Name = "label5"; - this.label5.Size = new System.Drawing.Size(25, 15); - this.label5.TabIndex = 1; - this.label5.Text = "192"; - // - // label4 - // - this.label4.AutoSize = true; - this.label4.BackColor = System.Drawing.SystemColors.ControlLightLight; - this.label4.Location = new System.Drawing.Point(147, 52); - this.label4.Name = "label4"; - this.label4.Size = new System.Drawing.Size(25, 15); - this.label4.TabIndex = 1; - this.label4.Text = "128"; - // - // label11 - // - this.label11.AutoSize = true; - this.label11.BackColor = System.Drawing.SystemColors.ControlLightLight; - this.label11.Location = new System.Drawing.Point(10, 52); - this.label11.Name = "label11"; - this.label11.Size = new System.Drawing.Size(19, 15); - this.label11.TabIndex = 1; - this.label11.Text = "16"; - // - // label3 - // - this.label3.AutoSize = true; - this.label3.BackColor = System.Drawing.SystemColors.ControlLightLight; - this.label3.Location = new System.Drawing.Point(71, 52); - this.label3.Name = "label3"; - this.label3.Size = new System.Drawing.Size(19, 15); - this.label3.TabIndex = 1; - this.label3.Text = "64"; - // - // lameBitrateTb - // - this.lameBitrateTb.BackColor = System.Drawing.SystemColors.ControlLightLight; - this.lameBitrateTb.LargeChange = 32; - this.lameBitrateTb.Location = new System.Drawing.Point(6, 22); - this.lameBitrateTb.Maximum = 320; - this.lameBitrateTb.Minimum = 16; - this.lameBitrateTb.Name = "lameBitrateTb"; - this.lameBitrateTb.Size = new System.Drawing.Size(409, 45); - this.lameBitrateTb.SmallChange = 8; - this.lameBitrateTb.TabIndex = 0; - this.lameBitrateTb.TickFrequency = 16; - this.lameBitrateTb.Value = 64; - // - // label1 - // - this.label1.AutoSize = true; - this.label1.Enabled = false; - this.label1.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Italic, System.Drawing.GraphicsUnit.Point); - this.label1.Location = new System.Drawing.Point(6, 353); - this.label1.Name = "label1"; - this.label1.Size = new System.Drawing.Size(172, 15); - this.label1.TabIndex = 1; - this.label1.Text = "Using L.A.M.E. encoding engine"; - // - // lameQualityGb - // - this.lameQualityGb.Controls.Add(this.label19); - this.lameQualityGb.Controls.Add(this.label18); - this.lameQualityGb.Controls.Add(this.label17); - this.lameQualityGb.Controls.Add(this.label16); - this.lameQualityGb.Controls.Add(this.label12); - this.lameQualityGb.Controls.Add(this.label15); - this.lameQualityGb.Controls.Add(this.label9); - this.lameQualityGb.Controls.Add(this.label8); - this.lameQualityGb.Controls.Add(this.label13); - this.lameQualityGb.Controls.Add(this.label10); - this.lameQualityGb.Controls.Add(this.label14); - this.lameQualityGb.Controls.Add(this.label2); - this.lameQualityGb.Controls.Add(this.lameVBRQualityTb); - this.lameQualityGb.Location = new System.Drawing.Point(6, 202); - this.lameQualityGb.Name = "lameQualityGb"; - this.lameQualityGb.Size = new System.Drawing.Size(421, 109); - this.lameQualityGb.TabIndex = 0; - this.lameQualityGb.TabStop = false; - this.lameQualityGb.Text = "Quality"; - // - // label19 - // - this.label19.AutoSize = true; - this.label19.Location = new System.Drawing.Point(349, 52); - this.label19.Name = "label19"; - this.label19.Size = new System.Drawing.Size(20, 15); - this.label19.TabIndex = 1; - this.label19.Text = "V8"; - // - // label18 - // - this.label18.AutoSize = true; - this.label18.Location = new System.Drawing.Point(307, 52); - this.label18.Name = "label18"; - this.label18.Size = new System.Drawing.Size(20, 15); - this.label18.TabIndex = 1; - this.label18.Text = "V7"; - // - // label17 - // - this.label17.AutoSize = true; - this.label17.Location = new System.Drawing.Point(265, 52); - this.label17.Name = "label17"; - this.label17.Size = new System.Drawing.Size(20, 15); - this.label17.TabIndex = 1; - this.label17.Text = "V6"; - // - // label16 - // - this.label16.AutoSize = true; - this.label16.Location = new System.Drawing.Point(223, 52); - this.label16.Name = "label16"; - this.label16.Size = new System.Drawing.Size(20, 15); - this.label16.TabIndex = 1; - this.label16.Text = "V5"; - // - // label12 - // - this.label12.AutoSize = true; - this.label12.Location = new System.Drawing.Point(182, 52); - this.label12.Name = "label12"; - this.label12.Size = new System.Drawing.Size(20, 15); - this.label12.TabIndex = 1; - this.label12.Text = "V4"; - // - // label15 - // - this.label15.AutoSize = true; - this.label15.Location = new System.Drawing.Point(140, 52); - this.label15.Name = "label15"; - this.label15.Size = new System.Drawing.Size(20, 15); - this.label15.TabIndex = 1; - this.label15.Text = "V3"; - // - // label9 - // - this.label9.AutoSize = true; - this.label9.Location = new System.Drawing.Point(97, 52); - this.label9.Name = "label9"; - this.label9.Size = new System.Drawing.Size(20, 15); - this.label9.TabIndex = 1; - this.label9.Text = "V2"; - // - // label8 - // - this.label8.AutoSize = true; - this.label8.Location = new System.Drawing.Point(391, 52); - this.label8.Name = "label8"; - this.label8.Size = new System.Drawing.Size(20, 15); - this.label8.TabIndex = 1; - this.label8.Text = "V9"; - // - // label13 - // - this.label13.AutoSize = true; - this.label13.Location = new System.Drawing.Point(376, 81); - this.label13.Name = "label13"; - this.label13.Size = new System.Drawing.Size(39, 15); - this.label13.TabIndex = 1; - this.label13.Text = "Lower"; - // - // label10 - // - this.label10.AutoSize = true; - this.label10.Location = new System.Drawing.Point(6, 81); - this.label10.Name = "label10"; - this.label10.Size = new System.Drawing.Size(43, 15); - this.label10.TabIndex = 1; - this.label10.Text = "Higher"; - // - // label14 - // - this.label14.AutoSize = true; - this.label14.Location = new System.Drawing.Point(56, 52); - this.label14.Name = "label14"; - this.label14.Size = new System.Drawing.Size(20, 15); - this.label14.TabIndex = 1; - this.label14.Text = "V1"; - // - // label2 - // - this.label2.AutoSize = true; - this.label2.Location = new System.Drawing.Point(14, 52); - this.label2.Name = "label2"; - this.label2.Size = new System.Drawing.Size(20, 15); - this.label2.TabIndex = 1; - this.label2.Text = "V0"; - // - // lameVBRQualityTb - // - this.lameVBRQualityTb.BackColor = System.Drawing.SystemColors.ControlLightLight; - this.lameVBRQualityTb.LargeChange = 1; - this.lameVBRQualityTb.Location = new System.Drawing.Point(10, 22); - this.lameVBRQualityTb.Maximum = 9; - this.lameVBRQualityTb.Name = "lameVBRQualityTb"; - this.lameVBRQualityTb.Size = new System.Drawing.Size(405, 45); - this.lameVBRQualityTb.TabIndex = 0; - this.lameVBRQualityTb.Value = 9; - // - // groupBox2 - // - this.groupBox2.Controls.Add(this.lameTargetQualityRb); - this.groupBox2.Controls.Add(this.lameTargetBitrateRb); - this.groupBox2.Location = new System.Drawing.Point(6, 22); - this.groupBox2.Name = "groupBox2"; - this.groupBox2.Size = new System.Drawing.Size(222, 56); - this.groupBox2.TabIndex = 0; - this.groupBox2.TabStop = false; - this.groupBox2.Text = "Target"; - // - // lameTargetQualityRb - // - this.lameTargetQualityRb.AutoSize = true; - this.lameTargetQualityRb.Location = new System.Drawing.Point(138, 23); - this.lameTargetQualityRb.Name = "lameTargetQualityRb"; - this.lameTargetQualityRb.Size = new System.Drawing.Size(63, 19); - this.lameTargetQualityRb.TabIndex = 0; - this.lameTargetQualityRb.TabStop = true; - this.lameTargetQualityRb.Text = "Quality"; - this.lameTargetQualityRb.UseVisualStyleBackColor = true; - this.lameTargetQualityRb.CheckedChanged += new System.EventHandler(this.lameTargetRb_CheckedChanged); - // - // lameTargetBitrateRb - // - this.lameTargetBitrateRb.AutoSize = true; - this.lameTargetBitrateRb.Location = new System.Drawing.Point(6, 23); - this.lameTargetBitrateRb.Name = "lameTargetBitrateRb"; - this.lameTargetBitrateRb.Size = new System.Drawing.Size(59, 19); - this.lameTargetBitrateRb.TabIndex = 0; - this.lameTargetBitrateRb.TabStop = true; - this.lameTargetBitrateRb.Text = "Bitrate"; - this.lameTargetBitrateRb.UseVisualStyleBackColor = true; - this.lameTargetBitrateRb.CheckedChanged += new System.EventHandler(this.lameTargetRb_CheckedChanged); - // - // stripUnabridgedCbox - // - this.stripUnabridgedCbox.AutoSize = true; - this.stripUnabridgedCbox.Location = new System.Drawing.Point(19, 143); - this.stripUnabridgedCbox.Name = "stripUnabridgedCbox"; - this.stripUnabridgedCbox.Size = new System.Drawing.Size(147, 19); - this.stripUnabridgedCbox.TabIndex = 13; - this.stripUnabridgedCbox.Text = "[StripUnabridged desc]"; - this.stripUnabridgedCbox.UseVisualStyleBackColor = true; - // - // retainAaxFileCbox - // - this.retainAaxFileCbox.AutoSize = true; - this.retainAaxFileCbox.Location = new System.Drawing.Point(19, 93); - this.retainAaxFileCbox.Name = "retainAaxFileCbox"; - this.retainAaxFileCbox.Size = new System.Drawing.Size(132, 19); - this.retainAaxFileCbox.TabIndex = 10; - this.retainAaxFileCbox.Text = "[RetainAaxFile desc]"; - this.retainAaxFileCbox.UseVisualStyleBackColor = true; - this.retainAaxFileCbox.CheckedChanged += new System.EventHandler(this.allowLibationFixupCbox_CheckedChanged); - // - // createCueSheetCbox - // - this.createCueSheetCbox.AutoSize = true; - this.createCueSheetCbox.Checked = true; - this.createCueSheetCbox.CheckState = System.Windows.Forms.CheckState.Checked; - this.createCueSheetCbox.Location = new System.Drawing.Point(19, 43); - this.createCueSheetCbox.Name = "createCueSheetCbox"; - this.createCueSheetCbox.Size = new System.Drawing.Size(145, 19); - this.createCueSheetCbox.TabIndex = 10; - this.createCueSheetCbox.Text = "[CreateCueSheet desc]"; - this.createCueSheetCbox.UseVisualStyleBackColor = true; - this.createCueSheetCbox.CheckedChanged += new System.EventHandler(this.allowLibationFixupCbox_CheckedChanged); - // - // downloadCoverArtCbox - // - this.downloadCoverArtCbox.AutoSize = true; - this.downloadCoverArtCbox.Checked = true; - this.downloadCoverArtCbox.CheckState = System.Windows.Forms.CheckState.Checked; - this.downloadCoverArtCbox.Location = new System.Drawing.Point(19, 68); - this.downloadCoverArtCbox.Name = "downloadCoverArtCbox"; - this.downloadCoverArtCbox.Size = new System.Drawing.Size(162, 19); - this.downloadCoverArtCbox.TabIndex = 10; - this.downloadCoverArtCbox.Text = "[DownloadCoverArt desc]"; - this.downloadCoverArtCbox.UseVisualStyleBackColor = true; - this.downloadCoverArtCbox.CheckedChanged += new System.EventHandler(this.allowLibationFixupCbox_CheckedChanged); - // - // SettingsDialog - // - this.AcceptButton = this.saveBtn; - this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F); - this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.CancelButton = this.cancelBtn; - this.ClientSize = new System.Drawing.Size(886, 484); - this.Controls.Add(this.tabControl); - this.Controls.Add(this.cancelBtn); - this.Controls.Add(this.saveBtn); - this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog; - this.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3); - this.MaximizeBox = false; - this.MinimizeBox = false; - this.Name = "SettingsDialog"; - this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent; - this.Text = "Edit Settings"; - this.Load += new System.EventHandler(this.SettingsDialog_Load); - this.badBookGb.ResumeLayout(false); - this.badBookGb.PerformLayout(); - this.tabControl.ResumeLayout(false); - this.tab1ImportantSettings.ResumeLayout(false); - this.tab1ImportantSettings.PerformLayout(); - this.booksGb.ResumeLayout(false); - this.booksGb.PerformLayout(); - this.tab2ImportLibrary.ResumeLayout(false); - this.tab2ImportLibrary.PerformLayout(); - this.tab3DownloadDecrypt.ResumeLayout(false); - this.inProgressFilesGb.ResumeLayout(false); - this.inProgressFilesGb.PerformLayout(); - this.customFileNamingGb.ResumeLayout(false); - this.customFileNamingGb.PerformLayout(); - this.tab4AudioFileOptions.ResumeLayout(false); - this.tab4AudioFileOptions.PerformLayout(); - this.lameOptionsGb.ResumeLayout(false); - this.lameOptionsGb.PerformLayout(); - this.lameBitrateGb.ResumeLayout(false); - this.lameBitrateGb.PerformLayout(); - ((System.ComponentModel.ISupportInitialize)(this.lameBitrateTb)).EndInit(); - this.lameQualityGb.ResumeLayout(false); - this.lameQualityGb.PerformLayout(); - ((System.ComponentModel.ISupportInitialize)(this.lameVBRQualityTb)).EndInit(); - this.groupBox2.ResumeLayout(false); - this.groupBox2.PerformLayout(); - this.ResumeLayout(false); + this.folderTemplateTb.Location = new System.Drawing.Point(5, 37); + this.folderTemplateTb.Name = "folderTemplateTb"; + this.folderTemplateTb.ReadOnly = true; + this.folderTemplateTb.Size = new System.Drawing.Size(749, 23); + this.folderTemplateTb.TabIndex = 1; + // + // folderTemplateLbl + // + this.folderTemplateLbl.AutoSize = true; + this.folderTemplateLbl.Location = new System.Drawing.Point(5, 19); + this.folderTemplateLbl.Name = "folderTemplateLbl"; + this.folderTemplateLbl.Size = new System.Drawing.Size(123, 15); + this.folderTemplateLbl.TabIndex = 0; + this.folderTemplateLbl.Text = "[folder template desc]"; + // + // tab4AudioFileOptions + // + this.tab4AudioFileOptions.Controls.Add(this.lameOptionsGb); + this.tab4AudioFileOptions.Controls.Add(this.convertLossyRb); + this.tab4AudioFileOptions.Controls.Add(this.stripAudibleBrandingCbox); + this.tab4AudioFileOptions.Controls.Add(this.convertLosslessRb); + this.tab4AudioFileOptions.Controls.Add(this.stripUnabridgedCbox); + this.tab4AudioFileOptions.Controls.Add(this.splitFilesByChapterCbox); + this.tab4AudioFileOptions.Controls.Add(this.retainAaxFileCbox); + this.tab4AudioFileOptions.Controls.Add(this.downloadCoverArtCbox); + this.tab4AudioFileOptions.Controls.Add(this.createCueSheetCbox); + this.tab4AudioFileOptions.Controls.Add(this.allowLibationFixupCbox); + this.tab4AudioFileOptions.Location = new System.Drawing.Point(4, 24); + this.tab4AudioFileOptions.Name = "tab4AudioFileOptions"; + this.tab4AudioFileOptions.Padding = new System.Windows.Forms.Padding(3); + this.tab4AudioFileOptions.Size = new System.Drawing.Size(854, 395); + this.tab4AudioFileOptions.TabIndex = 3; + this.tab4AudioFileOptions.Text = "Audio File Options"; + this.tab4AudioFileOptions.UseVisualStyleBackColor = true; + // + // lameOptionsGb + // + this.lameOptionsGb.Controls.Add(this.lameDownsampleMonoCbox); + this.lameOptionsGb.Controls.Add(this.lameBitrateGb); + this.lameOptionsGb.Controls.Add(this.label1); + this.lameOptionsGb.Controls.Add(this.lameQualityGb); + this.lameOptionsGb.Controls.Add(this.groupBox2); + this.lameOptionsGb.Location = new System.Drawing.Point(415, 18); + this.lameOptionsGb.Name = "lameOptionsGb"; + this.lameOptionsGb.Size = new System.Drawing.Size(433, 371); + this.lameOptionsGb.TabIndex = 14; + this.lameOptionsGb.TabStop = false; + this.lameOptionsGb.Text = "Mp3 Encoding Options"; + // + // lameDownsampleMonoCbox + // + this.lameDownsampleMonoCbox.AutoSize = true; + this.lameDownsampleMonoCbox.Location = new System.Drawing.Point(234, 35); + this.lameDownsampleMonoCbox.Name = "lameDownsampleMonoCbox"; + this.lameDownsampleMonoCbox.Size = new System.Drawing.Size(184, 34); + this.lameDownsampleMonoCbox.TabIndex = 1; + this.lameDownsampleMonoCbox.Text = "Downsample stereo to mono?\r\n(Recommended)\r\n"; + this.lameDownsampleMonoCbox.UseVisualStyleBackColor = true; + // + // lameBitrateGb + // + this.lameBitrateGb.Controls.Add(this.LameMatchSourceBRCbox); + this.lameBitrateGb.Controls.Add(this.lameConstantBitrateCbox); + this.lameBitrateGb.Controls.Add(this.label7); + this.lameBitrateGb.Controls.Add(this.label6); + this.lameBitrateGb.Controls.Add(this.label5); + this.lameBitrateGb.Controls.Add(this.label4); + this.lameBitrateGb.Controls.Add(this.label11); + this.lameBitrateGb.Controls.Add(this.label3); + this.lameBitrateGb.Controls.Add(this.lameBitrateTb); + this.lameBitrateGb.Location = new System.Drawing.Point(6, 84); + this.lameBitrateGb.Name = "lameBitrateGb"; + this.lameBitrateGb.Size = new System.Drawing.Size(421, 112); + this.lameBitrateGb.TabIndex = 0; + this.lameBitrateGb.TabStop = false; + this.lameBitrateGb.Text = "Bitrate"; + // + // LameMatchSourceBRCbox + // + this.LameMatchSourceBRCbox.AutoSize = true; + this.LameMatchSourceBRCbox.Location = new System.Drawing.Point(260, 87); + this.LameMatchSourceBRCbox.Name = "LameMatchSourceBRCbox"; + this.LameMatchSourceBRCbox.Size = new System.Drawing.Size(140, 19); + this.LameMatchSourceBRCbox.TabIndex = 3; + this.LameMatchSourceBRCbox.Text = "Match source bitrate?"; + this.LameMatchSourceBRCbox.UseVisualStyleBackColor = true; + this.LameMatchSourceBRCbox.CheckedChanged += new System.EventHandler(this.LameMatchSourceBRCbox_CheckedChanged); + // + // lameConstantBitrateCbox + // + this.lameConstantBitrateCbox.AutoSize = true; + this.lameConstantBitrateCbox.Location = new System.Drawing.Point(6, 87); + this.lameConstantBitrateCbox.Name = "lameConstantBitrateCbox"; + this.lameConstantBitrateCbox.Size = new System.Drawing.Size(216, 19); + this.lameConstantBitrateCbox.TabIndex = 2; + this.lameConstantBitrateCbox.Text = "Restrict encoder to constant bitrate?"; + this.lameConstantBitrateCbox.UseVisualStyleBackColor = true; + // + // label7 + // + this.label7.AutoSize = true; + this.label7.BackColor = System.Drawing.SystemColors.ControlLightLight; + this.label7.Location = new System.Drawing.Point(390, 52); + this.label7.Name = "label7"; + this.label7.Size = new System.Drawing.Size(25, 15); + this.label7.TabIndex = 1; + this.label7.Text = "320"; + // + // label6 + // + this.label6.AutoSize = true; + this.label6.BackColor = System.Drawing.SystemColors.ControlLightLight; + this.label6.Location = new System.Drawing.Point(309, 52); + this.label6.Name = "label6"; + this.label6.Size = new System.Drawing.Size(25, 15); + this.label6.TabIndex = 1; + this.label6.Text = "256"; + // + // label5 + // + this.label5.AutoSize = true; + this.label5.BackColor = System.Drawing.SystemColors.ControlLightLight; + this.label5.Location = new System.Drawing.Point(228, 52); + this.label5.Name = "label5"; + this.label5.Size = new System.Drawing.Size(25, 15); + this.label5.TabIndex = 1; + this.label5.Text = "192"; + // + // label4 + // + this.label4.AutoSize = true; + this.label4.BackColor = System.Drawing.SystemColors.ControlLightLight; + this.label4.Location = new System.Drawing.Point(147, 52); + this.label4.Name = "label4"; + this.label4.Size = new System.Drawing.Size(25, 15); + this.label4.TabIndex = 1; + this.label4.Text = "128"; + // + // label11 + // + this.label11.AutoSize = true; + this.label11.BackColor = System.Drawing.SystemColors.ControlLightLight; + this.label11.Location = new System.Drawing.Point(10, 52); + this.label11.Name = "label11"; + this.label11.Size = new System.Drawing.Size(19, 15); + this.label11.TabIndex = 1; + this.label11.Text = "16"; + // + // label3 + // + this.label3.AutoSize = true; + this.label3.BackColor = System.Drawing.SystemColors.ControlLightLight; + this.label3.Location = new System.Drawing.Point(71, 52); + this.label3.Name = "label3"; + this.label3.Size = new System.Drawing.Size(19, 15); + this.label3.TabIndex = 1; + this.label3.Text = "64"; + // + // lameBitrateTb + // + this.lameBitrateTb.BackColor = System.Drawing.SystemColors.ControlLightLight; + this.lameBitrateTb.LargeChange = 32; + this.lameBitrateTb.Location = new System.Drawing.Point(6, 22); + this.lameBitrateTb.Maximum = 320; + this.lameBitrateTb.Minimum = 16; + this.lameBitrateTb.Name = "lameBitrateTb"; + this.lameBitrateTb.Size = new System.Drawing.Size(409, 45); + this.lameBitrateTb.SmallChange = 8; + this.lameBitrateTb.TabIndex = 0; + this.lameBitrateTb.TickFrequency = 16; + this.lameBitrateTb.Value = 64; + // + // label1 + // + this.label1.AutoSize = true; + this.label1.Enabled = false; + this.label1.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Italic, System.Drawing.GraphicsUnit.Point); + this.label1.Location = new System.Drawing.Point(6, 353); + this.label1.Name = "label1"; + this.label1.Size = new System.Drawing.Size(172, 15); + this.label1.TabIndex = 1; + this.label1.Text = "Using L.A.M.E. encoding engine"; + // + // lameQualityGb + // + this.lameQualityGb.Controls.Add(this.label19); + this.lameQualityGb.Controls.Add(this.label18); + this.lameQualityGb.Controls.Add(this.label17); + this.lameQualityGb.Controls.Add(this.label16); + this.lameQualityGb.Controls.Add(this.label12); + this.lameQualityGb.Controls.Add(this.label15); + this.lameQualityGb.Controls.Add(this.label9); + this.lameQualityGb.Controls.Add(this.label8); + this.lameQualityGb.Controls.Add(this.label13); + this.lameQualityGb.Controls.Add(this.label10); + this.lameQualityGb.Controls.Add(this.label14); + this.lameQualityGb.Controls.Add(this.label2); + this.lameQualityGb.Controls.Add(this.lameVBRQualityTb); + this.lameQualityGb.Location = new System.Drawing.Point(6, 202); + this.lameQualityGb.Name = "lameQualityGb"; + this.lameQualityGb.Size = new System.Drawing.Size(421, 109); + this.lameQualityGb.TabIndex = 0; + this.lameQualityGb.TabStop = false; + this.lameQualityGb.Text = "Quality"; + // + // label19 + // + this.label19.AutoSize = true; + this.label19.Location = new System.Drawing.Point(349, 52); + this.label19.Name = "label19"; + this.label19.Size = new System.Drawing.Size(20, 15); + this.label19.TabIndex = 1; + this.label19.Text = "V8"; + // + // label18 + // + this.label18.AutoSize = true; + this.label18.Location = new System.Drawing.Point(307, 52); + this.label18.Name = "label18"; + this.label18.Size = new System.Drawing.Size(20, 15); + this.label18.TabIndex = 1; + this.label18.Text = "V7"; + // + // label17 + // + this.label17.AutoSize = true; + this.label17.Location = new System.Drawing.Point(265, 52); + this.label17.Name = "label17"; + this.label17.Size = new System.Drawing.Size(20, 15); + this.label17.TabIndex = 1; + this.label17.Text = "V6"; + // + // label16 + // + this.label16.AutoSize = true; + this.label16.Location = new System.Drawing.Point(223, 52); + this.label16.Name = "label16"; + this.label16.Size = new System.Drawing.Size(20, 15); + this.label16.TabIndex = 1; + this.label16.Text = "V5"; + // + // label12 + // + this.label12.AutoSize = true; + this.label12.Location = new System.Drawing.Point(182, 52); + this.label12.Name = "label12"; + this.label12.Size = new System.Drawing.Size(20, 15); + this.label12.TabIndex = 1; + this.label12.Text = "V4"; + // + // label15 + // + this.label15.AutoSize = true; + this.label15.Location = new System.Drawing.Point(140, 52); + this.label15.Name = "label15"; + this.label15.Size = new System.Drawing.Size(20, 15); + this.label15.TabIndex = 1; + this.label15.Text = "V3"; + // + // label9 + // + this.label9.AutoSize = true; + this.label9.Location = new System.Drawing.Point(97, 52); + this.label9.Name = "label9"; + this.label9.Size = new System.Drawing.Size(20, 15); + this.label9.TabIndex = 1; + this.label9.Text = "V2"; + // + // label8 + // + this.label8.AutoSize = true; + this.label8.Location = new System.Drawing.Point(391, 52); + this.label8.Name = "label8"; + this.label8.Size = new System.Drawing.Size(20, 15); + this.label8.TabIndex = 1; + this.label8.Text = "V9"; + // + // label13 + // + this.label13.AutoSize = true; + this.label13.Location = new System.Drawing.Point(376, 81); + this.label13.Name = "label13"; + this.label13.Size = new System.Drawing.Size(39, 15); + this.label13.TabIndex = 1; + this.label13.Text = "Lower"; + // + // label10 + // + this.label10.AutoSize = true; + this.label10.Location = new System.Drawing.Point(6, 81); + this.label10.Name = "label10"; + this.label10.Size = new System.Drawing.Size(43, 15); + this.label10.TabIndex = 1; + this.label10.Text = "Higher"; + // + // label14 + // + this.label14.AutoSize = true; + this.label14.Location = new System.Drawing.Point(56, 52); + this.label14.Name = "label14"; + this.label14.Size = new System.Drawing.Size(20, 15); + this.label14.TabIndex = 1; + this.label14.Text = "V1"; + // + // label2 + // + this.label2.AutoSize = true; + this.label2.Location = new System.Drawing.Point(14, 52); + this.label2.Name = "label2"; + this.label2.Size = new System.Drawing.Size(20, 15); + this.label2.TabIndex = 1; + this.label2.Text = "V0"; + // + // lameVBRQualityTb + // + this.lameVBRQualityTb.BackColor = System.Drawing.SystemColors.ControlLightLight; + this.lameVBRQualityTb.LargeChange = 1; + this.lameVBRQualityTb.Location = new System.Drawing.Point(10, 22); + this.lameVBRQualityTb.Maximum = 9; + this.lameVBRQualityTb.Name = "lameVBRQualityTb"; + this.lameVBRQualityTb.Size = new System.Drawing.Size(405, 45); + this.lameVBRQualityTb.TabIndex = 0; + this.lameVBRQualityTb.Value = 9; + // + // groupBox2 + // + this.groupBox2.Controls.Add(this.lameTargetQualityRb); + this.groupBox2.Controls.Add(this.lameTargetBitrateRb); + this.groupBox2.Location = new System.Drawing.Point(6, 22); + this.groupBox2.Name = "groupBox2"; + this.groupBox2.Size = new System.Drawing.Size(222, 56); + this.groupBox2.TabIndex = 0; + this.groupBox2.TabStop = false; + this.groupBox2.Text = "Target"; + // + // lameTargetQualityRb + // + this.lameTargetQualityRb.AutoSize = true; + this.lameTargetQualityRb.Location = new System.Drawing.Point(138, 23); + this.lameTargetQualityRb.Name = "lameTargetQualityRb"; + this.lameTargetQualityRb.Size = new System.Drawing.Size(63, 19); + this.lameTargetQualityRb.TabIndex = 0; + this.lameTargetQualityRb.TabStop = true; + this.lameTargetQualityRb.Text = "Quality"; + this.lameTargetQualityRb.UseVisualStyleBackColor = true; + this.lameTargetQualityRb.CheckedChanged += new System.EventHandler(this.lameTargetRb_CheckedChanged); + // + // lameTargetBitrateRb + // + this.lameTargetBitrateRb.AutoSize = true; + this.lameTargetBitrateRb.Location = new System.Drawing.Point(6, 23); + this.lameTargetBitrateRb.Name = "lameTargetBitrateRb"; + this.lameTargetBitrateRb.Size = new System.Drawing.Size(59, 19); + this.lameTargetBitrateRb.TabIndex = 0; + this.lameTargetBitrateRb.TabStop = true; + this.lameTargetBitrateRb.Text = "Bitrate"; + this.lameTargetBitrateRb.UseVisualStyleBackColor = true; + this.lameTargetBitrateRb.CheckedChanged += new System.EventHandler(this.lameTargetRb_CheckedChanged); + // + // stripUnabridgedCbox + // + this.stripUnabridgedCbox.AutoSize = true; + this.stripUnabridgedCbox.Location = new System.Drawing.Point(19, 143); + this.stripUnabridgedCbox.Name = "stripUnabridgedCbox"; + this.stripUnabridgedCbox.Size = new System.Drawing.Size(147, 19); + this.stripUnabridgedCbox.TabIndex = 13; + this.stripUnabridgedCbox.Text = "[StripUnabridged desc]"; + this.stripUnabridgedCbox.UseVisualStyleBackColor = true; + // + // retainAaxFileCbox + // + this.retainAaxFileCbox.AutoSize = true; + this.retainAaxFileCbox.Location = new System.Drawing.Point(19, 93); + this.retainAaxFileCbox.Name = "retainAaxFileCbox"; + this.retainAaxFileCbox.Size = new System.Drawing.Size(132, 19); + this.retainAaxFileCbox.TabIndex = 10; + this.retainAaxFileCbox.Text = "[RetainAaxFile desc]"; + this.retainAaxFileCbox.UseVisualStyleBackColor = true; + this.retainAaxFileCbox.CheckedChanged += new System.EventHandler(this.allowLibationFixupCbox_CheckedChanged); + // + // downloadCoverArtCbox + // + this.downloadCoverArtCbox.AutoSize = true; + this.downloadCoverArtCbox.Checked = true; + this.downloadCoverArtCbox.CheckState = System.Windows.Forms.CheckState.Checked; + this.downloadCoverArtCbox.Location = new System.Drawing.Point(19, 68); + this.downloadCoverArtCbox.Name = "downloadCoverArtCbox"; + this.downloadCoverArtCbox.Size = new System.Drawing.Size(162, 19); + this.downloadCoverArtCbox.TabIndex = 10; + this.downloadCoverArtCbox.Text = "[DownloadCoverArt desc]"; + this.downloadCoverArtCbox.UseVisualStyleBackColor = true; + this.downloadCoverArtCbox.CheckedChanged += new System.EventHandler(this.allowLibationFixupCbox_CheckedChanged); + // + // createCueSheetCbox + // + this.createCueSheetCbox.AutoSize = true; + this.createCueSheetCbox.Checked = true; + this.createCueSheetCbox.CheckState = System.Windows.Forms.CheckState.Checked; + this.createCueSheetCbox.Location = new System.Drawing.Point(19, 43); + this.createCueSheetCbox.Name = "createCueSheetCbox"; + this.createCueSheetCbox.Size = new System.Drawing.Size(145, 19); + this.createCueSheetCbox.TabIndex = 10; + this.createCueSheetCbox.Text = "[CreateCueSheet desc]"; + this.createCueSheetCbox.UseVisualStyleBackColor = true; + this.createCueSheetCbox.CheckedChanged += new System.EventHandler(this.allowLibationFixupCbox_CheckedChanged); + // + // SettingsDialog + // + this.AcceptButton = this.saveBtn; + this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.CancelButton = this.cancelBtn; + this.ClientSize = new System.Drawing.Size(886, 484); + this.Controls.Add(this.tabControl); + this.Controls.Add(this.cancelBtn); + this.Controls.Add(this.saveBtn); + this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog; + this.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3); + this.MaximizeBox = false; + this.MinimizeBox = false; + this.Name = "SettingsDialog"; + this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent; + this.Text = "Edit Settings"; + this.Load += new System.EventHandler(this.SettingsDialog_Load); + this.badBookGb.ResumeLayout(false); + this.badBookGb.PerformLayout(); + this.tabControl.ResumeLayout(false); + this.tab1ImportantSettings.ResumeLayout(false); + this.tab1ImportantSettings.PerformLayout(); + this.booksGb.ResumeLayout(false); + this.booksGb.PerformLayout(); + this.tab2ImportLibrary.ResumeLayout(false); + this.tab2ImportLibrary.PerformLayout(); + this.tab3DownloadDecrypt.ResumeLayout(false); + this.inProgressFilesGb.ResumeLayout(false); + this.inProgressFilesGb.PerformLayout(); + this.customFileNamingGb.ResumeLayout(false); + this.customFileNamingGb.PerformLayout(); + this.tab4AudioFileOptions.ResumeLayout(false); + this.tab4AudioFileOptions.PerformLayout(); + this.lameOptionsGb.ResumeLayout(false); + this.lameOptionsGb.PerformLayout(); + this.lameBitrateGb.ResumeLayout(false); + this.lameBitrateGb.PerformLayout(); + ((System.ComponentModel.ISupportInitialize)(this.lameBitrateTb)).EndInit(); + this.lameQualityGb.ResumeLayout(false); + this.lameQualityGb.PerformLayout(); + ((System.ComponentModel.ISupportInitialize)(this.lameVBRQualityTb)).EndInit(); + this.groupBox2.ResumeLayout(false); + this.groupBox2.PerformLayout(); + this.ResumeLayout(false); } @@ -1072,5 +1084,6 @@ private System.Windows.Forms.CheckBox createCueSheetCbox; private System.Windows.Forms.CheckBox autoScanCb; private System.Windows.Forms.CheckBox downloadCoverArtCbox; - } + private System.Windows.Forms.CheckBox autoDownloadEpisodesCb; + } } \ No newline at end of file diff --git a/Source/LibationWinForms/Dialogs/SettingsDialog.cs b/Source/LibationWinForms/Dialogs/SettingsDialog.cs index cc84ecc2..dbfe1e5a 100644 --- a/Source/LibationWinForms/Dialogs/SettingsDialog.cs +++ b/Source/LibationWinForms/Dialogs/SettingsDialog.cs @@ -35,6 +35,7 @@ namespace LibationWinForms.Dialogs this.showImportedStatsCb.Text = desc(nameof(config.ShowImportedStats)); this.importEpisodesCb.Text = desc(nameof(config.ImportEpisodes)); this.downloadEpisodesCb.Text = desc(nameof(config.DownloadEpisodes)); + this.autoDownloadEpisodesCb.Text = desc(nameof(config.AutoDownloadEpisodes)); this.booksLocationDescLbl.Text = desc(nameof(config.Books)); this.inProgressDescLbl.Text = desc(nameof(config.InProgress)); @@ -80,6 +81,7 @@ namespace LibationWinForms.Dialogs showImportedStatsCb.Checked = config.ShowImportedStats; importEpisodesCb.Checked = config.ImportEpisodes; downloadEpisodesCb.Checked = config.DownloadEpisodes; + autoDownloadEpisodesCb.Checked = config.AutoDownloadEpisodes; lameTargetRb_CheckedChanged(this, e); LameMatchSourceBRCbox_CheckedChanged(this, e); @@ -204,6 +206,7 @@ namespace LibationWinForms.Dialogs config.ShowImportedStats = showImportedStatsCb.Checked; config.ImportEpisodes = importEpisodesCb.Checked; config.DownloadEpisodes = downloadEpisodesCb.Checked; + config.AutoDownloadEpisodes = autoDownloadEpisodesCb.Checked; config.InProgress = inProgressSelectControl.SelectedDirectory; diff --git a/Source/LibationWinForms/Form1.BackupCounts.cs b/Source/LibationWinForms/Form1.BackupCounts.cs index 8c25d699..0046cc61 100644 --- a/Source/LibationWinForms/Form1.BackupCounts.cs +++ b/Source/LibationWinForms/Form1.BackupCounts.cs @@ -6,6 +6,8 @@ namespace LibationWinForms { public partial class Form1 { + private System.ComponentModel.BackgroundWorker updateCountsBw = new(); + protected void Configure_BackupCounts() { // init formattable @@ -16,22 +18,23 @@ namespace LibationWinForms Load += setBackupCounts; LibraryCommands.LibrarySizeChanged += setBackupCounts; LibraryCommands.BookUserDefinedItemCommitted += setBackupCounts; - } - private System.ComponentModel.BackgroundWorker updateCountsBw; + updateCountsBw.DoWork += UpdateCountsBw_DoWork; + updateCountsBw.RunWorkerCompleted += exportMenuEnable; + updateCountsBw.RunWorkerCompleted += updateBottomBookNumbers; + updateCountsBw.RunWorkerCompleted += update_BeginBookBackups_menuItem; + updateCountsBw.RunWorkerCompleted += updateBottomPdfNumbers; + updateCountsBw.RunWorkerCompleted += udpate_BeginPdfOnlyBackups_menuItem; + } + private bool runBackupCountsAgain; private void setBackupCounts(object _, object __) { runBackupCountsAgain = true; - if (updateCountsBw is not null) - return; - - updateCountsBw = new System.ComponentModel.BackgroundWorker(); - updateCountsBw.DoWork += UpdateCountsBw_DoWork; - updateCountsBw.RunWorkerCompleted += UpdateCountsBw_RunWorkerCompleted; - updateCountsBw.RunWorkerAsync(); + if (!updateCountsBw.IsBusy) + updateCountsBw.RunWorkerAsync(); } private void UpdateCountsBw_DoWork(object sender, System.ComponentModel.DoWorkEventArgs e) @@ -39,87 +42,78 @@ namespace LibationWinForms while (runBackupCountsAgain) { runBackupCountsAgain = false; - - var libraryStats = LibraryCommands.GetCounts(); - e.Result = libraryStats; + e.Result = LibraryCommands.GetCounts(); } - updateCountsBw = null; } - private void UpdateCountsBw_RunWorkerCompleted(object sender, System.ComponentModel.RunWorkerCompletedEventArgs e) + private void exportMenuEnable(object _, System.ComponentModel.RunWorkerCompletedEventArgs e) { var libraryStats = e.Result as LibraryCommands.LibraryStats; - - setBookBackupCounts(libraryStats); - setPdfBackupCounts(libraryStats); + exportLibraryToolStripMenuItem.Enabled = libraryStats.HasBookResults; } // this cannot be cleanly be FormattableToolStripMenuItem because of the optional "Errors" text private const string backupsCountsLbl_Format = "BACKUPS: No progress: {0} In process: {1} Fully backed up: {2}"; - private void setBookBackupCounts(LibraryCommands.LibraryStats libraryStats) + private void updateBottomBookNumbers(object _, System.ComponentModel.RunWorkerCompletedEventArgs e) { - var pending = libraryStats.booksNoProgress + libraryStats.booksDownloadedOnly; - var hasResults = 0 < (libraryStats.booksFullyBackedUp + libraryStats.booksDownloadedOnly + libraryStats.booksNoProgress + libraryStats.booksError); + var libraryStats = e.Result as LibraryCommands.LibraryStats; - // enable/disable export - { - exportLibraryToolStripMenuItem.Enabled = hasResults; - } - - // update bottom numbers - { - var formatString - = !hasResults ? "No books. Begin by importing your library" - : libraryStats.booksError > 0 ? backupsCountsLbl_Format + " Errors: {3}" - : pending > 0 ? backupsCountsLbl_Format - : $"All {"book".PluralizeWithCount(libraryStats.booksFullyBackedUp)} backed up"; - var statusStripText = string.Format(formatString, - libraryStats.booksNoProgress, - libraryStats.booksDownloadedOnly, - libraryStats.booksFullyBackedUp, - libraryStats.booksError); - statusStrip1.UIThreadAsync(() => backupsCountsLbl.Text = statusStripText); - } - - // update 'begin book backups' menu item - { - var menuItemText - = pending > 0 - ? $"{pending} remaining" - : "All books have been liberated"; - menuStrip1.UIThreadAsync(() => - { - beginBookBackupsToolStripMenuItem.Format(menuItemText); - beginBookBackupsToolStripMenuItem.Enabled = pending > 0; - }); - } + var formatString + = !libraryStats.HasBookResults ? "No books. Begin by importing your library" + : libraryStats.booksError > 0 ? backupsCountsLbl_Format + " Errors: {3}" + : libraryStats.HasPendingBooks ? backupsCountsLbl_Format + : $"All {"book".PluralizeWithCount(libraryStats.booksFullyBackedUp)} backed up"; + var statusStripText = string.Format(formatString, + libraryStats.booksNoProgress, + libraryStats.booksDownloadedOnly, + libraryStats.booksFullyBackedUp, + libraryStats.booksError); + statusStrip1.UIThreadAsync(() => backupsCountsLbl.Text = statusStripText); } - private void setPdfBackupCounts(LibraryCommands.LibraryStats libraryStats) - { - // update bottom numbers - { - var hasResults = 0 < (libraryStats.pdfsNotDownloaded + libraryStats.pdfsDownloaded); - // don't need to assign the output of Format(). It just makes this logic cleaner - var statusStripText - = !hasResults ? "" - : libraryStats.pdfsNotDownloaded > 0 ? pdfsCountsLbl.Format(libraryStats.pdfsNotDownloaded, libraryStats.pdfsDownloaded) - : $"| All {libraryStats.pdfsDownloaded} PDFs downloaded"; - statusStrip1.UIThreadAsync(() => pdfsCountsLbl.Text = statusStripText); - } - // update 'begin pdf only backups' menu item + // update 'begin book backups' menu item + private void update_BeginBookBackups_menuItem(object _, System.ComponentModel.RunWorkerCompletedEventArgs e) + { + var libraryStats = e.Result as LibraryCommands.LibraryStats; + + var menuItemText + = libraryStats.HasPendingBooks + ? $"{libraryStats.PendingBooks} remaining" + : "All books have been liberated"; + menuStrip1.UIThreadAsync(() => { - var menuItemText - = libraryStats.pdfsNotDownloaded > 0 - ? $"{libraryStats.pdfsNotDownloaded} remaining" - : "All PDFs have been downloaded"; - menuStrip1.UIThreadAsync(() => - { - beginPdfBackupsToolStripMenuItem.Format(menuItemText); - beginPdfBackupsToolStripMenuItem.Enabled = libraryStats.pdfsNotDownloaded > 0; - }); - } + beginBookBackupsToolStripMenuItem.Format(menuItemText); + beginBookBackupsToolStripMenuItem.Enabled = libraryStats.HasPendingBooks; + }); + } + + private void updateBottomPdfNumbers(object _, System.ComponentModel.RunWorkerCompletedEventArgs e) + { + var libraryStats = e.Result as LibraryCommands.LibraryStats; + + // don't need to assign the output of Format(). It just makes this logic cleaner + var statusStripText + = !libraryStats.HasPdfResults ? "" + : libraryStats.pdfsNotDownloaded > 0 ? pdfsCountsLbl.Format(libraryStats.pdfsNotDownloaded, libraryStats.pdfsDownloaded) + : $"| All {libraryStats.pdfsDownloaded} PDFs downloaded"; + statusStrip1.UIThreadAsync(() => pdfsCountsLbl.Text = statusStripText); + } + + // update 'begin pdf only backups' menu item + private void udpate_BeginPdfOnlyBackups_menuItem(object _, System.ComponentModel.RunWorkerCompletedEventArgs e) + { + var libraryStats = e.Result as LibraryCommands.LibraryStats; + + var menuItemText + = libraryStats.pdfsNotDownloaded > 0 + ? $"{libraryStats.pdfsNotDownloaded} remaining" + : "All PDFs have been downloaded"; + menuStrip1.UIThreadAsync(() => + { + beginPdfBackupsToolStripMenuItem.Format(menuItemText); + beginPdfBackupsToolStripMenuItem.Enabled = libraryStats.pdfsNotDownloaded > 0; + }); } } } diff --git a/Source/LibationWinForms/Form1.Liberate.cs b/Source/LibationWinForms/Form1.Liberate.cs index 66a24ebf..619fc69a 100644 --- a/Source/LibationWinForms/Form1.Liberate.cs +++ b/Source/LibationWinForms/Form1.Liberate.cs @@ -10,7 +10,7 @@ namespace LibationWinForms private void Configure_Liberate() { } //GetLibrary_Flat_NoTracking() may take a long time on a hugh library. so run in new thread - private async void beginBookBackupsToolStripMenuItem_Click(object sender, EventArgs e) + private async void beginBookBackupsToolStripMenuItem_Click(object _ = null, EventArgs __ = null) { SetQueueCollapseState(false); await Task.Run(() => processBookQueue1.AddDownloadDecrypt(ApplicationServices.DbContexts.GetLibrary_Flat_NoTracking() diff --git a/Source/LibationWinForms/Form1.PictureStorage.cs b/Source/LibationWinForms/Form1.PictureStorage.cs deleted file mode 100644 index c400eaf6..00000000 --- a/Source/LibationWinForms/Form1.PictureStorage.cs +++ /dev/null @@ -1,18 +0,0 @@ -using Dinah.Core.Drawing; -using LibationFileManager; - -namespace LibationWinForms -{ - public partial class Form1 - { - private void Configure_PictureStorage() - { - // init default/placeholder cover art - var format = System.Drawing.Imaging.ImageFormat.Jpeg; - PictureStorage.SetDefaultImage(PictureSize._80x80, Properties.Resources.default_cover_80x80.ToBytes(format)); - PictureStorage.SetDefaultImage(PictureSize._300x300, Properties.Resources.default_cover_300x300.ToBytes(format)); - PictureStorage.SetDefaultImage(PictureSize._500x500, Properties.Resources.default_cover_500x500.ToBytes(format)); - PictureStorage.SetDefaultImage(PictureSize.Native, Properties.Resources.default_cover_500x500.ToBytes(format)); - } - } -} diff --git a/Source/LibationWinForms/Form1._NonUI.cs b/Source/LibationWinForms/Form1._NonUI.cs new file mode 100644 index 00000000..c94611be --- /dev/null +++ b/Source/LibationWinForms/Form1._NonUI.cs @@ -0,0 +1,37 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using ApplicationServices; +using Dinah.Core.Drawing; +using LibationFileManager; + +namespace LibationWinForms +{ + public partial class Form1 + { + private void Configure_NonUI() + { + // init default/placeholder cover art + var format = System.Drawing.Imaging.ImageFormat.Jpeg; + PictureStorage.SetDefaultImage(PictureSize._80x80, Properties.Resources.default_cover_80x80.ToBytes(format)); + PictureStorage.SetDefaultImage(PictureSize._300x300, Properties.Resources.default_cover_300x300.ToBytes(format)); + PictureStorage.SetDefaultImage(PictureSize._500x500, Properties.Resources.default_cover_500x500.ToBytes(format)); + PictureStorage.SetDefaultImage(PictureSize.Native, Properties.Resources.default_cover_500x500.ToBytes(format)); + + // wire-up event to automatically download after scan. + // winforms only. this should NOT be allowed in cli + updateCountsBw.RunWorkerCompleted += (object sender, System.ComponentModel.RunWorkerCompletedEventArgs e) => + { + if (!Configuration.Instance.AutoDownloadEpisodes) + return; + + var libraryStats = e.Result as LibraryCommands.LibraryStats; + + if ((libraryStats.booksNoProgress + libraryStats.pdfsNotDownloaded) > 0) + beginBookBackupsToolStripMenuItem_Click(); + }; + } + } +} diff --git a/Source/LibationWinForms/Form1.cs b/Source/LibationWinForms/Form1.cs index 43151f73..8eb15705 100644 --- a/Source/LibationWinForms/Form1.cs +++ b/Source/LibationWinForms/Form1.cs @@ -38,7 +38,6 @@ namespace LibationWinForms // these should do nothing interesting yet (storing simple var, subscribe to events) and should never rely on each other for order. // otherwise, order could be an issue. // eg: if one of these init'd productsGrid, then another can't reliably subscribe to it - Configure_PictureStorage(); Configure_BackupCounts(); Configure_ScanAuto(); Configure_ScanNotification(); @@ -50,6 +49,8 @@ namespace LibationWinForms Configure_Settings(); Configure_ProcessQueue(); Configure_Filter(); + // misc which belongs in winforms app but doesn't have a UI element + Configure_NonUI(); // Configure_Grid(); // since it's just this, can keep here. If it needs more, then give grid it's own 'partial class Form1' {