This commit is contained in:
Florian Rappl 2019-05-15 02:07:59 +02:00
Родитель 45d3f7a03b
Коммит e8e47d5b14
26 изменённых файлов: 640 добавлений и 615 удалений

Просмотреть файл

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" /> <Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup> <PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
@ -9,7 +9,7 @@
<AppDesignerFolder>Properties</AppDesignerFolder> <AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>Samples</RootNamespace> <RootNamespace>Samples</RootNamespace>
<AssemblyName>Samples</AssemblyName> <AssemblyName>Samples</AssemblyName>
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion> <TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment> <FileAlignment>512</FileAlignment>
<ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids> <ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>
@ -17,6 +17,7 @@
<RestorePackages>true</RestorePackages> <RestorePackages>true</RestorePackages>
<NuGetPackageImportStamp>65879974</NuGetPackageImportStamp> <NuGetPackageImportStamp>65879974</NuGetPackageImportStamp>
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects> <AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
<TargetFrameworkProfile />
</PropertyGroup> </PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget> <PlatformTarget>AnyCPU</PlatformTarget>
@ -42,21 +43,23 @@
</PropertyGroup> </PropertyGroup>
<ItemGroup> <ItemGroup>
<Reference Include="Accessibility" /> <Reference Include="Accessibility" />
<Reference Include="AngleSharp, Version=0.9.9.0, Culture=neutral, PublicKeyToken=e83494dcdc6d31ea, processorArchitecture=MSIL"> <Reference Include="AngleSharp, Version=0.12.1.0, Culture=neutral, PublicKeyToken=e83494dcdc6d31ea, processorArchitecture=MSIL">
<HintPath>..\packages\AngleSharp.0.9.9\lib\net45\AngleSharp.dll</HintPath> <HintPath>..\packages\AngleSharp.0.12.1\lib\net46\AngleSharp.dll</HintPath>
<Private>True</Private>
</Reference> </Reference>
<Reference Include="AngleSharp.Io, Version=0.3.2.0, Culture=neutral, processorArchitecture=MSIL"> <Reference Include="AngleSharp.Css, Version=0.12.1.0, Culture=neutral, PublicKeyToken=e83494dcdc6d31ea, processorArchitecture=MSIL">
<HintPath>..\packages\AngleSharp.Io.0.3.2\lib\net45\AngleSharp.Io.dll</HintPath> <HintPath>..\packages\AngleSharp.Css.0.12.1\lib\net46\AngleSharp.Css.dll</HintPath>
<Private>True</Private>
</Reference> </Reference>
<Reference Include="AngleSharp.Scripting.JavaScript, Version=0.5.0.0, Culture=neutral, processorArchitecture=MSIL"> <Reference Include="AngleSharp.Io, Version=0.12.1.0, Culture=neutral, PublicKeyToken=e83494dcdc6d31ea, processorArchitecture=MSIL">
<HintPath>..\packages\AngleSharp.Scripting.JavaScript.0.5.0\lib\portable-windows8+net45+windowsphone8+wpa+monoandroid+monotouch\AngleSharp.Scripting.JavaScript.dll</HintPath> <HintPath>..\packages\AngleSharp.Io.0.12.1\lib\netstandard2.0\AngleSharp.Io.dll</HintPath>
<Private>True</Private>
</Reference> </Reference>
<Reference Include="Jint, Version=2.9.1.0, Culture=neutral, PublicKeyToken=2e92ba9c8d81157f, processorArchitecture=MSIL"> <Reference Include="AngleSharp.Js, Version=0.12.1.0, Culture=neutral, PublicKeyToken=e83494dcdc6d31ea, processorArchitecture=MSIL">
<HintPath>..\packages\Jint.2.9.1\lib\portable-net40+sl50+win+WindowsPhoneApp81+wp80\Jint.dll</HintPath> <HintPath>..\packages\AngleSharp.Js.0.12.1\lib\net46\AngleSharp.Js.dll</HintPath>
<Private>True</Private> </Reference>
<Reference Include="AngleSharp.Xml, Version=0.12.1.0, Culture=neutral, PublicKeyToken=e83494dcdc6d31ea, processorArchitecture=MSIL">
<HintPath>..\packages\AngleSharp.Xml.0.12.1\lib\netstandard1.3\AngleSharp.Xml.dll</HintPath>
</Reference>
<Reference Include="jint, Version=2.10.4.0, Culture=neutral, PublicKeyToken=2e92ba9c8d81157f, processorArchitecture=MSIL">
<HintPath>..\packages\jint.2.10.4\lib\net45\jint.dll</HintPath>
</Reference> </Reference>
<Reference Include="MahApps.Metro, Version=1.2.4.0, Culture=neutral, PublicKeyToken=f4fb5a3c4d1e5b4f, processorArchitecture=MSIL"> <Reference Include="MahApps.Metro, Version=1.2.4.0, Culture=neutral, PublicKeyToken=f4fb5a3c4d1e5b4f, processorArchitecture=MSIL">
<HintPath>..\packages\MahApps.Metro.1.2.4.0\lib\net45\MahApps.Metro.dll</HintPath> <HintPath>..\packages\MahApps.Metro.1.2.4.0\lib\net45\MahApps.Metro.dll</HintPath>
@ -91,9 +94,16 @@
<Reference Include="System" /> <Reference Include="System" />
<Reference Include="System.Data" /> <Reference Include="System.Data" />
<Reference Include="System.Deployment" /> <Reference Include="System.Deployment" />
<Reference Include="System.Diagnostics.Contracts, Version=4.0.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL" />
<Reference Include="System.Net" /> <Reference Include="System.Net" />
<Reference Include="System.Net.Http" /> <Reference Include="System.Net.Http" />
<Reference Include="System.Printing" /> <Reference Include="System.Printing" />
<Reference Include="System.Runtime.CompilerServices.Unsafe, Version=4.0.4.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<HintPath>..\packages\System.Runtime.CompilerServices.Unsafe.4.5.0\lib\netstandard2.0\System.Runtime.CompilerServices.Unsafe.dll</HintPath>
</Reference>
<Reference Include="System.Text.Encoding.CodePages, Version=4.1.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<HintPath>..\packages\System.Text.Encoding.CodePages.4.5.0\lib\net461\System.Text.Encoding.CodePages.dll</HintPath>
</Reference>
<Reference Include="System.Windows.Interactivity, Version=4.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL"> <Reference Include="System.Windows.Interactivity, Version=4.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<HintPath>..\packages\MahApps.Metro.1.2.4.0\lib\net45\System.Windows.Interactivity.dll</HintPath> <HintPath>..\packages\MahApps.Metro.1.2.4.0\lib\net45\System.Windows.Interactivity.dll</HintPath>
<Private>True</Private> <Private>True</Private>

Просмотреть файл

@ -6,7 +6,7 @@
</sectionGroup> </sectionGroup>
</configSections> </configSections>
<startup> <startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5" /> <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6.1" />
</startup> </startup>
<userSettings> <userSettings>
<Samples.Properties.Settings> <Samples.Properties.Settings>
@ -33,6 +33,10 @@
<assemblyIdentity name="System.Windows.Interactivity" publicKeyToken="31bf3856ad364e35" culture="neutral" /> <assemblyIdentity name="System.Windows.Interactivity" publicKeyToken="31bf3856ad364e35" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.5.0.0" newVersion="4.5.0.0" /> <bindingRedirect oldVersion="0.0.0.0-4.5.0.0" newVersion="4.5.0.0" />
</dependentAssembly> </dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="System.Text.Encoding.CodePages" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.1.1.0" newVersion="4.1.1.0" />
</dependentAssembly>
</assemblyBinding> </assemblyBinding>
</runtime> </runtime>
</configuration> </configuration>

Просмотреть файл

@ -1,15 +1,15 @@
//------------------------------------------------------------------------------ //------------------------------------------------------------------------------
// <auto-generated> // <auto-generated>
// This code was generated by a tool. // This code was generated by a tool.
// Runtime Version:4.0.30319.18033 // Runtime Version:4.0.30319.42000
// //
// Changes to this file may cause incorrect behavior and will be lost if // Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated. // the code is regenerated.
// </auto-generated> // </auto-generated>
//------------------------------------------------------------------------------ //------------------------------------------------------------------------------
namespace Samples.Properties namespace Samples.Properties {
{ using System;
/// <summary> /// <summary>
@ -19,31 +19,26 @@ namespace Samples.Properties
// class via a tool like ResGen or Visual Studio. // class via a tool like ResGen or Visual Studio.
// To add or remove a member, edit your .ResX file then rerun ResGen // To add or remove a member, edit your .ResX file then rerun ResGen
// with the /str option, or rebuild your VS project. // with the /str option, or rebuild your VS project.
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "15.0.0.0")]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
internal class Resources internal class Resources {
{
private static global::System.Resources.ResourceManager resourceMan; private static global::System.Resources.ResourceManager resourceMan;
private static global::System.Globalization.CultureInfo resourceCulture; private static global::System.Globalization.CultureInfo resourceCulture;
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
internal Resources() internal Resources() {
{
} }
/// <summary> /// <summary>
/// Returns the cached ResourceManager instance used by this class. /// Returns the cached ResourceManager instance used by this class.
/// </summary> /// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Resources.ResourceManager ResourceManager internal static global::System.Resources.ResourceManager ResourceManager {
{ get {
get if (object.ReferenceEquals(resourceMan, null)) {
{
if ((resourceMan == null))
{
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("Samples.Properties.Resources", typeof(Resources).Assembly); global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("Samples.Properties.Resources", typeof(Resources).Assembly);
resourceMan = temp; resourceMan = temp;
} }
@ -56,14 +51,11 @@ namespace Samples.Properties
/// resource lookups using this strongly typed resource class. /// resource lookups using this strongly typed resource class.
/// </summary> /// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Globalization.CultureInfo Culture internal static global::System.Globalization.CultureInfo Culture {
{ get {
get
{
return resourceCulture; return resourceCulture;
} }
set set {
{
resourceCulture = value; resourceCulture = value;
} }
} }

Просмотреть файл

@ -1,7 +1,7 @@
//------------------------------------------------------------------------------ //------------------------------------------------------------------------------
// <auto-generated> // <auto-generated>
// This code was generated by a tool. // This code was generated by a tool.
// Runtime Version:4.0.30319.18046 // Runtime Version:4.0.30319.42000
// //
// Changes to this file may cause incorrect behavior and will be lost if // Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated. // the code is regenerated.
@ -12,7 +12,7 @@ namespace Samples.Properties {
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "11.0.0.0")] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "15.9.0.0")]
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase { internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase {
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));

Просмотреть файл

@ -1,6 +1,6 @@
namespace Samples.ViewModels namespace Samples.ViewModels
{ {
using AngleSharp.Dom.Css; using AngleSharp.Css.Dom;
using System; using System;
using System.Collections.ObjectModel; using System.Collections.ObjectModel;

Просмотреть файл

@ -1,7 +1,10 @@
namespace Samples.ViewModels namespace Samples.ViewModels
{ {
using AngleSharp; using AngleSharp;
using AngleSharp.Css.Dom.Events;
using AngleSharp.Dom;
using AngleSharp.Dom.Events; using AngleSharp.Dom.Events;
using AngleSharp.Html.Dom.Events;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Collections.ObjectModel; using System.Collections.ObjectModel;
@ -34,15 +37,13 @@
private void Register<T>(Action<T> listener) private void Register<T>(Action<T> listener)
where T : Event where T : Event
{ {
_context.ParseError += (obj, ev) => _context.AddEventListener(EventNames.Error, (obj, ev) =>
{ {
var data = ev as T; if (ev is T data)
if (data != null)
{ {
listener.Invoke(data); listener.Invoke(data);
} }
}; });
} }
public void Reset() public void Reset()

Просмотреть файл

@ -1,6 +1,7 @@
namespace Samples.ViewModels namespace Samples.ViewModels
{ {
using AngleSharp; using AngleSharp;
using AngleSharp.Io;
using System; using System;
using System.Threading; using System.Threading;
using System.Threading.Tasks; using System.Threading.Tasks;
@ -38,11 +39,15 @@
public MainViewModel() public MainViewModel()
{ {
var config = Configuration.Default.WithCss().WithRequesters(setup => var config = Configuration.Default
{ .WithCss()
setup.IsNavigationEnabled = true; .WithCookies()
setup.IsResourceLoadingEnabled = true; .WithJs()
}).WithJavaScript(); .WithDefaultLoader(new LoaderOptions
{
IsNavigationDisabled = true,
IsResourceLoadingEnabled = true,
});
_context = BrowsingContext.New(config); _context = BrowsingContext.New(config);
_profiler = new ProfilerViewModel(_context); _profiler = new ProfilerViewModel(_context);
_errors = new ErrorsViewModel(_context); _errors = new ErrorsViewModel(_context);

Просмотреть файл

@ -1,7 +1,10 @@
namespace Samples.ViewModels namespace Samples.ViewModels
{ {
using AngleSharp; using AngleSharp;
using AngleSharp.Css.Dom.Events;
using AngleSharp.Dom;
using AngleSharp.Dom.Events; using AngleSharp.Dom.Events;
using AngleSharp.Html.Dom.Events;
using OxyPlot; using OxyPlot;
using OxyPlot.Axes; using OxyPlot.Axes;
using OxyPlot.Series; using OxyPlot.Series;
@ -22,10 +25,10 @@
_tracker = new Dictionary<Object, TimeSpan>(); _tracker = new Dictionary<Object, TimeSpan>();
_context = context; _context = context;
_model = CreateModel(); _model = CreateModel();
_context.Parsing += TrackParsing; _context.AddEventListener(EventNames.Parsing, TrackParsing);
_context.Parsed += TrackParsed; _context.AddEventListener(EventNames.Parsed, TrackParsed);
_context.Requesting += TrackRequesting; _context.AddEventListener(EventNames.Requesting, TrackRequesting);
_context.Requested += TrackRequested; _context.AddEventListener(EventNames.Requested, TrackRequested);
} }
private static PlotModel CreateModel() private static PlotModel CreateModel()
@ -91,14 +94,11 @@
private void TrackParsing(Object sender, Event ev) private void TrackParsing(Object sender, Event ev)
{ {
var html = ev as HtmlParseEvent; if (ev is HtmlParseEvent html)
var css = ev as CssParseEvent;
if (html != null)
{ {
_tracker.Add(html.Document, _time.Elapsed); _tracker.Add(html.Document, _time.Elapsed);
} }
else if (css != null) else if (ev is CssParseEvent css)
{ {
_tracker.Add(css.StyleSheet, _time.Elapsed); _tracker.Add(css.StyleSheet, _time.Elapsed);
} }
@ -106,20 +106,16 @@
private void TrackParsed(Object sender, Event ev) private void TrackParsed(Object sender, Event ev)
{ {
var html = ev as HtmlParseEvent; if (ev is HtmlParseEvent html && _tracker.TryGetValue(html.Document, out var startHtml))
var css = ev as CssParseEvent;
var start = default(TimeSpan);
if (html != null && _tracker.TryGetValue(html.Document, out start))
{ {
var document = html.Document; var document = html.Document;
AddItem("Parse HTML " + document.Url, OxyColors.Orange, start, _time.Elapsed); AddItem("Parse HTML " + document.Url, OxyColors.Orange, startHtml, _time.Elapsed);
_tracker.Remove(document); _tracker.Remove(document);
} }
else if (css != null && _tracker.TryGetValue(css.StyleSheet, out start)) else if (ev is CssParseEvent css && _tracker.TryGetValue(css.StyleSheet, out var startCss))
{ {
var styleSheet = css.StyleSheet; var styleSheet = css.StyleSheet;
AddItem("Parse CSS " + styleSheet.Href, OxyColors.Violet, start, _time.Elapsed); AddItem("Parse CSS " + styleSheet.Href, OxyColors.Violet, startCss, _time.Elapsed);
_tracker.Remove(styleSheet); _tracker.Remove(styleSheet);
} }
} }

Просмотреть файл

@ -1,7 +1,7 @@
namespace Samples.ViewModels namespace Samples.ViewModels
{ {
using AngleSharp.Dom; using AngleSharp.Dom;
using AngleSharp.Extensions; using AngleSharp.Js;
using Jint.Runtime; using Jint.Runtime;
using System; using System;
using System.Collections.ObjectModel; using System.Collections.ObjectModel;

Просмотреть файл

@ -1,7 +1,8 @@
namespace Samples.ViewModels namespace Samples.ViewModels
{ {
using AngleSharp.Css.Dom;
using AngleSharp.Css.Dom.Events;
using AngleSharp.Dom; using AngleSharp.Dom;
using AngleSharp.Dom.Css;
using AngleSharp.Dom.Events; using AngleSharp.Dom.Events;
using System; using System;
using System.Collections.ObjectModel; using System.Collections.ObjectModel;
@ -37,9 +38,8 @@
_selected = value; _selected = value;
RaisePropertyChanged(); RaisePropertyChanged();
_tree.Clear(); _tree.Clear();
var sheet = _selected as ICssStyleSheet;
if (sheet != null) if (_selected is ICssStyleSheet sheet)
{ {
for (int i = 0; i < sheet.Rules.Length; i++) for (int i = 0; i < sheet.Rules.Length; i++)
{ {
@ -57,7 +57,7 @@
{ {
if (_document != null) if (_document != null)
{ {
_document.Context.Parsed -= ParseEnded; _document.Context.RemoveEventListener(EventNames.Parsed, ParseEnded);
} }
_document = value; _document = value;
@ -68,16 +68,14 @@
_source.Add(sheet); _source.Add(sheet);
} }
_document.Context.Parsed += ParseEnded; _document.Context.AddEventListener(EventNames.Parsed, ParseEnded);
Selected = null; Selected = null;
} }
} }
private void ParseEnded(Object sender, Event ev) private void ParseEnded(Object sender, Event ev)
{ {
var data = ev as CssParseEvent; if (ev is CssParseEvent data)
if (data != null)
{ {
App.Current.Dispatcher.Invoke(() => _source.Add(data.StyleSheet)); App.Current.Dispatcher.Invoke(() => _source.Add(data.StyleSheet));
} }

Просмотреть файл

@ -104,7 +104,7 @@
if (data.Length == 0) if (data.Length == 0)
return null; return null;
return new TreeNodeViewModel { Value = HtmlMarkupFormatter.Instance.Text(text.Data), Foreground = Brushes.SteelBlue }; return new TreeNodeViewModel { Value = HtmlMarkupFormatter.Instance.Text(text), Foreground = Brushes.SteelBlue };
} }
private static TreeNodeViewModel Create(IElement node) private static TreeNodeViewModel Create(IElement node)

Просмотреть файл

@ -1,12 +1,16 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<packages> <packages>
<package id="AngleSharp" version="0.9.9" targetFramework="net45" /> <package id="AngleSharp" version="0.12.1" targetFramework="net461" />
<package id="AngleSharp.Io" version="0.3.2" targetFramework="net45" /> <package id="AngleSharp.Css" version="0.12.1" targetFramework="net461" />
<package id="AngleSharp.Scripting.JavaScript" version="0.5.0" targetFramework="net45" /> <package id="AngleSharp.Io" version="0.12.1" targetFramework="net461" />
<package id="Jint" version="2.9.1" targetFramework="net45" /> <package id="AngleSharp.Js" version="0.12.1" targetFramework="net461" />
<package id="AngleSharp.Xml" version="0.12.1" targetFramework="net461" />
<package id="jint" version="2.10.4" targetFramework="net461" />
<package id="MahApps.Metro" version="1.2.4.0" targetFramework="net45" /> <package id="MahApps.Metro" version="1.2.4.0" targetFramework="net45" />
<package id="OxyPlot.Core" version="2015.1.943-alpha" targetFramework="net45" /> <package id="OxyPlot.Core" version="2015.1.943-alpha" targetFramework="net45" />
<package id="OxyPlot.Wpf" version="2015.1.943-alpha" targetFramework="net45" /> <package id="OxyPlot.Wpf" version="2015.1.943-alpha" targetFramework="net45" />
<package id="Simple.Wpf.Terminal" version="1.35.0.0" targetFramework="net45" /> <package id="Simple.Wpf.Terminal" version="1.35.0.0" targetFramework="net45" />
<package id="System.Runtime.CompilerServices.Unsafe" version="4.5.0" targetFramework="net461" />
<package id="System.Text.Encoding.CodePages" version="4.5.0" targetFramework="net461" />
<package id="System.Windows.Interactivity.WPF" version="2.0.20525" targetFramework="net45" /> <package id="System.Windows.Interactivity.WPF" version="2.0.20525" targetFramework="net45" />
</packages> </packages>

Просмотреть файл

@ -9,10 +9,11 @@
<AppDesignerFolder>Properties</AppDesignerFolder> <AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>AngleSharp.Samples.Demos</RootNamespace> <RootNamespace>AngleSharp.Samples.Demos</RootNamespace>
<AssemblyName>AngleSharp.Samples.Demos</AssemblyName> <AssemblyName>AngleSharp.Samples.Demos</AssemblyName>
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion> <TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment> <FileAlignment>512</FileAlignment>
<NuGetPackageImportStamp>ba6035cc</NuGetPackageImportStamp> <NuGetPackageImportStamp>ba6035cc</NuGetPackageImportStamp>
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects> <AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
<TargetFrameworkProfile />
</PropertyGroup> </PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget> <PlatformTarget>AnyCPU</PlatformTarget>
@ -34,21 +35,28 @@
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>
</PropertyGroup> </PropertyGroup>
<ItemGroup> <ItemGroup>
<Reference Include="AngleSharp, Version=0.9.9.0, Culture=neutral, PublicKeyToken=e83494dcdc6d31ea, processorArchitecture=MSIL"> <Reference Include="AngleSharp, Version=0.12.1.0, Culture=neutral, PublicKeyToken=e83494dcdc6d31ea, processorArchitecture=MSIL">
<HintPath>..\packages\AngleSharp.0.9.9\lib\net45\AngleSharp.dll</HintPath> <HintPath>..\packages\AngleSharp.0.12.1\lib\net46\AngleSharp.dll</HintPath>
<Private>True</Private>
</Reference> </Reference>
<Reference Include="AngleSharp.Scripting.JavaScript, Version=0.5.0.0, Culture=neutral, processorArchitecture=MSIL"> <Reference Include="AngleSharp.Css, Version=0.12.1.0, Culture=neutral, PublicKeyToken=e83494dcdc6d31ea, processorArchitecture=MSIL">
<HintPath>..\packages\AngleSharp.Scripting.JavaScript.0.5.0\lib\portable-windows8+net45+windowsphone8+wpa+monoandroid+monotouch\AngleSharp.Scripting.JavaScript.dll</HintPath> <HintPath>..\packages\AngleSharp.Css.0.12.1\lib\net46\AngleSharp.Css.dll</HintPath>
<Private>True</Private>
</Reference> </Reference>
<Reference Include="Jint, Version=2.9.1.0, Culture=neutral, PublicKeyToken=2e92ba9c8d81157f, processorArchitecture=MSIL"> <Reference Include="AngleSharp.Js, Version=0.12.1.0, Culture=neutral, PublicKeyToken=e83494dcdc6d31ea, processorArchitecture=MSIL">
<HintPath>..\packages\Jint.2.9.1\lib\portable-net40+sl50+win+WindowsPhoneApp81+wp80\Jint.dll</HintPath> <HintPath>..\packages\AngleSharp.Js.0.12.1\lib\net46\AngleSharp.Js.dll</HintPath>
<Private>True</Private> </Reference>
<Reference Include="jint, Version=2.10.4.0, Culture=neutral, PublicKeyToken=2e92ba9c8d81157f, processorArchitecture=MSIL">
<HintPath>..\packages\jint.2.10.4\lib\net45\jint.dll</HintPath>
</Reference> </Reference>
<Reference Include="System" /> <Reference Include="System" />
<Reference Include="System.Core" /> <Reference Include="System.Core" />
<Reference Include="System.Diagnostics.Contracts" />
<Reference Include="System.Net" /> <Reference Include="System.Net" />
<Reference Include="System.Runtime.CompilerServices.Unsafe, Version=4.0.4.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<HintPath>..\packages\System.Runtime.CompilerServices.Unsafe.4.5.0\lib\netstandard2.0\System.Runtime.CompilerServices.Unsafe.dll</HintPath>
</Reference>
<Reference Include="System.Text.Encoding.CodePages, Version=4.0.2.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<HintPath>..\packages\System.Text.Encoding.CodePages.4.5.0\lib\net46\System.Text.Encoding.CodePages.dll</HintPath>
</Reference>
<Reference Include="System.Xml.Linq" /> <Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" /> <Reference Include="System.Data.DataSetExtensions" />
<Reference Include="Microsoft.CSharp" /> <Reference Include="Microsoft.CSharp" />

Просмотреть файл

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<configuration> <configuration>
<startup> <startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5" /> <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6.1" />
</startup> </startup>
<runtime> <runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
@ -11,7 +11,7 @@
</dependentAssembly> </dependentAssembly>
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="AngleSharp" publicKeyToken="e83494dcdc6d31ea" culture="neutral" /> <assemblyIdentity name="AngleSharp" publicKeyToken="e83494dcdc6d31ea" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-0.9.9.0" newVersion="0.9.9.0" /> <bindingRedirect oldVersion="0.0.0.0-0.12.1.0" newVersion="0.12.1.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
</runtime> </runtime>

Просмотреть файл

@ -1,7 +1,7 @@
namespace AngleSharp.Samples.Demos.Snippets namespace AngleSharp.Samples.Demos.Snippets
{ {
using AngleSharp.Dom.Html; using AngleSharp.Dom;
using AngleSharp.Extensions; using AngleSharp.Html.Dom;
using System; using System;
using System.Threading.Tasks; using System.Threading.Tasks;

Просмотреть файл

@ -1,8 +1,7 @@
namespace AngleSharp.Samples.Demos.Snippets namespace AngleSharp.Samples.Demos.Snippets
{ {
using AngleSharp.Dom; using AngleSharp.Dom;
using AngleSharp.Dom.Html; using AngleSharp.Html.Dom;
using AngleSharp.Extensions;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Linq; using System.Linq;

Просмотреть файл

@ -8,8 +8,9 @@
public async Task Run() public async Task Run()
{ {
// We require a custom configuration with JavaScript // We require a custom configuration with JavaScript
var config = Configuration.Default.WithJavaScript(). var config = Configuration.Default
WithConsoleLogger(context => new StandardConsoleLogger()); .WithJs()
.WithConsoleLogger(context => new StandardConsoleLogger());
// This is our sample source, we will trigger the load event // This is our sample source, we will trigger the load event
var source = @"<!doctype html> var source = @"<!doctype html>

Просмотреть файл

@ -9,7 +9,7 @@
{ {
//We require a custom configuration with JavaScript and CSS //We require a custom configuration with JavaScript and CSS
var config = Configuration.Default var config = Configuration.Default
.WithJavaScript() .WithJs()
.WithCss(); .WithCss();
// This is our sample source, we will do some DOM manipulation // This is our sample source, we will do some DOM manipulation

Просмотреть файл

@ -10,7 +10,7 @@
{ {
// We require a custom configuration with JavaScript, CSS and the default loader // We require a custom configuration with JavaScript, CSS and the default loader
var config = Configuration.Default var config = Configuration.Default
.WithJavaScript() .WithJs()
.WithCss() .WithCss()
.WithDefaultLoader(); .WithDefaultLoader();

Просмотреть файл

@ -8,8 +8,9 @@
public async Task Run() public async Task Run()
{ {
// We require a custom configuration with JavaScript // We require a custom configuration with JavaScript
var config = Configuration.Default.WithJavaScript(). var config = Configuration.Default
WithConsoleLogger(context => new StandardConsoleLogger()); .WithJs()
.WithConsoleLogger(context => new StandardConsoleLogger());
// This is our sample source, we will trigger the load event // This is our sample source, we will trigger the load event
var source = @"<!doctype html> var source = @"<!doctype html>

Просмотреть файл

@ -8,7 +8,7 @@
public async Task Run() public async Task Run()
{ {
// We require a custom configuration with JavaScript // We require a custom configuration with JavaScript
var config = Configuration.Default.WithJavaScript(); var config = Configuration.Default.WithJs();
// This is our sample source, we will set the title and write on the document // This is our sample source, we will set the title and write on the document
var source = @"<!doctype html> var source = @"<!doctype html>

Просмотреть файл

@ -1,6 +1,6 @@
namespace AngleSharp.Samples.Demos.Snippets namespace AngleSharp.Samples.Demos.Snippets
{ {
using AngleSharp.Extensions; using AngleSharp.Dom;
using System; using System;
using System.Threading.Tasks; using System.Threading.Tasks;

Просмотреть файл

@ -1,6 +1,6 @@
namespace AngleSharp.Samples.Demos.Snippets namespace AngleSharp.Samples.Demos.Snippets
{ {
using AngleSharp.Extensions; using AngleSharp.Dom;
using System; using System;
using System.Linq; using System.Linq;
using System.Threading.Tasks; using System.Threading.Tasks;

Просмотреть файл

@ -1,6 +1,6 @@
namespace AngleSharp.Samples.Demos namespace AngleSharp.Samples.Demos
{ {
using AngleSharp.Scripting.JavaScript.Services; using AngleSharp.Js;
using System; using System;
using System.Linq; using System.Linq;

Просмотреть файл

@ -1,6 +1,9 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<packages> <packages>
<package id="AngleSharp" version="0.9.9" targetFramework="net45" /> <package id="AngleSharp" version="0.12.1" targetFramework="net461" />
<package id="AngleSharp.Scripting.JavaScript" version="0.5.0" targetFramework="net45" /> <package id="AngleSharp.Css" version="0.12.1" targetFramework="net461" />
<package id="Jint" version="2.9.1" targetFramework="net45" /> <package id="AngleSharp.Js" version="0.12.1" targetFramework="net461" />
<package id="jint" version="2.10.4" targetFramework="net461" />
<package id="System.Runtime.CompilerServices.Unsafe" version="4.5.0" targetFramework="net461" />
<package id="System.Text.Encoding.CodePages" version="4.5.0" targetFramework="net46" requireReinstallation="true" />
</packages> </packages>

Просмотреть файл

@ -1,7 +1,7 @@
 
Microsoft Visual Studio Solution File, Format Version 12.00 Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 14 # Visual Studio 15
VisualStudioVersion = 14.0.22310.1 VisualStudioVersion = 15.0.28307.572
MinimumVisualStudioVersion = 10.0.40219.1 MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AngleSharp.Samples.App", "AngleSharp.Samples.App\AngleSharp.Samples.App.csproj", "{DA318620-F6B5-4DFA-B012-38F06141A2DD}" Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AngleSharp.Samples.App", "AngleSharp.Samples.App\AngleSharp.Samples.App.csproj", "{DA318620-F6B5-4DFA-B012-38F06141A2DD}"
EndProject EndProject
@ -25,4 +25,7 @@ Global
GlobalSection(SolutionProperties) = preSolution GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE HideSolutionNode = FALSE
EndGlobalSection EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {0DF14775-AB02-41C1-B392-62858D096DB1}
EndGlobalSection
EndGlobal EndGlobal