New feature #170 : book details, added link to audible's page for that book
This commit is contained in:
parent
77e61479cf
commit
63877160aa
@ -41,6 +41,7 @@
|
||||
this.bookLiberatedCb = new System.Windows.Forms.ComboBox();
|
||||
this.bookLiberatedLbl = new System.Windows.Forms.Label();
|
||||
this.liberatedDescLbl = new System.Windows.Forms.Label();
|
||||
this.audibleLink = new System.Windows.Forms.LinkLabel();
|
||||
((System.ComponentModel.ISupportInitialize)(this.coverPb)).BeginInit();
|
||||
this.tagsGb.SuspendLayout();
|
||||
this.liberatedGb.SuspendLayout();
|
||||
@ -53,7 +54,7 @@
|
||||
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 = 3;
|
||||
this.saveBtn.TabIndex = 4;
|
||||
this.saveBtn.Text = "Save";
|
||||
this.saveBtn.UseVisualStyleBackColor = true;
|
||||
this.saveBtn.Click += new System.EventHandler(this.saveBtn_Click);
|
||||
@ -110,7 +111,7 @@
|
||||
this.tagsGb.Location = new System.Drawing.Point(12, 220);
|
||||
this.tagsGb.Name = "tagsGb";
|
||||
this.tagsGb.Size = new System.Drawing.Size(570, 73);
|
||||
this.tagsGb.TabIndex = 0;
|
||||
this.tagsGb.TabIndex = 2;
|
||||
this.tagsGb.TabStop = false;
|
||||
this.tagsGb.Text = "Edit Tags";
|
||||
//
|
||||
@ -120,7 +121,7 @@
|
||||
this.cancelBtn.Location = new System.Drawing.Point(494, 427);
|
||||
this.cancelBtn.Name = "cancelBtn";
|
||||
this.cancelBtn.Size = new System.Drawing.Size(88, 27);
|
||||
this.cancelBtn.TabIndex = 4;
|
||||
this.cancelBtn.TabIndex = 5;
|
||||
this.cancelBtn.Text = "Cancel";
|
||||
this.cancelBtn.UseVisualStyleBackColor = true;
|
||||
this.cancelBtn.Click += new System.EventHandler(this.cancelBtn_Click);
|
||||
@ -137,7 +138,7 @@
|
||||
this.liberatedGb.Location = new System.Drawing.Point(12, 299);
|
||||
this.liberatedGb.Name = "liberatedGb";
|
||||
this.liberatedGb.Size = new System.Drawing.Size(570, 122);
|
||||
this.liberatedGb.TabIndex = 2;
|
||||
this.liberatedGb.TabIndex = 3;
|
||||
this.liberatedGb.TabStop = false;
|
||||
this.liberatedGb.Text = "Liberated status: Whether the book/pdf has been downloaded";
|
||||
//
|
||||
@ -186,6 +187,17 @@
|
||||
this.liberatedDescLbl.TabIndex = 0;
|
||||
this.liberatedDescLbl.Text = "To download again next time: change to Not Downloaded\r\nTo not download: change to" +
|
||||
" Downloaded";
|
||||
//
|
||||
// audibleLink
|
||||
//
|
||||
this.audibleLink.AutoSize = true;
|
||||
this.audibleLink.Location = new System.Drawing.Point(12, 169);
|
||||
this.audibleLink.Name = "audibleLink";
|
||||
this.audibleLink.Size = new System.Drawing.Size(57, 45);
|
||||
this.audibleLink.TabIndex = 0;
|
||||
this.audibleLink.TabStop = true;
|
||||
this.audibleLink.Text = "Open in\r\nAudible\r\n(browser)";
|
||||
this.audibleLink.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.audibleLink_LinkClicked);
|
||||
//
|
||||
// BookDetailsDialog
|
||||
//
|
||||
@ -194,6 +206,7 @@
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.CancelButton = this.cancelBtn;
|
||||
this.ClientSize = new System.Drawing.Size(594, 466);
|
||||
this.Controls.Add(this.audibleLink);
|
||||
this.Controls.Add(this.liberatedGb);
|
||||
this.Controls.Add(this.cancelBtn);
|
||||
this.Controls.Add(this.tagsGb);
|
||||
@ -232,5 +245,6 @@
|
||||
private System.Windows.Forms.ComboBox bookLiberatedCb;
|
||||
private System.Windows.Forms.Label bookLiberatedLbl;
|
||||
private System.Windows.Forms.Label liberatedDescLbl;
|
||||
private System.Windows.Forms.LinkLabel audibleLink;
|
||||
}
|
||||
}
|
||||
@ -131,5 +131,12 @@ Audible ID: {Book.AudibleProductId}
|
||||
this.DialogResult = DialogResult.Cancel;
|
||||
this.Close();
|
||||
}
|
||||
|
||||
private void audibleLink_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
|
||||
{
|
||||
var locale = AudibleApi.Localization.Get(_libraryBook.Book.Locale);
|
||||
var link = $"https://www.audible.{locale.TopDomain}/pd/{Book.AudibleProductId}";
|
||||
Go.To.Url(link);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user