Skip to content

Commit 6882a83

Browse files
committed
v1.6.2
1 parent 7f7489b commit 6882a83

File tree

5 files changed

+9
-29
lines changed

5 files changed

+9
-29
lines changed

IMDbAPI_Client/IMDbAPI_Client.csproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,8 @@
5151
<ApplicationIcon>ProjectIcon.ico</ApplicationIcon>
5252
</PropertyGroup>
5353
<ItemGroup>
54-
<Reference Include="IMDbApiLib, Version=1.6.0.0, Culture=neutral, processorArchitecture=MSIL">
55-
<HintPath>..\packages\IMDbApiLib.1.6.0\lib\net45\IMDbApiLib.dll</HintPath>
54+
<Reference Include="IMDbApiLib, Version=1.6.2.0, Culture=neutral, processorArchitecture=MSIL">
55+
<HintPath>..\packages\IMDbApiLib.1.6.2\lib\net45\IMDbApiLib.dll</HintPath>
5656
</Reference>
5757
<Reference Include="MetroFramework, Version=1.4.0.0, Culture=neutral, PublicKeyToken=5f91a84759bf584a, processorArchitecture=MSIL">
5858
<HintPath>..\packages\MetroModernUI.1.4.0.0\lib\net\MetroFramework.dll</HintPath>

IMDbAPI_Client/Program.cs

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -16,25 +16,5 @@ private static void Main()
1616
Application.SetCompatibleTextRenderingDefault(false);
1717
Application.Run(new MainForm());
1818
}
19-
20-
public static WebProxy GetWebProxy()
21-
{
22-
if (!Properties.Settings.Default.UseProxy)
23-
return null;
24-
25-
var webProxy = new WebProxy();
26-
webProxy.Address = new Uri(Properties.Settings.Default.ProxyAddress);
27-
if (!string.IsNullOrEmpty(Properties.Settings.Default.ProxyUsername)
28-
&& !string.IsNullOrEmpty(Properties.Settings.Default.ProxyPassword))
29-
{
30-
webProxy.Credentials = new NetworkCredential(
31-
Properties.Settings.Default.ProxyUsername,
32-
Properties.Settings.Default.ProxyPassword);
33-
webProxy.UseDefaultCredentials = false;
34-
}
35-
webProxy.BypassProxyOnLocal = false;
36-
37-
return webProxy;
38-
}
3919
}
4020
}

IMDbAPI_Client/Properties/AssemblyInfo.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,5 +31,5 @@
3131
// You can specify all the values or you can default the Build and Revision Numbers
3232
// by using the '*' as shown below:
3333
// [assembly: AssemblyVersion("1.0.*")]
34-
[assembly: AssemblyVersion("1.6.0.0")]
35-
[assembly: AssemblyFileVersion("1.6.0.0")]
34+
[assembly: AssemblyVersion("1.6.2.0")]
35+
[assembly: AssemblyFileVersion("1.6.2.0")]

IMDbAPI_Client/UserControls/Step4_DownloadUC.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -203,15 +203,15 @@ await _apiLib.DownloadReportAsync(
203203
{
204204
ReportCurrent("Posters", current, total, cancellationToken.IsCancellationRequested);
205205
string filePath = Path.Combine(dir, $"{item.Id}-{index.ToString("000")}.jpg");
206-
await Utils.DownloadFileAsync(filePath, p.Link, Program.GetWebProxy());
206+
await Utils.DownloadFileAsync(filePath, p.Link, _apiLib.WebProxy);
207207
current++;
208208
index++;
209209
}
210210
foreach (var p in data.Posters.Backdrops)
211211
{
212212
ReportCurrent("Posters", current, total, cancellationToken.IsCancellationRequested);
213213
string filePath = Path.Combine(dir, $"{item.Id}-{index.ToString("000")}.jpg");
214-
await Utils.DownloadFileAsync(filePath, p.Link, Program.GetWebProxy());
214+
await Utils.DownloadFileAsync(filePath, p.Link, _apiLib.WebProxy);
215215
current++;
216216
index++;
217217
}
@@ -246,7 +246,7 @@ await _apiLib.DownloadReportAsync(
246246
ReportCurrent("Images", currentIndex, total, cancellationToken.IsCancellationRequested);
247247
string filePath = Path.Combine(dir, $"{Utils.RenameToPhisicalName(img.Title)}.jpg");
248248
string url = img.Image;
249-
await Utils.DownloadImageAsync(filePath, url, Program.GetWebProxy());
249+
await Utils.DownloadImageAsync(filePath, url, _apiLib.WebProxy);
250250
currentIndex++;
251251
}
252252

@@ -271,7 +271,7 @@ await _apiLib.DownloadReportAsync(
271271
video.Url,
272272
new ProgressData(progress => ReportCurrent($"Trailer", progress.Current, progress.Total, cancellationToken.IsCancellationRequested, true)),
273273
cancellationToken,
274-
Program.GetWebProxy());
274+
_apiLib.WebProxy);
275275

276276
if (trailerBytes != null)
277277
{

IMDbAPI_Client/packages.config

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<packages>
3-
<package id="IMDbApiLib" version="1.6.0" targetFramework="net472" />
3+
<package id="IMDbApiLib" version="1.6.2" targetFramework="net472" />
44
<package id="MetroModernUI" version="1.4.0.0" targetFramework="net472" />
55
<package id="Newtonsoft.Json" version="13.0.1" targetFramework="net472" />
66
</packages>

0 commit comments

Comments
 (0)