conflict_resolution
stringlengths 27
16k
|
---|
<<<<<<<
};
=======
[!ItemsPresenter.MemberSelectorProperty] = parent[!ItemsControl.MemberSelectorProperty],
}.RegisterInNameScope(scope);
>>>>>>>
}.RegisterInNameScope(scope); |
<<<<<<<
#endif
public async Task Path_Tick_Scaled()
=======
public void Path_Tick_Scaled()
>>>>>>>
public async Task Path_Tick_Scaled()
<<<<<<<
#endif
public async Task Path_Tick_Scaled_Stroke_8px()
=======
public void Path_Tick_Scaled_Stroke_8px()
>>>>>>>
public async Task Path_Tick_Scaled_Stroke_8px() |
<<<<<<<
[Fact]
public void HotKeyManager_Should_Release_Reference_When_Control_In_Item_Template_Detached()
{
using (UnitTestApplication.Start(TestServices.StyledWindow))
{
var styler = new Mock<Styler>();
AvaloniaLocator.CurrentMutable
.Bind<IWindowingPlatform>().ToConstant(new WindowingPlatformMock())
.Bind<IStyler>().ToConstant(styler.Object);
var gesture1 = new KeyGesture(Key.A, KeyModifiers.Control);
var weakReferences = new List<WeakReference>();
var tl = new Window { SizeToContent = SizeToContent.WidthAndHeight, IsVisible = true };
var lm = tl.LayoutManager;
var keyGestures = new AvaloniaList<KeyGesture> { gesture1 };
var listBox = new ListBox
{
Width = 100,
Height = 100,
VirtualizationMode = ItemVirtualizationMode.None,
// Create a button with binding to the KeyGesture in the template and add it to references list
ItemTemplate = new FuncDataTemplate(typeof(KeyGesture), (o, scope) =>
{
var keyGesture = o as KeyGesture;
var button = new Button
{
DataContext = keyGesture, [!Button.HotKeyProperty] = new Binding("")
};
weakReferences.Add(new WeakReference(button, true));
return button;
})
};
// Add the listbox and render it
tl.Content = listBox;
lm.ExecuteInitialLayoutPass();
listBox.Items = keyGestures;
lm.ExecuteLayoutPass();
// Let the button detach when clearing the source items
keyGestures.Clear();
lm.ExecuteLayoutPass();
// Add it again to double check,and render
keyGestures.Add(gesture1);
lm.ExecuteLayoutPass();
keyGestures.Clear();
lm.ExecuteLayoutPass();
// The button should be collected since it's detached from the listbox
GC.Collect();
GC.WaitForPendingFinalizers();
GC.Collect();
GC.WaitForPendingFinalizers();
Assert.True(weakReferences.Count > 0);
foreach (var weakReference in weakReferences)
{
Assert.Null(weakReference.Target);
}
}
}
=======
[Theory]
[MemberData(nameof(ElementsFactory))]
public void HotKeyManager_Should_Use_CommandParameter(string factoryName, Factory factory)
{
using (AvaloniaLocator.EnterScope())
{
var styler = new Mock<Styler>();
var target = new KeyboardDevice();
var commandResult = 0;
var expectedParameter = 1;
AvaloniaLocator.CurrentMutable
.Bind<IWindowingPlatform>().ToConstant(new WindowingPlatformMock())
.Bind<IStyler>().ToConstant(styler.Object);
var gesture = new KeyGesture(Key.A, KeyModifiers.Control);
var action = new Action<object>(parameter =>
{
if (parameter is int value)
{
commandResult = value;
}
});
var root = new Window();
var element = factory(expectedParameter, action, root);
root.Template = CreateWindowTemplate();
root.ApplyTemplate();
root.Presenter.ApplyTemplate();
HotKeyManager.SetHotKey(element, gesture);
target.ProcessRawEvent(new RawKeyEventArgs(target,
0,
root,
RawKeyEventType.KeyDown,
Key.A,
RawInputModifiers.Control));
Assert.True(expectedParameter == commandResult, $"{factoryName} HotKey did not carry the CommandParameter.");
}
}
[Theory]
[MemberData(nameof(ElementsFactory))]
public void HotKeyManager_Should_Do_Not_Executed_When_IsEnabled_False(string factoryName, Factory factory)
{
using (AvaloniaLocator.EnterScope())
{
var styler = new Mock<Styler>();
var target = new KeyboardDevice();
var isExecuted = false;
AvaloniaLocator.CurrentMutable
.Bind<IWindowingPlatform>().ToConstant(new WindowingPlatformMock())
.Bind<IStyler>().ToConstant(styler.Object);
var gesture = new KeyGesture(Key.A, KeyModifiers.Control);
var action = new Action<object>(parameter =>
{
isExecuted = true;
});
var root = new Window();
var element = factory(0, action, root) as InputElement;
element.IsEnabled = false;
root.Template = CreateWindowTemplate();
root.ApplyTemplate();
root.Presenter.ApplyTemplate();
HotKeyManager.SetHotKey(element, gesture);
target.ProcessRawEvent(new RawKeyEventArgs(target,
0,
root,
RawKeyEventType.KeyDown,
Key.A,
RawInputModifiers.Control));
Assert.True(isExecuted == false, $"{factoryName} Execution raised when IsEnabled is false.");
}
}
public static TheoryData<string, Factory> ElementsFactory =>
new TheoryData<string, Factory>()
{
{nameof(Button), MakeButton},
{nameof(MenuItem),MakeMenu},
};
private static AvaloniaObject MakeMenu(int expectedParameter, Action<object> action, Window root)
{
var menuitem = new MenuItem()
{
Command = new Command(action),
CommandParameter = expectedParameter,
};
var rootMenu = new Menu();
rootMenu.Items = new[] { menuitem };
root.Content = rootMenu;
return menuitem;
}
private static AvaloniaObject MakeButton(int expectedParameter, Action<object> action, Window root)
{
var button = new Button()
{
Command = new Command(action),
CommandParameter = expectedParameter,
};
root.Content = button;
return button;
}
>>>>>>>
[Fact]
public void HotKeyManager_Should_Release_Reference_When_Control_In_Item_Template_Detached()
{
using (UnitTestApplication.Start(TestServices.StyledWindow))
{
var styler = new Mock<Styler>();
AvaloniaLocator.CurrentMutable
.Bind<IWindowingPlatform>().ToConstant(new WindowingPlatformMock())
.Bind<IStyler>().ToConstant(styler.Object);
var gesture1 = new KeyGesture(Key.A, KeyModifiers.Control);
var weakReferences = new List<WeakReference>();
var tl = new Window { SizeToContent = SizeToContent.WidthAndHeight, IsVisible = true };
var lm = tl.LayoutManager;
var keyGestures = new AvaloniaList<KeyGesture> { gesture1 };
var listBox = new ListBox
{
Width = 100,
Height = 100,
VirtualizationMode = ItemVirtualizationMode.None,
// Create a button with binding to the KeyGesture in the template and add it to references list
ItemTemplate = new FuncDataTemplate(typeof(KeyGesture), (o, scope) =>
{
var keyGesture = o as KeyGesture;
var button = new Button
{
DataContext = keyGesture, [!Button.HotKeyProperty] = new Binding("")
};
weakReferences.Add(new WeakReference(button, true));
return button;
})
};
// Add the listbox and render it
tl.Content = listBox;
lm.ExecuteInitialLayoutPass();
listBox.Items = keyGestures;
lm.ExecuteLayoutPass();
// Let the button detach when clearing the source items
keyGestures.Clear();
lm.ExecuteLayoutPass();
// Add it again to double check,and render
keyGestures.Add(gesture1);
lm.ExecuteLayoutPass();
keyGestures.Clear();
lm.ExecuteLayoutPass();
// The button should be collected since it's detached from the listbox
GC.Collect();
GC.WaitForPendingFinalizers();
GC.Collect();
GC.WaitForPendingFinalizers();
Assert.True(weakReferences.Count > 0);
foreach (var weakReference in weakReferences)
{
Assert.Null(weakReference.Target);
}
}
}
[Theory]
[MemberData(nameof(ElementsFactory))]
public void HotKeyManager_Should_Use_CommandParameter(string factoryName, Factory factory)
{
using (AvaloniaLocator.EnterScope())
{
var styler = new Mock<Styler>();
var target = new KeyboardDevice();
var commandResult = 0;
var expectedParameter = 1;
AvaloniaLocator.CurrentMutable
.Bind<IWindowingPlatform>().ToConstant(new WindowingPlatformMock())
.Bind<IStyler>().ToConstant(styler.Object);
var gesture = new KeyGesture(Key.A, KeyModifiers.Control);
var action = new Action<object>(parameter =>
{
if (parameter is int value)
{
commandResult = value;
}
});
var root = new Window();
var element = factory(expectedParameter, action, root);
root.Template = CreateWindowTemplate();
root.ApplyTemplate();
root.Presenter.ApplyTemplate();
HotKeyManager.SetHotKey(element, gesture);
target.ProcessRawEvent(new RawKeyEventArgs(target,
0,
root,
RawKeyEventType.KeyDown,
Key.A,
RawInputModifiers.Control));
Assert.True(expectedParameter == commandResult, $"{factoryName} HotKey did not carry the CommandParameter.");
}
}
[Theory]
[MemberData(nameof(ElementsFactory))]
public void HotKeyManager_Should_Do_Not_Executed_When_IsEnabled_False(string factoryName, Factory factory)
{
using (AvaloniaLocator.EnterScope())
{
var styler = new Mock<Styler>();
var target = new KeyboardDevice();
var isExecuted = false;
AvaloniaLocator.CurrentMutable
.Bind<IWindowingPlatform>().ToConstant(new WindowingPlatformMock())
.Bind<IStyler>().ToConstant(styler.Object);
var gesture = new KeyGesture(Key.A, KeyModifiers.Control);
var action = new Action<object>(parameter =>
{
isExecuted = true;
});
var root = new Window();
var element = factory(0, action, root) as InputElement;
element.IsEnabled = false;
root.Template = CreateWindowTemplate();
root.ApplyTemplate();
root.Presenter.ApplyTemplate();
HotKeyManager.SetHotKey(element, gesture);
target.ProcessRawEvent(new RawKeyEventArgs(target,
0,
root,
RawKeyEventType.KeyDown,
Key.A,
RawInputModifiers.Control));
Assert.True(isExecuted == false, $"{factoryName} Execution raised when IsEnabled is false.");
}
}
public static TheoryData<string, Factory> ElementsFactory =>
new TheoryData<string, Factory>()
{
{nameof(Button), MakeButton},
{nameof(MenuItem),MakeMenu},
};
private static AvaloniaObject MakeMenu(int expectedParameter, Action<object> action, Window root)
{
var menuitem = new MenuItem()
{
Command = new Command(action),
CommandParameter = expectedParameter,
};
var rootMenu = new Menu();
rootMenu.Items = new[] { menuitem };
root.Content = rootMenu;
return menuitem;
}
private static AvaloniaObject MakeButton(int expectedParameter, Action<object> action, Window root)
{
var button = new Button()
{
Command = new Command(action),
CommandParameter = expectedParameter,
};
root.Content = button;
return button;
} |
<<<<<<<
private NativeControlHostImpl _nativeControlHost;
=======
private IGlContext _glContext;
>>>>>>>
private NativeControlHostImpl _nativeControlHost;
private IGlContext _glContext;
<<<<<<<
void IAvnWindowBaseEvents.LostFocus()
{
_parent.LostFocus?.Invoke();
}
=======
public AvnDragDropEffects DragEvent(AvnDragEventType type, AvnPoint position,
AvnInputModifiers modifiers,
AvnDragDropEffects effects,
IAvnClipboard clipboard, IntPtr dataObjectHandle)
{
var device = AvaloniaLocator.Current.GetService<IDragDropDevice>();
IDataObject dataObject = null;
if (dataObjectHandle != IntPtr.Zero)
dataObject = GCHandle.FromIntPtr(dataObjectHandle).Target as IDataObject;
using(var clipboardDataObject = new ClipboardDataObject(clipboard))
{
if (dataObject == null)
dataObject = clipboardDataObject;
var args = new RawDragEvent(device, (RawDragEventType)type,
_parent._inputRoot, position.ToAvaloniaPoint(), dataObject, (DragDropEffects)effects,
(RawInputModifiers)modifiers);
_parent.Input(args);
return (AvnDragDropEffects)args.Effects;
}
}
>>>>>>>
void IAvnWindowBaseEvents.LostFocus()
{
_parent.LostFocus?.Invoke();
}
public AvnDragDropEffects DragEvent(AvnDragEventType type, AvnPoint position,
AvnInputModifiers modifiers,
AvnDragDropEffects effects,
IAvnClipboard clipboard, IntPtr dataObjectHandle)
{
var device = AvaloniaLocator.Current.GetService<IDragDropDevice>();
IDataObject dataObject = null;
if (dataObjectHandle != IntPtr.Zero)
dataObject = GCHandle.FromIntPtr(dataObjectHandle).Target as IDataObject;
using(var clipboardDataObject = new ClipboardDataObject(clipboard))
{
if (dataObject == null)
dataObject = clipboardDataObject;
var args = new RawDragEvent(device, (RawDragEventType)type,
_parent._inputRoot, position.ToAvaloniaPoint(), dataObject, (DragDropEffects)effects,
(RawInputModifiers)modifiers);
_parent.Input(args);
return (AvnDragDropEffects)args.Effects;
}
} |
<<<<<<<
public PlatformRenderInterface(ISkiaGpu skiaGpu)
=======
private GRContext GrContext { get; }
public PlatformRenderInterface(ICustomSkiaGpu customSkiaGpu, long maxResourceBytes = 100663296)
>>>>>>>
public PlatformRenderInterface(ISkiaGpu skiaGpu, long maxResourceBytes)
<<<<<<<
_skiaGpu = skiaGpu;
=======
_customSkiaGpu = customSkiaGpu;
GrContext = _customSkiaGpu.GrContext;
GrContext.GetResourceCacheLimits(out var maxResources, out _);
GrContext.SetResourceCacheLimits(maxResources, maxResourceBytes);
>>>>>>>
_skiaGpu = skiaGpu;
<<<<<<<
if (gl != null)
_skiaGpu = new GlSkiaGpu(gl);
=======
if (gl != null)
{
var display = gl.ImmediateContext.Display;
gl.ImmediateContext.MakeCurrent();
using (var iface = display.Type == GlDisplayType.OpenGL2
? GRGlInterface.AssembleGlInterface((_, proc) => display.GlInterface.GetProcAddress(proc))
: GRGlInterface.AssembleGlesInterface((_, proc) => display.GlInterface.GetProcAddress(proc)))
{
GrContext = GRContext.Create(GRBackend.OpenGL, iface);
GrContext.GetResourceCacheLimits(out var maxResources, out _);
GrContext.SetResourceCacheLimits(maxResources, maxResourceBytes);
}
display.ClearContext();
}
>>>>>>>
if (gl != null)
_skiaGpu = new GlSkiaGpu(gl, maxResourceBytes);
<<<<<<<
public IOpenGlTextureBitmapImpl CreateOpenGlTextureBitmap()
{
if (_skiaGpu is IOpenGlAwareSkiaGpu glAware)
return glAware.CreateOpenGlTextureBitmap();
if (_skiaGpu == null)
throw new PlatformNotSupportedException("GPU acceleration is not available");
throw new PlatformNotSupportedException(
"Current GPU acceleration backend does not support OpenGL integration");
}
=======
public bool SupportsIndividualRoundRects => true;
>>>>>>>
public IOpenGlTextureBitmapImpl CreateOpenGlTextureBitmap()
{
if (_skiaGpu is IOpenGlAwareSkiaGpu glAware)
return glAware.CreateOpenGlTextureBitmap();
if (_skiaGpu == null)
throw new PlatformNotSupportedException("GPU acceleration is not available");
throw new PlatformNotSupportedException(
"Current GPU acceleration backend does not support OpenGL integration");
}
public bool SupportsIndividualRoundRects => true; |
<<<<<<<
public static readonly StyledProperty<IBrush> SelectionBrushProperty =
AvaloniaProperty.Register<TextBox, IBrush>(nameof(SelectionBrushProperty));
public static readonly StyledProperty<IBrush> SelectionForegroundBrushProperty =
AvaloniaProperty.Register<TextBox, IBrush>(nameof(SelectionForegroundBrushProperty));
=======
public static readonly StyledProperty<IBrush> CaretBrushProperty =
AvaloniaProperty.Register<TextPresenter, IBrush>(nameof(CaretBrushProperty));
>>>>>>>
public static readonly StyledProperty<IBrush> SelectionBrushProperty =
AvaloniaProperty.Register<TextBox, IBrush>(nameof(SelectionBrushProperty));
public static readonly StyledProperty<IBrush> SelectionForegroundBrushProperty =
AvaloniaProperty.Register<TextBox, IBrush>(nameof(SelectionForegroundBrushProperty));
public static readonly StyledProperty<IBrush> CaretBrushProperty =
AvaloniaProperty.Register<TextBox, IBrush>(nameof(CaretBrushProperty));
<<<<<<<
public IBrush SelectionBrush
{
get => GetValue(SelectionBrushProperty);
set => SetValue(SelectionBrushProperty, value);
}
public IBrush SelectionForegroundBrush
{
get => GetValue(SelectionForegroundBrushProperty);
set => SetValue(SelectionForegroundBrushProperty, value);
}
=======
public IBrush CaretBrush
{
get => GetValue(CaretBrushProperty);
set => SetValue(CaretBrushProperty, value);
}
>>>>>>>
public IBrush SelectionBrush
{
get => GetValue(SelectionBrushProperty);
set => SetValue(SelectionBrushProperty, value);
}
public IBrush SelectionForegroundBrush
{
get => GetValue(SelectionForegroundBrushProperty);
set => SetValue(SelectionForegroundBrushProperty, value);
}
public IBrush CaretBrush
{
get => GetValue(CaretBrushProperty);
set => SetValue(CaretBrushProperty, value);
} |
<<<<<<<
=======
/// <summary>
/// A specialized translator that can handle specific scenarios.
/// </summary>
class SpecializedTranslatorMiddleware : TranslationMiddleware
{
public SpecializedTranslatorMiddleware(string[] nativeLanguages, string translatorKey) : base(nativeLanguages, translatorKey)
{ }
public override async Task OnTurnAsync(ITurnContext context, NextDelegate next, CancellationToken cancellationToken)
{
// alter the original utterance before translation.
if (context.Activity.Text == "mañana")
{
context.Activity.Text = "para mañana";
}
await base.OnTurnAsync(context, next, cancellationToken);
}
}
>>>>>>>
<<<<<<<
var adapter = new TestAdapter(sendTraceActivity: true)
.Use(new SpecializedTranslatorMiddleware(new[] {"en-us"}, _translatorKey, mockHttp.ToHttpClient()));
=======
var adapter = new TestAdapter()
.Use(new SpecializedTranslatorMiddleware(new[] { "en" }, translatorKey));
>>>>>>>
var adapter = new TestAdapter(sendTraceActivity: true)
.Use(new SpecializedTranslatorMiddleware(new[] { "en" }, _translatorKey, mockHttp.ToHttpClient()));
<<<<<<<
.Use(new TranslationMiddleware(new[] {"en-us"}, _translatorKey, httpClient: mockHttp.ToHttpClient()));
=======
.Use(new TranslationMiddleware(new[] { "en" }, translatorKey));
>>>>>>>
.Use(new TranslationMiddleware(new[] { "en" }, _translatorKey, httpClient: mockHttp.ToHttpClient()));
<<<<<<<
private string GetRequestDetect(string text)
{
return "http://api.microsofttranslator.com/v2/Http.svc/Detect?text=" + text;
}
private string GetResponseDetect(string text)
{
return $"<string xmlns=\"http://schemas.microsoft.com/2003/10/Serialization/\">{text}</string>";
}
private Stream GetResponse(string fileName)
{
var path = Path.Combine(Environment.CurrentDirectory, "TestData", fileName);
return File.OpenRead(path);
}
private void SetLanguage(ITurnContext context, string language) => context.GetUserState<LanguageState>().Language = language;
protected async Task<bool> SetActiveLanguage(ITurnContext context)
=======
protected async Task<bool> HandleChangeLanguageRequest(ITurnContext context, IStatePropertyAccessor<string> languageProperty)
>>>>>>>
private string GetRequestDetect(string text)
{
return "http://api.microsofttranslator.com/v2/Http.svc/Detect?text=" + text;
}
private string GetResponseDetect(string text)
{
return $"<string xmlns=\"http://schemas.microsoft.com/2003/10/Serialization/\">{text}</string>";
}
private Stream GetResponse(string fileName)
{
var path = Path.Combine(Environment.CurrentDirectory, "TestData", fileName);
return File.OpenRead(path);
}
protected async Task<bool> HandleChangeLanguageRequest(ITurnContext context, IStatePropertyAccessor<string> languageProperty)
<<<<<<<
protected string GetActiveLanguage(ITurnContext context)
{
if (context.Activity.Type == ActivityTypes.Message
&& !string.IsNullOrEmpty(context.GetUserState<LanguageState>().Language))
{
return context.GetUserState<LanguageState>().Language;
}
return "en";
}
}
class LanguageState
{
public string Language { get; set; }
}
/// <summary>
/// A specialized translator that can handle specific scenarios.
/// </summary>
class SpecializedTranslatorMiddleware : TranslationMiddleware
{
public SpecializedTranslatorMiddleware(string[] nativeLanguages, string translatorKey, HttpClient client) : base(nativeLanguages, translatorKey, httpClient: client)
{ }
public override async Task OnTurnAsync(ITurnContext context, NextDelegate next, CancellationToken cancellationToken)
=======
private bool EnvironmentVariablesDefined()
>>>>>>>
}
class LanguageState
{
public string Language { get; set; }
}
/// <summary>
/// A specialized translator that can handle specific scenarios.
/// </summary>
class SpecializedTranslatorMiddleware : TranslationMiddleware
{
public SpecializedTranslatorMiddleware(string[] nativeLanguages, string translatorKey, HttpClient client) : base(nativeLanguages, translatorKey, httpClient: client)
{ }
public override async Task OnTurnAsync(ITurnContext context, NextDelegate next, CancellationToken cancellationToken) |
<<<<<<<
[Fact]
public void Shift_Right_Click_Should_Not_Select_Mutiple()
{
var target = new ListBox
{
Template = Template(),
Items = new[] { "Foo", "Bar", "Baz" },
ItemTemplate = new FuncDataTemplate<string>(x => new TextBlock { Width = 20, Height = 10 }),
SelectionMode = SelectionMode.Multiple,
};
target.ApplyTemplate();
target.Presenter.ApplyTemplate();
_helper.Click((Interactive)target.Presenter.Panel.Children[0]);
_helper.Click((Interactive)target.Presenter.Panel.Children[2], MouseButton.Right, modifiers: InputModifiers.Shift);
Assert.Equal(1, target.SelectedItems.Count);
}
[Fact]
public void Ctrl_Right_Click_Should_Not_Select_Mutiple()
{
var target = new ListBox
{
Template = Template(),
Items = new[] { "Foo", "Bar", "Baz" },
ItemTemplate = new FuncDataTemplate<string>(x => new TextBlock { Width = 20, Height = 10 }),
SelectionMode = SelectionMode.Multiple,
};
target.ApplyTemplate();
target.Presenter.ApplyTemplate();
_helper.Click((Interactive)target.Presenter.Panel.Children[0]);
_helper.Click((Interactive)target.Presenter.Panel.Children[2], MouseButton.Right, modifiers: InputModifiers.Control);
Assert.Equal(1, target.SelectedItems.Count);
}
=======
[Fact]
public void Adding_Selected_ItemContainers_Should_Update_Selection()
{
var items = new AvaloniaList<ItemContainer>(new[]
{
new ItemContainer(),
new ItemContainer(),
});
var target = new TestSelector
{
Items = items,
Template = Template(),
};
target.ApplyTemplate();
target.Presenter.ApplyTemplate();
items.Add(new ItemContainer { IsSelected = true });
items.Add(new ItemContainer { IsSelected = true });
Assert.Equal(2, target.SelectedIndex);
Assert.Equal(items[2], target.SelectedItem);
Assert.Equal(new[] { items[2], items[3] }, target.SelectedItems);
}
>>>>>>>
[Fact]
public void Adding_Selected_ItemContainers_Should_Update_Selection()
{
var items = new AvaloniaList<ItemContainer>(new[]
{
new ItemContainer(),
new ItemContainer(),
});
var target = new TestSelector
{
Items = items,
Template = Template(),
};
target.ApplyTemplate();
target.Presenter.ApplyTemplate();
items.Add(new ItemContainer { IsSelected = true });
items.Add(new ItemContainer { IsSelected = true });
Assert.Equal(2, target.SelectedIndex);
Assert.Equal(items[2], target.SelectedItem);
Assert.Equal(new[] { items[2], items[3] }, target.SelectedItems);
}
[Fact]
public void Shift_Right_Click_Should_Not_Select_Mutiple()
{
var target = new ListBox
{
Template = Template(),
Items = new[] { "Foo", "Bar", "Baz" },
ItemTemplate = new FuncDataTemplate<string>(x => new TextBlock { Width = 20, Height = 10 }),
SelectionMode = SelectionMode.Multiple,
};
target.ApplyTemplate();
target.Presenter.ApplyTemplate();
_helper.Click((Interactive)target.Presenter.Panel.Children[0]);
_helper.Click((Interactive)target.Presenter.Panel.Children[2], MouseButton.Right, modifiers: InputModifiers.Shift);
Assert.Equal(1, target.SelectedItems.Count);
}
[Fact]
public void Ctrl_Right_Click_Should_Not_Select_Mutiple()
{
var target = new ListBox
{
Template = Template(),
Items = new[] { "Foo", "Bar", "Baz" },
ItemTemplate = new FuncDataTemplate<string>(x => new TextBlock { Width = 20, Height = 10 }),
SelectionMode = SelectionMode.Multiple,
};
target.ApplyTemplate();
target.Presenter.ApplyTemplate();
_helper.Click((Interactive)target.Presenter.Panel.Children[0]);
_helper.Click((Interactive)target.Presenter.Panel.Children[2], MouseButton.Right, modifiers: InputModifiers.Control);
Assert.Equal(1, target.SelectedItems.Count);
} |
<<<<<<<
using Avalonia.Dialogs;
using Avalonia.OpenGL;
=======
using Avalonia.Controls;
using Avalonia.Controls.ApplicationLifetimes;
using Avalonia.Headless;
using Avalonia.LogicalTree;
using Avalonia.Skia;
>>>>>>>
using Avalonia.Controls;
using Avalonia.Controls.ApplicationLifetimes;
using Avalonia.Headless;
using Avalonia.LogicalTree;
using Avalonia.Skia;
using Avalonia.Dialogs;
using Avalonia.OpenGL; |
<<<<<<<
public static bool UseImmediateRenderer { get; set; }
public static void Initialize()
{
AvaloniaLocator.CurrentMutable
.Bind<IPlatformRenderInterface>().ToConstant(s_instance)
.Bind<IRendererFactory>().ToConstant(s_instance)
.Bind<SharpDX.Direct2D1.Factory>().ToConstant(s_d2D1Factory)
.Bind<SharpDX.Direct2D1.Factory1>().ToConstant(s_d2D1Factory)
.BindToSelf(s_dwfactory)
.BindToSelf(s_imagingFactory);
SharpDX.Configuration.EnableReleaseOnFinalizer = true;
}
=======
private static readonly SharpDX.DXGI.Device s_dxgiDevice;
private static readonly SharpDX.Direct2D1.Device s_d2D1Device;
static Direct2D1Platform()
{
var featureLevels = new[]
{
SharpDX.Direct3D.FeatureLevel.Level_11_1,
SharpDX.Direct3D.FeatureLevel.Level_11_0,
SharpDX.Direct3D.FeatureLevel.Level_10_1,
SharpDX.Direct3D.FeatureLevel.Level_10_0,
SharpDX.Direct3D.FeatureLevel.Level_9_3,
SharpDX.Direct3D.FeatureLevel.Level_9_2,
SharpDX.Direct3D.FeatureLevel.Level_9_1,
};
using (var d3dDevice = new SharpDX.Direct3D11.Device(
SharpDX.Direct3D.DriverType.Hardware,
SharpDX.Direct3D11.DeviceCreationFlags.BgraSupport | SharpDX.Direct3D11.DeviceCreationFlags.VideoSupport,
featureLevels))
{
s_dxgiDevice = d3dDevice.QueryInterface<SharpDX.DXGI.Device>();
}
using (var factory1 = s_d2D1Factory.QueryInterface<SharpDX.Direct2D1.Factory1>())
{
s_d2D1Device = new SharpDX.Direct2D1.Device(factory1, s_dxgiDevice);
}
}
public static void Initialize() => AvaloniaLocator.CurrentMutable
.Bind<IPlatformRenderInterface>().ToConstant(s_instance)
.Bind<IRendererFactory>().ToConstant(s_instance)
.BindToSelf(s_d2D1Factory)
.BindToSelf(s_dwfactory)
.BindToSelf(s_imagingFactory)
.BindToSelf(s_dxgiDevice)
.BindToSelf(s_d2D1Device);
>>>>>>>
public static bool UseImmediateRenderer { get; set; }
public static void Initialize()
{
AvaloniaLocator.CurrentMutable
.Bind<IPlatformRenderInterface>().ToConstant(s_instance)
.Bind<IRendererFactory>().ToConstant(s_instance)
.Bind<SharpDX.Direct2D1.Factory>().ToConstant(s_d2D1Factory)
.Bind<SharpDX.Direct2D1.Factory1>().ToConstant(s_d2D1Factory)
.BindToSelf(s_dwfactory)
.BindToSelf(s_imagingFactory)
.BindToSelf(s_dxgiDevice)
.BindToSelf(s_d2D1Device);
SharpDX.Configuration.EnableReleaseOnFinalizer = true;
}
private static readonly SharpDX.DXGI.Device s_dxgiDevice;
private static readonly SharpDX.Direct2D1.Device s_d2D1Device;
static Direct2D1Platform()
{
var featureLevels = new[]
{
SharpDX.Direct3D.FeatureLevel.Level_11_1,
SharpDX.Direct3D.FeatureLevel.Level_11_0,
SharpDX.Direct3D.FeatureLevel.Level_10_1,
SharpDX.Direct3D.FeatureLevel.Level_10_0,
SharpDX.Direct3D.FeatureLevel.Level_9_3,
SharpDX.Direct3D.FeatureLevel.Level_9_2,
SharpDX.Direct3D.FeatureLevel.Level_9_1,
};
using (var d3dDevice = new SharpDX.Direct3D11.Device(
SharpDX.Direct3D.DriverType.Hardware,
SharpDX.Direct3D11.DeviceCreationFlags.BgraSupport | SharpDX.Direct3D11.DeviceCreationFlags.VideoSupport,
featureLevels))
{
s_dxgiDevice = d3dDevice.QueryInterface<SharpDX.DXGI.Device>();
}
using (var factory1 = s_d2D1Factory.QueryInterface<SharpDX.Direct2D1.Factory1>())
{
s_d2D1Device = new SharpDX.Direct2D1.Device(factory1, s_dxgiDevice);
}
}
<<<<<<<
return new RenderTargetBitmapImpl(
s_imagingFactory,
s_d2D1Factory,
s_dwfactory,
width,
height,
dpiX,
dpiY);
=======
return new RenderTargetBitmapImpl(s_imagingFactory, s_d2D1Device.Factory, width, height);
>>>>>>>
return new RenderTargetBitmapImpl(
s_imagingFactory,
s_d2D1Factory,
s_dwfactory,
width,
height,
dpiX,
dpiY); |
<<<<<<<
BorderThickness = 2,
BorderBrush = Brushes.Black,
Padding = new Thickness(8),
Content = new Path
{
Id = "checkMark",
Data = StreamGeometry.Parse("M0,0 L10,10 M10,0 L0,10"),
Stroke = Brushes.Black,
StrokeThickness = 2,
VerticalAlignment = VerticalAlignment.Center,
},
[Grid.ColumnProperty] = 0,
=======
Id = "checkBorder",
Stroke = Brushes.Black,
StrokeThickness = 2,
Width = 16,
Height = 16,
VerticalAlignment = VerticalAlignment.Center,
},
new Path
{
Id = "checkMark",
Data = StreamGeometry.Parse("M0,0 L10,10 M10,0 L0,10"),
Stroke = Brushes.Black,
StrokeThickness = 2,
VerticalAlignment = VerticalAlignment.Center,
>>>>>>>
Id = "checkBorder",
Stroke = Brushes.Black,
StrokeThickness = 2,
Width = 16,
Height = 16,
VerticalAlignment = VerticalAlignment.Center,
[Grid.ColumnProperty] = 0,
},
new Path
{
Id = "checkMark",
Data = StreamGeometry.Parse("M0,0 L10,10 M10,0 L0,10"),
Stroke = Brushes.Black,
StrokeThickness = 2,
VerticalAlignment = VerticalAlignment.Center,
[Grid.ColumnProperty] = 0,
<<<<<<<
=======
result.TemplateBinding(control, Border.BackgroundProperty);
StackPanel stack = (StackPanel)result.Content;
ContentPresenter cp = (ContentPresenter)stack.Children[2];
cp.TemplateBinding(control, ContentPresenter.ContentProperty);
>>>>>>> |
<<<<<<<
var impl = new Mock<ITopLevelImpl>();
=======
RegisterServices();
PerspexLocator.CurrentMutable.Bind<ILayoutManager>().ToConstant(new LayoutManager());
var impl = Mock.Of<ITopLevelImpl>(x => x.Scaling == 1);
>>>>>>>
var impl = Mock.Of<ITopLevelImpl>(x => x.Scaling == 1); |
<<<<<<<
public static readonly StyledProperty<IBrush> SelectionBrushProperty =
AvaloniaProperty.Register<TextPresenter, IBrush>(nameof(SelectionBrushProperty));
public static readonly StyledProperty<IBrush> SelectionForegroundBrushProperty =
AvaloniaProperty.Register<TextPresenter, IBrush>(nameof(SelectionForegroundBrushProperty));
=======
public static readonly StyledProperty<IBrush> CaretBrushProperty =
AvaloniaProperty.Register<TextPresenter, IBrush>(nameof(CaretBrushProperty));
>>>>>>>
public static readonly StyledProperty<IBrush> SelectionBrushProperty =
AvaloniaProperty.Register<TextPresenter, IBrush>(nameof(SelectionBrushProperty));
public static readonly StyledProperty<IBrush> SelectionForegroundBrushProperty =
AvaloniaProperty.Register<TextPresenter, IBrush>(nameof(SelectionForegroundBrushProperty));
public static readonly StyledProperty<IBrush> CaretBrushProperty =
AvaloniaProperty.Register<TextPresenter, IBrush>(nameof(CaretBrushProperty));
<<<<<<<
=======
private IBrush _highlightBrush;
>>>>>>>
<<<<<<<
public IBrush SelectionBrush
{
get => GetValue(SelectionBrushProperty);
set => SetValue(SelectionBrushProperty, value);
}
public IBrush SelectionForegroundBrush
{
get => GetValue(SelectionForegroundBrushProperty);
set => SetValue(SelectionForegroundBrushProperty, value);
}
=======
public IBrush CaretBrush
{
get => GetValue(CaretBrushProperty);
set => SetValue(CaretBrushProperty, value);
}
>>>>>>>
public IBrush SelectionBrush
{
get => GetValue(SelectionBrushProperty);
set => SetValue(SelectionBrushProperty, value);
}
public IBrush SelectionForegroundBrush
{
get => GetValue(SelectionForegroundBrushProperty);
set => SetValue(SelectionForegroundBrushProperty, value);
}
public IBrush CaretBrush
{
get => GetValue(CaretBrushProperty);
set => SetValue(CaretBrushProperty, value);
} |
<<<<<<<
/// <summary>
/// Sets the shutdown mode of the application.
/// </summary>
/// <param name="exitMode">The shutdown mode.</param>
/// <returns></returns>
public TAppBuilder SetExitMode(ExitMode exitMode)
{
Instance.ExitMode = exitMode;
return Self;
}
private bool CheckSetup { get; set; } = true;
/// <summary>
/// Set this AppBuilder to ignore the setup check. Used for testing purposes.
/// </summary>
internal TAppBuilder IgnoreSetupCheck()
{
CheckSetup = false;
return Self;
}
=======
protected virtual bool CheckSetup => true;
>>>>>>>
/// <summary>
/// Sets the shutdown mode of the application.
/// </summary>
/// <param name="exitMode">The shutdown mode.</param>
/// <returns></returns>
public TAppBuilder SetExitMode(ExitMode exitMode)
{
Instance.ExitMode = exitMode;
return Self;
}
private bool CheckSetup { get; set; } = true;
/// <summary>
/// Set this AppBuilder to ignore the setup check. Used for testing purposes.
/// </summary>
internal TAppBuilder IgnoreSetupCheck()
{
CheckSetup = false;
return Self;
}
protected virtual bool CheckSetup => true; |
<<<<<<<
private IResourceDictionary _resources;
private Styles _styles;
=======
>>>>>>>
private IResourceDictionary _resources;
private Styles _styles;
<<<<<<<
public Styles Styles
{
get { return _styles ?? (Styles = new Styles()); }
set
{
Contract.Requires<ArgumentNullException>(value != null);
if (_styles != value)
{
if (_styles != null)
{
(_styles as ISetStyleParent)?.SetParent(null);
_styles.ResourcesChanged -= ThisResourcesChanged;
}
_styles = value;
if (value is ISetStyleParent setParent && setParent.ResourceParent == null)
{
setParent.SetParent(this);
}
_styles.ResourcesChanged += ThisResourcesChanged;
}
}
}
=======
public Styles Styles => _styles ?? (_styles = new Styles());
>>>>>>>
public Styles Styles
{
get { return _styles ?? (Styles = new Styles()); }
set
{
Contract.Requires<ArgumentNullException>(value != null);
if (_styles != value)
{
if (_styles != null)
{
(_styles as ISetStyleParent)?.SetParent(null);
_styles.ResourcesChanged -= ThisResourcesChanged;
}
_styles = value;
if (value is ISetStyleParent setParent && setParent.ResourceParent == null)
{
setParent.SetParent(this);
}
_styles.ResourcesChanged += ThisResourcesChanged;
}
}
} |
<<<<<<<
public BotFrameworkAdapter(string appId, string appPassword, HttpClient httpClient = null, IMiddleware middleware = null)
: this(new SimpleCredentialProvider(appId, appPassword), httpClient, middleware)
=======
public BotFrameworkAdapter(string appId, string appPassword) : this(appId, appPassword, null)
{
}
public BotFrameworkAdapter(string appId, string appPassword, HttpClient httpClient) : base()
>>>>>>>
public BotFrameworkAdapter(string appId, string appPassword, HttpClient httpClient = null, IMiddleware middleware = null)
: this(new SimpleCredentialProvider(appId, appPassword), httpClient, middleware)
<<<<<<<
protected override async Task<ResourceResponse> UpdateActivityImplementation(IBotContext context, IActivity activity)
=======
protected override Task<ResourceResponse> UpdateActivityImplementation(IBotContext context, Activity activity)
>>>>>>>
protected override async Task<ResourceResponse> UpdateActivityImplementation(IBotContext context, Activity activity)
<<<<<<<
protected override Task CreateConversationImplementation()
{
throw new NotImplementedException();
}
/// <summary>
/// Gets the application credentials. App Credentials are cached so as to ensure we are not refreshing
/// token everytime.
/// </summary>
/// <param name="appId">The application identifier (AAD Id for the bot).</param>
/// <returns>App credentials.</returns>
protected virtual async Task<MicrosoftAppCredentials> GetAppCredentials(string appId)
{
MicrosoftAppCredentials appCredentials;
if (!_appCredentialMap.TryGetValue(appId, out appCredentials))
{
string appPassword = await _credentialProvider.GetAppPasswordAsync(appId);
appCredentials = new MicrosoftAppCredentials(appId, appPassword);
_appCredentialMap[appId] = appCredentials;
}
return appCredentials;
}
/// <summary>
/// Gets the bot identifier from claims.
/// </summary>
/// <param name="claimsIdentity">The claims identity.</param>
/// <returns>Bot's AAD AppId, if it could be inferred from claims. Null otherwise.</returns>
private static string GetBotId(ClaimsIdentity claimsIdentity)
{
// For requests coming from channels Audience Claim contains the Bot's AAD AppId
Claim botAppIdClaim = (claimsIdentity.Claims?.SingleOrDefault(claim => claim.Type == AuthenticationConstants.AudienceClaim)
??
// For requests coming from Emulator AppId claim contains the Bot's AAD AppId.
claimsIdentity.Claims?.SingleOrDefault(claim => claim.Type == AuthenticationConstants.AppIdClaim));
// For anonymous requests (requests with no header) appId is not set in claims.
if (botAppIdClaim != null)
{
return botAppIdClaim.Value;
}
else
{
return null;
}
}
=======
>>>>>>>
/// <summary>
/// Gets the application credentials. App Credentials are cached so as to ensure we are not refreshing
/// token everytime.
/// </summary>
/// <param name="appId">The application identifier (AAD Id for the bot).</param>
/// <returns>App credentials.</returns>
protected virtual async Task<MicrosoftAppCredentials> GetAppCredentials(string appId)
{
MicrosoftAppCredentials appCredentials;
if (!_appCredentialMap.TryGetValue(appId, out appCredentials))
{
string appPassword = await _credentialProvider.GetAppPasswordAsync(appId);
appCredentials = new MicrosoftAppCredentials(appId, appPassword);
_appCredentialMap[appId] = appCredentials;
}
return appCredentials;
}
/// <summary>
/// Gets the bot identifier from claims.
/// </summary>
/// <param name="claimsIdentity">The claims identity.</param>
/// <returns>Bot's AAD AppId, if it could be inferred from claims. Null otherwise.</returns>
private static string GetBotId(ClaimsIdentity claimsIdentity)
{
// For requests coming from channels Audience Claim contains the Bot's AAD AppId
Claim botAppIdClaim = (claimsIdentity.Claims?.SingleOrDefault(claim => claim.Type == AuthenticationConstants.AudienceClaim)
??
// For requests coming from Emulator AppId claim contains the Bot's AAD AppId.
claimsIdentity.Claims?.SingleOrDefault(claim => claim.Type == AuthenticationConstants.AppIdClaim));
// For anonymous requests (requests with no header) appId is not set in claims.
if (botAppIdClaim != null)
{
return botAppIdClaim.Value;
}
else
{
return null;
}
} |
<<<<<<<
modifierMinorityPolicy, modifierSomeEverydayNeedsFulfilled;
static readonly Modifier modCountryIsToBig = new Modifier(x => (x as PopUnit).Country.getSize() > (x as PopUnit).Country.government.getTypedValue().getLoyaltySizeLimit(), "That country is too big for good management", -0.5f, false);
=======
modifierMinorityPolicy;
>>>>>>>
modifierMinorityPolicy, modifierSomeEverydayNeedsFulfilled; |
<<<<<<<
=======
public class LocaleState
{
public string Locale { get; set; }
}
>>>>>>> |
<<<<<<<
_statisticsViewModel = new StatisticsViewModel();
=======
_buildingSettingsViewModel = new BuildingSettingsViewModel();
>>>>>>>
_statisticsViewModel = new StatisticsViewModel();
_buildingSettingsViewModel = new BuildingSettingsViewModel();
<<<<<<<
private StatisticsViewModel _statisticsViewModel;
public StatisticsViewModel StatisticsViewModel
{
get { return _statisticsViewModel; }
set { _statisticsViewModel = value; }
}
=======
private BuildingSettingsViewModel _buildingSettingsViewModel;
public BuildingSettingsViewModel BuildingSettingsViewModel
{
get { return _buildingSettingsViewModel; }
set { _buildingSettingsViewModel = value; }
}
>>>>>>>
private StatisticsViewModel _statisticsViewModel;
public StatisticsViewModel StatisticsViewModel
{
get { return _statisticsViewModel; }
set { _statisticsViewModel = value; }
}
private BuildingSettingsViewModel _buildingSettingsViewModel;
public BuildingSettingsViewModel BuildingSettingsViewModel
{
get { return _buildingSettingsViewModel; }
set { _buildingSettingsViewModel = value; }
} |
<<<<<<<
using System.Threading;
=======
using System.Collections.ObjectModel;
>>>>>>>
using System.Threading;
using System.Collections.ObjectModel;
<<<<<<<
=======
//refresh localized influence types in combo box
comboxBoxInfluenceType.Items.Clear();
string[] rangeTypes = Enum.GetNames(typeof(BuildingInfluenceType));
string language = Localization.Localization.GetLanguageCodeFromName(SelectedLanguage);
foreach (string rangeType in rangeTypes)
{
comboxBoxInfluenceType.Items.Add(new KeyValuePair<BuildingInfluenceType, string>((BuildingInfluenceType)Enum.Parse(typeof(BuildingInfluenceType), rangeType), Localization.Localization.Translations[language][rangeType]));
}
comboxBoxInfluenceType.SelectedIndex = 0;
//update settings
>>>>>>>
//refresh localized influence types in combo box
comboxBoxInfluenceType.Items.Clear();
string[] rangeTypes = Enum.GetNames(typeof(BuildingInfluenceType));
string language = Localization.Localization.GetLanguageCodeFromName(SelectedLanguage);
foreach (string rangeType in rangeTypes)
{
comboxBoxInfluenceType.Items.Add(new KeyValuePair<BuildingInfluenceType, string>((BuildingInfluenceType)Enum.Parse(typeof(BuildingInfluenceType), rangeType), Localization.Localization.Translations[language][rangeType]));
}
comboxBoxInfluenceType.SelectedIndex = 0;
//update settings
<<<<<<<
var dependencyObject = LogicalTreeHelper.FindLogicalNode(this, "Menu");
mainWindowLocalization = (Localization.MainWindow)((Menu)dependencyObject).DataContext;
=======
DependencyObject dependencyObject = LogicalTreeHelper.FindLogicalNode(this, "Menu");
_mainWindowLocalization = (Localization.MainWindow)((Menu)dependencyObject).DataContext;
>>>>>>>
var dependencyObject = LogicalTreeHelper.FindLogicalNode(this, "Menu");
mainWindowLocalization = (Localization.MainWindow)((Menu)dependencyObject).DataContext;
<<<<<<<
/// <summary>
/// Renders the current layout to file.
/// </summary>
/// <param name="exportZoom">indicates whether the current zoom level should be applied, if false the default zoom is used</param>
/// <param name="exportSelection">indicates whether selection and influence highlights should be rendered</param>
public void ExportImage(bool exportZoom, bool exportSelection)
{
var dialog = new SaveFileDialog
{
DefaultExt = Constants.ExportedImageExtension,
Filter = Constants.ExportDialogFilter
};
if (!string.IsNullOrEmpty(annoCanvas.LoadedFile))
{
// default the filename to the same name as the saved layout
dialog.FileName = Path.GetFileNameWithoutExtension(annoCanvas.LoadedFile);
}
if (dialog.ShowDialog() == true)
{
try
{
RenderToFile(dialog.FileName, 1, exportZoom, exportSelection, statisticsView.IsVisible);
}
catch (Exception e)
{
MessageBox.Show(e.Message, "Something went wrong while saving/loading file.");
}
}
}
/// <summary>
/// Asynchronously renders the current layout to file.
/// </summary>
/// <param name="filename">filename of the output image</param>
/// <param name="border">normalization value used prior to exporting</param>
/// <param name="exportZoom">indicates whether the current zoom level should be applied, if false the default zoom is used</param>
/// <param name="exportSelection">indicates whether selection and influence highlights should be rendered</param>
private void RenderToFile(string filename, int border, bool exportZoom, bool exportSelection, bool renderStatistics)
{
if (annoCanvas.PlacedObjects.Count == 0)
{
return;
}
// copy all objects
var allObjects = annoCanvas.PlacedObjects.Select(_ => new AnnoObject(_)).ToList();
// copy selected objects
// note: should be references to the correct copied objects from allObjects
var selectedObjects = annoCanvas.SelectedObjects.Select(_ => new AnnoObject(_)).ToList();
System.Diagnostics.Debug.WriteLine("UI thread: {0}", Thread.CurrentThread.ManagedThreadId);
void renderThread()
{
System.Diagnostics.Debug.WriteLine("Render thread: {0}", Thread.CurrentThread.ManagedThreadId);
// initialize output canvas
var target = new AnnoCanvas
{
PlacedObjects = allObjects,
RenderGrid = annoCanvas.RenderGrid,
RenderIcon = annoCanvas.RenderIcon,
RenderLabel = annoCanvas.RenderLabel
};
// normalize layout
target.Normalize(border);
// set zoom level
if (exportZoom)
{
target.GridSize = annoCanvas.GridSize;
}
// set selection
if (exportSelection)
{
target.SelectedObjects.AddRange(selectedObjects);
}
// calculate output size
var width = target.GridToScreen(target.PlacedObjects.Max(_ => _.Position.X + _.Size.Width) + border) + 1;
var height = target.GridToScreen(target.PlacedObjects.Max(_ => _.Position.Y + _.Size.Height) + border) + 1;
if (renderStatistics)
{
var statisticsView = new StatisticsView
{
Margin = new Thickness(10, 0, 10, 0)
};
statisticsView.statisticsViewModel.UpdateStatistics(target.PlacedObjects, target.SelectedObjects, target.BuildingPresets);
target.StatisticsPanel.Children.Add(statisticsView);
width += Constants.StatisticsMargin + 10;
}
target.Width = width;
target.Height = height;
target.UpdateLayout();
// apply size
var outputSize = new Size(width, height);
target.Measure(outputSize);
target.Arrange(new Rect(outputSize));
// render canvas to file
DataIO.RenderToFile(target, filename);
}
var thread = new Thread(renderThread);
thread.SetApartmentState(ApartmentState.STA);
thread.Start();
}
=======
>>>>>>>
/// <summary>
/// Renders the current layout to file.
/// </summary>
/// <param name="exportZoom">indicates whether the current zoom level should be applied, if false the default zoom is used</param>
/// <param name="exportSelection">indicates whether selection and influence highlights should be rendered</param>
public void ExportImage(bool exportZoom, bool exportSelection)
{
var dialog = new SaveFileDialog
{
DefaultExt = Constants.ExportedImageExtension,
Filter = Constants.ExportDialogFilter
};
if (!string.IsNullOrEmpty(annoCanvas.LoadedFile))
{
// default the filename to the same name as the saved layout
dialog.FileName = Path.GetFileNameWithoutExtension(annoCanvas.LoadedFile);
}
if (dialog.ShowDialog() == true)
{
try
{
RenderToFile(dialog.FileName, 1, exportZoom, exportSelection, statisticsView.IsVisible);
}
catch (Exception e)
{
MessageBox.Show(e.Message, "Something went wrong while saving/loading file.");
}
}
}
/// <summary>
/// Asynchronously renders the current layout to file.
/// </summary>
/// <param name="filename">filename of the output image</param>
/// <param name="border">normalization value used prior to exporting</param>
/// <param name="exportZoom">indicates whether the current zoom level should be applied, if false the default zoom is used</param>
/// <param name="exportSelection">indicates whether selection and influence highlights should be rendered</param>
private void RenderToFile(string filename, int border, bool exportZoom, bool exportSelection, bool renderStatistics)
{
if (annoCanvas.PlacedObjects.Count == 0)
{
return;
}
// copy all objects
var allObjects = annoCanvas.PlacedObjects.Select(_ => new AnnoObject(_)).ToList();
// copy selected objects
// note: should be references to the correct copied objects from allObjects
var selectedObjects = annoCanvas.SelectedObjects.Select(_ => new AnnoObject(_)).ToList();
System.Diagnostics.Debug.WriteLine("UI thread: {0}", Thread.CurrentThread.ManagedThreadId);
void renderThread()
{
System.Diagnostics.Debug.WriteLine("Render thread: {0}", Thread.CurrentThread.ManagedThreadId);
// initialize output canvas
var target = new AnnoCanvas
{
PlacedObjects = allObjects,
RenderGrid = annoCanvas.RenderGrid,
RenderIcon = annoCanvas.RenderIcon,
RenderLabel = annoCanvas.RenderLabel
};
// normalize layout
target.Normalize(border);
// set zoom level
if (exportZoom)
{
target.GridSize = annoCanvas.GridSize;
}
// set selection
if (exportSelection)
{
target.SelectedObjects.AddRange(selectedObjects);
}
// calculate output size
var width = target.GridToScreen(target.PlacedObjects.Max(_ => _.Position.X + _.Size.Width) + border) + 1;
var height = target.GridToScreen(target.PlacedObjects.Max(_ => _.Position.Y + _.Size.Height) + border) + 1;
if (renderStatistics)
{
var statisticsView = new StatisticsView
{
Margin = new Thickness(10, 0, 10, 0)
};
statisticsView.statisticsViewModel.UpdateStatistics(target.PlacedObjects, target.SelectedObjects, target.BuildingPresets);
target.StatisticsPanel.Children.Add(statisticsView);
width += Constants.StatisticsMargin + 10;
}
target.Width = width;
target.Height = height;
target.UpdateLayout();
// apply size
var outputSize = new Size(width, height);
target.Measure(outputSize);
target.Arrange(new Rect(outputSize));
// render canvas to file
DataIO.RenderToFile(target, filename);
}
var thread = new Thread(renderThread);
thread.SetApartmentState(ApartmentState.STA);
thread.Start();
} |
<<<<<<<
private void LanguageMenuSubmenuClosed(object sender, RoutedEventArgs e)
{
SelectedLanguageChanged();
}
private void TreeViewPresetsMouseDoubleClick(object sender, MouseButtonEventArgs e)
{
ApplyPreset();
}
=======
private void LanguageMenuSubmenuClosed(object sender, RoutedEventArgs e)
{
SelectedLanguageChanged();
}
private void ComboxBoxInfluenceType_SelectionChanged(object sender, SelectionChangedEventArgs e)
{
var cbx = sender as ComboBox;
if (cbx.SelectedValue != null)
{
var influenceType = (BuildingInfluenceType)((KeyValuePair<BuildingInfluenceType, string>)cbx.SelectedItem).Key;
switch (influenceType)
{
case BuildingInfluenceType.None:
dockPanelInfluenceRadius.Visibility = Visibility.Collapsed;
dockPanelInfluenceRange.Visibility = Visibility.Collapsed;
break;
case BuildingInfluenceType.Radius:
dockPanelInfluenceRadius.Visibility = Visibility.Visible;
dockPanelInfluenceRange.Visibility = Visibility.Collapsed;
break;
case BuildingInfluenceType.Distance:
dockPanelInfluenceRadius.Visibility = Visibility.Collapsed;
dockPanelInfluenceRange.Visibility = Visibility.Visible;
break;
case BuildingInfluenceType.Both:
dockPanelInfluenceRadius.Visibility = Visibility.Visible;
dockPanelInfluenceRange.Visibility = Visibility.Visible;
break;
default:
dockPanelInfluenceRadius.Visibility = Visibility.Collapsed;
dockPanelInfluenceRange.Visibility = Visibility.Collapsed;
break;
}
}
}
#endregion
>>>>>>>
private void LanguageMenuSubmenuClosed(object sender, RoutedEventArgs e)
{
SelectedLanguageChanged();
}
private void TreeViewPresetsMouseDoubleClick(object sender, MouseButtonEventArgs e)
{
ApplyPreset();
}
}
}
private void LanguageMenuSubmenuClosed(object sender, RoutedEventArgs e)
{
SelectedLanguageChanged();
}
private void ComboxBoxInfluenceType_SelectionChanged(object sender, SelectionChangedEventArgs e)
{
var cbx = sender as ComboBox;
if (cbx.SelectedValue != null)
{
var influenceType = (BuildingInfluenceType)((KeyValuePair<BuildingInfluenceType, string>)cbx.SelectedItem).Key;
switch (influenceType)
{
case BuildingInfluenceType.None:
dockPanelInfluenceRadius.Visibility = Visibility.Collapsed;
dockPanelInfluenceRange.Visibility = Visibility.Collapsed;
break;
case BuildingInfluenceType.Radius:
dockPanelInfluenceRadius.Visibility = Visibility.Visible;
dockPanelInfluenceRange.Visibility = Visibility.Collapsed;
break;
case BuildingInfluenceType.Distance:
dockPanelInfluenceRadius.Visibility = Visibility.Collapsed;
dockPanelInfluenceRange.Visibility = Visibility.Visible;
break;
case BuildingInfluenceType.Both:
dockPanelInfluenceRadius.Visibility = Visibility.Visible;
dockPanelInfluenceRange.Visibility = Visibility.Visible;
break;
default:
dockPanelInfluenceRadius.Visibility = Visibility.Collapsed;
dockPanelInfluenceRange.Visibility = Visibility.Collapsed;
break;
}
<<<<<<<
private void TreeViewPresets_Loaded(object sender, RoutedEventArgs e)
{
if (Settings.Default.TreeViewState != null && Settings.Default.TreeViewState.Count > 0)
{
try
{
treeViewPresets.SetTreeViewState(Settings.Default.TreeViewState);
}
catch (Exception ex)
{
MessageBox.Show("Failed to restore previous preset menu settings.");
App.WriteToErrorLog("TreeView SetTreeViewState Error", ex.Message, ex.StackTrace);
}
}
_treeViewSearch = new TreeViewSearch<AnnoObject>(treeViewPresets, _ => _.Label)
{
MatchFullWordOnly = false,
IsCaseSensitive = false
};
_treeViewSearch.EnsureItemContainersGenerated();
}
#endregion
private void WindowClosing(object sender, CancelEventArgs e)
{
Settings.Default.TreeViewState = treeViewPresets.GetTreeViewState();
Settings.Default.Save();
}
=======
>>>>>>>
private void TreeViewPresets_Loaded(object sender, RoutedEventArgs e)
{
if (Settings.Default.TreeViewState != null && Settings.Default.TreeViewState.Count > 0)
{
try
{
treeViewPresets.SetTreeViewState(Settings.Default.TreeViewState);
}
catch (Exception ex)
{
MessageBox.Show("Failed to restore previous preset menu settings.");
App.WriteToErrorLog("TreeView SetTreeViewState Error", ex.Message, ex.StackTrace);
}
}
_treeViewSearch = new TreeViewSearch<AnnoObject>(treeViewPresets, _ => _.Label)
{
MatchFullWordOnly = false,
IsCaseSensitive = false
};
_treeViewSearch.EnsureItemContainersGenerated();
}
#endregion
private void WindowClosing(object sender, CancelEventArgs e)
{
Settings.Default.TreeViewState = treeViewPresets.GetTreeViewState();
Settings.Default.Save();
} |
<<<<<<<
//DockPanel
=======
#endregion
#region DockPanel
private string _buildingSettings;
public string BuildingSettings
{
get { return _buildingSettings; }
set
{
UpdateProperty(ref _buildingSettings, value);
}
}
private string _size;
public string Size
{
get { return _size; }
set
{
UpdateProperty(ref _size, value);
}
}
private string _color;
public string Color
{
get { return _color; }
set
{
UpdateProperty(ref _color, value);
}
}
private string _label;
public string Label
{
get { return _label; }
set
{
UpdateProperty(ref _label, value);
}
}
>>>>>>>
#endregion
#region DockPanel
<<<<<<<
private BuildingSettingsViewModel _buildingSettingsViewModel;
public BuildingSettingsViewModel BuildingSettingsViewModel
{
get { return _buildingSettingsViewModel; }
set { _buildingSettingsViewModel = value; }
}
=======
#endregion
>>>>>>>
#endregion
private BuildingSettingsViewModel _buildingSettingsViewModel;
public BuildingSettingsViewModel BuildingSettingsViewModel
{
get { return _buildingSettingsViewModel; }
set { _buildingSettingsViewModel = value; }
} |
<<<<<<<
=======
App.DpiScale = VisualTreeHelper.GetDpi(this);
>>>>>>>
App.DpiScale = VisualTreeHelper.GetDpi(this);
<<<<<<<
annoCanvas.StatisticsUpdated += AnnoCanvas_StatisticsUpdated;
=======
DpiChanged += MainWindow_DpiChanged;
>>>>>>>
annoCanvas.StatisticsUpdated += AnnoCanvas_StatisticsUpdated;
DpiChanged += MainWindow_DpiChanged;
<<<<<<<
/// <summary>
/// Renders the current layout to file.
/// </summary>
/// <param name="exportZoom">indicates whether the current zoom level should be applied, if false the default zoom is used</param>
/// <param name="exportSelection">indicates whether selection and influence highlights should be rendered</param>
public void ExportImage(bool exportZoom, bool exportSelection)
{
var dialog = new SaveFileDialog
{
DefaultExt = Constants.ExportedImageExtension,
Filter = Constants.ExportDialogFilter
};
if (!string.IsNullOrEmpty(annoCanvas.LoadedFile))
{
// default the filename to the same name as the saved layout
dialog.FileName = Path.GetFileNameWithoutExtension(annoCanvas.LoadedFile);
}
if (dialog.ShowDialog() == true)
{
try
{
RenderToFile(dialog.FileName, 1, exportZoom, exportSelection, statisticsView.IsVisible);
}
catch (Exception e)
{
MessageBox.Show(e.Message, "Something went wrong while saving/loading file.");
}
}
}
/// <summary>
/// Asynchronously renders the current layout to file.
/// </summary>
/// <param name="filename">filename of the output image</param>
/// <param name="border">normalization value used prior to exporting</param>
/// <param name="exportZoom">indicates whether the current zoom level should be applied, if false the default zoom is used</param>
/// <param name="exportSelection">indicates whether selection and influence highlights should be rendered</param>
private void RenderToFile(string filename, int border, bool exportZoom, bool exportSelection, bool renderStatistics)
{
if (annoCanvas.PlacedObjects.Count == 0)
{
return;
}
// copy all objects
var allObjects = annoCanvas.PlacedObjects.Select(_ => new AnnoObject(_)).ToList();
// copy selected objects
// note: should be references to the correct copied objects from allObjects
var selectedObjects = annoCanvas.SelectedObjects.Select(_ => new AnnoObject(_)).ToList();
System.Diagnostics.Debug.WriteLine("UI thread: {0}", Thread.CurrentThread.ManagedThreadId);
void renderThread()
{
System.Diagnostics.Debug.WriteLine("Render thread: {0}", Thread.CurrentThread.ManagedThreadId);
// initialize output canvas
var target = new AnnoCanvas
{
PlacedObjects = allObjects,
RenderGrid = annoCanvas.RenderGrid,
RenderIcon = annoCanvas.RenderIcon,
RenderLabel = annoCanvas.RenderLabel
};
// normalize layout
target.Normalize(border);
// set zoom level
if (exportZoom)
{
target.GridSize = annoCanvas.GridSize;
}
// set selection
if (exportSelection)
{
target.SelectedObjects.AddRange(selectedObjects);
}
// calculate output size
var width = target.GridToScreen(target.PlacedObjects.Max(_ => _.Position.X + _.Size.Width) + border) + 1;
var height = target.GridToScreen(target.PlacedObjects.Max(_ => _.Position.Y + _.Size.Height) + border) + 1;
if (renderStatistics)
{
var statisticsView = new StatisticsView
{
Margin = new Thickness(10, 0, 10, 0)
};
statisticsView.statisticsViewModel.UpdateStatistics(target.PlacedObjects, target.SelectedObjects, target.BuildingPresets);
target.StatisticsPanel.Children.Add(statisticsView);
width += Constants.StatisticsMargin + 10;
}
target.Width = width;
target.Height = height;
target.UpdateLayout();
// apply size
var outputSize = new Size(width, height);
target.Measure(outputSize);
target.Arrange(new Rect(outputSize));
// render canvas to file
DataIO.RenderToFile(target, filename);
}
var thread = new Thread(renderThread);
thread.SetApartmentState(ApartmentState.STA);
thread.Start();
}
=======
>>>>>>>
/// <summary>
/// Renders the current layout to file.
/// </summary>
/// <param name="exportZoom">indicates whether the current zoom level should be applied, if false the default zoom is used</param>
/// <param name="exportSelection">indicates whether selection and influence highlights should be rendered</param>
public void ExportImage(bool exportZoom, bool exportSelection)
{
var dialog = new SaveFileDialog
{
DefaultExt = Constants.ExportedImageExtension,
Filter = Constants.ExportDialogFilter
};
if (!string.IsNullOrEmpty(annoCanvas.LoadedFile))
{
// default the filename to the same name as the saved layout
dialog.FileName = Path.GetFileNameWithoutExtension(annoCanvas.LoadedFile);
}
if (dialog.ShowDialog() == true)
{
try
{
RenderToFile(dialog.FileName, 1, exportZoom, exportSelection, statisticsView.IsVisible);
}
catch (Exception e)
{
MessageBox.Show(e.Message, "Something went wrong while saving/loading file.");
}
}
}
/// <summary>
/// Asynchronously renders the current layout to file.
/// </summary>
/// <param name="filename">filename of the output image</param>
/// <param name="border">normalization value used prior to exporting</param>
/// <param name="exportZoom">indicates whether the current zoom level should be applied, if false the default zoom is used</param>
/// <param name="exportSelection">indicates whether selection and influence highlights should be rendered</param>
private void RenderToFile(string filename, int border, bool exportZoom, bool exportSelection, bool renderStatistics)
{
if (annoCanvas.PlacedObjects.Count == 0)
{
return;
}
// copy all objects
var allObjects = annoCanvas.PlacedObjects.Select(_ => new AnnoObject(_)).ToList();
// copy selected objects
// note: should be references to the correct copied objects from allObjects
var selectedObjects = annoCanvas.SelectedObjects.Select(_ => new AnnoObject(_)).ToList();
System.Diagnostics.Debug.WriteLine("UI thread: {0}", Thread.CurrentThread.ManagedThreadId);
void renderThread()
{
System.Diagnostics.Debug.WriteLine("Render thread: {0}", Thread.CurrentThread.ManagedThreadId);
// initialize output canvas
var target = new AnnoCanvas
{
PlacedObjects = allObjects,
RenderGrid = annoCanvas.RenderGrid,
RenderIcon = annoCanvas.RenderIcon,
RenderLabel = annoCanvas.RenderLabel
};
// normalize layout
target.Normalize(border);
// set zoom level
if (exportZoom)
{
target.GridSize = annoCanvas.GridSize;
}
// set selection
if (exportSelection)
{
target.SelectedObjects.AddRange(selectedObjects);
}
// calculate output size
var width = target.GridToScreen(target.PlacedObjects.Max(_ => _.Position.X + _.Size.Width) + border) + 1;
var height = target.GridToScreen(target.PlacedObjects.Max(_ => _.Position.Y + _.Size.Height) + border) + 1;
if (renderStatistics)
{
var statisticsView = new StatisticsView
{
Margin = new Thickness(10, 0, 10, 0)
};
statisticsView.statisticsViewModel.UpdateStatistics(target.PlacedObjects, target.SelectedObjects, target.BuildingPresets);
target.StatisticsPanel.Children.Add(statisticsView);
width += Constants.StatisticsMargin + 10;
}
target.Width = width;
target.Height = height;
target.UpdateLayout();
// apply size
var outputSize = new Size(width, height);
target.Measure(outputSize);
target.Arrange(new Rect(outputSize));
// render canvas to file
DataIO.RenderToFile(target, filename);
}
var thread = new Thread(renderThread);
thread.SetApartmentState(ApartmentState.STA);
thread.Start();
} |
<<<<<<<
{ "UpdateErrorPresetMessage" , "There was an error installing the update." },
{ "ColorsInLayout" , "Colors in Layout" },
{ "ColorsInLayoutToolTip" , "Double click color to select it" },
=======
{ "UpdateErrorPresetMessage" , "There was an error installing the update." },
{ "UpdateNoConnectionMessage" , "Could not establish a connection to the internet." }
>>>>>>>
{ "UpdateErrorPresetMessage" , "There was an error installing the update." },
{ "ColorsInLayout" , "Colors in Layout" },
{ "ColorsInLayoutToolTip" , "Double click color to select it" },
{ "UpdateNoConnectionMessage" , "Could not establish a connection to the internet." }
<<<<<<<
{ "UpdateErrorPresetMessage" , "Es gab einen Fehler bei der Installation des Updates." },
{ "ColorsInLayout" , "Farben im Layout" },
{ "ColorsInLayoutToolTip" , "Doppelklicken Sie auf die Farbe, um sie auszuwählen." },
=======
{ "UpdateErrorPresetMessage" , "Es gab einen Fehler bei der Installation des Updates." },
{ "UpdateNoConnectionMessage" , "Es konnte keine Verbindung zum Internet hergestellt werden." }
>>>>>>>
{ "UpdateErrorPresetMessage" , "Es gab einen Fehler bei der Installation des Updates." },
{ "ColorsInLayout" , "Farben im Layout" },
{ "ColorsInLayoutToolTip" , "Doppelklicken Sie auf die Farbe, um sie auszuwählen." },
{ "UpdateNoConnectionMessage" , "Es konnte keine Verbindung zum Internet hergestellt werden." }
<<<<<<<
{ "UpdateErrorPresetMessage" , "Il y a eu une erreur lors de l'installation de la mise à jour." },
{ "ColorsInLayout" , "Couleurs dans la mise en page" },
{ "ColorsInLayoutToolTip" , "Double-cliquez sur la couleur pour la sélectionner" },
=======
{ "UpdateErrorPresetMessage" , "Il y a eu une erreur lors de l'installation de la mise à jour." },
{ "UpdateNoConnectionMessage" , "Impossible d'établir une connexion à Internet." }
>>>>>>>
{ "UpdateErrorPresetMessage" , "Il y a eu une erreur lors de l'installation de la mise à jour." },
{ "ColorsInLayout" , "Couleurs dans la mise en page" },
{ "ColorsInLayoutToolTip" , "Double-cliquez sur la couleur pour la sélectionner" },
{ "UpdateNoConnectionMessage" , "Impossible d'établir une connexion à Internet." }
<<<<<<<
{ "UpdateErrorPresetMessage" , "Wystąpił błąd podczas instalacji aktualizacji." },
{ "ColorsInLayout" , "Kolory w układzie" },
{ "ColorsInLayoutToolTip" , "Podwójne kliknięcie na kolor, aby go wybrać" },
=======
{ "UpdateErrorPresetMessage" , "Wystąpił błąd podczas instalacji aktualizacji." },
{ "UpdateNoConnectionMessage" , "Nie udało się nawiązać połączenia z Internetem." }
>>>>>>>
{ "UpdateErrorPresetMessage" , "Wystąpił błąd podczas instalacji aktualizacji." },
{ "ColorsInLayout" , "Kolory w układzie" },
{ "ColorsInLayoutToolTip" , "Podwójne kliknięcie na kolor, aby go wybrać" },
{ "UpdateNoConnectionMessage" , "Nie udało się nawiązać połączenia z Internetem." }
<<<<<<<
{ "UpdateErrorPresetMessage" , "Произошла ошибка при установке обновления." },
{ "ColorsInLayout" , "Цвета в макетах" },
{ "ColorsInLayoutToolTip" , "Дважды щелкните по цвету, чтобы выбрать его." },
=======
{ "UpdateErrorPresetMessage" , "Произошла ошибка при установке обновления." },
{ "UpdateNoConnectionMessage" , "Не смог установить соединение с интернетом." }
>>>>>>>
{ "UpdateErrorPresetMessage" , "Произошла ошибка при установке обновления." },
{ "ColorsInLayout" , "Цвета в макетах" },
{ "ColorsInLayoutToolTip" , "Дважды щелкните по цвету, чтобы выбрать его." },
{ "UpdateNoConnectionMessage" , "Не смог установить соединение с интернетом." } |
<<<<<<<
_mainWindowLocalization.StatisticsViewModel.UpdateStatistics(annoCanvas.PlacedObjects,
annoCanvas.SelectedObjects,
annoCanvas.BuildingPresets);
=======
_mainWindowLocalization.TreeViewSearchText = string.Empty;
>>>>>>>
_mainWindowLocalization.StatisticsViewModel.UpdateStatistics(annoCanvas.PlacedObjects,
annoCanvas.SelectedObjects,
annoCanvas.BuildingPresets);
_mainWindowLocalization.TreeViewSearchText = string.Empty; |
<<<<<<<
=======
/// <summary>
/// A specialized translator that can handle specific scenarios.
/// </summary>
class SpecializedTranslatorMiddleware : TranslationMiddleware
{
public SpecializedTranslatorMiddleware(string[] nativeLanguages, string translatorKey) : base(nativeLanguages, translatorKey)
{ }
public override async Task OnTurnAsync(ITurnContext context, NextDelegate next, CancellationToken cancellationToken)
{
// alter the original utterance before translation.
if (context.Activity.Text == "mañana")
{
context.Activity.Text = "para mañana";
}
await base.OnTurnAsync(context, next, cancellationToken);
}
}
>>>>>>>
<<<<<<<
var adapter = new TestAdapter(sendTraceActivity: true)
.Use(new SpecializedTranslatorMiddleware(new[] {"en-us"}, _translatorKey, mockHttp.ToHttpClient()));
=======
var adapter = new TestAdapter()
.Use(new SpecializedTranslatorMiddleware(new[] { "en" }, translatorKey));
>>>>>>>
var adapter = new TestAdapter(sendTraceActivity: true)
.Use(new SpecializedTranslatorMiddleware(new[] { "en" }, _translatorKey, mockHttp.ToHttpClient()));
<<<<<<<
.Use(new TranslationMiddleware(new[] {"en-us"}, _translatorKey, httpClient: mockHttp.ToHttpClient()));
=======
.Use(new TranslationMiddleware(new[] { "en" }, translatorKey));
>>>>>>>
.Use(new TranslationMiddleware(new[] { "en" }, _translatorKey, httpClient: mockHttp.ToHttpClient()));
<<<<<<<
private string GetRequestDetect(string text)
{
return "http://api.microsofttranslator.com/v2/Http.svc/Detect?text=" + text;
}
private string GetResponseDetect(string text)
{
return $"<string xmlns=\"http://schemas.microsoft.com/2003/10/Serialization/\">{text}</string>";
}
private Stream GetResponse(string fileName)
{
var path = Path.Combine(Environment.CurrentDirectory, "TestData", fileName);
return File.OpenRead(path);
}
private void SetLanguage(ITurnContext context, string language) => context.GetUserState<LanguageState>().Language = language;
protected async Task<bool> SetActiveLanguage(ITurnContext context)
=======
protected async Task<bool> HandleChangeLanguageRequest(ITurnContext context, IStatePropertyAccessor<string> languageProperty)
>>>>>>>
private string GetRequestDetect(string text)
{
return "http://api.microsofttranslator.com/v2/Http.svc/Detect?text=" + text;
}
private string GetResponseDetect(string text)
{
return $"<string xmlns=\"http://schemas.microsoft.com/2003/10/Serialization/\">{text}</string>";
}
private Stream GetResponse(string fileName)
{
var path = Path.Combine(Environment.CurrentDirectory, "TestData", fileName);
return File.OpenRead(path);
}
protected async Task<bool> HandleChangeLanguageRequest(ITurnContext context, IStatePropertyAccessor<string> languageProperty)
<<<<<<<
protected string GetActiveLanguage(ITurnContext context)
{
if (context.Activity.Type == ActivityTypes.Message
&& !string.IsNullOrEmpty(context.GetUserState<LanguageState>().Language))
{
return context.GetUserState<LanguageState>().Language;
}
return "en";
}
}
class LanguageState
{
public string Language { get; set; }
}
/// <summary>
/// A specialized translator that can handle specific scenarios.
/// </summary>
class SpecializedTranslatorMiddleware : TranslationMiddleware
{
public SpecializedTranslatorMiddleware(string[] nativeLanguages, string translatorKey, HttpClient client) : base(nativeLanguages, translatorKey, httpClient: client)
{ }
public override async Task OnTurnAsync(ITurnContext context, NextDelegate next, CancellationToken cancellationToken)
=======
private bool EnvironmentVariablesDefined()
>>>>>>>
}
class LanguageState
{
public string Language { get; set; }
}
/// <summary>
/// A specialized translator that can handle specific scenarios.
/// </summary>
class SpecializedTranslatorMiddleware : TranslationMiddleware
{
public SpecializedTranslatorMiddleware(string[] nativeLanguages, string translatorKey, HttpClient client) : base(nativeLanguages, translatorKey, httpClient: client)
{ }
public override async Task OnTurnAsync(ITurnContext context, NextDelegate next, CancellationToken cancellationToken) |
<<<<<<<
using System.Collections.Generic;
using System.Drawing;
=======
>>>>>>>
using System.Collections.Generic;
<<<<<<<
IEnumerable<ShaderParamInfo> GetShaderParamList(IShaderProgramImp shaderProgram);
=======
>>>>>>>
IEnumerable<ShaderParamInfo> GetShaderParamList(IShaderProgramImp shaderProgram); |
<<<<<<<
=======
public static IMessageActivity ReplyWithSuggestions(BotContext context, string title, string message, string[] choices)
{
var reply = ReplyWithTitle(context, title, message);
reply.SuggestedActions = new SuggestedActions(
actions: choices.Select(choice =>
new CardAction(type: ActionTypes.ImBack,
title: choice,
value: choice.ToLower(),
displayText: choice.ToLower(),
text: choice.ToLower())).ToList());
return reply;
}
public static IMessageActivity ReplyWithTitle(IBotContext context, string title, string message)
{
StringBuilder sb = new StringBuilder();
if (title != null)
sb.AppendLine($"# {title}\n");
if (message != null)
sb.AppendLine(message);
return context.Request.CreateReply(sb.ToString());
}
>>>>>>>
public static IMessageActivity ReplyWithSuggestions(BotContext context, string title, string message, string[] choices)
{
var reply = ReplyWithTitle(context, title, message);
reply.SuggestedActions = new SuggestedActions(
actions: choices.Select(choice =>
new CardAction(type: ActionTypes.ImBack,
title: choice,
value: choice.ToLower(),
displayText: choice.ToLower(),
text: choice.ToLower())).ToList());
return reply;
}
public static IMessageActivity ReplyWithTitle(IBotContext context, string title, string message)
{
StringBuilder sb = new StringBuilder();
if (title != null)
sb.AppendLine($"# {title}\n");
if (message != null)
sb.AppendLine(message);
return context.Request.CreateReply(sb.ToString());
}
<<<<<<<
IMessageActivity reply = context.Request.CreateReply(message);
=======
IMessageActivity reply = context.Request.CreateReply(message);
>>>>>>>
IMessageActivity reply = context.Request.CreateReply(message); |
<<<<<<<
=======
#endregion
#region Constructors
>>>>>>>
#endregion
#region Constructors
<<<<<<<
=======
#endregion
#region Members
>>>>>>>
#endregion
#region Members |
<<<<<<<
{
if (services == null)
{
throw new ArgumentNullException(nameof(services));
}
if (configureAction != null)
{
services.Configure(configureAction);
}
services.PostConfigure<BotFrameworkOptions>(options =>
{
if (options.CredentialProvider == null)
{
options.CredentialProvider = new SimpleCredentialProvider();
}
});
services.AddTransient<IBot, TBot>();
services.AddSingleton(sp =>
{
var options = sp.GetRequiredService<IOptions<BotFrameworkOptions>>().Value;
var botFrameworkAdapter = new BotFrameworkAdapter(options.CredentialProvider, options.ChannelProvider, options.ConnectorClientRetryPolicy, options.HttpClient);
botFrameworkAdapter.OnTurnError = options.OnTurnError;
foreach (var middleware in options.Middleware)
{
botFrameworkAdapter.Use(middleware);
}
return botFrameworkAdapter;
});
return services;
}
}
}
=======
{
if (services == null)
{
throw new ArgumentNullException(nameof(services));
}
if (configureAction != null)
{
services.Configure(configureAction);
}
services.AddTransient<IBot, TBot>();
services.AddSingleton(sp =>
{
var options = sp.GetRequiredService<IOptions<BotFrameworkOptions>>().Value;
var botFrameworkAdapter = new BotFrameworkAdapter(options.CredentialProvider, options.ConnectorClientRetryPolicy, options.HttpClient)
{
OnTurnError = options.OnTurnError,
};
foreach (var middleware in options.Middleware)
{
botFrameworkAdapter.Use(middleware);
}
return botFrameworkAdapter;
});
return services;
}
}
}
>>>>>>>
{
if (services == null)
{
throw new ArgumentNullException(nameof(services));
}
if (configureAction != null)
{
services.Configure(configureAction);
}
services.AddTransient<IBot, TBot>();
services.AddSingleton(sp =>
{
var options = sp.GetRequiredService<IOptions<BotFrameworkOptions>>().Value;
var botFrameworkAdapter = new BotFrameworkAdapter(options.CredentialProvider, options.ChannelProvider, options.ConnectorClientRetryPolicy, options.HttpClient)
{
OnTurnError = options.OnTurnError,
};
foreach (var middleware in options.Middleware)
{
botFrameworkAdapter.Use(middleware);
}
return botFrameworkAdapter;
});
return services;
}
}
} |
<<<<<<<
private TransformComponent _camTransform;
private const float twoPi = M.Pi * 2.0f;
=======
//rnd is public so unit tests can inject a seeded random.
public Random rnd;
>>>>>>>
private TransformComponent _camTransform;
private const float twoPi = M.Pi * 2.0f;
//rnd is public so unit tests can inject a seeded random.
public Random rnd;
<<<<<<<
_camTransform = new TransformComponent()
{
Rotation = new float3(0, 0, 0),
Scale = float3.One,
Translation = new float3(0, 0, -5)
};
var monkey = _scene.Children[0].GetComponent<Mesh>();
var rnd = new Random();
=======
var monkey = _scene.Children[1].GetComponent<Mesh>();
if (rnd == null)
rnd = new Random();
>>>>>>>
_camTransform = new TransformComponent()
{
Rotation = new float3(0, 0, 0),
Scale = float3.One,
Translation = new float3(0, 0, -5)
};
var monkey = _scene.Children[0].GetComponent<Mesh>();
var rnd = new Random();
<<<<<<<
=======
var projComp = _scene.Children[0].GetComponent<ProjectionComponent>();
>>>>>>>
<<<<<<<
var newPick = _scenePicker.Pick(RC, new float2(clipPos.x, clipPos.y)).ToList().OrderBy(pr => pr.ClipPos.z).FirstOrDefault();
=======
var newPick = _scenePicker.Pick(new float2(clipPos.x, clipPos.y)).ToList().OrderBy(pr => pr.ClipPos.z).FirstOrDefault();
>>>>>>>
var newPick = _scenePicker.Pick(RC, new float2(clipPos.x, clipPos.y)).ToList().OrderBy(pr => pr.ClipPos.z).FirstOrDefault();
<<<<<<<
circle.GetComponent<ShaderEffectComponent>().Effect.SetDiffuseAlphaInShaderEffect(UIHelper.alphaVis);
=======
>>>>>>>
circle.GetComponent<ShaderEffectComponent>().Effect.SetDiffuseAlphaInShaderEffect(UIHelper.alphaVis);
<<<<<<<
=======
////TODO: set screen space UI projection to orthographic in SceneRenderer
//if (_canvasRenderMode == CanvasRenderMode.SCREEN)
//{
// // Render the scene loaded in Init()
// _sceneRenderer.Render(RC);
// projection = float4x4.CreateOrthographic(Width, Height, ZNear, ZFar);
// RC.Projection = projection;
// //_sih.Projection = projection;
// _guiRenderer.Render(RC);
//}
//else
//{
//}
>>>>>>>
<<<<<<<
=======
>>>>>>>
<<<<<<<
=======
var canvasProjComp = new ProjectionComponent(_canvasRenderMode == CanvasRenderMode.SCREEN ? ProjectionMethod.ORTHOGRAPHIC : ProjectionMethod.PERSPECTIVE, ZNear, ZFar, _fovy);
canvas.Components.Insert(0, canvasProjComp);
>>>>>>> |
<<<<<<<
private const string VsDiffuse = @"
#ifndef GL_ES
#version 120
#endif
=======
>>>>>>>
<<<<<<<
private const string PsDiffuse = @"
#ifndef GL_ES
#version 120
#endif
=======
>>>>>>>
<<<<<<<
private const string VsSpecular = @"
#ifndef GL_ES
#version 120
=======
private const string VsDiffuse2 = @"
attribute vec4 fuColor;
attribute vec3 fuVertex;
attribute vec3 fuNormal;
attribute vec2 fuUV;
uniform mat4 FUSEE_M;
uniform mat4 FUSEE_MV;
uniform mat4 FUSEE_MVP;
uniform vec4 FUSEE_L0_AMBIENT;
uniform vec4 FUSEE_L1_AMBIENT;
uniform vec4 FUSEE_L2_AMBIENT;
uniform vec4 FUSEE_L3_AMBIENT;
uniform vec4 FUSEE_L4_AMBIENT;
uniform vec4 FUSEE_L5_AMBIENT;
uniform vec4 FUSEE_L6_AMBIENT;
uniform vec4 FUSEE_L7_AMBIENT;
uniform float FUSEE_L0_ACTIVE;
uniform float FUSEE_L1_ACTIVE;
uniform float FUSEE_L2_ACTIVE;
uniform float FUSEE_L3_ACTIVE;
uniform float FUSEE_L4_ACTIVE;
uniform float FUSEE_L5_ACTIVE;
uniform float FUSEE_L6_ACTIVE;
uniform float FUSEE_L7_ACTIVE;
varying vec2 vUV;
varying vec3 vNormal;
varying vec4 endAmbient;
varying vec3 vPos;
void main(void)
{
vUV = fuUV;
vPos = normalize(vec3(mat3(FUSEE_MV[0].xyz, FUSEE_MV[1].xyz, FUSEE_MV[2].xyz) * fuVertex));
vNormal = normalize(vec3(mat3(FUSEE_M[0].xyz, FUSEE_M[1].xyz, FUSEE_M[2].xyz) * fuNormal));
endAmbient=vec4(0,0,0,0);
if(FUSEE_L0_ACTIVE == 1.0) {
endAmbient += FUSEE_L0_AMBIENT;
}
if(FUSEE_L1_ACTIVE == 1.0) {
endAmbient += FUSEE_L1_AMBIENT;
}
if(FUSEE_L2_ACTIVE == 1.0) {
endAmbient += FUSEE_L2_AMBIENT;
}
if(FUSEE_L3_ACTIVE == 1.0) {
endAmbient += FUSEE_L3_AMBIENT;
}
if(FUSEE_L4_ACTIVE == 1.0) {
endAmbient += FUSEE_L4_AMBIENT;
}
if(FUSEE_L5_ACTIVE == 1.0) {
endAmbient += FUSEE_L5_AMBIENT;
}
if(FUSEE_L6_ACTIVE == 1.0) {
endAmbient += FUSEE_L6_AMBIENT;
}
if(FUSEE_L7_ACTIVE == 1.0) {
endAmbient += FUSEE_L7_AMBIENT;
}
//endAmbient=normalize(endAmbient);
//endAmbient = clamp(endAmbient, 0.0, 1.0);
gl_Position = FUSEE_MVP * vec4(fuVertex, 1.0);
}";
private const string PsDiffuse2 = @"
#ifdef GL_ES
precision highp float;
>>>>>>>
#version 120private const string VsDiffuse2 = @"
attribute vec4 fuColor;
attribute vec3 fuVertex;
attribute vec3 fuNormal;
attribute vec2 fuUV;
uniform mat4 FUSEE_M;
uniform mat4 FUSEE_MV;
uniform mat4 FUSEE_MVP;
uniform vec4 FUSEE_L0_AMBIENT;
uniform vec4 FUSEE_L1_AMBIENT;
uniform vec4 FUSEE_L2_AMBIENT;
uniform vec4 FUSEE_L3_AMBIENT;
uniform vec4 FUSEE_L4_AMBIENT;
uniform vec4 FUSEE_L5_AMBIENT;
uniform vec4 FUSEE_L6_AMBIENT;
uniform vec4 FUSEE_L7_AMBIENT;
uniform float FUSEE_L0_ACTIVE;
uniform float FUSEE_L1_ACTIVE;
uniform float FUSEE_L2_ACTIVE;
uniform float FUSEE_L3_ACTIVE;
uniform float FUSEE_L4_ACTIVE;
uniform float FUSEE_L5_ACTIVE;
uniform float FUSEE_L6_ACTIVE;
uniform float FUSEE_L7_ACTIVE;
varying vec2 vUV;
varying vec3 vNormal;
varying vec4 endAmbient;
varying vec3 vPos;
void main(void)
{
vUV = fuUV;
vPos = normalize(vec3(mat3(FUSEE_MV[0].xyz, FUSEE_MV[1].xyz, FUSEE_MV[2].xyz) * fuVertex));
vNormal = normalize(vec3(mat3(FUSEE_M[0].xyz, FUSEE_M[1].xyz, FUSEE_M[2].xyz) * fuNormal));
endAmbient=vec4(0,0,0,0);
if(FUSEE_L0_ACTIVE == 1.0) {
endAmbient += FUSEE_L0_AMBIENT;
}
if(FUSEE_L1_ACTIVE == 1.0) {
endAmbient += FUSEE_L1_AMBIENT;
}
if(FUSEE_L2_ACTIVE == 1.0) {
endAmbient += FUSEE_L2_AMBIENT;
}
if(FUSEE_L3_ACTIVE == 1.0) {
endAmbient += FUSEE_L3_AMBIENT;
}
if(FUSEE_L4_ACTIVE == 1.0) {
endAmbient += FUSEE_L4_AMBIENT;
}
if(FUSEE_L5_ACTIVE == 1.0) {
endAmbient += FUSEE_L5_AMBIENT;
}
if(FUSEE_L6_ACTIVE == 1.0) {
endAmbient += FUSEE_L6_AMBIENT;
}
if(FUSEE_L7_ACTIVE == 1.0) {
endAmbient += FUSEE_L7_AMBIENT;
}
//endAmbient=normalize(endAmbient);
//endAmbient = clamp(endAmbient, 0.0, 1.0);
gl_Position = FUSEE_MVP * vec4(fuVertex, 1.0);
}";
private const string PsDiffuse2 = @"
#ifdef GL_ES
precision highp float;
<<<<<<<
private const string PsSpecular = @"
#ifndef GL_ES
#version 120
#endif
=======
>>>>>>>
<<<<<<<
private const string VsBump = @"
#ifndef GL_ES
# version 120
#endif
=======
>>>>>>>
<<<<<<<
eyeVector = mat3(FUSEE_MVP) * -fuVertex;
=======
eyeVector = mat3(FUSEE_MVP[0].xyz, FUSEE_MVP[1].xyz, FUSEE_MVP[2].xyz) * -fuVertex;
>>>>>>>
eyeVector = mat3(FUSEE_MVP[0].xyz, FUSEE_MVP[1].xyz, FUSEE_MVP[2].xyz) * -fuVertex;
<<<<<<<
private const string Ps = @"
#ifndef GL_ES
#version 120
#endif
=======
>>>>>>> |
<<<<<<<
=======
//if (_gamePad != null)
// Diagnostics.Log(_gamePad.LSX);
>>>>>>>
//if (_gamePad != null)
// Diagnostics.Log(_gamePad.LSX);
<<<<<<<
=======
// TODO: fixme I'm broken.
//else if (_spaceMouse != null)
//{
// _angleVelHorz += _spaceMouse.Rotation.y * -0.00005f * DeltaTime;
// _angleVelVert += _spaceMouse.Rotation.x * -0.00005f * DeltaTime;
//}
//else if (_gamePad != null)
//{
// _angleVelHorz -= -RotationSpeed * _gamePad.LSX * DeltaTime;
// _angleVelVert -= -RotationSpeed * _gamePad.LSY * DeltaTime;
//}
>>>>>>> |
<<<<<<<
internal struct MatrixParamNames
{
// ReSharper disable InconsistentNaming
public IShaderParam FUSEE_M;
public IShaderParam FUSEE_V;
public IShaderParam FUSEE_MV;
public IShaderParam FUSEE_P;
public IShaderParam FUSEE_MVP;
public IShaderParam FUSEE_IMV;
public IShaderParam FUSEE_IP;
public IShaderParam FUSEE_IMVP;
public IShaderParam FUSEE_TMV;
public IShaderParam FUSEE_TP;
public IShaderParam FUSEE_TMVP;
public IShaderParam FUSEE_ITMV;
public IShaderParam FUSEE_ITP;
public IShaderParam FUSEE_ITMVP;
// ReSharper restore InconsistentNaming
};
internal struct LightParamNames
{
// ReSharper disable InconsistentNaming
public IShaderParam FUSEE_L_AMBIENT;
public IShaderParam FUSEE_L_DIFFUSE;
public IShaderParam FUSEE_L_SPECULAR;
public IShaderParam FUSEE_L_POSITION;
public IShaderParam FUSEE_L_DIRECTION;
public IShaderParam FUSEE_L_SPOTANGLE;
public IShaderParam FUSEE_L_ACTIVE;
// ReSharper restore InconsistentNaming
}
/// <summary>
///
/// </summary>
/// <param name="rci"></param>
public RenderContext(IRenderContextImp rci)
{
_rci = rci;
View = float4x4.Identity;
ModelView = float4x4.Identity;
Projection = float4x4.Identity;
frustum = new Frustum(ModelViewProjection);
_lightParams = new Light[8];
_lightShaderParams = new LightParamNames[8];
_debugShader = MoreShaders.GetShader("color",this);
_debugColor = _debugShader.GetShaderParam("color");
_updatedShaderParams = false;
}
=======
>>>>>>>
public IShaderParam FUSEE_L_SPOTANGLE;
public IShaderParam FUSEE_L_ACTIVE;
<<<<<<<
_updatedShaderParams = false;
if (_currentShader != program)
{
_currentShader = program;
_rci.SetShader(program._spi);
}
UpdateShaderParams();
}
=======
_updatedShaderParams = false;
if (_currentShader != program)
{
_currentShader = program;
_rci.SetShader(program._spi);
}
UpdateShaderParams();
}
>>>>>>>
_updatedShaderParams = false;
if (_currentShader != program)
{
_currentShader = program;
_rci.SetShader(program._spi);
}
UpdateShaderParams();
}
<<<<<<<
public bool DebugLinesEnabled
{
get { return _debugLinesEnabled; }
set { _debugLinesEnabled = value; }
}
=======
/// <summary>
/// Draws a Debug Line in 3D Space by using a start and end point (float3).
/// </summary>
/// <param name="start">The startpoint of the DebugLine.</param>
/// <param name="end">The endpoint of the DebugLine.</param>
/// <param name="color">The color of the DebugLine.</param>
>>>>>>>
public bool DebugLinesEnabled
{
get { return _debugLinesEnabled; }
set { _debugLinesEnabled = value; }
}
/// <summary>
/// Draws a Debug Line in 3D Space by using a start and end point (float3).
/// </summary>
/// <param name="start">The startpoint of the DebugLine.</param>
/// <param name="end">The endpoint of the DebugLine.</param>
/// <param name="color">The color of the DebugLine.</param>
<<<<<<<
if (_debugLinesEnabled)
{
start /= 2;
end /= 2;
SetShader(_debugShader);
SetShaderParam(_currentShaderParams.FUSEE_MVP, ModelViewProjection);
//IShaderParam col = _debugShader.GetShaderParam("Col");
SetShaderParam(_debugColor, color);
_rci.DebugLine(start, end, color);
}
=======
start /= 2;
end /= 2;
var oldShader = _currentShader;
SetShader(_debugShader);
SetShaderParam(_currentShaderParams.FUSEE_MVP, ModelViewProjection);
//IShaderParam col = _debugShader.GetShaderParam("Col");
SetShaderParam(_debugColor, color);
_rci.DebugLine(start, end, color);
SetShader(oldShader);
}
public void GetBufferContent(Rectangle quad, ITexture texId)
{
_rci.GetBufferContent(quad, texId);
>>>>>>>
if (_debugLinesEnabled)
{
start /= 2;
end /= 2;
var oldShader = _currentShader;
SetShader(_debugShader);
SetShaderParam(_currentShaderParams.FUSEE_MVP, ModelViewProjection);
//IShaderParam col = _debugShader.GetShaderParam("Col");
SetShaderParam(_debugColor, color);
_rci.DebugLine(start, end, color);
SetShader(oldShader);
}
public void GetBufferContent(Rectangle quad, ITexture texId)
{
_rci.GetBufferContent(quad, texId);
}
<<<<<<<
/// <summary>
/// The depth value to use when clearing the color buffer.
/// </summary>
/// <value>
/// Typically set to the highest possible depth value. Typically ranges between 0 and 1.
/// </value>
/// <remarks>
/// This is the depth (z-) value that will be copied to all pixels in the depth (z-) buffer when Clear is called on the render context.
/// </remarks>
public float ClearDepth
{
set { _rci.ClearDepth = value; }
get { return _rci.ClearDepth; }
}
public void UpdateFrustum()
{
frustum.setFrustum(InvModelViewProjection);
}
=======
#endregion
>>>>>>>
#endregion
public void UpdateFrustum()
{
frustum.setFrustum(InvModelViewProjection);
} |
<<<<<<<
private static Type _physicsImplementor;
[JSIgnore]
=======
private static Type _networkImplementor;
[JSIgnore]
>>>>>>>
private static Type _physicsImplementor;
[JSIgnore]
private static Type _networkImplementor;
[JSIgnore]
<<<<<<<
//PhysicsImp
[JSExternal]
public static IDynamicWorldImp CreateIDynamicWorldImp()
{
MethodInfo mi = PhysicsImplementor.GetMethod("CreateDynamicWorldImp");
if (mi == null)
throw new Exception("Implementor type (" + PhysicsImplementor.ToString() + ") doesn't contain method CreateDynamicWorldImp");
return (IDynamicWorldImp)mi.Invoke(null, null);
}
=======
/// <summary>
/// Creates an instance of <see cref="IRenderContextImp"/> by reflection of RenderingImplementor.
/// </summary>
/// <param name="renderCanvas">The render canvas.</param>
/// <returns></returns>
/// <exception cref="System.Exception">Implementor type ( + RenderingImplementor.ToString() + ) doesn't contain method CreateRenderContextImp</exception>
>>>>>>>
//PhysicsImp
[JSExternal]
public static IDynamicWorldImp CreateIDynamicWorldImp()
{
MethodInfo mi = PhysicsImplementor.GetMethod("CreateDynamicWorldImp");
if (mi == null)
throw new Exception("Implementor type (" + PhysicsImplementor.ToString() + ") doesn't contain method CreateDynamicWorldImp");
return (IDynamicWorldImp)mi.Invoke(null, null);
}
/// <summary>
/// Creates an instance of <see cref="IRenderContextImp"/> by reflection of RenderingImplementor.
/// </summary>
/// <param name="renderCanvas">The render canvas.</param>
/// <returns></returns>
/// <exception cref="System.Exception">Implementor type ( + RenderingImplementor.ToString() + ) doesn't contain method CreateRenderContextImp</exception> |
<<<<<<<
//directional or Point- Light
public void SetLight(float3 v3, float4 color, int type, int id)
{
switch (type)
{
case 0:
SetLightActive(id, 1);
SetLightAmbient(id, color);
SetLightDiffuse(id, color);
SetLightSpecular(id, color);
SetLightDirection(id, v3);
break;
case 1:
SetLightActive(id, 1);
SetLightAmbient(id, color);
SetLightDiffuse(id, color);
SetLightSpecular(id, color);
SetLightPosition(id, v3);
break;
}
}
//Spotlight with position AND direction
public void SetLight(float3 position, float3 direction, float4 color, int type, int id)
{
SetLightActive(id, 1);
SetLightAmbient(id, color);
SetLightDiffuse(id, color);
SetLightSpecular(id, color);
SetLightPosition(id, position);
SetLightDirection(id,direction);
}
=======
public ShaderProgram CurrentShader
{
get { return _currentShader; }
}
>>>>>>>
public ShaderProgram CurrentShader
{
get { return _currentShader; }
}
//directional or Point- Light
public void SetLight(float3 v3, float4 color, int type, int id)
{
switch (type)
{
case 0:
SetLightActive(id, 1);
SetLightAmbient(id, color);
SetLightDiffuse(id, color);
SetLightSpecular(id, color);
SetLightDirection(id, v3);
break;
case 1:
SetLightActive(id, 1);
SetLightAmbient(id, color);
SetLightDiffuse(id, color);
SetLightSpecular(id, color);
SetLightPosition(id, v3);
break;
}
}
//Spotlight with position AND direction
public void SetLight(float3 position, float3 direction, float4 color, int type, int id)
{
SetLightActive(id, 1);
SetLightAmbient(id, color);
SetLightDiffuse(id, color);
SetLightSpecular(id, color);
SetLightPosition(id, position);
SetLightDirection(id,direction);
} |
<<<<<<<
=======
#endregion
#region Constructors
>>>>>>>
#endregion
<<<<<<<
renderContext.SetLight(_position, _diffuseColor, _ambientColor, _specularColor, (int)_type, _channel);
//Console.WriteLine("Pointlight worked");
=======
renderContext.SetLight(_position, _color, (int)_type, _channel);
>>>>>>>
renderContext.SetLight(_position, _diffuseColor, _ambientColor, _specularColor, (int)_type, _channel); |
<<<<<<<
=======
>>>>>>>
<<<<<<<
// Set Context here, so that even the first pass is rendered defered or with shadows
// otherwise DeferredShaderHelper.GBufferPassShaderEffect is not initialized and null leading to an exception
SetContext(rc);
if (DoRenderWithShadows)
{
RenderWithShadow(rc);
}
else if (DoRenderDeferred)
{
RenderDeferredPasses(rc);
}
else if (DoRenderEnvMap)
{
RenderEnvMapPasses(rc);
}
else
{
rc.SetRenderTarget(null);
Traverse(_sc.Children);
}
}
private void RenderDeferredPasses(RenderContext rc)
{
=======
>>>>>>>
<<<<<<<
if (DeferredShaderHelper.GBufferTexture == null)
DeferredShaderHelper.GBufferTexture = rc.CreateWritableTexture(rc.ViewportWidth, rc.ViewportHeight, WritableTextureFormat.GBuffer);
if (DeferredShaderHelper.GBufferPassShaderEffect == null)
CreateGBufferPassEffect(rc);
if (DeferredShaderHelper.GBufferDrawPassShaderEffect == null)
CreateGBufferDrawPassEffect(rc);
if (DeferredShaderHelper.GBufferPassShaderEffect != null)
DeferredShaderHelper.GBufferPassShaderEffect.AttachToContext(rc);
// Set RenderTarget to gBuffer
rc.SetRenderTarget(DeferredShaderHelper.GBufferTexture);
//rc.SetRenderTarget(null);
Traverse(_sc.Children);
DeferredShaderHelper.CurrentRenderPass++;
// copy depthbuffer to current buffer
rc.SetRenderTarget(null);
rc.CopyDepthBufferFromDeferredBuffer(DeferredShaderHelper.GBufferTexture);
RenderDeferredLightPass();
//Traverse(_sc.Children);
DeferredShaderHelper.CurrentRenderPass--;
}
private void RenderEnvMapPasses(RenderContext rc)
{
SetContext(rc);
if (DeferredShaderHelper.EnvMapTexture == null)
DeferredShaderHelper.EnvMapTexture = rc.CreateWritableTexture(rc.ViewportWidth, rc.ViewportHeight, WritableTextureFormat.CubeMap);
if (DeferredShaderHelper.EnvMapPassShaderEffect == null)
CreateEnvMapPassEffect(rc);
if (DeferredShaderHelper.EnvMapPassShaderEffect != null)
DeferredShaderHelper.EnvMapPassShaderEffect.AttachToContext(rc);
// Set RenderTarget to EnvMap
for (var i = 0; i < 6; i++) // render all sides
{
rc.SetCubeMapRenderTarget(DeferredShaderHelper.EnvMapTexture, i);
DeferredShaderHelper.EnvMapTextureOrientation = i;
Traverse(_sc.Children);
}
DeferredShaderHelper.CurrentRenderPass++;
=======
>>>>>>>
<<<<<<<
var newRect = new MinMaxRect
{
Min = _state.UiRect.Min + _state.UiRect.Size * rtc.Anchors.Min + rtc.Offsets.Min,
Max = _state.UiRect.Min + _state.UiRect.Size * rtc.Anchors.Max + rtc.Offsets.Max
};
var transformChild = float4x4.CreateTranslation(newRect.Center.x, newRect.Center.y, 0);
=======
MinMaxRect newRect = new MinMaxRect();
newRect.Min = _state.UiRect.Min + _state.UiRect.Size * rtc.Anchors.Min + rtc.Offsets.Min;
newRect.Max = _state.UiRect.Min + _state.UiRect.Size * rtc.Anchors.Max + rtc.Offsets.Max;
var trans = newRect.Center - _state.UiRect.Center;
var scale = new float2(newRect.Size.x / _state.UiRect.Size.x, newRect.Size.y / _state.UiRect.Size.y);
var model = float4x4.CreateTranslation(trans.x, trans.y, 0) * float4x4.Scale(scale.x, scale.y, 1.0f);
// var model = float4x4.Invert(_state.Model) * float4x4.CreateTranslation(newRectCenter.x, newRectCenter.y, 0) * float4x4.Scale(0.5f * newRect.Size.x, 0.5f * newRect.Size.y, 1.0f);
>>>>>>>
var newRect = new MinMaxRect
{
Min = _state.UiRect.Min + _state.UiRect.Size * rtc.Anchors.Min + rtc.Offsets.Min,
Max = _state.UiRect.Min + _state.UiRect.Size * rtc.Anchors.Max + rtc.Offsets.Max
};
var transformChild = float4x4.CreateTranslation(newRect.Center.x, newRect.Center.y, 0); |
<<<<<<<
/// <summary>
/// Contains all pixel and vertex shaders and a method to create a ShaderProgram in Rendercontext.
/// </summary>
=======
/// <summary>
/// Handles the <see cref="ShaderProgram"/> creation.
/// </summary>
>>>>>>>
/// <summary>
/// Contains all pixel and vertex shaders and a method to create a ShaderProgram in Rendercontext.
/// Handles the <see cref="ShaderProgram"/> creation.
/// </summary> |
<<<<<<<
private static float _angleHorz = 0.0f, _angleVert = 0.0f, _angleVelHorz = 0, _angleVelVert = 0, _rotationSpeed = 10.0f, _damping = 0.95f;
protected Mesh Mesh;//, MeshFace;
//protected IShaderParam VColorParam;
protected IShaderParam Shininess;
protected IShaderParam Ambient;
protected IShaderParam Specular;
protected IShaderParam Diffuse;
protected IShaderParam Emission;
=======
// angle variables
private static float _angleHorz, _angleVert, _angleVelHorz, _angleVelVert;
private const float RotationSpeed = 1f;
private const float Damping = 0.92f;
// model variables
private Mesh _meshTea, _meshFace;
// variable for color
private IShaderParam _vColorParam;
>>>>>>>
protected IShaderParam VColorParam;
// angle variables
private static float _angleHorz, _angleVert, _angleVelHorz, _angleVelVert;
private const float RotationSpeed = 1f;
private const float Damping = 0.92f;
// model variables
private Mesh _meshTea, _meshFace;
// variable for color
private IShaderParam _vColorParam;
<<<<<<<
float3[] verts = new float3[1000000];
double t1 = Diagnostics.Timer;
for (int i = 0; i < verts.Length; i++)
{
verts[i].x = i;
verts[i].y = i + 1;
verts[i].z = i - 1;
}
double t2 = Diagnostics.Timer;
Diagnostics.Log("Initializing " + verts.Length + " float3 objects took " + (t2 - t1) + " ms.");
Simple app = new Simple();
=======
var app = new Simple();
>>>>>>>
Simple app = new Simple();
var app = new Simple(); |
<<<<<<<
if (_inputDriverImp == null)
_inputDriverImp = ImpFactory.CreateIInputDriverImp();
=======
if (_networkImp == null)
_networkImp = ImpFactory.CreateINetworkImp();
>>>>>>>
if (_inputDriverImp == null)
_inputDriverImp = ImpFactory.CreateIInputDriverImp();
if (_networkImp == null)
_networkImp = ImpFactory.CreateINetworkImp();
<<<<<<<
Input.Instance.InputDriverImp = _inputDriverImp;
=======
Network.Instance.NetworkImp = _networkImp;
>>>>>>>
Input.Instance.InputDriverImp = _inputDriverImp;
Network.Instance.NetworkImp = _networkImp; |
<<<<<<<
this.tabSource = new System.Windows.Forms.TabPage();
this.videoSourceResetButton = new System.Windows.Forms.Button();
this.lbl_VideoSourceURL = new System.Windows.Forms.Label();
this.changeVideoSourceText = new System.Windows.Forms.TextBox();
this.tvChosen = new Aerial.Controls.EntitiesTreeView();
=======
this.fullDownloadBtn = new System.Windows.Forms.Button();
this.player = new AxWMPLib.AxWindowsMediaPlayer();
this.numOfCurrDown_lbl = new System.Windows.Forms.Label();
this.tvChosen = new Aerial.Controls.EntitiesTreeView();
>>>>>>>
this.fullDownloadBtn = new System.Windows.Forms.Button();
this.numOfCurrDown_lbl = new System.Windows.Forms.Label();
<<<<<<<
this.tabSource.SuspendLayout();
=======
((System.ComponentModel.ISupportInitialize)(this.player)).BeginInit();
>>>>>>>
this.tabSource.SuspendLayout();
<<<<<<<
// player
//
this.player.Enabled = true;
this.player.Location = new System.Drawing.Point(151, 19);
this.player.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.player.Name = "player";
this.player.OcxState = ((System.Windows.Forms.AxHost.State)(resources.GetObject("player.OcxState")));
this.player.Size = new System.Drawing.Size(232, 132);
this.player.TabIndex = 16;
//
=======
>>>>>>>
// player
//
this.player.Enabled = true;
this.player.Location = new System.Drawing.Point(151, 19);
this.player.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.player.Name = "player";
this.player.OcxState = ((System.Windows.Forms.AxHost.State)(resources.GetObject("player.OcxState")));
this.player.Size = new System.Drawing.Size(232, 132);
this.player.TabIndex = 16;
//
<<<<<<<
this.lblFreeSpace.Location = new System.Drawing.Point(24, 117);
this.lblFreeSpace.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
=======
this.lblFreeSpace.Location = new System.Drawing.Point(24, 139);
this.lblFreeSpace.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
>>>>>>>
this.lblFreeSpace.Location = new System.Drawing.Point(24, 169);
this.lblFreeSpace.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
<<<<<<<
this.btnPurgeCache.Location = new System.Drawing.Point(346, 109);
this.btnPurgeCache.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
=======
this.btnPurgeCache.Location = new System.Drawing.Point(346, 131);
this.btnPurgeCache.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
>>>>>>>
this.btnPurgeCache.Location = new System.Drawing.Point(346, 161);
this.btnPurgeCache.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
<<<<<<<
this.lblCacheSize.Location = new System.Drawing.Point(24, 80);
this.lblCacheSize.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
=======
this.lblCacheSize.Location = new System.Drawing.Point(24, 102);
this.lblCacheSize.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
>>>>>>>
this.lblCacheSize.Location = new System.Drawing.Point(24, 132);
this.lblCacheSize.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
<<<<<<<
this.btnOpenCache.Location = new System.Drawing.Point(346, 72);
this.btnOpenCache.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
=======
this.btnOpenCache.Location = new System.Drawing.Point(346, 94);
this.btnOpenCache.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
>>>>>>>
this.btnOpenCache.Location = new System.Drawing.Point(346, 124);
this.btnOpenCache.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
<<<<<<<
this.changeCacheLocationButton.Location = new System.Drawing.Point(346, 162);
this.changeCacheLocationButton.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
=======
this.changeCacheLocationButton.Location = new System.Drawing.Point(346, 184);
this.changeCacheLocationButton.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
>>>>>>>
this.changeCacheLocationButton.Location = new System.Drawing.Point(346, 214);
this.changeCacheLocationButton.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
<<<<<<<
this.txtCacheFolderPath.Location = new System.Drawing.Point(9, 165);
this.txtCacheFolderPath.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
=======
this.txtCacheFolderPath.Location = new System.Drawing.Point(9, 187);
this.txtCacheFolderPath.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
>>>>>>>
this.txtCacheFolderPath.Location = new System.Drawing.Point(9, 217);
this.txtCacheFolderPath.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
<<<<<<<
// tabSource
//
this.tabSource.Controls.Add(this.videoSourceResetButton);
this.tabSource.Controls.Add(this.lbl_VideoSourceURL);
this.tabSource.Controls.Add(this.changeVideoSourceText);
this.tabSource.Location = new System.Drawing.Point(4, 29);
this.tabSource.Name = "tabSource";
this.tabSource.Size = new System.Drawing.Size(607, 522);
this.tabSource.TabIndex = 3;
this.tabSource.Text = "Video Source";
this.tabSource.UseVisualStyleBackColor = true;
//
// videoSourceResetButton
//
this.videoSourceResetButton.Location = new System.Drawing.Point(17, 90);
this.videoSourceResetButton.Name = "videoSourceResetButton";
this.videoSourceResetButton.Size = new System.Drawing.Size(179, 34);
this.videoSourceResetButton.TabIndex = 25;
this.videoSourceResetButton.Text = "Reset Video Source";
this.videoSourceResetButton.UseVisualStyleBackColor = true;
this.videoSourceResetButton.Click += new System.EventHandler(this.videoSourceResetButton_Click);
//
// lbl_VideoSourceURL
//
this.lbl_VideoSourceURL.AutoSize = true;
this.lbl_VideoSourceURL.Location = new System.Drawing.Point(13, 21);
this.lbl_VideoSourceURL.Name = "lbl_VideoSourceURL";
this.lbl_VideoSourceURL.Size = new System.Drawing.Size(418, 20);
this.lbl_VideoSourceURL.TabIndex = 24;
this.lbl_VideoSourceURL.Text = "Video Source URL (change requires restart to take effect)";
//
// changeVideoSourceText
//
this.changeVideoSourceText.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.changeVideoSourceText.Location = new System.Drawing.Point(17, 56);
this.changeVideoSourceText.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.changeVideoSourceText.Name = "changeVideoSourceText";
this.changeVideoSourceText.Size = new System.Drawing.Size(565, 26);
this.changeVideoSourceText.TabIndex = 23;
//
// tvChosen
//
this.tvChosen.CheckBoxes = true;
this.tvChosen.FullRowSelect = true;
this.tvChosen.Location = new System.Drawing.Point(9, 29);
this.tvChosen.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.tvChosen.Name = "tvChosen";
this.tvChosen.ShowLines = false;
this.tvChosen.ShowPlusMinus = false;
this.tvChosen.Size = new System.Drawing.Size(206, 350);
this.tvChosen.TabIndex = 19;
this.tvChosen.AfterSelect += new System.Windows.Forms.TreeViewEventHandler(this.tvChosen_AfterSelect);
//
=======
// fullDownloadBtn
//
this.fullDownloadBtn.Location = new System.Drawing.Point(346, 18);
this.fullDownloadBtn.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.fullDownloadBtn.Name = "fullDownloadBtn";
this.fullDownloadBtn.Size = new System.Drawing.Size(228, 35);
this.fullDownloadBtn.TabIndex = 20;
this.fullDownloadBtn.Text = "Download All Videos";
this.fullDownloadBtn.UseVisualStyleBackColor = true;
this.fullDownloadBtn.Click += new System.EventHandler(this.fullDownloadBtn_Click);
//
// player
//
this.player.Enabled = true;
this.player.Location = new System.Drawing.Point(151, 19);
this.player.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.player.Name = "player";
this.player.OcxState = ((System.Windows.Forms.AxHost.State)(resources.GetObject("player.OcxState")));
this.player.Size = new System.Drawing.Size(232, 132);
this.player.TabIndex = 16;
//
// numOfCurrDown_lbl
//
this.numOfCurrDown_lbl.AutoSize = true;
this.numOfCurrDown_lbl.Location = new System.Drawing.Point(382, 58);
this.numOfCurrDown_lbl.Name = "numOfCurrDown_lbl";
this.numOfCurrDown_lbl.Size = new System.Drawing.Size(0, 20);
this.numOfCurrDown_lbl.TabIndex = 21;
//
// tvChosen
//
this.tvChosen.CheckBoxes = true;
this.tvChosen.FullRowSelect = true;
this.tvChosen.Location = new System.Drawing.Point(9, 29);
this.tvChosen.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.tvChosen.Name = "tvChosen";
this.tvChosen.ShowLines = false;
this.tvChosen.ShowPlusMinus = false;
this.tvChosen.Size = new System.Drawing.Size(206, 350);
this.tvChosen.TabIndex = 19;
this.tvChosen.AfterSelect += new System.Windows.Forms.TreeViewEventHandler(this.tvChosen_AfterSelect);
//
>>>>>>>
// fullDownloadBtn
//
this.fullDownloadBtn.Location = new System.Drawing.Point(346, 28);
this.fullDownloadBtn.Name = "fullDownloadBtn";
this.fullDownloadBtn.Size = new System.Drawing.Size(228, 36);
this.fullDownloadBtn.TabIndex = 20;
this.fullDownloadBtn.Text = "Download All Videos";
this.fullDownloadBtn.UseVisualStyleBackColor = true;
this.fullDownloadBtn.Click += new System.EventHandler(this.fullDownloadBtn_Click);
//
// numOfCurrDown_lbl
//
this.numOfCurrDown_lbl.AutoSize = true;
this.numOfCurrDown_lbl.Location = new System.Drawing.Point(375, 71);
this.numOfCurrDown_lbl.Name = "numOfCurrDown_lbl";
this.numOfCurrDown_lbl.Size = new System.Drawing.Size(169, 20);
this.numOfCurrDown_lbl.TabIndex = 21;
this.numOfCurrDown_lbl.Text = "# of files downloading: ";
//
<<<<<<<
this.tabSource.ResumeLayout(false);
this.tabSource.PerformLayout();
=======
((System.ComponentModel.ISupportInitialize)(this.player)).EndInit();
>>>>>>>
this.tabSource.ResumeLayout(false);
this.tabSource.PerformLayout();
<<<<<<<
private System.Windows.Forms.TabPage tabSource;
private System.Windows.Forms.Button videoSourceResetButton;
private System.Windows.Forms.Label lbl_VideoSourceURL;
private System.Windows.Forms.TextBox changeVideoSourceText;
=======
private System.Windows.Forms.Button fullDownloadBtn;
private System.Windows.Forms.Label numOfCurrDown_lbl;
>>>>>>>
private System.Windows.Forms.TabPage tabSource;
private System.Windows.Forms.Button videoSourceResetButton;
private System.Windows.Forms.Label lbl_VideoSourceURL;
private System.Windows.Forms.TextBox changeVideoSourceText;
private System.Windows.Forms.Button fullDownloadBtn;
private System.Windows.Forms.Label numOfCurrDown_lbl; |
<<<<<<<
=======
using System.Text;
using System.Threading.Tasks;
using Dalamud.Data;
>>>>>>>
using Dalamud.Data;
<<<<<<<
case SeStringChunkType.UIForeground:
payload = new UIForegroundPayload();
break;
case SeStringChunkType.UIGlow:
payload = new UIGlowPayload();
break;
=======
>>>>>>>
case SeStringChunkType.UIForeground:
payload = new UIForegroundPayload();
break;
case SeStringChunkType.UIGlow:
payload = new UIGlowPayload();
break;
<<<<<<<
// Custom value indicating no marker at all
None = 0x0,
=======
// used as an internal marker; sometimes single bytes are bare with no marker at all
None = 0,
>>>>>>>
// used as an internal marker; sometimes single bytes are bare with no marker at all
None = 0, |
<<<<<<<
=======
this.clmName = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
this.clmSize = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
>>>>>>>
this.clmName = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
this.clmSize = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
<<<<<<<
this.splMain.Panel1.Controls.Add(this.treFiles);
=======
this.splMain.Panel1.Controls.Add(this.treDirectories);
>>>>>>>
this.splMain.Panel1.Controls.Add(this.treDirectories);
<<<<<<<
// treFiles
//
this.treFiles.AllowDrop = true;
this.treFiles.ContextMenuStrip = this.mnuFiles;
this.treFiles.Dock = System.Windows.Forms.DockStyle.Fill;
this.treFiles.FullRowSelect = true;
this.treFiles.HideSelection = false;
this.treFiles.ItemHeight = 18;
this.treFiles.Location = new System.Drawing.Point(0, 27);
this.treFiles.Name = "treFiles";
this.treFiles.Size = new System.Drawing.Size(320, 537);
this.treFiles.TabIndex = 4;
this.treFiles.AfterCollapse += new System.Windows.Forms.TreeViewEventHandler(this.treEntries_AfterCollapse);
this.treFiles.AfterExpand += new System.Windows.Forms.TreeViewEventHandler(this.treEntries_AfterExpand);
this.treFiles.AfterSelect += new System.Windows.Forms.TreeViewEventHandler(this.treEntries_AfterSelect);
this.treFiles.NodeMouseClick += new System.Windows.Forms.TreeNodeMouseClickEventHandler(this.treEntries_NodeMouseClick);
this.treFiles.NodeMouseDoubleClick += new System.Windows.Forms.TreeNodeMouseClickEventHandler(this.treEntries_NodeMouseDoubleClick);
=======
// treDirectories
//
this.treDirectories.AllowDrop = true;
this.treDirectories.ContextMenuStrip = this.mnuFiles;
this.treDirectories.Dock = System.Windows.Forms.DockStyle.Fill;
this.treDirectories.FullRowSelect = true;
this.treDirectories.HideSelection = false;
this.treDirectories.ItemHeight = 18;
this.treDirectories.Location = new System.Drawing.Point(0, 27);
this.treDirectories.Name = "treDirectories";
this.treDirectories.ShowLines = false;
this.treDirectories.Size = new System.Drawing.Size(320, 537);
this.treDirectories.TabIndex = 4;
this.treDirectories.AfterCollapse += new System.Windows.Forms.TreeViewEventHandler(this.treEntries_AfterCollapse);
this.treDirectories.AfterExpand += new System.Windows.Forms.TreeViewEventHandler(this.treEntries_AfterExpand);
this.treDirectories.AfterSelect += new System.Windows.Forms.TreeViewEventHandler(this.treEntries_AfterSelect);
this.treDirectories.NodeMouseClick += new System.Windows.Forms.TreeNodeMouseClickEventHandler(this.treEntries_NodeMouseClick);
this.treDirectories.NodeMouseDoubleClick += new System.Windows.Forms.TreeNodeMouseClickEventHandler(this.treEntries_NodeMouseDoubleClick);
>>>>>>>
// treDirectories
//
this.treDirectories.AllowDrop = true;
this.treDirectories.ContextMenuStrip = this.mnuFiles;
this.treDirectories.Dock = System.Windows.Forms.DockStyle.Fill;
this.treDirectories.FullRowSelect = true;
this.treDirectories.HideSelection = false;
this.treDirectories.ItemHeight = 18;
this.treDirectories.Location = new System.Drawing.Point(0, 27);
this.treDirectories.Name = "treDirectories";
this.treDirectories.ShowLines = false;
this.treDirectories.Size = new System.Drawing.Size(320, 537);
this.treDirectories.TabIndex = 4;
this.treDirectories.AfterCollapse += new System.Windows.Forms.TreeViewEventHandler(this.treEntries_AfterCollapse);
this.treDirectories.AfterExpand += new System.Windows.Forms.TreeViewEventHandler(this.treEntries_AfterExpand);
this.treDirectories.AfterSelect += new System.Windows.Forms.TreeViewEventHandler(this.treEntries_AfterSelect);
this.treDirectories.NodeMouseClick += new System.Windows.Forms.TreeNodeMouseClickEventHandler(this.treEntries_NodeMouseClick);
this.treDirectories.NodeMouseDoubleClick += new System.Windows.Forms.TreeNodeMouseClickEventHandler(this.treEntries_NodeMouseDoubleClick);
<<<<<<<
// Manager
=======
// clmName
//
this.clmName.Text = "Name";
this.clmName.Width = 281;
//
// clmSize
//
this.clmSize.Text = "Size";
this.clmSize.Width = 81;
//
// Manager
>>>>>>>
// clmName
//
this.clmName.Text = "Name";
this.clmName.Width = 281;
//
// clmSize
//
this.clmSize.Text = "Size";
this.clmSize.Width = 81;
//
// Manager
<<<<<<<
this.Name = "Manager";
this.Text = "Karameru";
=======
this.Name = "Manager";
this.Text = "s";
>>>>>>>
this.Name = "Manager";
this.Text = "Karameru";
<<<<<<<
=======
private System.Windows.Forms.ListView lstFiles;
private System.Windows.Forms.ColumnHeader clmName;
private System.Windows.Forms.ColumnHeader clmSize;
>>>>>>>
private System.Windows.Forms.ListView lstFiles;
private System.Windows.Forms.ColumnHeader clmName;
private System.Windows.Forms.ColumnHeader clmSize; |
<<<<<<<
var merge = new MergePullRequest { Message = "thing the thing" };
var result = await _fixture.Merge(Helper.UserName, _context.RepositoryName, pullRequest.Number, merge);
=======
var merge = new MergePullRequest { CommitMessage = "thing the thing" };
var result = await _fixture.Merge(Helper.UserName, _repository.Name, pullRequest.Number, merge);
>>>>>>>
var merge = new MergePullRequest { CommitMessage = "thing the thing" };
var result = await _fixture.Merge(Helper.UserName, _context.RepositoryName, pullRequest.Number, merge);
<<<<<<<
var merge = new MergePullRequest { Message = "thing the thing", Sha = pullRequest.Head.Sha };
var result = await _fixture.Merge(Helper.UserName, _context.RepositoryName, pullRequest.Number, merge);
=======
var merge = new MergePullRequest { CommitMessage = "thing the thing", Sha = pullRequest.Head.Sha };
var result = await _fixture.Merge(Helper.UserName, _repository.Name, pullRequest.Number, merge);
>>>>>>>
var merge = new MergePullRequest { CommitMessage = "thing the thing", Sha = pullRequest.Head.Sha };
var result = await _fixture.Merge(Helper.UserName, _context.RepositoryName, pullRequest.Number, merge);
<<<<<<<
var merge = new MergePullRequest { Message = "thing the thing" };
var result = await _fixture.Merge(Helper.UserName, _context.RepositoryName, pullRequest.Number, merge);
=======
var merge = new MergePullRequest { CommitMessage = "thing the thing" };
var result = await _fixture.Merge(Helper.UserName, _repository.Name, pullRequest.Number, merge);
>>>>>>>
var merge = new MergePullRequest { CommitMessage = "thing the thing" };
var result = await _fixture.Merge(Helper.UserName, _context.RepositoryName, pullRequest.Number, merge); |
<<<<<<<
/// <summary>
/// Returns the <see cref="System.Uri"/> for the Deployments API for the given repository.
/// </summary>
/// <param name="owner">Owner of the repository</param>
/// <param name="name">Name of the repository</param>
/// <returns></returns>
public static Uri Deployments(string owner, string name)
{
return "repos/{0}/{1}/deployments".FormatUri(owner, name);
}
/// <summary>
/// Returns the <see cref="System.Uri"/> for the Deployment Statuses API for the given deployment.
/// </summary>
/// <param name="owner">Owner of the repository</param>
/// <param name="name">Name of the repository</param>
/// <param name="deploymentId">Id of the deployment</param>
/// <returns></returns>
public static Uri DeploymentStatuses(string owner, string name, int deploymentId)
{
return "repos/{0}/{1}/deployments/{2}/statuses".FormatUri(owner, name, deploymentId);
}
=======
/// <summary>
/// Creates the relative <see cref="Uri"/> for retrieving the
/// current users followers
/// </summary>
/// <returns>The <see cref="Uri"/> for retrieving the current users followers</returns>
public static Uri Followers()
{
return "user/followers".FormatUri();
}
/// <summary>
/// Creates the relative <see cref="Uri"/> for retrieving
/// the followers for the specified user
/// </summary>
/// <param name="login">name of the user</param>
/// <returns>The <see cref="Uri"/> for retrieving the specified users followers</returns>
public static Uri Followers(string login)
{
return "users/{0}/followers".FormatUri(login);
}
/// <summary>
/// Creates the relative <see cref="Uri"/> for retrieving the users the current user follows
/// </summary>
/// <returns>The <see cref="Uri"/> for retrieiving the users the current user follows</returns>
public static Uri Following()
{
return "user/following".FormatUri();
}
/// <summary>
/// Creates the relative <see cref="Uri"/> for retrieving the users the specified user follows
/// </summary>
/// <param name="login">name of the user</param>
/// <returns>The <see cref="Uri"/> for retrieving the users the specified user follows</returns>
public static Uri Following(string login)
{
return "users/{0}/following".FormatUri(login);
}
/// <summary>
/// Creates the relative <see cref="Uri"/> for checking is the current user is following
/// another user
/// </summary>
/// <param name="following">name of the user followed</param>
/// <returns>The <see cref="Uri"/> for checking if the current user follows the specified user.</returns>
public static Uri IsFollowing(string following)
{
return "user/following/{0}".FormatUri(following);
}
/// <summary>
/// Creates the relative <see cref="Uri"/> for checking if a user is following another user
/// </summary>
/// <param name="login">name of the user following</param>
/// <param name="following">name of the user followed</param>
/// <returns>The <see cref="Uri"/> for checking if the specified user follows another user</returns>
public static Uri IsFollowing(string login, string following)
{
return "users/{0}/following/{1}".FormatUri(login, following);
}
>>>>>>>
/// <summary>
/// Returns the <see cref="System.Uri"/> for the Deployments API for the given repository.
/// </summary>
/// <param name="owner">Owner of the repository</param>
/// <param name="name">Name of the repository</param>
/// <returns></returns>
public static Uri Deployments(string owner, string name)
{
return "repos/{0}/{1}/deployments".FormatUri(owner, name);
}
/// <summary>
/// Returns the <see cref="System.Uri"/> for the Deployment Statuses API for the given deployment.
/// </summary>
/// <param name="owner">Owner of the repository</param>
/// <param name="name">Name of the repository</param>
/// <param name="deploymentId">Id of the deployment</param>
/// <returns></returns>
public static Uri DeploymentStatuses(string owner, string name, int deploymentId)
{
return "repos/{0}/{1}/deployments/{2}/statuses".FormatUri(owner, name, deploymentId);
}
/// <summary>
/// Creates the relative <see cref="Uri"/> for retrieving the
/// current users followers
/// </summary>
/// <returns>The <see cref="Uri"/> for retrieving the current users followers</returns>
public static Uri Followers()
{
return "user/followers".FormatUri();
}
/// <summary>
/// Creates the relative <see cref="Uri"/> for retrieving
/// the followers for the specified user
/// </summary>
/// <param name="login">name of the user</param>
/// <returns>The <see cref="Uri"/> for retrieving the specified users followers</returns>
public static Uri Followers(string login)
{
return "users/{0}/followers".FormatUri(login);
}
/// <summary>
/// Creates the relative <see cref="Uri"/> for retrieving the users the current user follows
/// </summary>
/// <returns>The <see cref="Uri"/> for retrieiving the users the current user follows</returns>
public static Uri Following()
{
return "user/following".FormatUri();
}
/// <summary>
/// Creates the relative <see cref="Uri"/> for retrieving the users the specified user follows
/// </summary>
/// <param name="login">name of the user</param>
/// <returns>The <see cref="Uri"/> for retrieving the users the specified user follows</returns>
public static Uri Following(string login)
{
return "users/{0}/following".FormatUri(login);
}
/// <summary>
/// Creates the relative <see cref="Uri"/> for checking is the current user is following
/// another user
/// </summary>
/// <param name="following">name of the user followed</param>
/// <returns>The <see cref="Uri"/> for checking if the current user follows the specified user.</returns>
public static Uri IsFollowing(string following)
{
return "user/following/{0}".FormatUri(following);
}
/// <summary>
/// Creates the relative <see cref="Uri"/> for checking if a user is following another user
/// </summary>
/// <param name="login">name of the user following</param>
/// <param name="following">name of the user followed</param>
/// <returns>The <see cref="Uri"/> for checking if the specified user follows another user</returns>
public static Uri IsFollowing(string login, string following)
{
return "users/{0}/following/{1}".FormatUri(login, following);
} |
<<<<<<<
IObservableWatchedClient Watched { get; }
=======
IObservableStarredClient Starred { get; }
>>>>>>>
IObservableWatchedClient Watched { get; }
IObservableStarredClient Starred { get; } |
<<<<<<<
Watched = new ObservableWatchedClient(client);
=======
Starred = new ObservableStarredClient(client);
>>>>>>>
Watched = new ObservableWatchedClient(client);
Starred = new ObservableStarredClient(client);
<<<<<<<
public IObservableWatchedClient Watched { get; private set; }
=======
public IObservableStarredClient Starred { get; private set; }
>>>>>>>
public IObservableWatchedClient Watched { get; private set; }
public IObservableStarredClient Starred { get; private set; } |
<<<<<<<
/// <summary>
/// Add a member to the team
/// </summary>
/// <exception cref="ApiException">Thrown when a general API error occurs.</exception>
/// <returns></returns>
Task AddMember(int id, string login);
/// <summary>
/// Remove a member from the team
/// </summary>
/// <exception cref="ApiException">Thrown when a general API error occurs.</exception>
/// <returns></returns>
Task RemoveMember(int id, string login);
/// <summary>
/// Returns all team's repositories.
/// </summary>
/// <exception cref="ApiException">Thrown when a general API error occurs.</exception>
/// <returns>The team's repositories</returns>
Task<IReadOnlyList<Repository>> GetAllRepositories(int id);
/// <summary>
/// Add a repository to the team
/// </summary>
/// <exception cref="ApiException">Thrown when a general API error occurs.</exception>
/// <returns></returns>
Task AddRepository(int id, string organization, string repoName);
/// <summary>
/// Remove a repository from the team
/// </summary>
/// <exception cref="ApiException">Thrown when a general API error occurs.</exception>
/// <returns></returns>
Task RemoveRepository(int id, string organization, string repoName);
=======
/// <summary>
/// Returns all <see cref="Repository"/>(ies) associated with the given team.
/// </summary>
/// <param name="id">The team identifier</param>
/// <remarks>
/// See the <a href="https://developer.github.com/v3/orgs/teams/#list-team-repos">API documentation</a> for more information.
/// </remarks>
/// <returns>A list of the team's <see cref="Repository"/>(ies).</returns>
Task<IReadOnlyList<Repository>> GetRepositories(int id);
/// <summary>
/// Adds a <see cref="Repository"/> to a <see cref="Team"/>.
/// </summary>
/// <param name="id">The team identifier.</param>
/// <param name="org">Org to associate the repo with.</param>
/// <param name="repo">Name of the repo.</param>
/// <exception cref="ApiValidationException">Thrown if you attempt to add a repository to a team that is not owned by the organization.</exception>
/// <remarks>
/// See the <a href="https://developer.github.com/v3/orgs/teams/#add-team-repo">API documentation</a> for more information.
/// </remarks>
/// <returns><see langword="true"/> if the repository was added to the team; <see langword="false"/> otherwise.</returns>
Task<bool> AddRepository(int id, string org, string repo);
/// <summary>
/// Removes a <see cref="Repository"/> from a <see cref="Team"/>.
/// </summary>
/// <param name="id">The team identifier.</param>
/// <param name="owner">Owner of the org the team is associated with.</param>
/// <param name="repo">Name of the repo.</param>
/// <remarks>
/// See the <a href="https://developer.github.com/v3/orgs/teams/#remove-team-repo">API documentation</a> for more information.
/// </remarks>
/// <returns><see langword="true"/> if the repository was removed from the team; <see langword="false"/> otherwise.</returns>
Task<bool> RemoveRepository(int id, string owner, string repo);
/// <summary>
/// Gets whether or not the given repository is managed by the given team.
/// </summary>
/// <param name="id">The team identifier</param>
/// <param name="owner">Owner of the org the team is associated with.</param>
/// <param name="repo">Name of the repo.</param>
/// <remarks>
/// See the <a href="https://developer.github.com/v3/orgs/teams/#get-team-repo">API documentation</a> for more information.
/// </remarks>
/// <returns><see langword="true"/> if the repository is managed by the given team; <see langword="false"/> otherwise.</returns>
Task<bool> IsRepositoryManagedByTeam(int id, string owner, string repo);
>>>>>>>
/// <summary>
/// Returns all team's repositories.
/// </summary>
/// <exception cref="ApiException">Thrown when a general API error occurs.</exception>
/// <returns>The team's repositories</returns>
Task<IReadOnlyList<Repository>> GetAllRepositories(int id);
/// <summary>
/// Add a repository to the team
/// </summary>
/// <exception cref="ApiException">Thrown when a general API error occurs.</exception>
/// <returns></returns>
Task<bool> AddRepository(int id, string organization, string repoName);
/// <summary>
/// Remove a repository from the team
/// </summary>
/// <exception cref="ApiException">Thrown when a general API error occurs.</exception>
/// <returns></returns>
Task<bool> RemoveRepository(int id, string organization, string repoName);
/// <summary>
/// Returns all <see cref="Repository"/>(ies) associated with the given team.
/// </summary>
/// <param name="id">The team identifier</param>
/// <remarks>
/// See the <a href="https://developer.github.com/v3/orgs/teams/#list-team-repos">API documentation</a> for more information.
/// </remarks>
/// <returns>A list of the team's <see cref="Repository"/>(ies).</returns>
Task<IReadOnlyList<Repository>> GetRepositories(int id);
/// <summary>
/// Gets whether or not the given repository is managed by the given team.
/// </summary>
/// <param name="id">The team identifier</param>
/// <param name="owner">Owner of the org the team is associated with.</param>
/// <param name="repo">Name of the repo.</param>
/// <remarks>
/// See the <a href="https://developer.github.com/v3/orgs/teams/#get-team-repo">API documentation</a> for more information.
/// </remarks>
/// <returns><see langword="true"/> if the repository is managed by the given team; <see langword="false"/> otherwise.</returns>
Task<bool> IsRepositoryManagedByTeam(int id, string owner, string repo); |
<<<<<<<
/// Gets a <see cref="Team"/>.
/// </summary>
/// <remarks>
/// http://developer.github.com/v3/orgs/teams/#get-team
/// </remarks>
/// <param name="id">The id of the <see cref="Team"/>.</param>
/// <exception cref="ApiException">Thrown when a general API error occurs.</exception>
/// <returns>A <see cref="Team"/>.</returns>
[SuppressMessage("Microsoft.Naming", "CA1716:IdentifiersShouldNotMatchKeywords", MessageId = "Get",
Justification = "Method makes a network request")]
IObservable<Team> Get(int id);
/// <summary>
=======
/// Gets a single <see cref="Team"/> by identifier.
/// </summary>
/// <remarks>
/// https://developer.github.com/v3/orgs/teams/#get-team
/// </remarks>
/// <param name="id">The team identifier.</param>
/// <returns>The <see cref="Team"/> with the given identifier.</returns>
[SuppressMessage("Microsoft.Naming", "CA1716:IdentifiersShouldNotMatchKeywords", MessageId = "Get",
Justification = "Method makes a network request")]
IObservable<Team> Get(int id);
/// <summary>
>>>>>>>
/// Gets a single <see cref="Team"/> by identifier.
/// </summary>
/// <remarks>
/// https://developer.github.com/v3/orgs/teams/#get-team
/// </remarks>
/// <param name="id">The team identifier.</param>
/// <exception cref="ApiException">Thrown when a general API error occurs.</exception>
/// <returns>The <see cref="Team"/> with the given identifier.</returns>
[SuppressMessage("Microsoft.Naming", "CA1716:IdentifiersShouldNotMatchKeywords", MessageId = "Get",
Justification = "Method makes a network request")]
IObservable<Team> Get(int id);
/// <summary> |
<<<<<<<
Deployment = new DeploymentsClient(apiConnection);
Statistics = new StatisticsClient(apiConnection);
=======
PullRequest = new PullRequestsClient(apiConnection);
>>>>>>>
Statistics = new StatisticsClient(apiConnection);
<<<<<<<
/// <summary>
/// Client for GitHub's Repository Deployments API
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/deployment/">Collaborators API documentation</a> for more details
/// </remarks>
public IDeploymentsClient Deployment { get; private set; }
/// <summary>
/// Client for GitHub's Repository Statistics API
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/statistics/">Statistics API documentation</a> for more details
///</remarks>
public IStatisticsClient Statistics { get; private set; }
=======
/// <summary>
/// Client for managing pull requests.
/// </summary>
public IPullRequestsClient PullRequest { get; private set; }
>>>>>>>
/// <summary>
/// Client for GitHub's Repository Deployments API
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/deployment/">Collaborators API documentation</a> for more details
/// </remarks>
public IDeploymentsClient Deployment { get; private set; }
/// <summary>
/// Client for GitHub's Repository Statistics API
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/statistics/">Statistics API documentation</a> for more details
///</remarks>
public IStatisticsClient Statistics { get; private set; }
/// <summary>
/// Client for managing pull requests.
/// </summary>
public IPullRequestsClient PullRequest { get; private set; } |
<<<<<<<
Hooks = new RepositoryHooksClient(apiConnection);
Forks = new RepositoryForksClient(apiConnection);
=======
RepoCollaborators = new RepoCollaboratorsClient(apiConnection);
>>>>>>>
Hooks = new RepositoryHooksClient(apiConnection);
Forks = new RepositoryForksClient(apiConnection);
RepoCollaborators = new RepoCollaboratorsClient(apiConnection);
<<<<<<<
/// <summary>
/// Gets a client for GitHub's Repository Hooks
/// </summary>
public IRepositoryHooksClient Hooks
{
get; private set;
}
/// <summary>
/// Gets a client for GitHub's Repository Forks
/// </summary>
public IRepositoryForksClient Forks
{
get;
private set;
}
=======
/// <summary>
/// A client for GitHub's Repo Collaborators.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/collaborators/">Collaborators API documentation</a> for more details
/// </remarks>
public IRepoCollaboratorsClient RepoCollaborators { get; private set; }
/// <summary>
/// Gets all the branches for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-branches">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <exception cref="ApiException">Thrown when a general API error occurs.</exception>
/// <returns>All <see cref="T:Octokit.Branch"/>es of the repository</returns>
public Task<IReadOnlyList<Branch>> GetAllBranches(string owner, string name)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
var endpoint = ApiUrls.RepoBranches(owner, name);
return ApiConnection.GetAll<Branch>(endpoint);
}
/// <summary>
/// Gets all contributors for the specified repository. Does not include anonymous contributors.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-contributors">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All contributors of the repository.</returns>
public Task<IReadOnlyList<User>> GetAllContributors(string owner, string name)
{
return GetAllContributors(owner, name, false);
}
/// <summary>
/// Gets all contributors for the specified repository. With the option to include anonymous contributors.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-contributors">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <param name="includeAnonymous">True if anonymous contributors should be included in result; Otherwise false</param>
/// <returns>All contributors of the repository.</returns>
public Task<IReadOnlyList<User>> GetAllContributors(string owner, string name, bool includeAnonymous)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
var parameters = new Dictionary<string, string>();
if (includeAnonymous)
parameters.Add("anon", "1");
return ApiConnection.GetAll<User>(ApiUrls.RepositoryContributors(owner, name), parameters);
}
/// <summary>
/// Gets all languages for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-languages">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All languages used in the repository and the number of bytes of each language.</returns>
public Task<IReadOnlyList<RepositoryLanguage>> GetAllLanguages(string owner, string name)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
return ApiConnection
.Get<IDictionary<string, long>>(ApiUrls.RepositoryLanguages(owner, name))
.ContinueWith<IReadOnlyList<RepositoryLanguage>>(t =>
new ReadOnlyCollection<RepositoryLanguage>(
t.Result.Select(kvp => new RepositoryLanguage(kvp.Key, kvp.Value)).ToList()
),
TaskContinuationOptions.OnlyOnRanToCompletion);
}
/// <summary>
/// Gets all teams for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-teams">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All <see cref="T:Octokit.Team"/>s associated with the repository</returns>
public Task<IReadOnlyList<Team>> GetAllTeams(string owner, string name)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
return ApiConnection.GetAll<Team>(ApiUrls.RepositoryTeams(owner, name));
}
/// <summary>
/// Gets all tags for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-tags">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All of the repositorys tags.</returns>
public Task<IReadOnlyList<RepositoryTag>> GetAllTags(string owner, string name)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
return ApiConnection.GetAll<RepositoryTag>(ApiUrls.RepositoryTags(owner, name));
}
/// <summary>
/// Gets the specified branch.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#get-branch">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="repositoryName">The name of the repository</param>
/// <param name="branchName">The name of the branch</param>
/// <returns>The specified <see cref="T:Octokit.Branch"/></returns>
public Task<Branch> GetBranch(string owner, string repositoryName, string branchName)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(repositoryName, "repositoryName");
Ensure.ArgumentNotNullOrEmptyString(branchName, "branchName");
return ApiConnection.Get<Branch>(ApiUrls.RepoBranch(owner, repositoryName, branchName));
}
>>>>>>>
/// <summary>
/// Gets a client for GitHub's Repository Hooks
/// </summary>
public IRepositoryHooksClient Hooks
{
get; private set;
}
/// <summary>
/// Gets a client for GitHub's Repository Forks
/// </summary>
public IRepositoryForksClient Forks
{
get;
private set;
}
/// <summary>
/// A client for GitHub's Repo Collaborators.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/collaborators/">Collaborators API documentation</a> for more details
/// </remarks>
public IRepoCollaboratorsClient RepoCollaborators { get; private set; }
/// <summary>
/// Gets all the branches for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-branches">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <exception cref="ApiException">Thrown when a general API error occurs.</exception>
/// <returns>All <see cref="T:Octokit.Branch"/>es of the repository</returns>
public Task<IReadOnlyList<Branch>> GetAllBranches(string owner, string name)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
var endpoint = ApiUrls.RepoBranches(owner, name);
return ApiConnection.GetAll<Branch>(endpoint);
}
/// <summary>
/// Gets all contributors for the specified repository. Does not include anonymous contributors.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-contributors">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All contributors of the repository.</returns>
public Task<IReadOnlyList<User>> GetAllContributors(string owner, string name)
{
return GetAllContributors(owner, name, false);
}
/// <summary>
/// Gets all contributors for the specified repository. With the option to include anonymous contributors.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-contributors">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <param name="includeAnonymous">True if anonymous contributors should be included in result; Otherwise false</param>
/// <returns>All contributors of the repository.</returns>
public Task<IReadOnlyList<User>> GetAllContributors(string owner, string name, bool includeAnonymous)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
var parameters = new Dictionary<string, string>();
if (includeAnonymous)
parameters.Add("anon", "1");
return ApiConnection.GetAll<User>(ApiUrls.RepositoryContributors(owner, name), parameters);
}
/// <summary>
/// Gets all languages for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-languages">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All languages used in the repository and the number of bytes of each language.</returns>
public Task<IReadOnlyList<RepositoryLanguage>> GetAllLanguages(string owner, string name)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
return ApiConnection
.Get<IDictionary<string, long>>(ApiUrls.RepositoryLanguages(owner, name))
.ContinueWith<IReadOnlyList<RepositoryLanguage>>(t =>
new ReadOnlyCollection<RepositoryLanguage>(
t.Result.Select(kvp => new RepositoryLanguage(kvp.Key, kvp.Value)).ToList()
),
TaskContinuationOptions.OnlyOnRanToCompletion);
}
/// <summary>
/// Gets all teams for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-teams">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All <see cref="T:Octokit.Team"/>s associated with the repository</returns>
public Task<IReadOnlyList<Team>> GetAllTeams(string owner, string name)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
return ApiConnection.GetAll<Team>(ApiUrls.RepositoryTeams(owner, name));
}
/// <summary>
/// Gets all tags for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-tags">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All of the repositorys tags.</returns>
public Task<IReadOnlyList<RepositoryTag>> GetAllTags(string owner, string name)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
return ApiConnection.GetAll<RepositoryTag>(ApiUrls.RepositoryTags(owner, name));
}
/// <summary>
/// Gets the specified branch.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#get-branch">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="repositoryName">The name of the repository</param>
/// <param name="branchName">The name of the branch</param>
/// <returns>The specified <see cref="T:Octokit.Branch"/></returns>
public Task<Branch> GetBranch(string owner, string repositoryName, string branchName)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(repositoryName, "repositoryName");
Ensure.ArgumentNotNullOrEmptyString(branchName, "branchName");
return ApiConnection.Get<Branch>(ApiUrls.RepoBranch(owner, repositoryName, branchName));
} |
<<<<<<<
Email = new UserEmailsClient(apiConnection);
=======
Followers = new FollowersClient(apiConnection);
>>>>>>>
Email = new UserEmailsClient(apiConnection);
Followers = new FollowersClient(apiConnection);
<<<<<<<
=======
/// <summary>
/// Returns emails for the current user.
/// </summary>
/// <returns></returns>
public Task<IReadOnlyList<EmailAddress>> GetEmails()
{
return ApiConnection.GetAll<EmailAddress>(ApiUrls.Emails(), null);
}
/// <summary>
/// A client for GitHub's User Followers API
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/users/followers/">Followers API documentation</a> for more information.
///</remarks>
public IFollowersClient Followers { get; private set; }
>>>>>>>
/// <summary>
/// A client for GitHub's User Followers API
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/users/followers/">Followers API documentation</a> for more information.
///</remarks>
public IFollowersClient Followers { get; private set; } |
<<<<<<<
Hooks = new ObservableRepositoryHooksClient(client);
=======
RepoCollaborators = new ObservableRepoCollaboratorsClient(client);
>>>>>>>
Hooks = new ObservableRepositoryHooksClient(client);
RepoCollaborators = new ObservableRepoCollaboratorsClient(client);
<<<<<<<
/// <summary>
/// Gets a client for GitHub's Repository Hooks
/// </summary>
public IObservableRepositoryHooksClient Hooks
{
get; private set;
}
=======
/// <summary>
/// Gets all the branches for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-branches">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <exception cref="ApiException">Thrown when a general API error occurs.</exception>
/// <returns>All <see cref="T:Octokit.Branch"/>es of the repository</returns>
public IObservable<Branch> GetAllBranches(string owner, string name)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
var endpoint = ApiUrls.RepoBranches(owner, name);
return _connection.GetAndFlattenAllPages<Branch>(endpoint);
}
/// <summary>
/// Gets all contributors for the specified repository. Does not include anonymous contributors.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-contributors">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All contributors of the repository.</returns>
public IObservable<User> GetAllContributors(string owner, string name)
{
return GetAllContributors(owner, name, false);
}
/// <summary>
/// Gets all contributors for the specified repository. With the option to include anonymous contributors.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-contributors">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <param name="includeAnonymous">True if anonymous contributors should be included in result; Otherwise false</param>
/// <returns>All contributors of the repository.</returns>
public IObservable<User> GetAllContributors(string owner, string name, bool includeAnonymous)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
var endpoint = ApiUrls.RepositoryContributors(owner, name);
var parameters = new Dictionary<string, string>();
if (includeAnonymous)
parameters.Add("anon", "1");
return _connection.GetAndFlattenAllPages<User>(endpoint, parameters);
}
/// <summary>
/// Gets all languages for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-languages">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All languages used in the repository and the number of bytes of each language.</returns>
public IObservable<RepositoryLanguage> GetAllLanguages(string owner, string name)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
var endpoint = ApiUrls.RepositoryLanguages(owner, name);
return _connection
.GetAndFlattenAllPages<Tuple<string, long>>(endpoint)
.Select(t => new RepositoryLanguage(t.Item1, t.Item2));
}
/// <summary>
/// Gets all teams for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-teams">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All <see cref="T:Octokit.Team"/>s associated with the repository</returns>
public IObservable<Team> GetAllTeams(string owner, string name)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
var endpoint = ApiUrls.RepositoryTeams(owner, name);
return _connection.GetAndFlattenAllPages<Team>(endpoint);
}
/// <summary>
/// Gets all tags for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-tags">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All of the repositorys tags.</returns>
public IObservable<RepositoryTag> GetAllTags(string owner, string name)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
var endpoint = ApiUrls.RepositoryTags(owner, name);
return _connection.GetAndFlattenAllPages<RepositoryTag>(endpoint);
}
/// <summary>
/// Gets the specified branch.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#get-branch">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="repositoryName">The name of the repository</param>
/// <param name="branchName">The name of the branch</param>
/// <returns>The specified <see cref="T:Octokit.Branch"/></returns>
public IObservable<Branch> GetBranch(string owner, string repositoryName, string branchName)
{
return _client.GetBranch(owner, repositoryName, branchName).ToObservable();
}
/// <summary>
/// Updates the specified repository with the values given in <paramref name="update"/>
/// </summary>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <param name="update">New values to update the repository with</param>
/// <returns>The updated <see cref="T:Octokit.Repository"/></returns>
public IObservable<Repository> Edit(string owner, string name, RepositoryUpdate update)
{
return _client.Edit(owner, name, update).ToObservable();
}
/// A client for GitHub's Repo Collaborators.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/collaborators/">Collaborators API documentation</a> for more details
/// </remarks>
public IObservableRepoCollaboratorsClient RepoCollaborators { get; private set; }
>>>>>>>
/// <summary>
/// Gets a client for GitHub's Repository Hooks
/// </summary>
public IObservableRepositoryHooksClient Hooks
{
get; private set;
}
/// Gets all the branches for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-branches">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <exception cref="ApiException">Thrown when a general API error occurs.</exception>
/// <returns>All <see cref="T:Octokit.Branch"/>es of the repository</returns>
public IObservable<Branch> GetAllBranches(string owner, string name)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
var endpoint = ApiUrls.RepoBranches(owner, name);
return _connection.GetAndFlattenAllPages<Branch>(endpoint);
}
/// <summary>
/// Gets all contributors for the specified repository. Does not include anonymous contributors.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-contributors">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All contributors of the repository.</returns>
public IObservable<User> GetAllContributors(string owner, string name)
{
return GetAllContributors(owner, name, false);
}
/// <summary>
/// Gets all contributors for the specified repository. With the option to include anonymous contributors.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-contributors">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <param name="includeAnonymous">True if anonymous contributors should be included in result; Otherwise false</param>
/// <returns>All contributors of the repository.</returns>
public IObservable<User> GetAllContributors(string owner, string name, bool includeAnonymous)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
var endpoint = ApiUrls.RepositoryContributors(owner, name);
var parameters = new Dictionary<string, string>();
if (includeAnonymous)
parameters.Add("anon", "1");
return _connection.GetAndFlattenAllPages<User>(endpoint, parameters);
}
/// <summary>
/// Gets all languages for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-languages">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All languages used in the repository and the number of bytes of each language.</returns>
public IObservable<RepositoryLanguage> GetAllLanguages(string owner, string name)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
var endpoint = ApiUrls.RepositoryLanguages(owner, name);
return _connection
.GetAndFlattenAllPages<Tuple<string, long>>(endpoint)
.Select(t => new RepositoryLanguage(t.Item1, t.Item2));
}
/// <summary>
/// Gets all teams for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-teams">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All <see cref="T:Octokit.Team"/>s associated with the repository</returns>
public IObservable<Team> GetAllTeams(string owner, string name)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
var endpoint = ApiUrls.RepositoryTeams(owner, name);
return _connection.GetAndFlattenAllPages<Team>(endpoint);
}
/// <summary>
/// Gets all tags for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-tags">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All of the repositorys tags.</returns>
public IObservable<RepositoryTag> GetAllTags(string owner, string name)
{
Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
Ensure.ArgumentNotNullOrEmptyString(name, "name");
var endpoint = ApiUrls.RepositoryTags(owner, name);
return _connection.GetAndFlattenAllPages<RepositoryTag>(endpoint);
}
/// <summary>
/// Gets the specified branch.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#get-branch">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="repositoryName">The name of the repository</param>
/// <param name="branchName">The name of the branch</param>
/// <returns>The specified <see cref="T:Octokit.Branch"/></returns>
public IObservable<Branch> GetBranch(string owner, string repositoryName, string branchName)
{
return _client.GetBranch(owner, repositoryName, branchName).ToObservable();
}
/// <summary>
/// Updates the specified repository with the values given in <paramref name="update"/>
/// </summary>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <param name="update">New values to update the repository with</param>
/// <returns>The updated <see cref="T:Octokit.Repository"/></returns>
public IObservable<Repository> Edit(string owner, string name, RepositoryUpdate update)
{
return _client.Edit(owner, name, update).ToObservable();
}
/// A client for GitHub's Repo Collaborators.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/collaborators/">Collaborators API documentation</a> for more details
/// </remarks>
public IObservableRepoCollaboratorsClient RepoCollaborators { get; private set; } |
<<<<<<<
/// <summary>
/// A client for GitHub's Repository Hooks API.
/// </summary>
/// <remarks>See <a href="http://developer.github.com/v3/repos/hooks/">API documentation</a> for more information.</remarks>
IRepositoryHooksClient Hooks { get; }
/// <summary>
/// Gets a client for GitHub's Repository Hooks
/// </summary>
IRepositoryForksClient Forks { get; }
=======
/// <summary>
/// A client for GitHub's Repo Collaborators.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/collaborators/">Collaborators API documentation</a> for more details
/// </remarks>
IRepoCollaboratorsClient RepoCollaborators { get; }
/// <summary>
/// Gets all the branches for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-branches">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <exception cref="ApiException">Thrown when a general API error occurs.</exception>
/// <returns>All <see cref="T:Octokit.Branch"/>es of the repository</returns>
Task<IReadOnlyList<Branch>> GetAllBranches(string owner, string name);
/// <summary>
/// Gets all contributors for the specified repository. Does not include anonymous contributors.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-contributors">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All contributors of the repository.</returns>
Task<IReadOnlyList<User>> GetAllContributors(string owner, string name);
/// <summary>
/// Gets all contributors for the specified repository. With the option to include anonymous contributors.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-contributors">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <param name="includeAnonymous">True if anonymous contributors should be included in result; Otherwise false</param>
/// <returns>All contributors of the repository.</returns>
Task<IReadOnlyList<User>> GetAllContributors(string owner, string name, bool includeAnonymous);
/// <summary>
/// Gets all languages for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-languages">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All languages used in the repository and the number of bytes of each language.</returns>
Task<IReadOnlyList<RepositoryLanguage>> GetAllLanguages(string owner, string name);
/// <summary>
/// Gets all teams for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-teams">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All <see cref="T:Octokit.Team"/>s associated with the repository</returns>
Task<IReadOnlyList<Team>> GetAllTeams(string owner, string name);
/// <summary>
/// Gets all tags for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-tags">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All of the repositorys tags.</returns>
Task<IReadOnlyList<RepositoryTag>> GetAllTags(string owner, string name);
/// <summary>
/// Gets the specified branch.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#get-branch">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="repositoryName">The name of the repository</param>
/// <param name="branchName">The name of the branch</param>
/// <returns>The specified <see cref="T:Octokit.Branch"/></returns>
Task<Branch> GetBranch(string owner, string repositoryName, string branchName);
/// <summary>
/// Updates the specified repository with the values given in <paramref name="update"/>
/// </summary>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <param name="update">New values to update the repository with</param>
/// <returns>The updated <see cref="T:Octokit.Repository"/></returns>
Task<Repository> Edit(string owner, string name, RepositoryUpdate update);
>>>>>>>
/// <summary>
/// A client for GitHub's Repository Hooks API.
/// </summary>
/// <remarks>See <a href="http://developer.github.com/v3/repos/hooks/">API documentation</a> for more information.</remarks>
IRepositoryHooksClient Hooks { get; }
/// <summary>
/// Gets a client for GitHub's Repository Hooks
/// </summary>
IRepositoryForksClient Forks { get; }
/// A client for GitHub's Repo Collaborators.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/collaborators/">Collaborators API documentation</a> for more details
/// </remarks>
IRepoCollaboratorsClient RepoCollaborators { get; }
/// <summary>
/// Gets all the branches for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-branches">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <exception cref="ApiException">Thrown when a general API error occurs.</exception>
/// <returns>All <see cref="T:Octokit.Branch"/>es of the repository</returns>
Task<IReadOnlyList<Branch>> GetAllBranches(string owner, string name);
/// <summary>
/// Gets all contributors for the specified repository. Does not include anonymous contributors.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-contributors">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All contributors of the repository.</returns>
Task<IReadOnlyList<User>> GetAllContributors(string owner, string name);
/// <summary>
/// Gets all contributors for the specified repository. With the option to include anonymous contributors.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-contributors">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <param name="includeAnonymous">True if anonymous contributors should be included in result; Otherwise false</param>
/// <returns>All contributors of the repository.</returns>
Task<IReadOnlyList<User>> GetAllContributors(string owner, string name, bool includeAnonymous);
/// <summary>
/// Gets all languages for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-languages">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All languages used in the repository and the number of bytes of each language.</returns>
Task<IReadOnlyList<RepositoryLanguage>> GetAllLanguages(string owner, string name);
/// <summary>
/// Gets all teams for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-teams">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All <see cref="T:Octokit.Team"/>s associated with the repository</returns>
Task<IReadOnlyList<Team>> GetAllTeams(string owner, string name);
/// <summary>
/// Gets all tags for the specified repository.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#list-tags">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <returns>All of the repositorys tags.</returns>
Task<IReadOnlyList<RepositoryTag>> GetAllTags(string owner, string name);
/// <summary>
/// Gets the specified branch.
/// </summary>
/// <remarks>
/// See the <a href="http://developer.github.com/v3/repos/#get-branch">API documentation</a> for more details
/// </remarks>
/// <param name="owner">The owner of the repository</param>
/// <param name="repositoryName">The name of the repository</param>
/// <param name="branchName">The name of the branch</param>
/// <returns>The specified <see cref="T:Octokit.Branch"/></returns>
Task<Branch> GetBranch(string owner, string repositoryName, string branchName);
/// <summary>
/// Updates the specified repository with the values given in <paramref name="update"/>
/// </summary>
/// <param name="owner">The owner of the repository</param>
/// <param name="name">The name of the repository</param>
/// <param name="update">New values to update the repository with</param>
/// <returns>The updated <see cref="T:Octokit.Repository"/></returns>
Task<Repository> Edit(string owner, string name, RepositoryUpdate update); |
<<<<<<<
var position = sourceText.Lines.GetPosition(new LinePosition(request.Line, request.Column));
var symbol = SymbolFinder.FindSymbolAtPosition(semanticModel, position, _workspace);
=======
var position = sourceText.Lines.GetPosition(new LinePosition(request.Line - 1, request.Column - 1));
var symbol = await SymbolFinder.FindSymbolAtPositionAsync(semanticModel, position, _workspace);
>>>>>>>
var position = sourceText.Lines.GetPosition(new LinePosition(request.Line, request.Column));
var symbol = await SymbolFinder.FindSymbolAtPositionAsync(semanticModel, position, _workspace); |
<<<<<<<
private readonly CachingCodeFixProviderForProjects _codeFixesForProjects;
=======
private readonly RulesetsForProjects _rulesetsForProjects;
>>>>>>>
<<<<<<<
_codeFixesForProjects = codeFixesForProjects;
=======
_rulesetsForProjects = rulesetsForProjects;
>>>>>>>
<<<<<<<
_manager = new ProjectManager(_loggerFactory, _options, _eventEmitter, _fileSystemWatcher, _metadataFileReferenceCache, _packageDependencyChecker, _loader, _workspace, _codeFixesForProjects, _assemblyLoader, _eventSinks);
=======
_manager = new ProjectManager(_loggerFactory, _options, _eventEmitter, _fileSystemWatcher, _metadataFileReferenceCache, _packageDependencyChecker, _loader, _workspace, _rulesetsForProjects, _assemblyLoader, _eventSinks);
>>>>>>>
_manager = new ProjectManager(_loggerFactory, _options, _eventEmitter, _fileSystemWatcher, _metadataFileReferenceCache, _packageDependencyChecker, _loader, _workspace, _assemblyLoader, _eventSinks); |
<<<<<<<
public const string DiscoverTests = "/v2/discovertests";
=======
public const string RunTestsInContext = "/v2/runtestsincontext";
>>>>>>>
public const string DiscoverTests = "/v2/discovertests";
public const string RunTestsInContext = "/v2/runtestsincontext"; |
<<<<<<<
//Gets the parameter documentation from this object
public string GetParameterText(string name)
{
var requiredParam = Array.Find(ParamElements, parameter => parameter.Name == name);
if (requiredParam != null)
return requiredParam.Documentation;
return string.Empty;
}
public static readonly DocumentationComment Empty = new DocumentationComment();
=======
private static string TrimStartRetainingSingleLeadingSpace(string input)
{
if (string.IsNullOrWhiteSpace(input))
return string.Empty;
if (!char.IsWhiteSpace(input[0]))
return input;
return $" {input.TrimStart()}";
}
>>>>>>>
private static string TrimStartRetainingSingleLeadingSpace(string input)
{
if (string.IsNullOrWhiteSpace(input))
return string.Empty;
if (!char.IsWhiteSpace(input[0]))
return input;
return $" {input.TrimStart()}";
}
//Gets the parameter documentation from this object
public string GetParameterText(string name)
{
var requiredParam = Array.Find(ParamElements, parameter => parameter.Name == name);
if (requiredParam != null)
return requiredParam.Documentation;
return string.Empty;
}
public static readonly DocumentationComment Empty = new DocumentationComment(); |
<<<<<<<
public Dialog(string dialogId = null)
{
Id = dialogId;
_telemetryClient = NullBotTelemetryClient.Instance;
}
private string id;
/// <summary>
/// Unique id for the dialog.
/// </summary>
public string Id
=======
/// <summary>
/// Initializes a new instance of the <see cref="Dialog"/> class.
/// Called from constructors in derived classes to initialize the <see cref="Dialog"/> class.
/// </summary>
/// <param name="dialogId">The ID to assign to this dialog.</param>
public Dialog(string dialogId)
>>>>>>>
/// <summary>
/// Initializes a new instance of the <see cref="Dialog"/> class.
/// Called from constructors in derived classes to initialize the <see cref="Dialog"/> class.
/// </summary>
/// <param name="dialogId">The ID to assign to this dialog.</param>
public Dialog(string dialogId = null)
{
Id = dialogId;
_telemetryClient = NullBotTelemetryClient.Instance;
}
private string id;
/// <summary>
/// Unique id for the dialog.
/// </summary>
public string Id
<<<<<<<
/// <summary>
/// Set of tags assigned to the dialog.
/// </summary>
public List<string> Tags { get; private set; } = new List<string>();
/// <summary>
/// Gets or sets jSONPath expression for the memory slots to bind the dialogs options to on a call to `beginDialog()`.
/// </summary>
public Dictionary<string, string> InputBindings { get; set; } = new Dictionary<string, string>();
/// <summary>
/// Gets or sets jSONPath expression for the memory slot to bind the dialogs result to when `endDialog()` is called.
/// </summary>
public string OutputBinding { get; set; }
=======
/// <summary>
/// Gets the ID assigned to this dialog.
/// </summary>
/// <value>The ID assigned to this dialog.</value>
public string Id { get; }
>>>>>>>
/// <summary>
/// Set of tags assigned to the dialog.
/// </summary>
public List<string> Tags { get; private set; } = new List<string>();
/// <summary>
/// Gets or sets jSONPath expression for the memory slots to bind the dialogs options to on a call to `beginDialog()`.
/// </summary>
public Dictionary<string, string> InputBindings { get; set; } = new Dictionary<string, string>();
/// <summary>
/// Gets or sets jSONPath expression for the memory slot to bind the dialogs result to when `endDialog()` is called.
/// </summary>
public string OutputBinding { get; set; } |
<<<<<<<
[Option('e', HelpText = "Use an enhanced transcription model.")]
public bool UseEnhancedModel { get; set; }
=======
[Option('c', HelpText = "Set number of channels")]
public int NumberOfChannels { get; set; }
>>>>>>>
[Option('e', HelpText = "Use an enhanced transcription model.")]
public bool UseEnhancedModel { get; set; }
[Option('c', HelpText = "Set number of channels")]
public int NumberOfChannels { get; set; }
<<<<<<<
// [START speech_transcribe_enhanced_model]
static object SyncRecognizeEnhancedModel(string filePath)
{
var speech = SpeechClient.Create();
var response = speech.Recognize(new RecognitionConfig()
{
Encoding = RecognitionConfig.Types.AudioEncoding.Linear16,
SampleRateHertz = 8000,
LanguageCode = "en-US",
UseEnhanced = true,
// A model must be specified to use an enhanced model.
// Currently, only 'phone_call' is supported.
Model = "phone_call",
}, RecognitionAudio.FromFile(filePath));
foreach (var result in response.Results)
{
foreach (var alternative in result.Alternatives)
{
Console.WriteLine(alternative.Transcript);
}
}
return 0;
}
// [END speech_transcribe_enhanced_model]
=======
// [START speech_transcribe_multichannel_beta]
static object SyncRecognizeMultipleChannels(string filePath, int channelCount)
{
Console.WriteLine("Starting multi-channel");
var speech = SpeechClient.Create();
// Create transcription request
var response = speech.Recognize(new RecognitionConfig()
{
Encoding = RecognitionConfig.Types.AudioEncoding.Linear16,
LanguageCode = "en",
// Configure request to enable multiple channels
EnableSeparateRecognitionPerChannel = true,
AudioChannelCount = channelCount
}, RecognitionAudio.FromFile(filePath));
// Print out the results.
foreach (var result in response.Results)
{
// There can be several transcripts for a chunk of audio.
// Print out the first (most likely) one here.
var alternative = result.Alternatives[0];
Console.WriteLine($"Transcript: {alternative.Transcript}");
Console.WriteLine($"Channel Tag: {result.ChannelTag}");
}
return 0;
}
// [END speech_transcribe_multichannel_beta]
>>>>>>>
// [START speech_transcribe_enhanced_model]
static object SyncRecognizeEnhancedModel(string filePath)
{
var speech = SpeechClient.Create();
var response = speech.Recognize(new RecognitionConfig()
{
Encoding = RecognitionConfig.Types.AudioEncoding.Linear16,
SampleRateHertz = 8000,
LanguageCode = "en-US",
UseEnhanced = true,
// A model must be specified to use an enhanced model.
// Currently, only 'phone_call' is supported.
Model = "phone_call",
}, RecognitionAudio.FromFile(filePath));
foreach (var result in response.Results)
{
foreach (var alternative in result.Alternatives)
{
Console.WriteLine(alternative.Transcript);
}
}
return 0;
}
// [END speech_transcribe_enhanced_model]
// [START speech_transcribe_multichannel_beta]
static object SyncRecognizeMultipleChannels(string filePath, int channelCount)
{
Console.WriteLine("Starting multi-channel");
var speech = SpeechClient.Create();
// Create transcription request
var response = speech.Recognize(new RecognitionConfig()
{
Encoding = RecognitionConfig.Types.AudioEncoding.Linear16,
LanguageCode = "en",
// Configure request to enable multiple channels
EnableSeparateRecognitionPerChannel = true,
AudioChannelCount = channelCount
}, RecognitionAudio.FromFile(filePath));
// Print out the results.
foreach (var result in response.Results)
{
// There can be several transcripts for a chunk of audio.
// Print out the first (most likely) one here.
var alternative = result.Alternatives[0];
Console.WriteLine($"Transcript: {alternative.Transcript}");
Console.WriteLine($"Channel Tag: {result.ChannelTag}");
}
return 0;
}
// [END speech_transcribe_multichannel_beta]
<<<<<<<
SyncRecognizeModelSelection(opts.FilePath, opts.SelectModel) : opts.UseEnhancedModel ?
SyncRecognizeEnhancedModel(opts.FilePath) : SyncRecognize(opts.FilePath),
=======
SyncRecognizeModelSelection(opts.FilePath, opts.SelectModel) : (opts.NumberOfChannels > 1) ?
SyncRecognizeMultipleChannels(opts.FilePath, opts.NumberOfChannels) : SyncRecognize(opts.FilePath),
>>>>>>>
SyncRecognizeModelSelection(opts.FilePath, opts.SelectModel) : opts.UseEnhancedModel ?
SyncRecognizeEnhancedModel(opts.FilePath) : (opts.NumberOfChannels > 1) ?
SyncRecognizeMultipleChannels(opts.FilePath, opts.NumberOfChannels) : SyncRecognize(opts.FilePath), |
<<<<<<<
ListBuckets
ListObjects
UploadStream
DownloadStream
DeleteObject
DownloadToFile
Required environment variables:
GOOGLE_PROJECT_ID The ID of Google Developers Console project
GOOGLE_BUCKET The name of Google Cloud Storage bucket
=======
Commands:
ListBuckets
ListObjects
UploadStream
DownloadStream
DeleteObject
Environment variables:
GOOGLE_PROJECT_ID The ID of Google Developers Console project
GOOGLE_BUCKET The name of Google Cloud Storage bucket
>>>>>>>
Commands:
ListBuckets
ListObjects
UploadStream
DownloadStream
DeleteObject
DownloadToFile
Environment variables:
GOOGLE_PROJECT_ID The ID of Google Developers Console project
GOOGLE_BUCKET The name of Google Cloud Storage bucket |
<<<<<<<
public static object AttachDevice(MqttClient client, string deviceId, string auth)
=======
//[START iot_listen_for_config_messages]
//[START iot_send_data_from_bound_device]
public static object AttachDevice(MqttClient client, string deviceId)
>>>>>>>
//[START iot_listen_for_config_messages]
//[START iot_send_data_from_bound_device]
public static object AttachDevice(MqttClient client, string deviceId, string auth)
<<<<<<<
AttachDevice(mqttClient, deviceId, "{}");
=======
AttachDevice(mqttClient, deviceId);
System.Threading.Thread.Sleep(2000);
>>>>>>>
AttachDevice(mqttClient, deviceId, "{}");
<<<<<<<
mqttClient = CloudIotMqttExample.GetClient(projectId, cloudRegion,
registryId, deviceId, privateKeyFile, algorithm,
caCerts, mqttBridgeHostname, mqttBridgePort);
mqttClient.Connect(clientId, "unused",
CloudIotMqttExample.CreateJwtRsa(projectId, privateKeyFile));
=======
// refresh token and reconnect.
pass = CloudIotMqttExample.CreateJwtRsa(projectId, privateKeyFile);
mqttClient = StartMqtt(mqttBridgeHostname, mqttBridgePort, projectId,
cloudRegion, registryId, gatewayId, privateKeyFile,
caCerts, algorithm, pass);
>>>>>>>
// refresh token and reconnect.
pass = CloudIotMqttExample.CreateJwtRsa(projectId, privateKeyFile);
mqttClient = StartMqtt(mqttBridgeHostname, mqttBridgePort, projectId,
cloudRegion, registryId, gatewayId, privateKeyFile,
caCerts, algorithm, pass); |
<<<<<<<
Name = "MainMenu";
BackgroundTexture = AssetLoader.LoadTexture("MainMenu/mainmenubg.png");
=======
Name = nameof(MainMenu);
BackgroundTexture = AssetLoader.LoadTexture("MainMenu\\mainmenubg.png");
>>>>>>>
Name = nameof(MainMenu);
BackgroundTexture = AssetLoader.LoadTexture("MainMenu/mainmenubg.png");
<<<<<<<
btnNewCampaign.Name = "btnNewCampaign";
btnNewCampaign.IdleTexture = AssetLoader.LoadTexture("MainMenu/campaign.png");
btnNewCampaign.HoverTexture = AssetLoader.LoadTexture("MainMenu/campaign_c.png");
btnNewCampaign.HoverSoundEffect = new EnhancedSoundEffect("MainMenu/button.wav");
=======
btnNewCampaign.Name = nameof(btnNewCampaign);
btnNewCampaign.IdleTexture = AssetLoader.LoadTexture("MainMenu\\campaign.png");
btnNewCampaign.HoverTexture = AssetLoader.LoadTexture("MainMenu\\campaign_c.png");
btnNewCampaign.HoverSoundEffect = new EnhancedSoundEffect("MainMenu\\button.wav");
>>>>>>>
btnNewCampaign.Name = nameof(btnNewCampaign);
btnNewCampaign.IdleTexture = AssetLoader.LoadTexture("MainMenu/campaign.png");
btnNewCampaign.HoverTexture = AssetLoader.LoadTexture("MainMenu/campaign_c.png");
btnNewCampaign.HoverSoundEffect = new EnhancedSoundEffect("MainMenu/button.wav");
<<<<<<<
btnLoadGame.Name = "btnLoadGame";
btnLoadGame.IdleTexture = AssetLoader.LoadTexture("MainMenu/loadmission.png");
btnLoadGame.HoverTexture = AssetLoader.LoadTexture("MainMenu/loadmission_c.png");
btnLoadGame.HoverSoundEffect = new EnhancedSoundEffect("MainMenu/button.wav");
=======
btnLoadGame.Name = nameof(btnLoadGame);
btnLoadGame.IdleTexture = AssetLoader.LoadTexture("MainMenu\\loadmission.png");
btnLoadGame.HoverTexture = AssetLoader.LoadTexture("MainMenu\\loadmission_c.png");
btnLoadGame.HoverSoundEffect = new EnhancedSoundEffect("MainMenu\\button.wav");
>>>>>>>
btnLoadGame.Name = nameof(btnLoadGame);
btnLoadGame.IdleTexture = AssetLoader.LoadTexture("MainMenu/loadmission.png");
btnLoadGame.HoverTexture = AssetLoader.LoadTexture("MainMenu/loadmission_c.png");
btnLoadGame.HoverSoundEffect = new EnhancedSoundEffect("MainMenu/button.wav");
<<<<<<<
btnSkirmish.Name = "btnSkirmish";
btnSkirmish.IdleTexture = AssetLoader.LoadTexture("MainMenu/skirmish.png");
btnSkirmish.HoverTexture = AssetLoader.LoadTexture("MainMenu/skirmish_c.png");
btnSkirmish.HoverSoundEffect = new EnhancedSoundEffect("MainMenu/button.wav");
=======
btnSkirmish.Name = nameof(btnSkirmish);
btnSkirmish.IdleTexture = AssetLoader.LoadTexture("MainMenu\\skirmish.png");
btnSkirmish.HoverTexture = AssetLoader.LoadTexture("MainMenu\\skirmish_c.png");
btnSkirmish.HoverSoundEffect = new EnhancedSoundEffect("MainMenu\\button.wav");
>>>>>>>
btnSkirmish.Name = nameof(btnSkirmish);
btnSkirmish.IdleTexture = AssetLoader.LoadTexture("MainMenu/skirmish.png");
btnSkirmish.HoverTexture = AssetLoader.LoadTexture("MainMenu/skirmish_c.png");
btnSkirmish.HoverSoundEffect = new EnhancedSoundEffect("MainMenu/button.wav");
<<<<<<<
btnCnCNet.Name = "btnCnCNet";
btnCnCNet.IdleTexture = AssetLoader.LoadTexture("MainMenu/cncnet.png");
btnCnCNet.HoverTexture = AssetLoader.LoadTexture("MainMenu/cncnet_c.png");
btnCnCNet.HoverSoundEffect = new EnhancedSoundEffect("MainMenu/button.wav");
=======
btnCnCNet.Name = nameof(btnCnCNet);
btnCnCNet.IdleTexture = AssetLoader.LoadTexture("MainMenu\\cncnet.png");
btnCnCNet.HoverTexture = AssetLoader.LoadTexture("MainMenu\\cncnet_c.png");
btnCnCNet.HoverSoundEffect = new EnhancedSoundEffect("MainMenu\\button.wav");
>>>>>>>
btnCnCNet.Name = nameof(btnCnCNet);
btnCnCNet.IdleTexture = AssetLoader.LoadTexture("MainMenu/cncnet.png");
btnCnCNet.HoverTexture = AssetLoader.LoadTexture("MainMenu/cncnet_c.png");
btnCnCNet.HoverSoundEffect = new EnhancedSoundEffect("MainMenu/button.wav");
<<<<<<<
btnLan.Name = "btnLan";
btnLan.IdleTexture = AssetLoader.LoadTexture("MainMenu/lan.png");
btnLan.HoverTexture = AssetLoader.LoadTexture("MainMenu/lan_c.png");
btnLan.HoverSoundEffect = new EnhancedSoundEffect("MainMenu/button.wav");
=======
btnLan.Name = nameof(btnLan);
btnLan.IdleTexture = AssetLoader.LoadTexture("MainMenu\\lan.png");
btnLan.HoverTexture = AssetLoader.LoadTexture("MainMenu\\lan_c.png");
btnLan.HoverSoundEffect = new EnhancedSoundEffect("MainMenu\\button.wav");
>>>>>>>
btnLan.Name = nameof(btnLan);
btnLan.IdleTexture = AssetLoader.LoadTexture("MainMenu/lan.png");
btnLan.HoverTexture = AssetLoader.LoadTexture("MainMenu/lan_c.png");
btnLan.HoverSoundEffect = new EnhancedSoundEffect("MainMenu/button.wav");
<<<<<<<
btnOptions.Name = "btnOptions";
btnOptions.IdleTexture = AssetLoader.LoadTexture("MainMenu/options.png");
btnOptions.HoverTexture = AssetLoader.LoadTexture("MainMenu/options_c.png");
btnOptions.HoverSoundEffect = new EnhancedSoundEffect("MainMenu/button.wav");
=======
btnOptions.Name = nameof(btnOptions);
btnOptions.IdleTexture = AssetLoader.LoadTexture("MainMenu\\options.png");
btnOptions.HoverTexture = AssetLoader.LoadTexture("MainMenu\\options_c.png");
btnOptions.HoverSoundEffect = new EnhancedSoundEffect("MainMenu\\button.wav");
>>>>>>>
btnOptions.Name = nameof(btnOptions);
btnOptions.IdleTexture = AssetLoader.LoadTexture("MainMenu/options.png");
btnOptions.HoverTexture = AssetLoader.LoadTexture("MainMenu/options_c.png");
btnOptions.HoverSoundEffect = new EnhancedSoundEffect("MainMenu/button.wav");
<<<<<<<
btnMapEditor.Name = "btnMapEditor";
btnMapEditor.IdleTexture = AssetLoader.LoadTexture("MainMenu/mapeditor.png");
btnMapEditor.HoverTexture = AssetLoader.LoadTexture("MainMenu/mapeditor_c.png");
btnMapEditor.HoverSoundEffect = new EnhancedSoundEffect("MainMenu/button.wav");
=======
btnMapEditor.Name = nameof(btnMapEditor);
btnMapEditor.IdleTexture = AssetLoader.LoadTexture("MainMenu\\mapeditor.png");
btnMapEditor.HoverTexture = AssetLoader.LoadTexture("MainMenu\\mapeditor_c.png");
btnMapEditor.HoverSoundEffect = new EnhancedSoundEffect("MainMenu\\button.wav");
>>>>>>>
btnMapEditor.Name = nameof(btnMapEditor);
btnMapEditor.IdleTexture = AssetLoader.LoadTexture("MainMenu/mapeditor.png");
btnMapEditor.HoverTexture = AssetLoader.LoadTexture("MainMenu/mapeditor_c.png");
btnMapEditor.HoverSoundEffect = new EnhancedSoundEffect("MainMenu/button.wav");
<<<<<<<
btnStatistics.Name = "btnStatistics";
btnStatistics.IdleTexture = AssetLoader.LoadTexture("MainMenu/statistics.png");
btnStatistics.HoverTexture = AssetLoader.LoadTexture("MainMenu/statistics_c.png");
btnStatistics.HoverSoundEffect = new EnhancedSoundEffect("MainMenu/button.wav");
=======
btnStatistics.Name = nameof(btnStatistics);
btnStatistics.IdleTexture = AssetLoader.LoadTexture("MainMenu\\statistics.png");
btnStatistics.HoverTexture = AssetLoader.LoadTexture("MainMenu\\statistics_c.png");
btnStatistics.HoverSoundEffect = new EnhancedSoundEffect("MainMenu\\button.wav");
>>>>>>>
btnStatistics.Name = nameof(btnStatistics);
btnStatistics.IdleTexture = AssetLoader.LoadTexture("MainMenu/statistics.png");
btnStatistics.HoverTexture = AssetLoader.LoadTexture("MainMenu/statistics_c.png");
btnStatistics.HoverSoundEffect = new EnhancedSoundEffect("MainMenu/button.wav");
<<<<<<<
btnCredits.Name = "btnCredits";
btnCredits.IdleTexture = AssetLoader.LoadTexture("MainMenu/credits.png");
btnCredits.HoverTexture = AssetLoader.LoadTexture("MainMenu/credits_c.png");
btnCredits.HoverSoundEffect = new EnhancedSoundEffect("MainMenu/button.wav");
=======
btnCredits.Name = nameof(btnCredits);
btnCredits.IdleTexture = AssetLoader.LoadTexture("MainMenu\\credits.png");
btnCredits.HoverTexture = AssetLoader.LoadTexture("MainMenu\\credits_c.png");
btnCredits.HoverSoundEffect = new EnhancedSoundEffect("MainMenu\\button.wav");
>>>>>>>
btnCredits.Name = nameof(btnCredits);
btnCredits.IdleTexture = AssetLoader.LoadTexture("MainMenu/credits.png");
btnCredits.HoverTexture = AssetLoader.LoadTexture("MainMenu/credits_c.png");
btnCredits.HoverSoundEffect = new EnhancedSoundEffect("MainMenu/button.wav");
<<<<<<<
btnExtras.Name = "btnExtras";
btnExtras.IdleTexture = AssetLoader.LoadTexture("MainMenu/extras.png");
btnExtras.HoverTexture = AssetLoader.LoadTexture("MainMenu/extras_c.png");
btnExtras.HoverSoundEffect = new EnhancedSoundEffect("MainMenu/button.wav");
=======
btnExtras.Name = nameof(btnExtras);
btnExtras.IdleTexture = AssetLoader.LoadTexture("MainMenu\\extras.png");
btnExtras.HoverTexture = AssetLoader.LoadTexture("MainMenu\\extras_c.png");
btnExtras.HoverSoundEffect = new EnhancedSoundEffect("MainMenu\\button.wav");
>>>>>>>
btnExtras.Name = nameof(btnExtras);
btnExtras.IdleTexture = AssetLoader.LoadTexture("MainMenu/extras.png");
btnExtras.HoverTexture = AssetLoader.LoadTexture("MainMenu/extras_c.png");
btnExtras.HoverSoundEffect = new EnhancedSoundEffect("MainMenu/button.wav");
<<<<<<<
btnExit.Name = "btnExit";
btnExit.IdleTexture = AssetLoader.LoadTexture("MainMenu/exitgame.png");
btnExit.HoverTexture = AssetLoader.LoadTexture("MainMenu/exitgame_c.png");
btnExit.HoverSoundEffect = new EnhancedSoundEffect("MainMenu/button.wav");
=======
btnExit.Name = nameof(btnExit);
btnExit.IdleTexture = AssetLoader.LoadTexture("MainMenu\\exitgame.png");
btnExit.HoverTexture = AssetLoader.LoadTexture("MainMenu\\exitgame_c.png");
btnExit.HoverSoundEffect = new EnhancedSoundEffect("MainMenu\\button.wav");
>>>>>>>
btnExit.Name = nameof(btnExit);
btnExit.IdleTexture = AssetLoader.LoadTexture("MainMenu/exitgame.png");
btnExit.HoverTexture = AssetLoader.LoadTexture("MainMenu/exitgame_c.png");
btnExit.HoverSoundEffect = new EnhancedSoundEffect("MainMenu/button.wav"); |
<<<<<<<
XNALabel lblPrivateMessaging;
XNAClientTabControl tabControl;
XNALabel lblPlayers;
XNAListBox lbUserList;
XNALabel lblMessages;
ChatListBox lbMessages;
XNATextBox tbMessageInput;
XNAContextMenu playerContextMenu;
CnCNetManager connectionManager;
GameCollection gameCollection;
Texture2D unknownGameIcon;
Texture2D adminGameIcon;
Color personalMessageColor;
Color otherUserMessageColor;
string lastReceivedPMSender;
string lastConversationPartner;
/// <summary>
/// Holds the users that the local user has had conversations with
/// during this client session.
/// </summary>
List<PrivateMessageUser> privateMessageUsers = new List<PrivateMessageUser>();
PrivateMessageNotificationBox notificationBox;
EnhancedSoundEffect sndPrivateMessageSound;
EnhancedSoundEffect sndMessageSound;
/// <summary>
/// Because the user cannot view PMs during a game, we store the latest
/// PM received during a game in this variable and display it when the
/// user has returned from the game.
/// </summary>
PrivateMessage pmReceivedDuringGame;
// these are used by the "invite to game" feature in the
// context menu and are kept up-to-date by the lobby
private string inviteChannelName;
private string inviteGameName;
private string inviteChannelPassword;
public override void Initialize()
{
Name = "PrivateMessagingWindow";
ClientRectangle = new Rectangle(0, 0, 600, 600);
BackgroundTexture = AssetLoader.LoadTextureUncached("privatemessagebg.png");
unknownGameIcon = AssetLoader.TextureFromImage(ClientCore.Properties.Resources.unknownicon);
adminGameIcon = AssetLoader.TextureFromImage(ClientCore.Properties.Resources.cncneticon);
personalMessageColor = AssetLoader.GetColorFromString(ClientConfiguration.Instance.SentPMColor);
otherUserMessageColor = AssetLoader.GetColorFromString(ClientConfiguration.Instance.ReceivedPMColor);
lblPrivateMessaging = new XNALabel(WindowManager);
lblPrivateMessaging.Name = "lblPrivateMessaging";
lblPrivateMessaging.FontIndex = 1;
lblPrivateMessaging.Text = "PRIVATE MESSAGING";
AddChild(lblPrivateMessaging);
lblPrivateMessaging.CenterOnParent();
lblPrivateMessaging.ClientRectangle = new Rectangle(
lblPrivateMessaging.X, 12,
lblPrivateMessaging.Width,
lblPrivateMessaging.Height);
tabControl = new XNAClientTabControl(WindowManager);
tabControl.Name = "tabControl";
tabControl.ClientRectangle = new Rectangle(60, 50, 0, 0);
tabControl.ClickSound = new EnhancedSoundEffect("button.wav");
tabControl.FontIndex = 1;
tabControl.AddTab("Messages", 160);
tabControl.AddTab("Friend List", 160);
tabControl.AddTab("All Players", 160);
tabControl.SelectedIndexChanged += TabControl_SelectedIndexChanged;
lblPlayers = new XNALabel(WindowManager);
lblPlayers.Name = "lblPlayers";
lblPlayers.ClientRectangle = new Rectangle(12, tabControl.Bottom + 24, 0, 0);
lblPlayers.FontIndex = 1;
lblPlayers.Text = "PLAYERS:";
lbUserList = new XNAListBox(WindowManager);
lbUserList.Name = "lbUserList";
lbUserList.ClientRectangle = new Rectangle(lblPlayers.X,
lblPlayers.Bottom + 6,
150, Height - lblPlayers.Bottom - 18);
lbUserList.RightClick += LbUserList_RightClick;
lbUserList.SelectedIndexChanged += LbUserList_SelectedIndexChanged;
lbUserList.BackgroundTexture = AssetLoader.CreateTexture(new Color(0, 0, 0, 128), 1, 1);
lbUserList.PanelBackgroundDrawMode = PanelBackgroundImageDrawMode.STRETCHED;
lblMessages = new XNALabel(WindowManager);
lblMessages.Name = "lblMessages";
lblMessages.ClientRectangle = new Rectangle(lbUserList.Right + 12,
lblPlayers.Y, 0, 0);
lblMessages.FontIndex = 1;
lblMessages.Text = "MESSAGES:";
lbMessages = new ChatListBox(WindowManager);
lbMessages.Name = "lbMessages";
lbMessages.ClientRectangle = new Rectangle(lblMessages.X,
lbUserList.Y,
Width - lblMessages.X - 12,
lbUserList.Height - 25);
lbMessages.BackgroundTexture = AssetLoader.CreateTexture(new Color(0, 0, 0, 128), 1, 1);
lbMessages.PanelBackgroundDrawMode = PanelBackgroundImageDrawMode.STRETCHED;
tbMessageInput = new XNATextBox(WindowManager);
tbMessageInput.Name = "tbMessageInput";
tbMessageInput.ClientRectangle = new Rectangle(lbMessages.X,
lbMessages.Bottom + 6, lbMessages.Width, 19);
tbMessageInput.EnterPressed += TbMessageInput_EnterPressed;
tbMessageInput.MaximumTextLength = 200;
tbMessageInput.Enabled = false;
playerContextMenu = new XNAContextMenu(WindowManager);
playerContextMenu.Name = "playerContextMenu";
playerContextMenu.ClientRectangle = new Rectangle(0, 0, 150, 2);
playerContextMenu.Enabled = false;
playerContextMenu.Visible = false;
playerContextMenu.AddItem("Add Friend", PlayerContextMenu_ToggleFriend);
playerContextMenu.AddItem("Invite", PlayerContextMenu_Invite, null, () => !string.IsNullOrEmpty(inviteChannelName));
notificationBox = new PrivateMessageNotificationBox(WindowManager);
notificationBox.Enabled = false;
notificationBox.Visible = false;
notificationBox.LeftClick += NotificationBox_LeftClick;
AddChild(tabControl);
AddChild(lblPlayers);
AddChild(lbUserList);
AddChild(lblMessages);
AddChild(lbMessages);
AddChild(tbMessageInput);
AddChild(playerContextMenu);
WindowManager.AddAndInitializeControl(notificationBox);
base.Initialize();
CenterOnParent();
tabControl.SelectedTab = 0;
connectionManager.PrivateMessageReceived += ConnectionManager_PrivateMessageReceived;
sndMessageSound = new EnhancedSoundEffect("message.wav");
sndPrivateMessageSound = new EnhancedSoundEffect("pm.wav");
sndMessageSound.Enabled = UserINISettings.Instance.MessageSound;
GameProcessLogic.GameProcessExited += SharedUILogic_GameProcessExited;
}
public void SetInviteChannelInfo(string channelName, string gameName, string channelPassword)
{
inviteChannelName = channelName;
inviteGameName = gameName;
inviteChannelPassword = channelPassword;
}
public void ClearInviteChannelInfo()
{
SetInviteChannelInfo(string.Empty, string.Empty, string.Empty);
}
private void NotificationBox_LeftClick(object sender, EventArgs e)
{
SwitchOn();
}
=======
private void NotificationBox_LeftClick(object sender, EventArgs e) => SwitchOn();
>>>>>>>
public void SetInviteChannelInfo(string channelName, string gameName, string channelPassword)
{
inviteChannelName = channelName;
inviteGameName = gameName;
inviteChannelPassword = channelPassword;
}
public void ClearInviteChannelInfo() => SetInviteChannelInfo(string.Empty, string.Empty, string.Empty);
private void NotificationBox_LeftClick(object sender, EventArgs e) => SwitchOn();
<<<<<<<
private void PlayerContextMenu_Invite()
{
var lbItem = lbUserList.SelectedItem;
if (lbItem == null)
{
return;
}
// note it's assumed that if the channel name is specified, the game name must be also
if (string.IsNullOrEmpty(inviteChannelName) || ProgramConstants.IsInGame)
{
return;
}
string messageBody = ProgramConstants.GAME_INVITE_CTCP_COMMAND + " " + inviteChannelName + ";" + inviteGameName;
if (!string.IsNullOrEmpty(inviteChannelPassword))
{
messageBody += ";" + inviteChannelPassword;
}
connectionManager.SendCustomMessage(new QueuedMessage("PRIVMSG " + lbItem.Text + " :\u0001" +
messageBody + "\u0001",
QueuedMessageType.CHAT_MESSAGE, 0));
}
private void SharedUILogic_GameProcessExited()
=======
private void PlayerContextMenu_ToggleIgnore()
>>>>>>>
private void PlayerContextMenu_Invite()
{
var lbItem = lbUserList.SelectedItem;
if (lbItem == null)
{
return;
}
// note it's assumed that if the channel name is specified, the game name must be also
if (string.IsNullOrEmpty(inviteChannelName) || ProgramConstants.IsInGame)
{
return;
}
string messageBody = ProgramConstants.GAME_INVITE_CTCP_COMMAND + " " + inviteChannelName + ";" + inviteGameName;
if (!string.IsNullOrEmpty(inviteChannelPassword))
{
messageBody += ";" + inviteChannelPassword;
}
connectionManager.SendCustomMessage(new QueuedMessage("PRIVMSG " + lbItem.Text + " :\u0001" +
messageBody + "\u0001",
QueuedMessageType.CHAT_MESSAGE, 0));
}
private void PlayerContextMenu_ToggleIgnore() |
<<<<<<<
var options = new IACompilerParameters { GenerateExecutable = false, GenerateInMemory = true };
options.ReferencedAssemblies.Add(typeof(Core).Namespace + ".dll");
=======
var options = new CompilerParameters { GenerateExecutable = false, GenerateInMemory = true, };
>>>>>>>
var options = new IACompilerParameters { GenerateExecutable = false, GenerateInMemory = true }; |
<<<<<<<
SetVariable = typeof(Script.Variables).GetMethod("set_Item");
GetVariable = typeof(Script.Variables).GetMethod("get_Item");
MethodInfo GetVars = typeof(Script).GetMethod("get_Vars");
if(Mirror != null)
{
ForceString = Mirror.GrabMethod(ForceString);
ForceDecimal = Mirror.GrabMethod(ForceDecimal);
ForceLong = Mirror.GrabMethod(ForceLong);
ForceInt = Mirror.GrabMethod(ForceInt);
ForceBool = Mirror.GrabMethod(ForceBool);
SetVariable = Mirror.GrabMethod(SetVariable);
GetVariable = Mirror.GrabMethod(GetVariable);
Variables = Mirror.GrabType(Variables);
GetVars = Mirror.GrabMethod(GetVars);
}
=======
SetVariable = typeof(Script.Variables).GetMethod("SetVariable");
GetVariable = typeof(Script.Variables).GetMethod("GetVariable");
>>>>>>>
SetVariable = typeof(Script.Variables).GetMethod("SetVariable");
GetVariable = typeof(Script.Variables).GetMethod("GetVariable");
MethodInfo GetVars = typeof(Script).GetMethod("get_Vars");
if(Mirror != null)
{
ForceString = Mirror.GrabMethod(ForceString);
ForceDecimal = Mirror.GrabMethod(ForceDecimal);
ForceLong = Mirror.GrabMethod(ForceLong);
ForceInt = Mirror.GrabMethod(ForceInt);
ForceBool = Mirror.GrabMethod(ForceBool);
SetVariable = Mirror.GrabMethod(SetVariable);
GetVariable = Mirror.GrabMethod(GetVariable);
Variables = Mirror.GrabType(Variables);
GetVars = Mirror.GrabMethod(GetVars);
} |
<<<<<<<
_logger.LogDebug($"Publishing message '{typeof(T).Name}' on exchange '{config.Exchange.Name}' with routing key {config.RoutingKey}.");
=======
_logger.LogDebug($"Initiating publish for message '{typeof(T).Name}' on exchange '{config.Exchange.ExchangeName}' with routing key {config.RoutingKey}.");
>>>>>>>
_logger.LogDebug($"Initiating publish for message '{typeof(T).Name}' on exchange '{config.Exchange.Name}' with routing key {config.RoutingKey}."); |
<<<<<<<
public class Pet : IEquatable<Pet>
{
[JsonConverter(typeof(StringEnumConverter))]
public enum StatusEnum {
[EnumMember(Value = "available")]
Available,
[EnumMember(Value = "pending")]
Pending,
[EnumMember(Value = "sold")]
Sold
}
/// <summary>
/// pet status in the store
/// </summary>
/// <value>pet status in the store</value>
[DataMember(Name="status", EmitDefaultValue=true)]
public StatusEnum Status { get; set; }
=======
public partial class Pet : IEquatable<Pet>
{
>>>>>>>
public partial class Pet : IEquatable<Pet>
{
[JsonConverter(typeof(StringEnumConverter))]
public enum StatusEnum {
[EnumMember(Value = "available")]
Available,
[EnumMember(Value = "pending")]
Pending,
[EnumMember(Value = "sold")]
Sold
}
/// <summary>
/// pet status in the store
/// </summary>
/// <value>pet status in the store</value>
[DataMember(Name="status", EmitDefaultValue=true)]
public StatusEnum Status { get; set; }
<<<<<<<
=======
// to ensure "Name" is required (not null)
if (Name == null)
{
throw new InvalidDataException("Name is a required property for Pet and cannot be null");
}
else
{
this.Name = Name;
}
// to ensure "PhotoUrls" is required (not null)
if (PhotoUrls == null)
{
throw new InvalidDataException("PhotoUrls is a required property for Pet and cannot be null");
}
else
{
this.PhotoUrls = PhotoUrls;
}
this.Id = Id;
this.Category = Category;
this.Tags = Tags;
this.Status = Status;
>>>>>>>
// to ensure "Name" is required (not null)
if (Name == null)
{
throw new InvalidDataException("Name is a required property for Pet and cannot be null");
}
else
{
this.Name = Name;
}
// to ensure "PhotoUrls" is required (not null)
if (PhotoUrls == null)
{
throw new InvalidDataException("PhotoUrls is a required property for Pet and cannot be null");
}
else
{
this.PhotoUrls = PhotoUrls;
}
this.Id = Id;
this.Category = Category;
this.Tags = Tags;
this.Status = Status; |
<<<<<<<
public class Tag : IEquatable<Tag>
{
=======
public partial class Tag : IEquatable<Tag>
{
>>>>>>>
public partial class Tag : IEquatable<Tag>
{
<<<<<<<
=======
this.Id = Id;
this.Name = Name;
>>>>>>>
this.Id = Id;
this.Name = Name; |
<<<<<<<
public class Order : IEquatable<Order>
{
[JsonConverter(typeof(StringEnumConverter))]
public enum StatusEnum {
[EnumMember(Value = "placed")]
Placed,
[EnumMember(Value = "approved")]
Approved,
[EnumMember(Value = "delivered")]
Delivered
}
/// <summary>
/// Order Status
/// </summary>
/// <value>Order Status</value>
[DataMember(Name="status", EmitDefaultValue=true)]
public StatusEnum Status { get; set; }
=======
public partial class Order : IEquatable<Order>
{
>>>>>>>
public partial class Order : IEquatable<Order>
{
[JsonConverter(typeof(StringEnumConverter))]
public enum StatusEnum {
[EnumMember(Value = "placed")]
Placed,
[EnumMember(Value = "approved")]
Approved,
[EnumMember(Value = "delivered")]
Delivered
}
/// <summary>
/// Order Status
/// </summary>
/// <value>Order Status</value>
[DataMember(Name="status", EmitDefaultValue=true)]
public StatusEnum Status { get; set; }
<<<<<<<
=======
this.PetId = PetId;
this.Quantity = Quantity;
this.ShipDate = ShipDate;
this.Status = Status;
this.Complete = Complete;
>>>>>>>
this.PetId = PetId;
this.Quantity = Quantity;
this.ShipDate = ShipDate;
this.Status = Status;
this.Complete = Complete;
<<<<<<<
[DataMember(Name="id", EmitDefaultValue=true)]
public long? Id { get; set; }
=======
[DataMember(Name="id", EmitDefaultValue=false)]
public long? Id { get; private set; }
>>>>>>>
[DataMember(Name="id", EmitDefaultValue=true)]
public long? Id { get; private set; } |
<<<<<<<
// authentication (test_api_key_query) required
if (!String.IsNullOrEmpty(Configuration.GetApiKeyWithPrefix("test_api_key_query")))
{
localVarQueryParams["test_api_key_query"] = Configuration.GetApiKeyWithPrefix("test_api_key_query");
}
// authentication (test_api_key_header) required
if (!String.IsNullOrEmpty(Configuration.GetApiKeyWithPrefix("test_api_key_header")))
{
localVarHeaderParams["test_api_key_header"] = Configuration.GetApiKeyWithPrefix("test_api_key_header");
}
=======
>>>>>>>
<<<<<<<
// authentication (test_api_key_query) required
if (!String.IsNullOrEmpty(Configuration.GetApiKeyWithPrefix("test_api_key_query")))
{
localVarQueryParams["test_api_key_query"] = Configuration.GetApiKeyWithPrefix("test_api_key_query");
}
// authentication (test_api_key_header) required
if (!String.IsNullOrEmpty(Configuration.GetApiKeyWithPrefix("test_api_key_header")))
{
localVarHeaderParams["test_api_key_header"] = Configuration.GetApiKeyWithPrefix("test_api_key_header");
}
=======
>>>>>>> |
<<<<<<<
struct Primitive {
public UnityEngine.Mesh mesh;
public int materialIndex;
public Primitive( UnityEngine.Mesh mesh, int materialIndex ) {
this.mesh = mesh;
this.materialIndex = materialIndex;
}
}
struct ImageCreateContext {
public int imageIndex;
public byte[] buffer;
public GCHandle gcHandle;
public JobHandle jobHandle;
}
abstract class KtxLoadContextBase {
public int imageIndex;
public Texture2D texture;
protected KtxTexture ktxTexture;
public abstract IEnumerator LoadKtx();
protected void OnKtxLoaded(Texture2D newTexture) {
ktxTexture.onTextureLoaded -= OnKtxLoaded;
texture = newTexture;
}
}
class KtxLoadContext : KtxLoadContextBase {
byte[] data;
public KtxLoadContext(int index,byte[] data) {
this.imageIndex = index;
this.data = data;
ktxTexture = new KtxTexture();
texture = null;
}
public override IEnumerator LoadKtx() {
ktxTexture.onTextureLoaded += OnKtxLoaded;
var slice = new NativeArray<byte>(data,KtxNativeInstance.defaultAllocator);
yield return ktxTexture.LoadBytesRoutine(slice);
slice.Dispose();
data = null;
}
}
class KtxLoadNativeContext : KtxLoadContextBase {
NativeSlice<byte> slice;
public KtxLoadNativeContext(int index,NativeSlice<byte> slice) {
this.imageIndex = index;
this.slice = slice;
ktxTexture = new KtxTexture();
texture = null;
}
public override IEnumerator LoadKtx() {
ktxTexture.onTextureLoaded += OnKtxLoaded;
return ktxTexture.LoadBytesRoutine(slice);
}
}
abstract class PrimitiveCreateContextBase {
public int primtiveIndex;
public MeshPrimitive primitive;
public abstract bool IsCompleted {get;}
public abstract Primitive? CreatePrimitive();
}
class PrimitiveCreateContext : PrimitiveCreateContextBase {
public Mesh mesh;
/// TODO remove begin
public Vector3[] positions;
public Vector3[] normals;
public Vector2[] uvs0;
public Vector2[] uvs1;
public Vector4[] tangents;
public Color32[] colors32;
public Color[] colors;
/// TODO remove end
public JobHandle jobHandle;
public int[] indices;
public GCHandle[] gcHandles;
public override bool IsCompleted {
get {
return jobHandle.IsCompleted;
}
}
public override Primitive? CreatePrimitive() {
Profiler.BeginSample("CreatePrimitive");
jobHandle.Complete();
var msh = new UnityEngine.Mesh();
if( positions.Length > 65536 ) {
#if UNITY_2017_3_OR_NEWER
msh.indexFormat = UnityEngine.Rendering.IndexFormat.UInt32;
#else
throw new System.Exception("Meshes with more than 65536 vertices are only supported from Unity 2017.3 onwards.");
#endif
}
msh.name = mesh.name;
msh.vertices = positions;
msh.SetIndices(
indices
,MeshTopology.Triangles
,0
);
if(uvs0!=null) {
msh.uv = uvs0;
}
if(uvs1!=null) {
msh.uv2 = uvs1;
}
if(normals!=null) {
msh.normals = normals;
} else {
msh.RecalculateNormals();
}
if (colors!=null) {
msh.colors = colors;
} else if(colors32!=null) {
msh.colors32 = colors32;
}
if(tangents!=null) {
msh.tangents = tangents;
} else {
msh.RecalculateTangents();
}
// primitives[c.primtiveIndex] = new Primitive(msh,c.primitive.material);
// resources.Add(msh);
Dispose();
Profiler.EndSample();
return new Primitive(msh,primitive.material);
}
void Dispose() {
for(int i=0;i<gcHandles.Length;i++) {
gcHandles[i].Free();
}
}
}
class PrimitiveDracoCreateContext : PrimitiveCreateContextBase {
public JobHandle jobHandle;
public NativeArray<int> dracoResult;
public NativeArray<IntPtr> dracoPtr;
public override bool IsCompleted {
get {
return jobHandle.IsCompleted;
}
}
public override Primitive? CreatePrimitive() {
jobHandle.Complete();
int result = dracoResult[0];
IntPtr dracoMesh = dracoPtr[0];
dracoResult.Dispose();
dracoPtr.Dispose();
if (result <= 0) {
Debug.LogError ("Failed: Decoding error.");
return null;
}
var msh = DracoMeshLoader.CreateMesh(dracoMesh);
return new Primitive(msh,primitive.material);
}
}
=======
>>>>>>>
<<<<<<<
public IEnumerator WaitForKtxTextures() {
if(ktxLoadContexts==null) yield break;
foreach (var ktx in ktxLoadContexts)
{
yield return ktx.LoadKtx();
images[ktx.imageIndex] = ktx.texture;
}
ktxLoadContexts.Clear();
}
public bool InstanciateGltf( Transform parent ) {
=======
public bool InstantiateGltf( Transform parent ) {
>>>>>>>
public IEnumerator WaitForKtxTextures() {
if(ktxLoadContexts==null) yield break;
foreach (var ktx in ktxLoadContexts)
{
yield return ktx.LoadKtx();
images[ktx.imageIndex] = ktx.texture;
}
ktxLoadContexts.Clear();
}
public bool InstantiateGltf( Transform parent ) {
<<<<<<<
=======
byte[] DecodeEmbedBuffer(string encodedBytes) {
string tmp;
return DecodeEmbedBuffer(encodedBytes,out tmp);
}
byte[] DecodeEmbedBuffer(string encodedBytes, out string mimeType) {
mimeType = null;
Debug.LogWarning("JSON embed buffers are slow! consider using glTF binary");
var mediaTypeEnd = encodedBytes.IndexOf(';',5,Math.Min(encodedBytes.Length-5,1000) );
if(mediaTypeEnd<0) return null;
mimeType = encodedBytes.Substring(5,mediaTypeEnd-5);
var tmp = encodedBytes.Substring(mediaTypeEnd+1,7);
if(tmp!="base64,") return null;
return System.Convert.FromBase64String(encodedBytes.Substring(mediaTypeEnd+8));
}
void LoadTexture( int index, string url ) {
var www = UnityWebRequestTexture.GetTexture(url);
if(textureDownloads==null) {
textureDownloads = new Dictionary<int, UnityWebRequestAsyncOperation>();
}
textureDownloads[index] = www.SendWebRequest();
}
>>>>>>>
byte[] DecodeEmbedBuffer(string encodedBytes) {
string tmp;
return DecodeEmbedBuffer(encodedBytes,out tmp);
}
byte[] DecodeEmbedBuffer(string encodedBytes, out string mimeType) {
mimeType = null;
Debug.LogWarning("JSON embed buffers are slow! consider using glTF binary");
var mediaTypeEnd = encodedBytes.IndexOf(';',5,Math.Min(encodedBytes.Length-5,1000) );
if(mediaTypeEnd<0) return null;
mimeType = encodedBytes.Substring(5,mediaTypeEnd-5);
var tmp = encodedBytes.Substring(mediaTypeEnd+1,7);
if(tmp!="base64,") return null;
return System.Convert.FromBase64String(encodedBytes.Substring(mediaTypeEnd+8));
}
void LoadTexture( int index, string url, bool isKtx ) {
UnityWebRequest www;
if(isKtx) {
www = UnityWebRequest.Get(url);
} else {
www = UnityWebRequestTexture.GetTexture(url);
}
if(textureDownloads==null) {
textureDownloads = new Dictionary<int, UnityWebRequestAsyncOperation>();
}
textureDownloads[index] = www.SendWebRequest();
}
<<<<<<<
Debug.LogWarning("Image is missing mime type");
knownImageType = IsKnownImageFileExtension(img.uri);
=======
// Image is missing mime type
// try to determine type by file extension
knownImageType = IsKnownImageFileExtension(img.uri);
>>>>>>>
// Image is missing mime type
// try to determine type by file extension
knownImageType = IsKnownImageFileExtension(img.uri);
<<<<<<<
=======
var buffer = GetBuffer(bufferView.buffer);
var chunk = binChunks[bufferView.buffer];
var txt = CreateEmptyTexture(img,i);
var icc = new ImageCreateContext();
icc.imageIndex = i;
icc.buffer = new byte[bufferView.byteLength];
icc.gcHandle = GCHandle.Alloc(icc.buffer,GCHandleType.Pinned);
var job = new Jobs.MemCopyJob();
job.bufferSize = bufferView.byteLength;
fixed( void* src = &(buffer[bufferView.byteOffset + chunk.start]), dst = &(icc.buffer[0]) ) {
job.input = src;
job.result = dst;
}
icc.jobHandle = job.Schedule();
contexts.Add(icc);
>>>>>>> |
<<<<<<<
UnityEngine.Material GetPbrMetallicRoughnessMaterial();
UnityEngine.Material GenerateMaterial(
Material gltfMaterial,
ref Schema.Texture[] textures,
ref Schema.Image[] schemaImages,
ref UnityEngine.Texture2D[] images
);
=======
UnityEngine.Material GetPbrMetallicRoughnessMaterial(bool doubleSided=false);
UnityEngine.Material GenerateMaterial( Material gltfMaterial, Schema.Texture[] textures, UnityEngine.Texture2D[] images );
>>>>>>>
UnityEngine.Material GetPbrMetallicRoughnessMaterial(bool doubleSided=false);
UnityEngine.Material GenerateMaterial(
Material gltfMaterial,
ref Schema.Texture[] textures,
ref Schema.Image[] schemaImages,
ref UnityEngine.Texture2D[] images
); |
<<<<<<<
var minDist = area.Center.Y - 40;
string widthText = $"{ViewModel.Width}{ViewModel.Unit}";
=======
string widthText = $"{MathF.Round(ViewModel.Width, 3)}{ViewModel.Unit}";
>>>>>>>
var minDist = area.Center.Y - 40;
string widthText = $"{MathF.Round(ViewModel.Width, 3)}{ViewModel.Unit}";
<<<<<<<
var minDist = area.Center.X - 40;
string heightText = $"{ViewModel.Height}{ViewModel.Unit}";
=======
string heightText = $"{MathF.Round(ViewModel.Height, 3)}{ViewModel.Unit}";
>>>>>>>
var minDist = area.Center.X - 40;
string heightText = $"{MathF.Round(ViewModel.Height, 3)}{ViewModel.Unit}"; |
<<<<<<<
var settingsFile = new FileInfo(appInfo.SettingsFile);
await Application.Instance.InvokeAsync(async () => Settings = await Driver.Instance.GetSettings());
if (!settingsFile.Exists)
await ShowFirstStartupGreeter();
outputModeEditor.SetDisplaySize(SystemInterop.VirtualScreen.Displays);
=======
settingsFile = new FileInfo(appInfo.SettingsFile);
if (await Driver.Instance.GetSettings() is Settings settings)
{
await Application.Instance.InvokeAsync(() => Settings = settings);
}
else if (settingsFile.Exists)
{
try
{
await Application.Instance.InvokeAsync(() => Settings = Settings.Deserialize(settingsFile));
await Driver.Instance.SetSettings(Settings);
}
catch
{
MessageBox.Show("Failed to load your current settings. They are either out of date or corrupted.", MessageBoxType.Error);
await ResetSettings();
}
}
else
{
await ResetSettings();
}
>>>>>>>
var settingsFile = new FileInfo(appInfo.SettingsFile);
await Application.Instance.InvokeAsync(async () => Settings = await Driver.Instance.GetSettings());
if (!settingsFile.Exists)
await ShowFirstStartupGreeter(); |
<<<<<<<
Info.Driver.ReportRecieved -= HandleReport;
lock (stateLock)
{
if (Enabled)
Enabled = false;
this.scheduler.Elapsed -= InterpolateHook;
this.scheduler.Dispose();
GC.SuppressFinalize(this);
isDisposed = true;
}
=======
if (Enabled)
Enabled = false;
this.scheduler.Elapsed -= InterpolateHook;
Info.Driver.ReportReceived -= HandleReport;
this.scheduler.Dispose();
GC.SuppressFinalize(this);
isDisposed = true;
>>>>>>>
Info.Driver.ReportReceived -= HandleReport;
lock (stateLock)
{
if (Enabled)
Enabled = false;
this.scheduler.Elapsed -= InterpolateHook;
this.scheduler.Dispose();
GC.SuppressFinalize(this);
isDisposed = true;
} |
<<<<<<<
private SocketClient _eventendpoint = null;
=======
private Thread _shutdownWhenDisconnected = null;
>>>>>>>
private SocketClient _eventendpoint = null;
private Thread _shutdownWhenDisconnected = null;
<<<<<<<
try
{
if (_client != null && _client.IsConnected)
return true;
var instance = new InstanceLocator("EditorEngine").GetInstance(_path);
if (instance == null)
return false;
_client = new SocketClient();
_client.IncomingMessage += Handle_clientIncomingMessage;
_client.Connect(instance.Port);
if (_client.IsConnected)
return true;
_client = null;
return false;
}
catch (Exception ex)
{
Debug.WriteError(ex.ToString());
return false;
=======
lock (_clientLock)
{
try
{
if (_client != null && _client.IsConnected)
return true;
var instance = new EngineLocator().GetInstance(_path);
if (instance == null)
return false;
_client = new SocketClient();
_client.IncomingMessage += Handle_clientIncomingMessage;
_client.Connect(instance.Port);
if (_client.IsConnected) {
_shutdownWhenDisconnected = new Thread(exitWhenDisconnected);
_shutdownWhenDisconnected.Start();
return true;
}
_client = null;
return false;
}
catch (Exception ex)
{
Debug.WriteError(ex.ToString());
return false;
}
}
}
private void exitWhenDisconnected()
{
while (isConnected()) {
Thread.Sleep(200);
>>>>>>>
try
{
if (_client != null && _client.IsConnected)
return true;
var instance = new InstanceLocator("EditorEngine").GetInstance(_path);
if (instance == null)
return false;
_client = new SocketClient();
_client.IncomingMessage += Handle_clientIncomingMessage;
_client.Connect(instance.Port);
if (_client.IsConnected) {
_shutdownWhenDisconnected = new Thread(exitWhenDisconnected);
_shutdownWhenDisconnected.Start();
return true;
}
_client = null;
return false;
}
catch (Exception ex)
{
Debug.WriteError(ex.ToString());
return false;
}
}
private void exitWhenDisconnected()
{
while (isConnected()) {
Thread.Sleep(200); |
<<<<<<<
/// <inheritdoc />
=======
/// <summary>
/// Converts a bool value into a <see cref="Visibility"/> value and back.
/// </summary>
>>>>>>>
/// <inheritdoc />
/// <summary>
/// Converts a bool value into a <see cref="Visibility"/> value and back.
/// </summary>
<<<<<<<
/// <inheritdoc />
=======
/// <summary>
/// Converts a bool value into a <see cref="Visibility"/> value.
/// </summary>
/// <param name="value">The value produced by the binding source.</param>
/// <param name="targetType">The type of the binding target property.</param>
/// <param name="parameter">The converter parameter to use.</param>
/// <param name="culture">The culture to use in the converter.</param>
/// <returns>
/// A converted value. If the method returns null, the valid null value is used.
/// </returns>
>>>>>>>
/// <inheritdoc />
/// <summary>
/// Converts a bool value into a <see cref="Visibility"/> value.
/// </summary>
/// <param name="value">The value produced by the binding source.</param>
/// <param name="targetType">The type of the binding target property.</param>
/// <param name="parameter">The converter parameter to use.</param>
/// <param name="culture">The culture to use in the converter.</param>
/// <returns>
/// A converted value. If the method returns null, the valid null value is used.
/// </returns>
<<<<<<<
/// <inheritdoc />
=======
/// <summary>
/// Converts a <see cref="Visibility"/> value into a bool value.
/// </summary>
/// <param name="value">The value that is produced by the binding target.</param>
/// <param name="targetType">The type to convert to.</param>
/// <param name="parameter">The converter parameter to use.</param>
/// <param name="culture">The culture to use in the converter.</param>
/// <returns>
/// A converted value. If the method returns null, the valid null value is used.
/// </returns>
>>>>>>>
/// <inheritdoc />
/// <summary>
/// Converts a <see cref="Visibility"/> value into a bool value.
/// </summary>
/// <param name="value">The value that is produced by the binding target.</param>
/// <param name="targetType">The type to convert to.</param>
/// <param name="parameter">The converter parameter to use.</param>
/// <param name="culture">The culture to use in the converter.</param>
/// <returns>
/// A converted value. If the method returns null, the valid null value is used.
/// </returns> |
<<<<<<<
[ContentProperty(nameof(Children))]
=======
/// <summary>Implements the model for a layout anchorable pane control (a pane in a tool window environment).
/// A layout anchorable pane control can have multiple LayoutAnchorable controls as its children.
/// </summary>
[ContentProperty(nameof(Children))]
>>>>>>>
/// <summary>Implements the model for a layout anchorable pane control (a pane in a tool window environment).
/// A layout anchorable pane control can have multiple LayoutAnchorable controls as its children.
/// </summary>
[ContentProperty(nameof(Children))]
<<<<<<<
/// <inheritdoc />
protected override bool GetVisibility() => Children.Count > 0 && Children.Any(c => c.IsVisible);
=======
/// <inheritdoc />
protected override bool GetVisibility()
{
return Children.Count > 0 && Children.Any(c => c.IsVisible);
}
>>>>>>>
/// <inheritdoc />
protected override bool GetVisibility() => Children.Count > 0 && Children.Any(c => c.IsVisible);
<<<<<<<
RaisePropertyChanged(nameof(CanClose));
RaisePropertyChanged(nameof(CanHide));
RaisePropertyChanged(nameof(IsDirectlyHostedInFloatingWindow));
=======
RaisePropertyChanged(nameof(CanClose));
RaisePropertyChanged(nameof(CanHide));
RaisePropertyChanged(nameof(IsDirectlyHostedInFloatingWindow));
>>>>>>>
RaisePropertyChanged(nameof(CanClose));
RaisePropertyChanged(nameof(CanHide));
RaisePropertyChanged(nameof(IsDirectlyHostedInFloatingWindow));
<<<<<<<
if (oldValue is ILayoutGroup oldGroup) oldGroup.ChildrenCollectionChanged -= OnParentChildrenCollectionChanged;
RaisePropertyChanged(nameof(IsDirectlyHostedInFloatingWindow));
if (newValue is ILayoutGroup newGroup) newGroup.ChildrenCollectionChanged += OnParentChildrenCollectionChanged;
=======
var oldGroup = oldValue as ILayoutGroup;
if (oldGroup != null)
oldGroup.ChildrenCollectionChanged -= new EventHandler(OnParentChildrenCollectionChanged);
RaisePropertyChanged(nameof(IsDirectlyHostedInFloatingWindow));
var newGroup = newValue as ILayoutGroup;
if (newGroup != null)
newGroup.ChildrenCollectionChanged += new EventHandler(OnParentChildrenCollectionChanged);
>>>>>>>
if (oldValue is ILayoutGroup oldGroup) oldGroup.ChildrenCollectionChanged -= OnParentChildrenCollectionChanged;
RaisePropertyChanged(nameof(IsDirectlyHostedInFloatingWindow));
if (newValue is ILayoutGroup newGroup) newGroup.ChildrenCollectionChanged += OnParentChildrenCollectionChanged;
<<<<<<<
internal void UpdateIsDirectlyHostedInFloatingWindow() => RaisePropertyChanged(nameof(IsDirectlyHostedInFloatingWindow));
=======
/// <summary>
/// Updates whether this object is hosted at the root level of a floating window control or not.
/// </summary>
internal void UpdateIsDirectlyHostedInFloatingWindow()
{
RaisePropertyChanged(nameof(IsDirectlyHostedInFloatingWindow));
}
>>>>>>>
/// <summary>
/// Updates whether this object is hosted at the root level of a floating window control or not.
/// </summary>
internal void UpdateIsDirectlyHostedInFloatingWindow() => RaisePropertyChanged(nameof(IsDirectlyHostedInFloatingWindow));
<<<<<<<
private void OnParentChildrenCollectionChanged(object sender, EventArgs e) => RaisePropertyChanged(nameof(IsDirectlyHostedInFloatingWindow));
=======
private void OnParentChildrenCollectionChanged(object sender, EventArgs e)
{
RaisePropertyChanged(nameof(IsDirectlyHostedInFloatingWindow));
}
>>>>>>>
private void OnParentChildrenCollectionChanged(object sender, EventArgs e) => RaisePropertyChanged(nameof(IsDirectlyHostedInFloatingWindow));
<<<<<<<
#region ILayoutPaneSerializable Interface
string _id;
/// <inheritdoc />
string ILayoutPaneSerializable.Id
{
get => _id;
set => _id = value;
}
#endregion ILayoutPaneSerializable Interface
=======
>>>>>>> |
<<<<<<<
/// <inheritdoc />
=======
/// <summary>
/// Converts an inverted bool value into a <see cref="Visibility"/> value.
/// </summary>
>>>>>>>
/// <inheritdoc />
/// <summary>
/// Converts an inverted bool value into a <see cref="Visibility"/> value.
/// </summary>
<<<<<<<
/// <inheritdoc />
=======
/// <summary>Converts an inverted bool value into a <see cref="Visibility"/> value.</summary>
/// <param name="value">The value produced by the binding source.</param>
/// <param name="targetType">The type of the binding target property.</param>
/// <param name="parameter">The converter parameter to use.</param>
/// <param name="culture">The culture to use in the converter.</param>
/// <returns>A converted value. If the method returns null, the valid null value is used.</returns>
>>>>>>>
/// <inheritdoc />
/// <summary>Converts an inverted bool value into a <see cref="Visibility"/> value.</summary>
/// <param name="value">The value produced by the binding source.</param>
/// <param name="targetType">The type of the binding target property.</param>
/// <param name="parameter">The converter parameter to use.</param>
/// <param name="culture">The culture to use in the converter.</param>
/// <returns>A converted value. If the method returns null, the valid null value is used.</returns>
<<<<<<<
if (!(value is bool)) throw new ArgumentException("Invalid argument type. Expected argument: bool.", nameof(value));
if (targetType != typeof(Visibility)) throw new ArgumentException("Invalid return type. Expected type: Visibility", nameof(targetType));
var val = !(bool)value;
if (val) return Visibility.Visible;
return parameter is Visibility ? parameter : Visibility.Collapsed;
=======
if (value is bool && targetType == typeof(Visibility))
{
bool val = !(bool)value;
if (val)
return Visibility.Visible;
else
if (parameter != null && parameter is Visibility)
return parameter;
else
return Visibility.Collapsed;
}
throw new ArgumentException("Invalid argument/return type. Expected argument: bool and return type: Visibility");
>>>>>>>
if (!(value is bool)) throw new ArgumentException("Invalid argument type. Expected argument: bool.", nameof(value));
if (targetType != typeof(Visibility)) throw new ArgumentException("Invalid return type. Expected type: Visibility", nameof(targetType));
var val = !(bool)value;
if (val) return Visibility.Visible;
return parameter is Visibility ? parameter : Visibility.Collapsed;
<<<<<<<
/// <inheritdoc />
=======
/// <summary>Converts an inverted <see cref="Visibility"/> value into a bool value.</summary>
/// <param name="value">The value that is produced by the binding target.</param>
/// <param name="targetType">The type to convert to.</param>
/// <param name="parameter">The converter parameter to use.</param>
/// <param name="culture">The culture to use in the converter.</param>
/// <returns>A converted value. If the method returns null, the valid null value is used.</returns>
>>>>>>>
/// <inheritdoc />
/// <summary>Converts an inverted <see cref="Visibility"/> value into a bool value.</summary>
/// <param name="value">The value that is produced by the binding target.</param>
/// <param name="targetType">The type to convert to.</param>
/// <param name="parameter">The converter parameter to use.</param>
/// <param name="culture">The culture to use in the converter.</param>
/// <returns>A converted value. If the method returns null, the valid null value is used.</returns> |
<<<<<<<
public bool IsHidden => Parent is LayoutRoot;
=======
public bool IsHidden { get => (Parent is LayoutRoot); }
>>>>>>>
public bool IsHidden => Parent is LayoutRoot;
<<<<<<<
get => Parent != null && !(Parent is LayoutRoot);
set { if (value) Show(); else Hide(); }
=======
get => Parent != null && !(Parent is LayoutRoot);
set
{
if (value)
{
Show();
}
else
{
Hide();
}
}
>>>>>>>
get => Parent != null && !(Parent is LayoutRoot);
set { if (value) Show(); else Hide(); }
<<<<<<<
/// <summary>Hide this contents.</summary>
=======
/// <summary>Hide this contents</summary>
>>>>>>>
/// <summary>Hide this contents.</summary>
<<<<<<<
/// <summary>Show the content.</summary>
=======
/// <summary>Show the content</summary>
>>>>>>>
/// <summary>Show the content.</summary>
<<<<<<<
/// <summary>Add the anchorable to a <see cref="DockingManager"/> layout.</summary>
=======
/// <summary>Add the anchorable to a DockingManager layout using the given strategy as preference.</summary>
>>>>>>>
/// <summary>Add the anchorable to a <see cref="DockingManager"/> layout.</summary>
<<<<<<<
protected virtual void OnHiding(CancelEventArgs args) => Hiding?.Invoke(this, args);
=======
>>>>>>> |
<<<<<<<
foreach (var entity in _globalEntityViewsDB)
if (entity.Value.isQueryiableEntityView)
=======
foreach (var entity in _entityViewsDB)
if (entity.Value.isQueryiableEntityView == true)
>>>>>>>
foreach (var groups in _groupEntityViewsDB)
foreach (var entity in groups.Value)
if (entity.Value.isQueryiableEntityView == true)
<<<<<<<
//remove it from entity views group DB
var typeSafeList = @group[entityViewType];
if (typeSafeList.MappedRemove(id) == false) //clean up
@group.Remove(entityViewType);
=======
#if DEBUG && !PROFILE
if (entityViewsDB.ContainsKey(entityViewType) == false)
throw new Exception(NO_ENTITY_FOUND_EXCEPTION + " - EntityViewType: " +
entityViewType.Name + " - ID " + entityID);
#endif
var entityViews = entityViewsDB[entityViewType];
if (entityViews.MappedRemove(entityID) == false)
entityViewsDB.Remove(entityViewType);
if (entityViews.isQueryiableEntityView)
{
var typeSafeDictionary = entityViewsDBDic[entityViewType];
var entityView = typeSafeDictionary.GetIndexedEntityView(entityID);
if (typeSafeDictionary.Remove(entityID) == false)
entityViewsDBDic.Remove(entityViewType);
for (var current = entityViewType; current != _entityViewType; current = current.BaseType)
RemoveEntityViewFromEngines(_entityViewEngines, entityView, current);
}
>>>>>>>
//remove it from entity views group DB
var typeSafeList = @group[entityViewType];
if (typeSafeList.MappedRemove(id) == false) //clean up
@group.Remove(entityViewType);
<<<<<<<
static void RemoveEntityViewFromEngines(Dictionary<Type, FasterList<IHandleEntityViewEngine>> entityViewEngines,
IEntityData entityView,
Type entityViewType)
=======
static void RemoveEntityViewFromEngines(Dictionary<Type, FasterList<IHandleEntityViewEngineAbstracted>> entityViewEngines,
IEntityView entityView, Type entityViewType)
>>>>>>>
static void RemoveEntityViewFromEngines(Dictionary<Type, FasterList<IHandleEntityViewEngineAbstracted>> entityViewEngines,
IEntityData entityView, Type entityViewType)
<<<<<<<
//grouped set of entity views, this is the standard way to handle entity views
readonly Dictionary<int, Dictionary<Type, ITypeSafeList>> _groupEntityViewsDB;
//TODO: Use faster dictionary and merge these two?
//Global pool of entity views when engines want to manage entityViews regardless
//the group
readonly Dictionary<Type, ITypeSafeList> _globalEntityViewsDB;
//indexable entity views when the entity ID is known. Usually useful to handle
//event based logic.
readonly Dictionary<Type, ITypeSafeDictionary> _globalEntityViewsDBDic;
readonly Dictionary<long, IEntityViewBuilder[]> _entityInfos;
=======
readonly Dictionary<Type, ITypeSafeList> _entityViewsDB;
readonly Dictionary<Type, ITypeSafeDictionary> _entityViewsDBDic;
readonly Dictionary<int, Dictionary<Type, ITypeSafeList>> _groupEntityViewsDB;
readonly Dictionary<Type, ITypeSafeList> _metaEntityViewsDB;
const string NO_ENTITY_FOUND_EXCEPTION =
"<color=orange>Svelto.ECS</color> Trying to remove an Entity never added, please be sure the " +
"Entity is submitted before trying to remove it";
readonly Dictionary<Type, ITypeSafeDictionary> _metaEntityViewsDBDic;
>>>>>>>
//grouped set of entity views, this is the standard way to handle entity views
readonly Dictionary<int, Dictionary<Type, ITypeSafeList>> _groupEntityViewsDB;
//TODO: Use faster dictionary and merge these two?
//indexable entity views when the entity ID is known. Usually useful to handle
//event based logic.
readonly Dictionary<Type, ITypeSafeDictionary> _globalEntityViewsDBDic;
readonly Dictionary<long, IEntityViewBuilder[]> _entityInfos; |
<<<<<<<
I18n.__("bookmark.overwrite.confirm", saveId),
=======
string.Format(saveBookmarkComfirmText, SaveIdToDisplayId(saveId)),
>>>>>>>
I18n.__("bookmark.overwrite.confirm", SaveIdToDisplayId(saveId)),
<<<<<<<
I18n.__("bookmark.load.confirm", saveId),
=======
string.Format(loadBookmarkComfirmText, SaveIdToDisplayId(saveId)),
>>>>>>>
I18n.__("bookmark.load.confirm", SaveIdToDisplayId(saveId)),
<<<<<<<
I18n.__("bookmark.delete.confirm", saveId),
=======
string.Format(deleteBookmarkComfirmText, SaveIdToDisplayId(saveId)),
>>>>>>>
I18n.__("bookmark.delete.confirm", SaveIdToDisplayId(saveId)),
<<<<<<<
ShowPreview(GetThumbnailSprite(saveId), I18n.__(
"bookmark.summary",
usedSaveSlots[saveId].ModifiedTime.ToString(dateTimeFormat),
=======
ShowPreview(GetThumbnailSprite(saveId), string.Format(
previewTextFormat,
checkpointManager.SaveSlotsMetadata[saveId].ModifiedTime.ToString(dateTimeFormat),
>>>>>>>
ShowPreview(GetThumbnailSprite(saveId), I18n.__(
"bookmark.summary",
checkpointManager.SaveSlotsMetadata[saveId].ModifiedTime.ToString(dateTimeFormat), |
<<<<<<<
private Dictionary<int, BookmarkMetadata> usedSaveSlots;
=======
private HashSet<int> usedSaveSlots;
private readonly Dictionary<int, Sprite> _cachedThumbnailSprite = new Dictionary<int, Sprite>();
>>>>>>>
private Dictionary<int, BookmarkMetadata> usedSaveSlots;
private readonly Dictionary<int, Sprite> _cachedThumbnailSprite = new Dictionary<int, Sprite>(); |
<<<<<<<
using NUnit.Framework;
=======
>>>>>>>
<<<<<<<
[TestFixture]
=======
>>>>>>>
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[ExpectedException(typeof(InternalErrorException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact] |
<<<<<<<
=======
using Microsoft.Build.Framework;
using Microsoft.Build.Tasks;
using Microsoft.Build.Utilities;
using Microsoft.Build.Shared;
>>>>>>>
using Microsoft.Build.Framework;
using Microsoft.Build.Tasks;
using Microsoft.Build.Utilities;
using Microsoft.Build.Shared;
<<<<<<<
[TestFixture]
=======
>>>>>>>
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[ExpectedException(typeof(ArgumentNullException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[ExpectedException(typeof(ArgumentNullException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
string targetCommandLine = "/assembly:\"" + sgen.BuildAssemblyPath + Path.DirectorySeparatorChar
+ "MyAsm, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null\"";
Assert.IsTrue(String.Equals(commandLine, targetCommandLine, StringComparison.OrdinalIgnoreCase));
=======
Assert.True(String.Equals(commandLine, "/assembly:\"C:\\SomeFolder\\MyAsm.dll\\MyAsm, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null\"", StringComparison.OrdinalIgnoreCase));
>>>>>>>
string targetCommandLine = "/assembly:\"" + sgen.BuildAssemblyPath + Path.DirectorySeparatorChar
+ "MyAsm, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null\"";
Assert.True(String.Equals(commandLine, targetCommandLine, StringComparison.OrdinalIgnoreCase)); |
<<<<<<<
using NUnit.Framework;
=======
>>>>>>>
<<<<<<<
[TestFixture]
=======
>>>>>>>
<<<<<<<
[SetUp]
public void SetUp()
=======
///
public TaskHost_Tests()
>>>>>>>
public TaskHost_Tests()
<<<<<<<
/// Clean up after each tests is run
/// </summary>
[TearDown]
public void TearDown()
{
_customLogger = null;
_mockHost = null;
_elementLocation = null;
_taskHost = null;
}
/// <summary>
=======
>>>>>>>
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[ExpectedException(typeof(ArgumentNullException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[ExpectedException(typeof(ArgumentNullException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[ExpectedException(typeof(ArgumentNullException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[ExpectedException(typeof(ArgumentNullException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact] |
<<<<<<<
=======
using System.Configuration;
using Microsoft.Win32;
using Microsoft.Build.Evaluation;
>>>>>>>
<<<<<<<
using Microsoft.Win32;
using NUnit.Framework;
using InvalidToolsetDefinitionException = Microsoft.Build.Exceptions.InvalidToolsetDefinitionException;
=======
using Xunit;
>>>>>>>
using Microsoft.Win32;
using Xunit;
using InvalidToolsetDefinitionException = Microsoft.Build.Exceptions.InvalidToolsetDefinitionException;
<<<<<<<
[TestFixture]
public class ToolsetRegistryReader_Tests
=======
public class ToolsetRegistryReader_Tests : IDisposable
>>>>>>>
public class ToolsetRegistryReader_Tests : IDisposable
<<<<<<<
[SetUp]
public void Setup()
=======
public ToolsetRegistryReader_Tests()
>>>>>>>
public ToolsetRegistryReader_Tests()
<<<<<<<
[TearDown]
public void TearDown()
=======
public void Dispose()
>>>>>>>
public void Dispose()
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[Ignore]
=======
[Fact(Skip = "Ignored in MSTest")]
>>>>>>>
[Fact(Skip = "Ignored in MSTest")]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
Assert.AreEqual(null, defaultToolsVersion);
Assert.AreEqual(1, values.Count);
Assert.AreEqual(0, values["tv1"].Properties.Count);
Assert.IsTrue(0 == String.Compare(xdir, values["tv1"].ToolsPath, StringComparison.OrdinalIgnoreCase));
=======
Assert.Equal(null, defaultToolsVersion);
Assert.Equal(1, values.Count);
Assert.Equal(0, values["tv1"].Properties.Count);
Assert.Equal(0, String.Compare("c:\\xxx", values["tv1"].ToolsPath, StringComparison.OrdinalIgnoreCase));
>>>>>>>
Assert.Equal(null, defaultToolsVersion);
Assert.Equal(1, values.Count);
Assert.Equal(0, values["tv1"].Properties.Count);
Assert.Equal(0, String.Compare(xdir, values["tv1"].ToolsPath, StringComparison.OrdinalIgnoreCase));
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
Assert.AreEqual(2, values.Count);
Assert.AreEqual(1, values["tv1"].Properties.Count);
Assert.IsTrue(0 == String.Compare(xdir, values["tv1"].ToolsPath, StringComparison.OrdinalIgnoreCase));
Assert.IsTrue(0 == String.Compare("value1", values["tv1"].Properties["name1"].EvaluatedValue, StringComparison.OrdinalIgnoreCase));
Assert.AreEqual(1, values["tv2"].Properties.Count);
Assert.IsTrue(0 == String.Compare(ydir, values["tv2"].ToolsPath, StringComparison.OrdinalIgnoreCase));
Assert.IsTrue(0 == String.Compare("value2", values["tv2"].Properties["name2"].EvaluatedValue, StringComparison.OrdinalIgnoreCase));
=======
Assert.Equal(2, values.Count);
Assert.Equal(1, values["tv1"].Properties.Count);
Assert.Equal(0, String.Compare("c:\\xxx", values["tv1"].ToolsPath, StringComparison.OrdinalIgnoreCase));
Assert.Equal(0, String.Compare("value1", values["tv1"].Properties["name1"].EvaluatedValue, StringComparison.OrdinalIgnoreCase));
Assert.Equal(1, values["tv2"].Properties.Count);
Assert.Equal(0, String.Compare("c:\\yyy", values["tv2"].ToolsPath, StringComparison.OrdinalIgnoreCase));
Assert.Equal(0, String.Compare("value2", values["tv2"].Properties["name2"].EvaluatedValue, StringComparison.OrdinalIgnoreCase));
>>>>>>>
Assert.Equal(2, values.Count);
Assert.Equal(1, values["tv1"].Properties.Count);
Assert.True(0 == String.Compare(xdir, values["tv1"].ToolsPath, StringComparison.OrdinalIgnoreCase));
Assert.True(0 == String.Compare("value1", values["tv1"].Properties["name1"].EvaluatedValue, StringComparison.OrdinalIgnoreCase));
Assert.Equal(1, values["tv2"].Properties.Count);
Assert.True(0 == String.Compare(ydir, values["tv2"].ToolsPath, StringComparison.OrdinalIgnoreCase));
Assert.True(0 == String.Compare("value2", values["tv2"].Properties["name2"].EvaluatedValue, StringComparison.OrdinalIgnoreCase));
<<<<<<<
[Test]
[ExpectedException(typeof(InvalidToolsetDefinitionException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
Assert.AreEqual(2, values.Count);
Assert.AreEqual(1, values["tv1"].Properties.Count);
Assert.AreEqual(xdir, values["tv1"].ToolsPath);
Assert.AreEqual("value1", values["tv1"].Properties["name1"].EvaluatedValue);
Assert.AreEqual(1, values["tv1"].SubToolsets.Count);
Assert.AreEqual(2, values["tv1"].SubToolsets["SubKey1"].Properties.Count);
Assert.AreEqual("value1a", values["tv1"].SubToolsets["SubKey1"].Properties["name1a"].EvaluatedValue);
Assert.AreEqual("value2a", values["tv1"].SubToolsets["SubKey1"].Properties["name2a"].EvaluatedValue);
Assert.AreEqual(1, values["tv2"].Properties.Count);
Assert.AreEqual(ydir, values["tv2"].ToolsPath);
Assert.AreEqual("value2", values["tv2"].Properties["name2"].EvaluatedValue);
Assert.AreEqual(2, values["tv2"].SubToolsets.Count);
Assert.AreEqual(2, values["tv2"].SubToolsets["SubKey2"].Properties.Count);
Assert.AreEqual("value3a", values["tv2"].SubToolsets["SubKey2"].Properties["name3a"].EvaluatedValue);
Assert.AreEqual("value2a", values["tv2"].SubToolsets["SubKey2"].Properties["name2a"].EvaluatedValue);
Assert.AreEqual(2, values["tv2"].SubToolsets["SubKey3"].Properties.Count);
Assert.AreEqual("value4a", values["tv2"].SubToolsets["SubKey3"].Properties["name4a"].EvaluatedValue);
Assert.AreEqual("value5a", values["tv2"].SubToolsets["SubKey3"].Properties["name5a"].EvaluatedValue);
=======
Assert.Equal(2, values.Count);
Assert.Equal(1, values["tv1"].Properties.Count);
Assert.Equal("c:\\xxx", values["tv1"].ToolsPath);
Assert.Equal("value1", values["tv1"].Properties["name1"].EvaluatedValue);
Assert.Equal(1, values["tv1"].SubToolsets.Count);
Assert.Equal(2, values["tv1"].SubToolsets["SubKey1"].Properties.Count);
Assert.Equal("value1a", values["tv1"].SubToolsets["SubKey1"].Properties["name1a"].EvaluatedValue);
Assert.Equal("value2a", values["tv1"].SubToolsets["SubKey1"].Properties["name2a"].EvaluatedValue);
Assert.Equal(1, values["tv2"].Properties.Count);
Assert.Equal("c:\\yyy", values["tv2"].ToolsPath);
Assert.Equal("value2", values["tv2"].Properties["name2"].EvaluatedValue);
Assert.Equal(2, values["tv2"].SubToolsets.Count);
Assert.Equal(2, values["tv2"].SubToolsets["SubKey2"].Properties.Count);
Assert.Equal("value3a", values["tv2"].SubToolsets["SubKey2"].Properties["name3a"].EvaluatedValue);
Assert.Equal("value2a", values["tv2"].SubToolsets["SubKey2"].Properties["name2a"].EvaluatedValue);
Assert.Equal(2, values["tv2"].SubToolsets["SubKey3"].Properties.Count);
Assert.Equal("value4a", values["tv2"].SubToolsets["SubKey3"].Properties["name4a"].EvaluatedValue);
Assert.Equal("value5a", values["tv2"].SubToolsets["SubKey3"].Properties["name5a"].EvaluatedValue);
>>>>>>>
Assert.Equal(2, values.Count);
Assert.Equal(1, values["tv1"].Properties.Count);
Assert.Equal(xdir, values["tv1"].ToolsPath);
Assert.Equal("value1", values["tv1"].Properties["name1"].EvaluatedValue);
Assert.Equal(1, values["tv1"].SubToolsets.Count);
Assert.Equal(2, values["tv1"].SubToolsets["SubKey1"].Properties.Count);
Assert.Equal("value1a", values["tv1"].SubToolsets["SubKey1"].Properties["name1a"].EvaluatedValue);
Assert.Equal("value2a", values["tv1"].SubToolsets["SubKey1"].Properties["name2a"].EvaluatedValue);
Assert.Equal(1, values["tv2"].Properties.Count);
Assert.Equal(ydir, values["tv2"].ToolsPath);
Assert.Equal("value2", values["tv2"].Properties["name2"].EvaluatedValue);
Assert.Equal(2, values["tv2"].SubToolsets.Count);
Assert.Equal(2, values["tv2"].SubToolsets["SubKey2"].Properties.Count);
Assert.Equal("value3a", values["tv2"].SubToolsets["SubKey2"].Properties["name3a"].EvaluatedValue);
Assert.Equal("value2a", values["tv2"].SubToolsets["SubKey2"].Properties["name2a"].EvaluatedValue);
Assert.Equal(2, values["tv2"].SubToolsets["SubKey3"].Properties.Count);
Assert.Equal("value4a", values["tv2"].SubToolsets["SubKey3"].Properties["name4a"].EvaluatedValue);
Assert.Equal("value5a", values["tv2"].SubToolsets["SubKey3"].Properties["name5a"].EvaluatedValue);
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
Assert.AreEqual(1, values.Count);
Assert.AreEqual(2, values["tv1"].Properties.Count);
Assert.AreEqual(xdir, values["tv1"].ToolsPath);
Assert.AreEqual("value1", values["tv1"].Properties["name1"].EvaluatedValue);
Assert.AreEqual("value2", values["tv1"].Properties["name2"].EvaluatedValue);
Assert.AreEqual(1, values["tv1"].SubToolsets.Count);
Assert.AreEqual(2, values["tv1"].SubToolsets["Foo"].Properties.Count);
Assert.AreEqual("value1a", values["tv1"].SubToolsets["Foo"].Properties["name1"].EvaluatedValue);
Assert.AreEqual("", values["tv1"].SubToolsets["Foo"].Properties["name2"].EvaluatedValue);
=======
Assert.Equal(1, values.Count);
Assert.Equal(2, values["tv1"].Properties.Count);
Assert.Equal("c:\\xxx", values["tv1"].ToolsPath);
Assert.Equal("value1", values["tv1"].Properties["name1"].EvaluatedValue);
Assert.Equal("value2", values["tv1"].Properties["name2"].EvaluatedValue);
Assert.Equal(1, values["tv1"].SubToolsets.Count);
Assert.Equal(2, values["tv1"].SubToolsets["Foo"].Properties.Count);
Assert.Equal("value1a", values["tv1"].SubToolsets["Foo"].Properties["name1"].EvaluatedValue);
Assert.Equal("", values["tv1"].SubToolsets["Foo"].Properties["name2"].EvaluatedValue);
>>>>>>>
Assert.Equal(1, values.Count);
Assert.Equal(2, values["tv1"].Properties.Count);
Assert.Equal(xdir, values["tv1"].ToolsPath);
Assert.Equal("value1", values["tv1"].Properties["name1"].EvaluatedValue);
Assert.Equal("value2", values["tv1"].Properties["name2"].EvaluatedValue);
Assert.Equal(1, values["tv1"].SubToolsets.Count);
Assert.Equal(2, values["tv1"].SubToolsets["Foo"].Properties.Count);
Assert.Equal("value1a", values["tv1"].SubToolsets["Foo"].Properties["name1"].EvaluatedValue);
Assert.Equal("", values["tv1"].SubToolsets["Foo"].Properties["name2"].EvaluatedValue);
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
Assert.AreEqual(1, values.Count);
Assert.AreEqual(2, values["tv1"].Properties.Count);
Assert.AreEqual(xdir, values["tv1"].ToolsPath);
Assert.AreEqual("value1", values["tv1"].Properties["name1"].EvaluatedValue);
Assert.AreEqual("value2", values["tv1"].Properties["name2"].EvaluatedValue);
=======
Assert.Equal(1, values.Count);
Assert.Equal(2, values["tv1"].Properties.Count);
Assert.Equal("c:\\xxx", values["tv1"].ToolsPath);
Assert.Equal("value1", values["tv1"].Properties["name1"].EvaluatedValue);
Assert.Equal("value2", values["tv1"].Properties["name2"].EvaluatedValue);
>>>>>>>
Assert.Equal(1, values.Count);
Assert.Equal(2, values["tv1"].Properties.Count);
Assert.Equal(xdir, values["tv1"].ToolsPath);
Assert.Equal("value1", values["tv1"].Properties["name1"].EvaluatedValue);
Assert.Equal("value2", values["tv1"].Properties["name2"].EvaluatedValue);
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[ExpectedException(typeof(InvalidToolsetDefinitionException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[ExpectedException(typeof(InvalidToolsetDefinitionException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
if (NativeMethodsShared.IsUnixLike)
{
Assert.Ignore("Registry is not supported under Unix");
}
_currentVersionRegistryKey.SetValue("MsBuildOverrideTasksPath", new String[] { "2938304894", "3948394.2.3.3.3" }, RegistryValueKind.MultiString);
=======
Assert.Throws<InvalidToolsetDefinitionException>(() =>
{
_currentVersionRegistryKey.SetValue("MsBuildOverrideTasksPath", new String[] { "2938304894", "3948394.2.3.3.3" }, RegistryValueKind.MultiString);
>>>>>>>
Assert.Throws<InvalidToolsetDefinitionException>(() =>
{
_currentVersionRegistryKey.SetValue("MsBuildOverrideTasksPath", new String[] { "2938304894", "3948394.2.3.3.3" }, RegistryValueKind.MultiString);
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[ExpectedException(typeof(InvalidToolsetDefinitionException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact] |
<<<<<<<
=======
using System.Text.RegularExpressions;
using System.Threading;
using Microsoft.Build.Framework;
>>>>>>>
using System.Text.RegularExpressions;
using System.Threading;
using Microsoft.Build.Framework;
<<<<<<<
using NUnit.Framework;
=======
using Microsoft.Build.Evaluation;
using Xunit;
>>>>>>>
using Microsoft.Build.Evaluation;
using Xunit;
<<<<<<<
[TestFixture]
=======
>>>>>>>
<<<<<<<
[SetUp]
public void SetUp()
{
}
[TearDown]
public void TearDown()
{
}
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[ExpectedException(typeof(ArgumentNullException))]
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[ExpectedException(typeof(ArgumentNullException))]
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact] |
<<<<<<<
using NUnit.Framework;
=======
using Xunit;
>>>>>>>
using Xunit;
<<<<<<<
[TestFixture]
=======
>>>>>>>
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact] |
<<<<<<<
=======
using System;
>>>>>>>
using System;
<<<<<<<
[TestFixture]
=======
>>>>>>>
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact] |
<<<<<<<
using System.Collections.Generic;
using System.IO;
=======
using System.Collections.Specialized;
using System.Text.RegularExpressions;
using Microsoft.Build.Framework;
>>>>>>>
using System.Collections.Specialized;
using System.Text.RegularExpressions;
using Microsoft.Build.Framework;
<<<<<<<
=======
using MSBuildApp = Microsoft.Build.CommandLine.MSBuildApp;
using Xunit;
>>>>>>>
using Xunit;
using System.Collections.Generic;
using System.IO;
<<<<<<<
[TestFixture]
=======
>>>>>>>
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[TestFixture]
=======
>>>>>>>
<<<<<<<
[Test]
[Ignore]
=======
[Fact(Skip = "Ignored in MSTest")]
>>>>>>>
[Fact(Skip = "Ignored in MSTest")]
<<<<<<<
Assert.AreEqual(MSBuildApp.ExitType.Success, MSBuildApp.Execute(@"c:\bin\msbuild.exe """ + input +
(NativeMethodsShared.IsUnixLike ? @""" -pp:""" : @""" /pp:""") + output + @""""));
=======
Assert.Equal(MSBuildApp.ExitType.Success, MSBuildApp.Execute(@"c:\bin\msbuild.exe """ + input + @""" /pp:""" + output + @""""));
>>>>>>>
Assert.Equal(MSBuildApp.ExitType.Success, MSBuildApp.Execute(@"c:\bin\msbuild.exe """ + input +
(NativeMethodsShared.IsUnixLike ? @""" -pp:""" : @""" /pp:""") + output + @""""));
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[TestFixture]
=======
>>>>>>>
<<<<<<<
[Test]
[ExpectedException(typeof(InvalidProjectFileException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[ExpectedException(typeof(InvalidProjectFileException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact] |
<<<<<<<
=======
using Microsoft.Build.UnitTests;
>>>>>>>
using Microsoft.Build.UnitTests;
<<<<<<<
[TestFixture]
public class SimpleScenarios
=======
public class SimpleScenarios : IDisposable
>>>>>>>
public class SimpleScenarios : IDisposable
<<<<<<<
[TearDown]
public void UnloadGlobalProjectCollection()
=======
public void Dispose()
>>>>>>>
public void Dispose()
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
//[Ignore("FEATURE: TASKHOST")]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
//[Ignore("FEATURE: TASKHOST")]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[TestFixture]
=======
>>>>>>>
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact(Skip = "Ignored in MSTest")]
// This is a known issue in Roslyn. This test should be enabled if Roslyn is updated for this scenario.
>>>>>>>
[Fact(Skip = "Ignored in MSTest")]
// This is a known issue in Roslyn. This test should be enabled if Roslyn is updated for this scenario.
<<<<<<<
[Test]
=======
[Fact(Skip = "Ignored in MSTest")]
// This is a known issue in Roslyn. This test should be enabled if Roslyn is updated for this scenario.
>>>>>>>
[Fact(Skip = "Ignored in MSTest")]
// This is a known issue in Roslyn. This test should be enabled if Roslyn is updated for this scenario. |
<<<<<<<
internal class CopyOnWriteDictionary<K, V> : IDictionary<K, V>, IDictionary, ISerializable where V : class
=======
internal class CopyOnWriteDictionary<K, V> : IDictionary<K, V>, IDictionary
>>>>>>>
internal class CopyOnWriteDictionary<K, V> : IDictionary<K, V>, IDictionary, ISerializable
<<<<<<<
public void GetObjectData(SerializationInfo info, StreamingContext context)
=======
/// <summary>
/// A dictionary which is reference counted to allow several references for read operations, but knows when to clone for
/// write operations.
/// </summary>
/// <typeparam name="K1">The key type.</typeparam>
/// <typeparam name="V1">The value type.</typeparam>
[Serializable]
private class CopyOnWriteBackingDictionary<K1, V1> : Dictionary<K1, V1>
>>>>>>>
public void GetObjectData(SerializationInfo info, StreamingContext context) |
<<<<<<<
using Microsoft.Build.Shared;
using NUnit.Framework;
=======
using Xunit;
>>>>>>>
using Microsoft.Build.Shared;
using Xunit;
<<<<<<<
[TestFixture]
=======
>>>>>>>
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[ExpectedException(typeof(InvalidOperationException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[Category("serialize")]
=======
[Fact]
[Trait("Category", "serialize")]
>>>>>>>
[Fact]
[Trait("Category", "serialize")]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[Category("serialize")]
=======
[Fact]
[Trait("Category", "serialize")]
>>>>>>>
[Fact]
[Trait("Category", "serialize")]
<<<<<<<
[Test]
[ExpectedException(typeof(InvalidProjectFileException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[ExpectedException(typeof(InvalidProjectFileException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[ExpectedException(typeof(InvalidProjectFileException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[ExpectedException(typeof(InvalidProjectFileException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[ExpectedException(typeof(InvalidProjectFileException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[ExpectedException(typeof(InvalidProjectFileException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[ExpectedException(typeof(InvalidProjectFileException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[ExpectedException(typeof(InvalidProjectFileException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact] |
<<<<<<<
=======
/// <summary>
/// If a config value is an empty string we return null, this is to keep
/// backward compatibility with old code
/// </summary>
public static string GetConfigValue(string value)
{
return string.IsNullOrEmpty(value) ? null : value.Trim();
}
>>>>>>> |
<<<<<<<
using NUnit.Framework;
=======
>>>>>>>
<<<<<<<
[TestFixture]
=======
>>>>>>>
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[Ignore("Reals aren't supported yet.")]
=======
[Fact(Skip = "Ignored in MSTest")]
>>>>>>>
[Fact(Skip = "Ignored in MSTest")]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[Ignore("Escape sequences aren't supported")]
=======
[Fact(Skip = "Ignored in MSTest")]
>>>>>>>
[Fact(Skip = "Ignored in MSTest")]
<<<<<<<
[Test]
[Ignore("Escape sequences aren't supported")]
=======
[Fact(Skip = "Ignored in MSTest")]
>>>>>>>
[Fact(Skip = "Ignored in MSTest")]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact] |
<<<<<<<
using NUnit.Framework;
=======
>>>>>>>
<<<<<<<
[TestFixture]
=======
>>>>>>>
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[ExpectedException(typeof(KeyNotFoundException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
[ExpectedException(typeof(KeyNotFoundException))]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact]
<<<<<<<
[Test]
=======
[Fact]
>>>>>>>
[Fact] |
<<<<<<<
#if FEATURE_SECURITY_PERMISSIONS
=======
using System.Resources;
>>>>>>>
using System.Resources;
#if FEATURE_SECURITY_PERMISSIONS |
Subsets and Splits