Skip to content
Permalink
Browse files

housekeeping: Release 10.0 (#2102)

  • Loading branch information...
glennawatson committed Sep 4, 2019
1 parent 5359fd8 commit f396c32159999686831c2801d4b7c4a538fd54a3
Showing with 2,802 additions and 5,236 deletions.
  1. +2 −2 .github/CODEOWNERS
  2. +2 −2 CONTRIBUTING.md
  3. +0 −1 README.md
  4. +1 −1 integrationtests/Directory.Build.props
  5. +3 −3 integrationtests/IntegrationTests.Shared.Tests/IntegrationTests.Shared.Tests.csproj
  6. +1 −0 integrationtests/IntegrationTests.Shared/IntegrationTests.Shared.csproj
  7. +2 −2 integrationtests/IntegrationTests.UWP/IntegrationTests.UWP.csproj
  8. +2 −2 integrationtests/IntegrationTests.WPF/IntegrationTests.WPF.csproj
  9. +2 −2 integrationtests/IntegrationTests.XamarinForms.UWP/IntegrationTests.XamarinForms.UWP.csproj
  10. +1 −1 src/Directory.build.props
  11. +1 −1 src/Directory.build.targets
  12. +9 −9 src/ReactiveUI.AndroidSupport/ReactiveAppCompatActivity.cs
  13. +9 −9 src/ReactiveUI.AndroidSupport/ReactiveFragmentActivity.cs
  14. +2 −2 src/ReactiveUI.AndroidSupport/ReactiveRecyclerViewViewHolder.cs
  15. +10 −6 ...tiveUI/EventManagers/CollectionChangingEventManager.cs → ReactiveUI.Blazor/PlatformOperations.cs}
  16. +27 −0 src/ReactiveUI.Blazor/Properties/launchSettings.json
  17. +130 −0 src/ReactiveUI.Blazor/ReactiveComponentBase.cs
  18. +124 −0 src/ReactiveUI.Blazor/ReactiveLayoutComponentBase.cs
  19. +16 −0 src/ReactiveUI.Blazor/ReactiveUI.Blazor.csproj
  20. +44 −0 src/ReactiveUI.Blazor/Registrations.cs
  21. 0 src/ReactiveUI.Blend/Platforms/{net461 → net4}/ObservableTrigger.cs
  22. +1 −1 src/ReactiveUI.Blend/ReactiveUI.Blend.csproj
  23. +20 −2 src/ReactiveUI.Events.WPF/ReactiveUI.Events.WPF.csproj
  24. +22 −4 src/ReactiveUI.Events.Winforms/ReactiveUI.Events.Winforms.csproj
  25. +1 −0 src/ReactiveUI.Events/ReactiveUI.Events.csproj
  26. +1 −0 src/ReactiveUI.Fody.Tests/FodyWeavers.xsd
  27. +1 −1 src/ReactiveUI.Testing/ReactiveUI.Testing.csproj
  28. +14 −164 src/ReactiveUI.Tests/API/ApiApprovalTests.ReactiveUI.approved.txt
  29. +69 −200 src/ReactiveUI.Tests/API/ApiApprovalTests.ReactiveUI.net461.approved.txt
  30. +69 −200 src/ReactiveUI.Tests/API/ApiApprovalTests.ReactiveUI.netcoreapp2.0.approved.txt
  31. +837 −0 src/ReactiveUI.Tests/API/ApiApprovalTests.ReactiveUI.netcoreapp3.0.approved.txt
  32. +43 −0 src/ReactiveUI.Tests/API/ApiApprovalTests.Testing.netcoreapp3.0.approved.txt
  33. +1 −1 src/ReactiveUI.Tests/Activation/ActivatingViewFetcher.cs
  34. +1 −1 src/ReactiveUI.Tests/Activation/ActivatingViewModel.cs
  35. +0 −7 src/ReactiveUI.Tests/Platforms/uwp/App.xaml
  36. +0 −41 src/ReactiveUI.Tests/Platforms/uwp/App.xaml.cs
  37. +0 −97 src/ReactiveUI.Tests/Platforms/windows-xaml/Legacy/ControlsReactiveCollectionTest.cs
  38. +0 −55 src/ReactiveUI.Tests/Platforms/windows-xaml/Legacy/Mocks/LegacyPropertyBindView.cs
  39. +0 −87 src/ReactiveUI.Tests/Platforms/windows-xaml/Legacy/Mocks/LegacyPropertyBindViewModel.cs
  40. +6 −48 src/ReactiveUI.Tests/Platforms/winforms/API/ApiApprovalTests.Winforms.net461.approved.txt
  41. +109 −0 src/ReactiveUI.Tests/Platforms/winforms/API/ApiApprovalTests.Winforms.netcoreapp3.0.approved.txt
  42. +2 −2 src/ReactiveUI.Tests/Platforms/winforms/CommandBindingTests.cs
  43. +1 −1 src/ReactiveUI.Tests/Platforms/winforms/Mocks/TestControl.cs
  44. +1 −1 src/ReactiveUI.Tests/Platforms/winforms/Mocks/TestForm.cs
  45. +0 −221 src/ReactiveUI.Tests/Platforms/winforms/ReactiveBindingListTests.cs
  46. +6 −6 src/ReactiveUI.Tests/Platforms/wpf/API/ApiApprovalTests.Wpf.net461.approved.txt
  47. +132 −0 src/ReactiveUI.Tests/Platforms/wpf/API/ApiApprovalTests.Wpf.netcoreapp3.0.approved.txt
  48. +1 −1 src/ReactiveUI.Tests/Platforms/wpf/Mocks/WpfTestUserControl.cs
  49. +1 −1 src/ReactiveUI.Tests/Platforms/wpf/WpfCommandBindingImplementationTests.cs
  50. +44 −39 src/ReactiveUI.Tests/ReactiveUI.Tests.csproj
  51. +1 −1 src/ReactiveUI.Tests/Utilities/ApiApprovalBase.cs
  52. +5 −5 src/ReactiveUI.Tests/Utilities/CountingTestScheduler.cs
  53. +6 −6 src/ReactiveUI.Tests/Utilities/TestLogger.cs
  54. +291 −270 src/ReactiveUI.Tests/WhenAny/ReactiveNotifyPropertyChangedMixinTest.cs
  55. +1 −1 src/ReactiveUI.Uno/ActivationForViewFetcher.cs
  56. +1 −1 src/ReactiveUI.Uno/{PlatformRegistrations.cs → Registrations.cs}
  57. +0 −79 src/ReactiveUI.Uno/WinRTAppDataDriver.cs
  58. +35 −5 src/ReactiveUI.Winforms/ActivationForViewFetcher.cs
  59. +13 −7 src/ReactiveUI.Winforms/CreatesWinformsCommandBinding.cs
  60. +1 −0 src/ReactiveUI.Winforms/EventShims/PropertyChangingEventManager.cs
  61. +0 −28 src/ReactiveUI.Winforms/IReactiveDerivedBindingList.cs
  62. +0 −176 src/ReactiveUI.Winforms/ObservableCollectionMixin.cs
  63. +0 −131 src/ReactiveUI.Winforms/ReactiveBindingList.cs
  64. +0 −94 src/ReactiveUI.Winforms/ReactiveDerivedBindingList.cs
  65. +14 −2 src/ReactiveUI.Winforms/ReactiveUI.Winforms.csproj
  66. +3 −0 src/ReactiveUI.Winforms/Registrations.cs
  67. +5 −5 src/ReactiveUI.Winforms/WinformsCreatesObservableForProperty.cs
  68. +22 −10 src/ReactiveUI.Wpf/ActivationForViewFetcher.cs
  69. +33 −11 src/ReactiveUI.Wpf/AutoSuspendHelper.cs
  70. +13 −1 src/ReactiveUI.Wpf/ReactiveUI.Wpf.csproj
  71. +3 −0 src/ReactiveUI.Wpf/Registrations.cs
  72. +47 −9 src/ReactiveUI.XamForms/ActivationForViewFetcher.cs
  73. +10 −3 src/ReactiveUI.XamForms/RoutedViewHost.cs
  74. +62 −1 src/ReactiveUI.sln
  75. +2 −2 src/ReactiveUI/Activation/CanActivateViewFetcher.cs
  76. +1 −1 src/ReactiveUI/Activation/IActivationForViewFetcher.cs
  77. +12 −12 src/ReactiveUI/Activation/ViewForMixins.cs
  78. +6 −6 src/ReactiveUI/Bindings/Command/CreatesCommandBinding.cs
  79. +8 −8 src/ReactiveUI/Bindings/Command/CreatesCommandBindingViaEvent.cs
  80. +2 −2 src/ReactiveUI/Bindings/Property/IPropertyBinderImplementation.cs
  81. +10 −10 src/ReactiveUI/Bindings/Property/PropertyBinderImplementation.cs
  82. +4 −4 src/ReactiveUI/Bindings/Property/PropertyBindingMixins.cs
  83. +0 −22 src/ReactiveUI/EventHandlers/INotifyPropertyChanging.cs
  84. +0 −30 src/ReactiveUI/EventHandlers/PropertyChangingEventArgs.cs
  85. +0 −15 src/ReactiveUI/EventHandlers/PropertyChangingEventHandler.cs
  86. +0 −15 src/ReactiveUI/EventManagers/CollectionChangedEventManager.cs
  87. +2 −0 src/ReactiveUI/EventManagers/PropertyChangingEventManager.cs
  88. +14 −4 src/ReactiveUI/Expression/Reflection.cs
  89. +1 −1 src/ReactiveUI/Interfaces/{IActivatable.cs → IActivatableView.cs}
  90. +1 −1 src/ReactiveUI/Interfaces/{ISupportsActivation.cs → IActivatableViewModel.cs}
  91. +1 −1 src/ReactiveUI/Interfaces/IViewFor.cs
  92. +2 −0 src/ReactiveUI/Interfaces/ReactivePropertyChangingEventArgs.cs
  93. +0 −33 src/ReactiveUI/Legacy/IMoveInfo.cs
  94. +0 −22 src/ReactiveUI/Legacy/INotifyCollectionChanging.cs
  95. +0 −30 src/ReactiveUI/Legacy/IReactiveCollection.cs
  96. +0 −20 src/ReactiveUI/Legacy/IReactiveDerivedList.cs
  97. +0 −75 src/ReactiveUI/Legacy/IReactiveList.cs
  98. +0 −105 src/ReactiveUI/Legacy/IReactiveNotifyCollectionChanged.cs
  99. +0 −37 src/ReactiveUI/Legacy/IReactiveNotifyCollectionItemChanged.cs
  100. +0 −25 src/ReactiveUI/Legacy/IReadOnlyReactiveCollection.cs
  101. +0 −29 src/ReactiveUI/Legacy/IReadOnlyReactiveList.cs
  102. +0 −29 src/ReactiveUI/Legacy/MoveInfo.cs
  103. +0 −230 src/ReactiveUI/Legacy/ObservableCollectionMixin.cs
  104. +0 −85 src/ReactiveUI/Legacy/ReactiveCollectionMixins.cs
  105. +0 −872 src/ReactiveUI/Legacy/ReactiveDerivedCollection.cs
  106. +0 −75 src/ReactiveUI/Legacy/ReactiveDerivedCollectionFromObservable.cs
  107. +0 −1,084 src/ReactiveUI/Legacy/ReactiveList.cs
  108. +2 −5 src/ReactiveUI/Mixins/DependencyResolverMixins.cs
  109. +7 −9 src/ReactiveUI/Mixins/ReactiveNotifyPropertyChangedMixin.cs
  110. +24 −12 src/ReactiveUI/ObservableForProperty/INPCObservableForProperty.cs
  111. +37 −21 src/ReactiveUI/Platforms/android/AndroidObservableForWidgets.cs
  112. +9 −3 src/ReactiveUI/Platforms/android/FlexibleCommandBinder.cs
  113. +9 −9 src/ReactiveUI/Platforms/android/ReactiveActivity.cs
  114. +0 −97 src/ReactiveUI/Platforms/android/ReactiveListAdapter.cs
  115. +9 −9 src/ReactiveUI/Platforms/android/ReactivePreferenceActivity.cs
  116. +5 −5 src/ReactiveUI/Platforms/apple-common/KVOObservableForProperty.cs
  117. +8 −2 src/ReactiveUI/Platforms/apple-common/TargetActionCommandBinder.cs
  118. +7 −7 src/ReactiveUI/Platforms/{net461 → net4}/ComponentModelTypeConverter.cs
  119. 0 src/ReactiveUI/Platforms/{net461 → net4}/PlatformRegistrations.cs
  120. 0 src/ReactiveUI/Platforms/{netcoreapp2.0 → netcoreapp2}/PlatformRegistrations.cs
  121. +86 −0 src/ReactiveUI/Platforms/netcoreapp3/ComponentModelTypeConverter.cs
  122. +29 −0 src/ReactiveUI/Platforms/netcoreapp3/PlatformRegistrations.cs
  123. +16 −5 src/ReactiveUI/Platforms/uap/ActivationForViewFetcher.cs
  124. +8 −5 src/ReactiveUI/Platforms/uap/SingleWindowDispatcherScheduler.cs
  125. +13 −13 src/ReactiveUI/Platforms/uikit-common/CommonReactiveSource.cs
  126. +16 −4 src/ReactiveUI/Platforms/uikit-common/FlexibleCommandBinder.cs
  127. +1 −2 src/ReactiveUI/Platforms/uikit-common/ReactiveCollectionViewSource.cs
  128. +1 −2 src/ReactiveUI/Platforms/uikit-common/ReactiveCollectionViewSourceExtensions.cs
  129. +1 −1 src/ReactiveUI/Platforms/uikit-common/ReactiveNavigationController.cs
  130. +0 −3 src/ReactiveUI/Platforms/uikit-common/ReactiveTableViewSource.cs
  131. +1 −1 src/ReactiveUI/Platforms/uikit-common/ReactiveTableViewSourceExtensions.cs
  132. +2 −0 src/ReactiveUI/Platforms/windows-common/AutoDataTemplateBindingHook.cs
  133. +15 −9 src/ReactiveUI/Platforms/windows-common/RoutedViewHost.cs
  134. +8 −2 src/ReactiveUI/Platforms/windows-common/ViewModelViewHost.cs
  135. +7 −7 src/ReactiveUI/Platforms/xamarin-common/ComponentModelTypeConverter.cs
  136. +1 −0 src/ReactiveUI/Properties/AssemblyInfo.cs
  137. +1 −2 src/ReactiveUI/ReactiveCommand/CombinedReactiveCommand.cs
  138. +1 −2 src/ReactiveUI/ReactiveCommand/ReactiveCommand.cs
  139. +5 −2 src/ReactiveUI/ReactiveCommand/ReactiveCommandBase.cs
  140. +20 −9 src/ReactiveUI/ReactiveCommand/ReactiveCommandMixins.cs
  141. +23 −6 src/ReactiveUI/ReactiveUI.csproj
  142. +11 −11 src/ReactiveUI/Routing/MessageBus.cs
  143. +12 −12 src/ReactiveUI/VariadicTemplates.cs
  144. +2 −2 src/ReactiveUI/VariadicTemplates.tt
  145. +2 −2 version.json
@@ -24,8 +24,8 @@ src/ReactiveUI/Platforms/apple-common/* @reactiveui/ios-team @reactiveui/mac-
src/ReactiveUI/Platforms/ios/* @reactiveui/ios-team
src/ReactiveUI/Platforms/mac/* @reactiveui/mac-team
src/ReactiveUI/Platforms/net461/* @reactiveui/wpf-team @reactiveui/winforms-team
src/ReactiveUI/Platforms/netcoreapp2.0/* @reactiveui/dotnetcore-team @reactiveui/webassembly-team
src/ReactiveUI/Platforms/uap/* @reactiveui/uwp-team
src/ReactiveUI/Platforms/netcoreapp/* @reactiveui/dotnetcore-team @reactiveui/webassembly-team
src/ReactiveUI/Platforms/uap10/* @reactiveui/uwp-team
src/ReactiveUI/Platforms/tizen/* @reactiveui/tizen-team
src/ReactiveUI/Platforms/tvos/* @reactiveui/tvos-team
src/ReactiveUI/Platforms/windows-common/* @reactiveui/wpf-team @reactiveui/winforms-team @reactiveui/uwp-team
@@ -142,12 +142,12 @@ from the main (upstream) repository:
## Coding

### Developer Environment
- Visual Studio 2017 (with latest patches/updates), with the following workloads/components
- Visual Studio 2019 (with latest patches/updates), with the following workloads/components
- Windows Universal Platform Development workload
- .NET desktop development workload
- Mobile development with .NET workload
- .NET Core cross-platform development
- Windows 10 SDK 10.0.16299 (individual component)
- Windows 10 SDK 10.0.17763.0 (individual component)
- PowerShell
- Android SDK Platform 26 (install through Visual Studio)

@@ -407,4 +407,3 @@ This is how we use the donations:
[Become a backer](https://opencollective.com/reactiveui#backer) and get your image on our README on Github with a link to your site.

<a href="https://opencollective.com/reactiveui#backer"><img src="https://opencollective.com/reactiveui/backer.svg?width=890&avatarHeight=50&button=false"></a>

@@ -32,5 +32,5 @@
<ItemGroup>
<AdditionalFiles Include="$(MSBuildThisFileDirectory)stylecop.json" Link="stylecop.json" />
</ItemGroup>
<Import Project="..\directory.build.props" />
<Import Project="..\src\directory.build.props" />
</Project>
@@ -15,8 +15,8 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="15.9.0" />
<PackageReference Include="Shouldly" Version="3.0.2" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.2.0" />
<PackageReference Include="Shouldly" Version="4.0.0-beta0002" />
</ItemGroup>

<ItemGroup>
@@ -29,7 +29,7 @@
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
</PackageReference>
<PackageReference Include="Xunit.StaFact" Version="0.3.13" />
<PackageReference Include="Xunit.StaFact" Version="0.3.18" />
<PackageReference Include="FluentAssertions" Version="5.6.0" />
<PackageReference Include="ReactiveUI.Testing" Version="*" />
</ItemGroup>
@@ -1,4 +1,5 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>netstandard2.0</TargetFramework>
</PropertyGroup>
@@ -11,8 +11,8 @@
<AssemblyName>IntegrationTests.UWP</AssemblyName>
<DefaultLanguage>en-US</DefaultLanguage>
<TargetPlatformIdentifier>UAP</TargetPlatformIdentifier>
<TargetPlatformVersion Condition=" '$(TargetPlatformVersion)' == '' ">10.0.16299.0</TargetPlatformVersion>
<TargetPlatformMinVersion>10.0.16299.0</TargetPlatformMinVersion>
<TargetPlatformVersion Condition=" '$(TargetPlatformVersion)' == '' ">10.0.17763.0</TargetPlatformVersion>
<TargetPlatformMinVersion>10.0.17763.0</TargetPlatformMinVersion>
<MinimumVisualStudioVersion>14</MinimumVisualStudioVersion>
<FileAlignment>512</FileAlignment>
<ProjectTypeGuids>{A5A43C5B-DE2A-4C0C-9213-0A381AF9435A};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
@@ -30,8 +30,8 @@
<PackageReference Include="ReactiveUI.Events.WPF" Version="*" />
<PackageReference Include="ReactiveUI.WPF" Version="*" />
</ItemGroup>

<ItemGroup>
<ProjectReference Include="..\IntegrationTests.Shared\IntegrationTests.Shared.csproj" />
<ProjectReference Include="..\IntegrationTests.Shared\IntegrationTests.Shared.csproj" />
</ItemGroup>
</Project>
@@ -11,8 +11,8 @@
<AssemblyName>IntegrationTests.XamarinForms.UWP</AssemblyName>
<DefaultLanguage>en-US</DefaultLanguage>
<TargetPlatformIdentifier>UAP</TargetPlatformIdentifier>
<TargetPlatformVersion>10.0.16299.0</TargetPlatformVersion>
<TargetPlatformMinVersion>10.0.16299.0</TargetPlatformMinVersion>
<TargetPlatformVersion>10.0.17763.0</TargetPlatformVersion>
<TargetPlatformMinVersion>10.0.17763.0</TargetPlatformMinVersion>
<MinimumVisualStudioVersion>14</MinimumVisualStudioVersion>
<EnableDotNetNativeCompatibleProfile>true</EnableDotNetNativeCompatibleProfile>
<FileAlignment>512</FileAlignment>
@@ -66,7 +66,7 @@
<ItemGroup>
<None Include="$(MSBuildThisFileDirectory)..\LICENSE" Pack="true" PackagePath="LICENSE" />
</ItemGroup>

<ItemGroup>
<PackageReference Include="Nerdbank.GitVersioning" Version="3.0.25" PrivateAssets="all" />
</ItemGroup>
@@ -4,7 +4,7 @@
<PropertyGroup>
<Product>$(AssemblyName) ($(TargetFramework))</Product>
</PropertyGroup>

<PropertyGroup Condition="$(TargetFramework.StartsWith('netstandard'))">
<DefineConstants>$(DefineConstants);NETSTANDARD;PORTABLE</DefineConstants>
</PropertyGroup>
@@ -60,7 +60,7 @@ public class ReactiveAppCompatActivity : AppCompatActivity, IReactiveObject, IRe
{
private readonly Subject<Unit> _activated = new Subject<Unit>();
private readonly Subject<Unit> _deactivated = new Subject<Unit>();
private readonly Subject<Tuple<int, Result, Intent>> _activityResult = new Subject<Tuple<int, Result, Intent>>();
private readonly Subject<(int requestCode, Result result, Intent intent)> _activityResult = new Subject<(int requestCode, Result result, Intent intent)>();

/// <summary>
/// Initializes a new instance of the <see cref="ReactiveAppCompatActivity" /> class.
@@ -124,7 +124,7 @@ protected ReactiveAppCompatActivity(IntPtr handle, JniHandleOwnership ownership)
/// <value>
/// The activity result.
/// </value>
public IObservable<Tuple<int, Result, Intent>> ActivityResult => _activityResult.AsObservable();
public IObservable<(int requestCode, Result result, Intent intent)> ActivityResult => _activityResult.AsObservable();

/// <inheritdoc/>
void IReactiveObject.RaisePropertyChanging(PropertyChangingEventArgs args)
@@ -150,13 +150,13 @@ public IDisposable SuppressChangeNotifications()
/// <param name="intent">The intent.</param>
/// <param name="requestCode">The request code.</param>
/// <returns>A task with the result and intent.</returns>
public Task<Tuple<Result, Intent>> StartActivityForResultAsync(Intent intent, int requestCode)
public Task<(Result result, Intent intent)> StartActivityForResultAsync(Intent intent, int requestCode)
{
// NB: It's important that we set up the subscription *before* we
// call ActivityForResult
var ret = ActivityResult
.Where(x => x.Item1 == requestCode)
.Select(x => Tuple.Create(x.Item2, x.Item3))
.Where(x => x.requestCode == requestCode)
.Select(x => (x.result, x.intent))
.FirstAsync()
.ToTask();

@@ -170,13 +170,13 @@ public IDisposable SuppressChangeNotifications()
/// <param name="type">The type.</param>
/// <param name="requestCode">The request code.</param>
/// <returns>A task with the result and intent.</returns>
public Task<Tuple<Result, Intent>> StartActivityForResultAsync(Type type, int requestCode)
public Task<(Result result, Intent intent)> StartActivityForResultAsync(Type type, int requestCode)
{
// NB: It's important that we set up the subscription *before* we
// call ActivityForResult
var ret = ActivityResult
.Where(x => x.Item1 == requestCode)
.Select(x => Tuple.Create(x.Item2, x.Item3))
.Where(x => x.requestCode == requestCode)
.Select(x => (x.result, x.intent))
.FirstAsync()
.ToTask();

@@ -202,7 +202,7 @@ protected override void OnResume()
protected override void OnActivityResult(int requestCode, Result resultCode, Intent data)
{
base.OnActivityResult(requestCode, resultCode, data);
_activityResult.OnNext(Tuple.Create(requestCode, resultCode, data));
_activityResult.OnNext((requestCode, resultCode, data));
}

/// <inheritdoc/>
@@ -74,7 +74,7 @@ public class ReactiveFragmentActivity : FragmentActivity, IReactiveObject, IReac
{
private readonly Subject<Unit> _activated = new Subject<Unit>();
private readonly Subject<Unit> _deactivated = new Subject<Unit>();
private readonly Subject<Tuple<int, Result, Intent>> _activityResult = new Subject<Tuple<int, Result, Intent>>();
private readonly Subject<(int requestCode, Result result, Intent intent)> _activityResult = new Subject<(int requestCode, Result result, Intent intent)>();

/// <inheritdoc/>
public event PropertyChangingEventHandler PropertyChanging
@@ -112,7 +112,7 @@ public class ReactiveFragmentActivity : FragmentActivity, IReactiveObject, IReac
/// <summary>
/// Gets the activity result.
/// </summary>
public IObservable<Tuple<int, Result, Intent>> ActivityResult => _activityResult.AsObservable();
public IObservable<(int requestCode, Result result, Intent intent)> ActivityResult => _activityResult.AsObservable();

/// <inheritdoc/>
void IReactiveObject.RaisePropertyChanging(PropertyChangingEventArgs args)
@@ -135,13 +135,13 @@ void IReactiveObject.RaisePropertyChanged(PropertyChangedEventArgs args)
/// <param name="intent">The intent.</param>
/// <param name="requestCode">The request code.</param>
/// <returns>A task with the result and intent.</returns>
public Task<Tuple<Result, Intent>> StartActivityForResultAsync(Intent intent, int requestCode)
public Task<(Result result, Intent intent)> StartActivityForResultAsync(Intent intent, int requestCode)
{
// NB: It's important that we set up the subscription *before* we
// call ActivityForResult
var ret = ActivityResult
.Where(x => x.Item1 == requestCode)
.Select(x => Tuple.Create(x.Item2, x.Item3))
.Where(x => x.requestCode == requestCode)
.Select(x => (x.result, x.intent))
.FirstAsync()
.ToTask();

@@ -155,13 +155,13 @@ void IReactiveObject.RaisePropertyChanged(PropertyChangedEventArgs args)
/// <param name="type">The type.</param>
/// <param name="requestCode">The request code.</param>
/// <returns>A task with the result and intent.</returns>
public Task<Tuple<Result, Intent>> StartActivityForResultAsync(Type type, int requestCode)
public Task<(Result result, Intent intent)> StartActivityForResultAsync(Type type, int requestCode)
{
// NB: It's important that we set up the subscription *before* we
// call ActivityForResult
var ret = ActivityResult
.Where(x => x.Item1 == requestCode)
.Select(x => Tuple.Create(x.Item2, x.Item3))
.Where(x => x.requestCode == requestCode)
.Select(x => (x.result, x.intent))
.FirstAsync()
.ToTask();

@@ -187,7 +187,7 @@ protected override void OnResume()
protected override void OnActivityResult(int requestCode, Result resultCode, Intent data)
{
base.OnActivityResult(requestCode, resultCode, data);
_activityResult.OnNext(Tuple.Create(requestCode, resultCode, data));
_activityResult.OnNext((requestCode, resultCode, data));
}

/// <inheritdoc/>
@@ -104,7 +104,7 @@ protected ReactiveRecyclerViewViewHolder(View view)
/// <summary>
/// Gets an observable that signals that this ViewHolder has been selected.
///
/// The <see cref="TViewModel"/> is the ViewModel of this ViewHolder in the <see cref="RecyclerView"/>.
/// The <see cref="IObservable{TViewModel}"/> is the ViewModel of this ViewHolder in the <see cref="RecyclerView"/>.
/// </summary>
public IObservable<TViewModel> SelectedWithViewModel { get; }

@@ -119,7 +119,7 @@ protected ReactiveRecyclerViewViewHolder(View view)
/// <summary>
/// Gets an observable that signals that this ViewHolder has been long-clicked.
///
/// The <see cref="TViewModel"/> is the ViewModel of this ViewHolder in the <see cref="RecyclerView"/>.
/// The <see cref="IObservable{TViewModel}"/> is the ViewModel of this ViewHolder in the <see cref="RecyclerView"/>.
/// </summary>
public IObservable<TViewModel> LongClickedWithViewModel { get; }

@@ -3,13 +3,17 @@
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for full license information.

using System.Collections.Specialized;

namespace ReactiveUI
namespace ReactiveUI.Blazor
{
#if !NET_461
internal class CollectionChangingEventManager : WeakEventManager<INotifyCollectionChanging, NotifyCollectionChangedEventHandler, NotifyCollectionChangedEventArgs>
/// <summary>
/// Returns the current orientation of the device on Windows.
/// </summary>
public class PlatformOperations : IPlatformOperations
{
/// <inheritdoc/>
public string GetOrientation()
{
return null;
}
}
#endif
}
@@ -0,0 +1,27 @@
{
"iisSettings": {
"windowsAuthentication": false,
"anonymousAuthentication": true,
"iisExpress": {
"applicationUrl": "http://localhost:50286/",
"sslPort": 0
}
},
"profiles": {
"IIS Express": {
"commandName": "IISExpress",
"launchBrowser": true,
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Development"
}
},
"ReactiveUI.Blazor": {
"commandName": "Project",
"launchBrowser": true,
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Development"
},
"applicationUrl": "http://localhost:50291/"
}
}
}

0 comments on commit f396c32

Please sign in to comment.
You can’t perform that action at this time.