Skip to content

Commit

Permalink
Works with Proxy.
Browse files Browse the repository at this point in the history
Closes #3.

Now uses default proxy and credentials.
  • Loading branch information
Clint Pearson committed Jun 22, 2015
1 parent 193b042 commit 6fffb8c
Show file tree
Hide file tree
Showing 9 changed files with 2 additions and 160 deletions.
21 changes: 0 additions & 21 deletions Pak/AkavacheSqliteLinkerOverride.cs

This file was deleted.

5 changes: 1 addition & 4 deletions Pak/App.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
using System;
using System.Windows;
using Akavache;

namespace Pack
{
Expand All @@ -11,15 +10,12 @@ public partial class App : Application
{
protected override void OnStartup(StartupEventArgs e)
{
BlobCache.ApplicationName = "Pack";
BlobCache.EnsureInitialized();
AppDomain.CurrentDomain.UnhandledException += CurrentDomain_UnhandledException;
base.OnStartup(e);
}

protected override void OnExit(ExitEventArgs e)
{
BlobCache.Shutdown();
base.OnExit(e);
}

Expand All @@ -28,6 +24,7 @@ private void CurrentDomain_UnhandledException(object sender, UnhandledExceptionE
var root = ((Exception) e.ExceptionObject).GetBaseException();
MessageBox.Show("ERROR:\n\n" + root.Message + "\n\n Full details are now on your Clipboard, please paste them into a new issue", "ERROR!",
MessageBoxButton.OK, MessageBoxImage.Error);
Clipboard.SetText(root.GetBaseException().ToString());
}
}
}
12 changes: 0 additions & 12 deletions Pak/MainWindow.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,6 @@
BorderThickness="0" GlowBrush="Black"
ResizeMode="NoResize"
Topmost="True">
<controls:MetroWindow.RightWindowCommands>
<controls:WindowCommands>
<Button Cursor="Hand" ToolTip="Settings" x:Name="SettingsButton"
Click="SettingsButton_OnClick">
<Rectangle Width="16" Height="16" Fill="White">
<Rectangle.OpacityMask>
<VisualBrush Visual="{StaticResource appbar_settings}" />
</Rectangle.OpacityMask>
</Rectangle>
</Button>
</controls:WindowCommands>
</controls:MetroWindow.RightWindowCommands>
<Grid>
<StackPanel x:Name="DropPanel" HorizontalAlignment="Center" VerticalAlignment="Center"
Orientation="Vertical">
Expand Down
10 changes: 0 additions & 10 deletions Pak/MainWindow.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ private async void OnDrop(object sender, DragEventArgs e)
var uri = new Uri((string) data.GetData(DataFormats.Text));
byte[] imgData;
var proxy = WebRequest.DefaultWebProxy;
//var creds = await Settings.GetProxyCredentials();
proxy.Credentials = CredentialCache.DefaultCredentials;
using (var client = new WebClient
{
Expand Down Expand Up @@ -130,14 +129,5 @@ private void GoAgainButton_OnClick(object sender, RoutedEventArgs e)
Message.Text = DropMessage;
DragDrop.AddDropHandler(Border, OnDrop);
}

private void SettingsButton_OnClick(object sender, RoutedEventArgs e)
{
var settingsWin = new SettingsWindow
{
Owner = this,
};
settingsWin.ShowDialog();
}
}
}
31 changes: 1 addition & 30 deletions Pak/Pack.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
<CreateDesktopShortcut>true</CreateDesktopShortcut>
<PublishWizardCompleted>true</PublishWizardCompleted>
<BootstrapperEnabled>true</BootstrapperEnabled>
<NuGetPackageImportStamp>d7069aa4</NuGetPackageImportStamp>
<NuGetPackageImportStamp>412a06b2</NuGetPackageImportStamp>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
Expand Down Expand Up @@ -73,19 +73,9 @@
<SignManifests>true</SignManifests>
</PropertyGroup>
<ItemGroup>
<Reference Include="Akavache">
<HintPath>..\packages\akavache.core.4.1.1\lib\net45\Akavache.dll</HintPath>
</Reference>
<Reference Include="Akavache.Sqlite3">
<HintPath>..\packages\akavache.sqlite3.4.1.1\lib\Portable-Net45+Win8+WP8+Wpa81\Akavache.Sqlite3.dll</HintPath>
</Reference>
<Reference Include="MahApps.Metro">
<HintPath>..\packages\MahApps.Metro.1.1.2.0\lib\net45\MahApps.Metro.dll</HintPath>
</Reference>
<Reference Include="Newtonsoft.Json, Version=6.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\packages\Newtonsoft.Json.6.0.3\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference>
<Reference Include="ReactiveUI">
<HintPath>..\packages\reactiveui-core.6.5.0\lib\Net45\ReactiveUI.dll</HintPath>
</Reference>
Expand All @@ -98,9 +88,6 @@
<Reference Include="Splat">
<HintPath>..\packages\Splat.1.6.2\lib\Net45\Splat.dll</HintPath>
</Reference>
<Reference Include="SQLitePCL.raw">
<HintPath>..\packages\SQLitePCL.raw_basic.0.7.0\lib\net45\SQLitePCL.raw.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Data" />
<Reference Include="System.Drawing" />
Expand Down Expand Up @@ -139,15 +126,10 @@
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</ApplicationDefinition>
<Compile Include="Settings.cs" />
<Compile Include="SettingsWindow.xaml.cs">
<DependentUpon>SettingsWindow.xaml</DependentUpon>
</Compile>
<Page Include="MainWindow.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Compile Include="AkavacheSqliteLinkerOverride.cs" />
<Compile Include="App.xaml.cs">
<DependentUpon>App.xaml</DependentUpon>
<SubType>Code</SubType>
Expand All @@ -160,10 +142,6 @@
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="SettingsWindow.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
</ItemGroup>
<ItemGroup>
<Compile Include="Packer.cs" />
Expand Down Expand Up @@ -220,13 +198,6 @@
</BootstrapperPackage>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Import Project="..\packages\SQLitePCL.raw_basic.0.7.0\build\net45\SQLitePCL.raw_basic.targets" Condition="Exists('..\packages\SQLitePCL.raw_basic.0.7.0\build\net45\SQLitePCL.raw_basic.targets')" />
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
<PropertyGroup>
<ErrorText>This project references NuGet package(s) that are missing on this computer. Enable NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
</PropertyGroup>
<Error Condition="!Exists('..\packages\SQLitePCL.raw_basic.0.7.0\build\net45\SQLitePCL.raw_basic.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\SQLitePCL.raw_basic.0.7.0\build\net45\SQLitePCL.raw_basic.targets'))" />
</Target>
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
Expand Down
14 changes: 0 additions & 14 deletions Pak/Settings.cs

This file was deleted.

36 changes: 0 additions & 36 deletions Pak/SettingsWindow.xaml

This file was deleted.

28 changes: 0 additions & 28 deletions Pak/SettingsWindow.xaml.cs

This file was deleted.

5 changes: 0 additions & 5 deletions Pak/packages.config
Original file line number Diff line number Diff line change
@@ -1,11 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="akavache" version="4.1.1" targetFramework="net451" />
<package id="akavache.core" version="4.1.1" targetFramework="net451" />
<package id="akavache.sqlite3" version="4.1.1" targetFramework="net451" />
<package id="MahApps.Metro" version="1.1.2.0" targetFramework="net451" />
<package id="MahApps.Metro.Resources" version="0.4.0.0" targetFramework="net451" />
<package id="Newtonsoft.Json" version="6.0.3" targetFramework="net451" />
<package id="reactiveui" version="6.5.0" targetFramework="net451" />
<package id="reactiveui-core" version="6.5.0" targetFramework="net451" />
<package id="reactiveui-events" version="6.5.0" targetFramework="net451" />
Expand All @@ -17,5 +13,4 @@
<package id="Rx-XAML" version="2.2.5" targetFramework="net451" />
<package id="SevenZipSharp" version="0.64" targetFramework="net451" />
<package id="Splat" version="1.6.2" targetFramework="net451" />
<package id="SQLitePCL.raw_basic" version="0.7.0" targetFramework="net451" />
</packages>

0 comments on commit 6fffb8c

Please sign in to comment.