提交 d52d68ef 编写于 作者: H Huajiang Wei

Add project files.

上级 65f324b2
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
namespace ScratchNet
{
public class ExecutionEngine : IExecutionEngine
{
//List<Class> Classes { get; set; }
List<Instance> Instances { get; set; }
public ExecutionEnvironment BaseEnvironment { get; internal set; }
List<RunThread> Threads = new List<RunThread>();
Dictionary<RunThread, DateTime> ThreadNextRun = new Dictionary<RunThread, DateTime>();
Thread RunThread;
bool requestStop = false;
AutoResetEvent resetEvent = new AutoResetEvent(true);
public ExecutionEngine()
{
Instances = new List<Instance>();
BaseEnvironment = new ExecutionEnvironment(this);
Threads = new List<RunThread>();
}
public void AddInstance(Instance inst)
{
Lock();
Instances.Add(inst);
inst.States.Clear();
foreach (Variable v in inst.Class.Variables)
{
inst.States.Add(v.Name, v.Value);
}
UnLock();
}
public Instance CreateInstance(Class c)
{
Lock();
Instance inst = new Instance(c) ;
Instances.Add(inst);
foreach (Variable v in inst.Class.Variables)
{
inst.States.Add(v.Name, v.Value);
}
UnLock();
return inst;
}
public void Start()
{
requestStop = false;
RunThread = new Thread(new ThreadStart(Run));
RunThread.Start();
}
public void Stop()
{
requestStop = true;
if(RunThread!=null)
RunThread.Join();
}
private void Run()
{
Nullable<DateTime> nextRun = DateTime.Now.AddMilliseconds(10);
while (!requestStop)
{
Lock();
foreach (RunThread t in Threads)
{
if (ThreadNextRun.ContainsKey(t))
{
DateTime d = ThreadNextRun[t];
if (d < DateTime.Now)
{
ThreadNextRun.Remove(t);
nextRun = null;
}
else
{
if (nextRun != null && nextRun > d)
nextRun = d;
continue;
}
}
else
{
nextRun = null;
}
if (!t.IsCompleted)
{
Nullable<DateTime> next = t.Step();
if (next != null)
{
ThreadNextRun.Add(t, next.Value);
if (nextRun!=null && next < nextRun)
nextRun = next;
}
else
{
nextRun = null;
}
}
}
foreach (RunThread t in Threads)
{
if(t.IsCompleted)
{
Threads.Remove(t);
break;
}
}
UnLock();
if (nextRun != null)
{
Thread.Sleep(10);
}
}
}
public void SendEvent(Event e)
{
Lock();
foreach (Instance inst in Instances)
{
foreach (EventHandler func in inst.Class.Handlers)
{
if (func.IsProcessEvent(e))
{
Threads.Add(new RunThread(inst, func, e,BaseEnvironment));
}
}
}
UnLock();
}
public void SendEventAsych(Event e)
{
new Thread(new ThreadStart(() =>
{
SendEvent(e);
})).Start();
}
public void SendEventAsych(Instance inst, Event e)
{
new Thread(new ThreadStart(() =>
{
SendEvent(inst, e);
})).Start();
}
public void SendEvent(Instance inst, Event e){
Lock();
foreach (EventHandler func in inst.Class.Handlers)
{
if (func.IsProcessEvent(e))
{
Threads.Add(new RunThread(inst, func, e, BaseEnvironment));
}
}
UnLock();
}
public void Lock()
{
resetEvent.WaitOne();
}
public void UnLock()
{
resetEvent.Set();
}
}
}
<?xml version="1.0" encoding="utf-8"?>
<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')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{86044555-48E3-4128-92EE-59F55F9D8B53}</ProjectGuid>
<OutputType>Library</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>ScratchNet</RootNamespace>
<AssemblyName>ExecutionEngine</AssemblyName>
<TargetFrameworkVersion>v4.5.1</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<TargetFrameworkProfile />
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Data" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="ExecutionEngine.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="Thread.cs" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\ScriptEngine\ScriptEngine.csproj">
<Project>{9efe2134-8015-4957-a9e1-f7d2fbb4cda7}</Project>
<Name>ScriptEngine</Name>
</ProjectReference>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- 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">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>
\ No newline at end of file
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("ExecutionEngine")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Microsoft")]
[assembly: AssemblyProduct("ExecutionEngine")]
[assembly: AssemblyCopyright("Copyright © Microsoft 2017")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("cbc3a394-17fc-41a4-b58d-982c19713ce9")]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ScratchNet
{
public class RunThread
{
public Instance Instance { get; internal set; }
public ExecutionEnvironment Environment { get; internal set; }
public bool IsStarted { get; internal set; }
public bool IsCompleted { get; internal set; }
Stack<ExecStackItem> Stacks { get; set; }
public RunThread(Instance instance, EventHandler fun, Event e, ExecutionEnvironment environment)
{
Instance = instance;
fun.Event = e;
IsStarted = false;
IsCompleted = false;
Stacks = new Stack<ExecStackItem>();
Execution2 exe = fun as Execution2;
Environment = new ExecutionEnvironment(environment, instance);
ExecutionEnvironment env= exe.StartCall(Environment);
Stacks.Push(new ExecStackItem(exe, FinishCallback, env, Environment));
}
Nullable<DateTime> FinishCallback(object value, object exception, ExecutionEnvironment e)
{
IsCompleted = true;
return null;
}
public Nullable<DateTime> Step()
{
IsStarted = true;
if (Stacks.Count == 0)
{
IsCompleted = true;
return null;
}
ExecStackItem current = Stacks.Peek();
if (!current.HasMoreExecution)
{
return EndCall(current);
}
object execution;
ExecutionCallback callback;
current.HasMoreExecution = (current.Execution.PopStack(out execution, out callback, current.Environment));
//Console.WriteLine("current is " + execution);
if (execution is Execution2)
{
Execution2 exec = execution as Execution2;
ExecutionEnvironment e= exec.StartCall(current.Environment);
Stacks.Push(new ExecStackItem(exec, callback, e, current.Environment));
}
else
{
return EndCall(current);
}
return null;
}
void HandleException(Exception e)
{
Console.WriteLine("Exception occur");
Console.WriteLine(e.Message);
Console.WriteLine(e.StackTrace);
ExecutionCallback callback = null;
while (Stacks.Count > 0)
{
ExecStackItem item = Stacks.Peek();
bool handle = false;
try
{
handle=item.Execution.HandleException(e);
callback(null, e, item.Previous);
}
catch (Exception excption) { }
if (handle)
{
return;
}
else
{
Stacks.Pop();
callback = item.Callback;
}
}
Console.WriteLine("Exception occur and no try block, so exit");
//TO DO terminate execution
}
Nullable<DateTime> ExecCallBack(ExecutionCallback callback, object value, object exception, ExecutionEnvironment env)
{
Exception ex = null;
try
{
return callback(value, exception, env);
}
catch (Exception e) {
ex = e;
}
if(ex!=null)
HandleException(ex);
return null;
}
Nullable<DateTime> EndCall(ExecStackItem current)
{
Exception ex = null;
Completion retVal = null;
try
{
retVal = current.Execution.EndCall(current.Environment);
}
catch (Exception e)
{
ex = e;
}
if (ex != null)
{
HandleException(ex);
return null;
}
Stacks.Pop();
if (current.Execution is ReturnStatement)
{
ExecStackItem func = Stacks.Peek();
while (!(func.Execution is Function))
{
Stacks.Pop();
func = Stacks.Peek();
}
ExecCallBack(func.Callback,retVal.ReturnValue, null, func.Previous);
return null;
}
else if (current.Execution is BreakStatement)
{
ExecStackItem func = Stacks.Peek();
while (!(func.Execution is Loop))
{
Stacks.Pop();
func = Stacks.Peek();
if (Stacks.Count == 1)
break;
}
func = Stacks.Pop();
if(!(func.Execution is Loop))
{
HandleException(new Exception("Break must be in a loop"));
return null;
}
ExecCallBack(func.Callback, retVal.ReturnValue, null, func.Previous);
return null;
}
else if (current.Execution is ContinueStatement)
{
ExecStackItem func = Stacks.Peek();
ExecStackItem last=null;
ExecutionCallback callBack = null;
while (!(func.Execution is Loop))
{
callBack = func.Callback;
last = func;
Stacks.Pop();
func = Stacks.Peek();
if (Stacks.Count == 1)
break;
}
if (!(func.Execution is Loop))
{
HandleException(new Exception("continue must be in a loop"));
return null;
}
return ExecCallBack(last.Callback, retVal.ReturnValue, null, last.Environment);
}
return ExecCallBack(current.Callback, retVal.ReturnValue, null, current.Previous);
}
}
class ExecStackItem
{
public ExecStackItem(Execution2 exec, ExecutionCallback callback, ExecutionEnvironment env, ExecutionEnvironment preEnv)
{
Execution = exec;
Callback = callback;
Environment = env;
HasMoreExecution = true;
Previous = preEnv;
}
public Execution2 Execution { get; set; }
public ExecutionCallback Callback { get; set; }
public ExecutionEnvironment Environment { get; set; }
public ExecutionEnvironment Previous { get; set; }
public bool HasMoreExecution { get; set; }
}
}
using System;
namespace FontAwesome.WPF
{
/// <summary>
/// Represents the category of a fontawesome icon.
/// </summary>
[AttributeUsage(AttributeTargets.All, AllowMultiple = true, Inherited = false)]
public class IconCategoryAttribute
: Attribute
{
/// <summary>
/// Gets or sets the category of the icon.
/// </summary>
public string Category { get; set; }
/// <summary>
/// Initializes a new instance of the FontAwesome.WPF.IconCategoryAttribute class.
/// </summary>
/// <param name="category">The icon category.</param>
public IconCategoryAttribute(string category)
{
Category = category;
}
}
/// <summary>
/// Represents the field is an alias of another icon.
/// </summary>
[AttributeUsage(AttributeTargets.All, AllowMultiple = false, Inherited = false)]
public class IconAliasAttribute
: Attribute
{ }
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Media;
using System.Windows.Media.Animation;
namespace FontAwesome.WPF
{
/// <summary>
/// Control extensions
/// </summary>
public static class ControlExtensions
{
/// <summary>
/// The key used for storing the spinner Storyboard.
/// </summary>
private static readonly string SpinnerStoryBoardName = String.Format("{0}Spinner", typeof(FontAwesome).Name);
/// <summary>
/// Start the spinning animation
/// </summary>
/// <typeparam name="T">FrameworkElement and ISpinable</typeparam>
/// <param name="control">Control to apply the rotation </param>
public static void BeginSpin<T>(this T control)
where T : FrameworkElement, ISpinable
{
if (!(control.RenderTransform is TransformGroup
&& ((TransformGroup)control.RenderTransform).Children.OfType<RotateTransform>().Any()))
{
var transformGroup = new TransformGroup();
transformGroup.Children.Add(new RotateTransform(0.0));
control.RenderTransform = transformGroup;
control.RenderTransformOrigin = new Point(0.5, 0.5);
}
var storyboard = new Storyboard();
var animation = new DoubleAnimation
{
From = 0,
To = 360,
AutoReverse = false,
RepeatBehavior = RepeatBehavior.Forever,
Duration = new Duration(TimeSpan.FromSeconds(1))
};
storyboard.Children.Add(animation);
Storyboard.SetTarget(animation, control);
Storyboard.SetTargetProperty(animation,
new PropertyPath("(0).(1)[0].(2)", UIElement.RenderTransformProperty,
TransformGroup.ChildrenProperty, RotateTransform.AngleProperty));
storyboard.Begin();
control.Resources.Add(SpinnerStoryBoardName, storyboard);
}
/// <summary>
/// Stop the spinning animation
/// </summary>
/// <typeparam name="T">FrameworkElement and ISpinable</typeparam>
/// <param name="control">Control to stop the rotation.</param>
public static void StopSpin<T>(this T control)
where T : FrameworkElement, ISpinable
{
var storyboard = control.Resources[SpinnerStoryBoardName] as Storyboard;
if (storyboard == null) return;
storyboard.Stop();
control.Resources.Remove(SpinnerStoryBoardName);
}
}
}
<?xml version="1.0" encoding="utf-8"?>
<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')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{7006AC9F-D218-4D7B-98EB-5D2D91F69C57}</ProjectGuid>
<OutputType>Library</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>FontAwesome.WPF</RootNamespace>
<AssemblyName>FontAwesome.WPF</AssemblyName>
<TargetFrameworkVersion>v4.5.1</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<TargetFrameworkProfile>
</TargetFrameworkProfile>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<DocumentationFile>bin\Debug\FontAwesome.WPF.xml</DocumentationFile>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<DocumentationFile>bin\Release\FontAwesome.WPF.xml</DocumentationFile>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<ItemGroup>
<Reference Include="PresentationCore">
<HintPath>..\..\..\..\..\..\..\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5\PresentationCore.dll</HintPath>
</Reference>
<Reference Include="PresentationFramework">
<HintPath>..\..\..\..\..\..\..\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5\PresentationFramework.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Xaml" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Data" />
<Reference Include="System.Xml" />
<Reference Include="WindowsBase" />
</ItemGroup>
<ItemGroup>
<Compile Include="ControlExtensions.cs" />
<Compile Include="FontAwesome.cs" />
<Compile Include="FontAwesomeIcon.cs">
<LastGenOutput>FontAwesomeIcon.log</LastGenOutput>
</Compile>
<Compile Include="Attributes.cs" />
<Compile Include="ImageAwesome.cs" />
<Compile Include="ISpinable.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<ItemGroup>
<Service Include="{508349B6-6B84-4DF5-91F0-309BEEBAD82D}" />
</ItemGroup>
<ItemGroup>
<EmbeddedResource Include="FontAwesome.Icon.png" />
</ItemGroup>
<ItemGroup>
<EmbeddedResource Include="ImageAwesome.Icon.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="FontAwesome.otf" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- 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">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>
\ No newline at end of file
using System;
using System.Linq;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Media;
using System.Windows.Media.Animation;
namespace FontAwesome.WPF
{
/// <summary>
/// Provides a lightweight control for displaying a FontAwesome icon as text.
/// </summary>
public class FontAwesome
: TextBlock, ISpinable
{
/// <summary>
/// FontAwesome FontFamily.
/// </summary>
private static readonly FontFamily FontAwesomeFontFamily = new FontFamily(new Uri("pack://application:,,,/FontAwesome.WPF;component/"), "./#FontAwesome");
/// <summary>
/// The key used for storing the spinner Storyboard.
/// </summary>
private static readonly string StoryBoardName = String.Format("{0}-storyboard-spinner", typeof(FontAwesome).Name);
/// <summary>
/// Identifies the FontAwesome.WPF.FontAwesome.Icon dependency property.
/// </summary>
public static readonly DependencyProperty IconProperty =
DependencyProperty.Register("Icon", typeof(FontAwesomeIcon), typeof(FontAwesome), new PropertyMetadata(FontAwesomeIcon.None, OnIconPropertyChanged));
/// <summary>
/// Identifies the FontAwesome.WPF.FontAwesome.Spin dependency property.
/// </summary>
public static readonly DependencyProperty SpinProperty =
DependencyProperty.Register("Spin", typeof(bool), typeof(FontAwesome), new PropertyMetadata(false, OnSpinPropertyChanged));
/// <summary>
/// Gets or sets the FontAwesome icon. Changing this property will cause the icon to be redrawn.
/// </summary>
public FontAwesomeIcon Icon
{
get { return (FontAwesomeIcon)GetValue(IconProperty); }
set { SetValue(IconProperty, value); }
}
/// <summary>
/// Gets or sets the current spin (angle) animation of the icon.
/// </summary>
public bool Spin
{
get { return (bool)GetValue(SpinProperty); }
set { SetValue(SpinProperty, value); }
}
private static void OnIconPropertyChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
{
d.SetValue(FontFamilyProperty, FontAwesomeFontFamily);
d.SetValue(TextAlignmentProperty, TextAlignment.Center);
d.SetValue(TextProperty, char.ConvertFromUtf32((int)e.NewValue));
}
private static void OnSpinPropertyChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
{
var fontAwesome = d as FontAwesome;
if (fontAwesome == null) return;
if((bool)e.NewValue)
fontAwesome.BeginSpin();
else
fontAwesome.StopSpin();
}
}
}
此差异已折叠。
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace FontAwesome.WPF
{
/// <summary>
/// Represents a spinable control
/// </summary>
public interface ISpinable
{
}
}
using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Media.Imaging;
namespace FontAwesome.WPF
{
/// <summary>
/// Represents a control that draws an FontAwesome icon as an image.
/// </summary>
public class ImageAwesome
: Image, ISpinable
{
/// <summary>
/// FontAwesome FontFamily.
/// </summary>
private static readonly FontFamily FontAwesomeFontFamily = new FontFamily(new Uri("pack://application:,,,/FontAwesome.WPF;component/"), "./#FontAwesome");
/// <summary>
/// Typeface used to generate FontAwesome icon.
/// </summary>
private static readonly Typeface FontAwesomeTypeface = new Typeface(FontAwesomeFontFamily, FontStyles.Normal,
FontWeights.Normal, FontStretches.Normal);
/// <summary>
/// Identifies the FontAwesome.WPF.ImageAwesome.Foreground dependency property.
/// </summary>
public static readonly DependencyProperty ForegroundProperty =
DependencyProperty.Register("Foreground", typeof(Brush), typeof(ImageAwesome), new PropertyMetadata(Brushes.Black, OnIconPropertyChanged));
/// <summary>
/// Identifies the FontAwesome.WPF.ImageAwesome.Icon dependency property.
/// </summary>
public static readonly DependencyProperty IconProperty =
DependencyProperty.Register("Icon", typeof(FontAwesomeIcon), typeof(ImageAwesome), new PropertyMetadata(FontAwesomeIcon.None, OnIconPropertyChanged));
/// <summary>
/// Identifies the FontAwesome.WPF.ImageAwesome.Spin dependency property.
/// </summary>
public static readonly DependencyProperty SpinProperty =
DependencyProperty.Register("Spin", typeof(bool), typeof(ImageAwesome), new PropertyMetadata(false, OnSpinPropertyChanged));
/// <summary>
/// Gets or sets the foreground brush of the icon. Changing this property will cause the icon to be redrawn.
/// </summary>
public Brush Foreground
{
get { return (Brush)GetValue(ForegroundProperty); }
set { SetValue(ForegroundProperty, value); }
}
/// <summary>
/// Gets or sets the FontAwesome icon. Changing this property will cause the icon to be redrawn.
/// </summary>
public FontAwesomeIcon Icon
{
get { return (FontAwesomeIcon)GetValue(IconProperty); }
set { SetValue(IconProperty, value); }
}
/// <summary>
/// Gets or sets the current spin (angle) animation of the icon.
/// </summary>
public bool Spin
{
get { return (bool)GetValue(SpinProperty); }
set { SetValue(SpinProperty, value); }
}
private static void OnSpinPropertyChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
{
var imageAwesome = d as ImageAwesome;
if (imageAwesome == null) return;
if((bool)e.NewValue)
imageAwesome.BeginSpin();
else
imageAwesome.StopSpin();
}
private static void OnIconPropertyChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
{
var imageAwesome = d as ImageAwesome;
if (imageAwesome == null) return;
d.SetValue(SourceProperty, CreateImageSource(imageAwesome.Icon, imageAwesome.Foreground));
}
/// <summary>
/// Creates a new System.Windows.Media.ImageSource of a specified FontAwesomeIcon and foreground System.Windows.Media.Brush.
/// </summary>
/// <param name="icon">The FontAwesome icon to be drawn.</param>
/// <param name="foregroundBrush">The System.Windows.Media.Brush to be used as the foreground.</param>
/// <returns>A new System.Windows.Media.ImageSource</returns>
public static ImageSource CreateImageSource(FontAwesomeIcon icon, Brush foregroundBrush)
{
var charIcon = char.ConvertFromUtf32((int)icon);
var visual = new DrawingVisual();
using (var drawingContext = visual.RenderOpen())
{
drawingContext.DrawText(
new FormattedText(charIcon, CultureInfo.InvariantCulture, FlowDirection.LeftToRight,
FontAwesomeTypeface, 100, foregroundBrush) { TextAlignment = TextAlignment.Center }, new Point(0, 0));
}
return new DrawingImage(visual.Drawing);
}
}
}
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Windows.Markup;
[assembly: AssemblyTitle("Font Awesome WPF")]
[assembly: AssemblyDescription("Wpf components for the iconic font and CSS toolkit Font-Awesome")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("charri")]
[assembly: AssemblyProduct("FontAwesome.WPF")]
[assembly: AssemblyCopyright("Copyright © 2015")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("c1ef07d8-c739-421a-a811-278c9341677c")]
// Version: First three numbers is FontAwesome version, the last number specifies code revision
//
[assembly: AssemblyVersion("4.3.0.*")]
[assembly: AssemblyFileVersion("4.3.0.2")]
[assembly: XmlnsPrefix("http://schemas.fontawesome.io/icons/", "fa")]
[assembly: XmlnsDefinition("http://schemas.fontawesome.io/icons/", "FontAwesome.WPF")]
\ No newline at end of file
namespace ScrachEditor
{
partial class Form1
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.components = new System.ComponentModel.Container();
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.Text = "Form1";
}
#endregion
}
}
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace ScrachEditor
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
}
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Windows.Forms;
namespace ScrachEditor
{
static class Program
{
/// <summary>
/// The main entry point for the application.
/// </summary>
[STAThread]
static void Main()
{
Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
Application.Run(new Form1());
}
}
}
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("ScrachEditor")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Microsoft")]
[assembly: AssemblyProduct("ScrachEditor")]
[assembly: AssemblyCopyright("Copyright © Microsoft 2018")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("a369d98a-8957-436d-8cfd-7b1f0c1d1f91")]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.18408
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
namespace ScrachEditor.Properties
{
/// <summary>
/// A strongly-typed resource class, for looking up localized strings, etc.
/// </summary>
// This class was auto-generated by the StronglyTypedResourceBuilder
// class via a tool like ResGen or Visual Studio.
// To add or remove a member, edit your .ResX file then rerun ResGen
// with the /str option, or rebuild your VS project.
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
internal class Resources
{
private static global::System.Resources.ResourceManager resourceMan;
private static global::System.Globalization.CultureInfo resourceCulture;
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
internal Resources()
{
}
/// <summary>
/// Returns the cached ResourceManager instance used by this class.
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Resources.ResourceManager ResourceManager
{
get
{
if ((resourceMan == null))
{
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("ScrachEditor.Properties.Resources", typeof(Resources).Assembly);
resourceMan = temp;
}
return resourceMan;
}
}
/// <summary>
/// Overrides the current thread's CurrentUICulture property for all
/// resource lookups using this strongly typed resource class.
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Globalization.CultureInfo Culture
{
get
{
return resourceCulture;
}
set
{
resourceCulture = value;
}
}
}
}
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>
\ No newline at end of file
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.18408
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
namespace ScrachEditor.Properties
{
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "11.0.0.0")]
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase
{
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
public static Settings Default
{
get
{
return defaultInstance;
}
}
}
}
<?xml version='1.0' encoding='utf-8'?>
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)">
<Profiles>
<Profile Name="(Default)" />
</Profiles>
<Settings />
</SettingsFile>
<?xml version="1.0" encoding="utf-8"?>
<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')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>a369d98a-8957-436d-8cfd-7b1f0c1d1f91</ProjectGuid>
<OutputType>WinExe</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>ScrachEditor</RootNamespace>
<AssemblyName>ScrachEditor</AssemblyName>
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Data" />
<Reference Include="System.Deployment" />
<Reference Include="System.Drawing" />
<Reference Include="System.Windows.Forms" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="Form1.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="Form1.Designer.cs">
<DependentUpon>Form1.cs</DependentUpon>
</Compile>
<Compile Include="Program.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<EmbeddedResource Include="Properties\Resources.resx">
<Generator>ResXFileCodeGenerator</Generator>
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
<SubType>Designer</SubType>
</EmbeddedResource>
<Compile Include="Properties\Resources.Designer.cs">
<AutoGen>True</AutoGen>
<DependentUpon>Resources.resx</DependentUpon>
</Compile>
<None Include="Properties\Settings.settings">
<Generator>SettingsSingleFileGenerator</Generator>
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
</None>
<Compile Include="Properties\Settings.Designer.cs">
<AutoGen>True</AutoGen>
<DependentUpon>Settings.settings</DependentUpon>
<DesignTimeSharedInput>True</DesignTimeSharedInput>
</Compile>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- 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">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>
\ No newline at end of file
<Application x:Class="ScratchControl.App"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
StartupUri="MainWindow.xaml">
<Application.Resources>
</Application.Resources>
</Application>
using System;
using System.Collections.Generic;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Windows;
namespace ScratchControl
{
/// <summary>
/// Interaction logic for App.xaml
/// </summary>
public partial class App : Application
{
}
}
<Window
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:ScratchControl" x:Class="ScratchControl.MainWindow"
Loaded="Window_Loaded"
FontSize="12"
Title="MainWindow" Height="350" Width="525">
<Canvas Background="White">
<local:NumberExpressionControl x:Name="NbExp" Canvas.Top="20" Canvas.Left="20"/>
<local:BooleanExpressionControl x:Name="BnExp" Canvas.Left="75" Canvas.Top="109"/>
<Button Content="Button" Canvas.Left="187" Canvas.Top="57" Width="75" Click="Button_Click"/>
</Canvas>
</Window>
using ScratchNet;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.InteropServices;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
namespace ScratchControl
{
/// <summary>
/// Interaction logic for MainWindow.xaml
/// </summary>
public partial class MainWindow : Window
{
[DllImport("kernel32.dll")]
public static extern Boolean AllocConsole();
[DllImport("kernel32.dll")]
public static extern Boolean FreeConsole();
public MainWindow()
{
InitializeComponent();
AllocConsole();
NbExp.Expression = new ConditionalExpression() { Test=new Identifier(){Variable="abc"}, Consequent = new BinaryExpression(), Alternate = new Identifier() { Variable = "abc", VarType="boolean" } };
BnExp.Expression = new ConditionalExpression();
}
private void Window_Loaded(object sender, RoutedEventArgs e)
{
}
private void Button_Click(object sender, RoutedEventArgs e)
{
}
}
}
using System.Reflection;
using System.Resources;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Windows;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("ScratchControl")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Microsoft")]
[assembly: AssemblyProduct("ScratchControl")]
[assembly: AssemblyCopyright("Copyright © Microsoft 2018")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
//In order to begin building localizable applications, set
//<UICulture>CultureYouAreCodingWith</UICulture> in your .csproj file
//inside a <PropertyGroup>. For example, if you are using US english
//in your source files, set the <UICulture> to en-US. Then uncomment
//the NeutralResourceLanguage attribute below. Update the "en-US" in
//the line below to match the UICulture setting in the project file.
//[assembly: NeutralResourcesLanguage("en-US", UltimateResourceFallbackLocation.Satellite)]
[assembly: ThemeInfo(
ResourceDictionaryLocation.None, //where theme specific resource dictionaries are located
//(used if a resource is not found in the page,
// or application resource dictionaries)
ResourceDictionaryLocation.SourceAssembly //where the generic resource dictionary is located
//(used if a resource is not found in the page,
// app, or any theme specific resource dictionaries)
)]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.18408
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
namespace ScratchControl.Properties {
using System;
/// <summary>
/// A strongly-typed resource class, for looking up localized strings, etc.
/// </summary>
// This class was auto-generated by the StronglyTypedResourceBuilder
// class via a tool like ResGen or Visual Studio.
// To add or remove a member, edit your .ResX file then rerun ResGen
// with the /str option, or rebuild your VS project.
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
internal class Resources {
private static global::System.Resources.ResourceManager resourceMan;
private static global::System.Globalization.CultureInfo resourceCulture;
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
internal Resources() {
}
/// <summary>
/// Returns the cached ResourceManager instance used by this class.
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Resources.ResourceManager ResourceManager {
get {
if (object.ReferenceEquals(resourceMan, null)) {
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("ScratchControl.Properties.Resources", typeof(Resources).Assembly);
resourceMan = temp;
}
return resourceMan;
}
}
/// <summary>
/// Overrides the current thread's CurrentUICulture property for all
/// resource lookups using this strongly typed resource class.
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Globalization.CultureInfo Culture {
get {
return resourceCulture;
}
set {
resourceCulture = value;
}
}
}
}
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>
\ No newline at end of file
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.18408
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
namespace ScratchControl.Properties {
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "12.0.0.0")]
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase {
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
public static Settings Default {
get {
return defaultInstance;
}
}
}
}
<?xml version='1.0' encoding='utf-8'?>
<SettingsFile xmlns="uri:settings" CurrentProfile="(Default)">
<Profiles>
<Profile Name="(Default)" />
</Profiles>
<Settings />
</SettingsFile>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<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')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{E1C33987-94F5-472F-B191-8CBEDDEE5D99}</ProjectGuid>
<OutputType>WinExe</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>ScratchControl</RootNamespace>
<AssemblyName>ScratchControl</AssemblyName>
<TargetFrameworkVersion>v4.5.1</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
<WarningLevel>4</WarningLevel>
<TargetFrameworkProfile />
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<ItemGroup>
<Reference Include="PresentationFramework.Aero" />
<Reference Include="System" />
<Reference Include="System.Data" />
<Reference Include="System.Xml" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="System.Xaml">
<RequiredTargetFramework>4.0</RequiredTargetFramework>
</Reference>
<Reference Include="WindowsBase" />
<Reference Include="PresentationCore" />
<Reference Include="PresentationFramework" />
</ItemGroup>
<ItemGroup>
<ApplicationDefinition Include="App.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</ApplicationDefinition>
<Page Include="expression\BooleanExpressionControl.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="expression\BooleanExpressionHolder.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="expression\NumberExpressionControl.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="expression\NumberExpressionHolder.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="expression\ObjectExpressionControl.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="expression\SelectionItemControl.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="MainWindow.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Compile Include="App.xaml.cs">
<DependentUpon>App.xaml</DependentUpon>
<SubType>Code</SubType>
</Compile>
<Compile Include="expression\BooleanExpressionControl.xaml.cs">
<DependentUpon>BooleanExpressionControl.xaml</DependentUpon>
</Compile>
<Compile Include="expression\BooleanExpressionHolder.xaml.cs">
<DependentUpon>BooleanExpressionHolder.xaml</DependentUpon>
</Compile>
<Compile Include="expression\ExpressionControl.cs" />
<Compile Include="expression\ExpressionHelper.cs" />
<Compile Include="expression\ExpressionHolder.cs" />
<Compile Include="expression\NumberExpressionControl.xaml.cs">
<DependentUpon>NumberExpressionControl.xaml</DependentUpon>
</Compile>
<Compile Include="expression\NumberExpressionHolder.xaml.cs">
<DependentUpon>NumberExpressionHolder.xaml</DependentUpon>
</Compile>
<Compile Include="expression\ObjectExpressionControl.xaml.cs">
<DependentUpon>ObjectExpressionControl.xaml</DependentUpon>
</Compile>
<Compile Include="expression\SelectionItemControl.xaml.cs">
<DependentUpon>SelectionItemControl.xaml</DependentUpon>
</Compile>
<Compile Include="global\GlobalResource.cs" />
<Compile Include="MainWindow.xaml.cs">
<DependentUpon>MainWindow.xaml</DependentUpon>
<SubType>Code</SubType>
</Compile>
</ItemGroup>
<ItemGroup>
<Compile Include="Properties\AssemblyInfo.cs">
<SubType>Code</SubType>
</Compile>
<Compile Include="Properties\Resources.Designer.cs">
<AutoGen>True</AutoGen>
<DesignTime>True</DesignTime>
<DependentUpon>Resources.resx</DependentUpon>
</Compile>
<Compile Include="Properties\Settings.Designer.cs">
<AutoGen>True</AutoGen>
<DependentUpon>Settings.settings</DependentUpon>
<DesignTimeSharedInput>True</DesignTimeSharedInput>
</Compile>
<EmbeddedResource Include="Properties\Resources.resx">
<Generator>ResXFileCodeGenerator</Generator>
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
</EmbeddedResource>
<None Include="app.config" />
<None Include="Properties\Settings.settings">
<Generator>SettingsSingleFileGenerator</Generator>
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
</None>
<AppDesigner Include="Properties\" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\ScriptEngine\ScriptEngine.csproj">
<Project>{9efe2134-8015-4957-a9e1-f7d2fbb4cda7}</Project>
<Name>ScriptEngine</Name>
</ProjectReference>
</ItemGroup>
<ItemGroup>
<Folder Include="function\" />
<Folder Include="statement\" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- 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">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<startup><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5.1"/></startup></configuration>
<Grid x:Class="ScratchControl.BooleanExpressionControl"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
mc:Ignorable="d"
d:DesignHeight="300" d:DesignWidth="300">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="auto"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="auto"/>
</Grid.ColumnDefinitions>
<Polygon Name="Polygon1"
VerticalAlignment="Stretch" Stretch="Fill" Points="0, 4, 4, 0, 4, 8"
Fill="Green"
SnapsToDevicePixels="True" Width="7"/>
<Polyline Name="Polyline1"
VerticalAlignment="Stretch" Stretch="Fill" Points="4, 0, 0, 4, 4, 8"
Stroke="Black"
SnapsToDevicePixels="True" Width="7"/>
<Border Name="CenterPart" Grid.Column="1" MinWidth="20" BorderBrush="Black" BorderThickness="0,1,0,1"
SnapsToDevicePixels="True"
Background="Green">
<StackPanel Margin="3,0" Orientation="Horizontal" Name="Container" VerticalAlignment="Center"/>
</Border>
<Polygon Name="Polygon2"
VerticalAlignment="Stretch" Stretch="Fill" Grid.Column="2"
Fill="Green"
Points="0, 0, 0, 8, 4, 4" SnapsToDevicePixels="True" Width="7"/>
<Polyline Name="Polyline2"
VerticalAlignment="Stretch" Stretch="Fill" Grid.Column="2"
Stroke="Black"
Points="0, 0, 4, 4, 0, 8" SnapsToDevicePixels="True" Width="7"/>
</Grid>
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
namespace ScratchControl
{
/// <summary>
/// Interaction logic for BooleanExpressionControl.xaml
/// </summary>
public partial class BooleanExpressionControl : Grid, ExpressionControl
{
public BooleanExpressionControl()
{
InitializeComponent();
}
public Brush ExpressionBackground
{
set
{
Polygon1.Fill = value;
Polygon2.Fill = value;
CenterPart.Background = value;
}
}
Brush borderBrush = new SolidColorBrush(Colors.LightGray);
public Brush ExpressionBorderBrush
{
set
{
Polyline1.Stroke = value;
Polyline2.Stroke = value;
CenterPart.BorderBrush = value;
borderBrush = value;
}
get
{
return borderBrush;
}
}
ScratchNet.Expression expression;
public ScratchNet.Expression Expression
{
get
{
return expression;
}
set
{
expression = value;
if (value == null)
{
Container.Children.Clear();
return;
}
ExpressionHelper.SetupExpressionControl(value, Container);
}
}
public bool IsSelectetet
{
set
{
if (value)
{
Polyline1.Stroke = GlobalResource.SelectionBorderBrush;
Polyline2.Stroke = GlobalResource.SelectionBorderBrush; ;
CenterPart.BorderBrush = GlobalResource.SelectionBorderBrush; ;
}
else
{
Polyline1.Stroke = borderBrush;
Polyline2.Stroke = borderBrush;
CenterPart.BorderBrush = borderBrush;
}
}
}
public bool IsHovered
{
set
{
if (value)
{
Polyline1.Stroke = GlobalResource.HoverBorderBrush;
Polyline2.Stroke = GlobalResource.HoverBorderBrush;
CenterPart.BorderBrush = GlobalResource.HoverBorderBrush;
}
else
{
Polyline1.Stroke = borderBrush;
Polyline2.Stroke = borderBrush;
CenterPart.BorderBrush = borderBrush;
}
}
}
public Nullable<bool> CanDrop
{
set
{
if (value == true)
{
Polyline1.Stroke = GlobalResource.CanDropBorderBrush;
Polyline2.Stroke = GlobalResource.CanDropBorderBrush; ;
CenterPart.BorderBrush = GlobalResource.CanDropBorderBrush; ;
}
else if (value == false)
{
Polyline1.Stroke = GlobalResource.CanDropBorderBrush;
Polyline1.Stroke = GlobalResource.CanDropBorderBrush;
CenterPart.BorderBrush = GlobalResource.CanDropBorderBrush;
}
else
{
Polyline1.Stroke = borderBrush;
Polyline1.Stroke = borderBrush;
CenterPart.BorderBrush = borderBrush;
}
}
}
}
}
<Grid x:Class="ScratchControl.BooleanExpressionHolder"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
mc:Ignorable="d"
d:DesignHeight="300" d:DesignWidth="300">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="auto"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="auto"/>
</Grid.ColumnDefinitions>
<Polygon Name="LeftPart"
VerticalAlignment="Stretch" Stretch="Fill" Points="0, 4, 4, 0, 4, 8"
Fill="White" Stroke="White"
SnapsToDevicePixels="True" Width="7"/>
<Grid Name="CenterPart" Grid.Column="1" MinWidth="20" Margin="0"
SnapsToDevicePixels="True"
Background="White">
</Grid>
<Polygon Name="RightPart"
VerticalAlignment="Stretch" Stretch="Fill" Grid.Column="2"
Fill="White" Stroke="White"
Points="0, 0, 0, 8, 4, 4" SnapsToDevicePixels="True" Width="7"/>
</Grid>
using ScratchNet;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Media;
namespace ScratchControl
{
public interface ExpressionControl
{
Brush ExpressionBackground { set; }
Brush ExpressionBorderBrush { set; }
Expression Expression { get; set; }
bool IsSelectetet {set; }
bool IsHovered { set; }
Nullable<bool> CanDrop { set; }
}
}
此差异已折叠。
using ScratchNet;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ScratchControl
{
public interface ExpressionHolder
{
ExpressionDescriptor Descriptor { get; set; }
void SetExpression(ScratchNet.Expression exp);
}
}
<Grid x:Class="ScratchControl.NumberExpressionControl"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
mc:Ignorable="d"
MinHeight="20" SnapsToDevicePixels="True"
d:DesignHeight="300" d:DesignWidth="300">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="auto"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="auto"/>
</Grid.ColumnDefinitions>
<Border Name="LeftPart" Grid.Column="0" CornerRadius="7, 0, 0, 7" Background="Green" BorderBrush="Black"
Width="7"
BorderThickness="1, 1, 0, 1"/>
<Border Name="CenterPart" Grid.Column="1" MinWidth="20" BorderBrush="Black" BorderThickness="0,1,0,1"
SnapsToDevicePixels="True"
Background="Green">
<StackPanel Margin="3,0" Orientation="Horizontal" Name="Container" VerticalAlignment="Center"/>
</Border>
<Border Name="RightPart" Grid.Column="2" CornerRadius="0, 7,7, 0" Background="Green" BorderBrush="Black"
Width="7"
BorderThickness="0, 1, 1, 1"/>
</Grid>
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ScratchNet
{
public interface ActualSizeAdjustment
{
void GetActualSize(out double width, out double height);
}
}
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册