Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changed the base class of SizeMonitoringFrameLayout to ContentControl… #78

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion ReactWindows/Playground/MainPage.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,12 @@
xmlns:local="using:Playground"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:views="using:ReactNative.Views"
mc:Ignorable="d">

<Grid Background="{ThemeResource ApplicationPageBackgroundThemeBrush}">
<TextBlock Name="Output" />
<views:ReactRootView VerticalAlignment="Stretch" HorizontalAlignment="Stretch">
<TextBlock Name="Output" />
</views:ReactRootView>
</Grid>
</Page>
2 changes: 2 additions & 0 deletions ReactWindows/ReactNative.sln
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@ Global
{C7673AD5-E3AA-468C-A5FD-FA38154E205C}.Release|x86.ActiveCfg = Release|x86
{C7673AD5-E3AA-468C-A5FD-FA38154E205C}.Release|x86.Build.0 = Release|x86
{D52267B5-396F-424A-BB26-C9E750032846}.Debug|Any CPU.ActiveCfg = Debug|x86
{D52267B5-396F-424A-BB26-C9E750032846}.Debug|Any CPU.Build.0 = Debug|x86
{D52267B5-396F-424A-BB26-C9E750032846}.Debug|Any CPU.Deploy.0 = Debug|x86
{D52267B5-396F-424A-BB26-C9E750032846}.Debug|ARM.ActiveCfg = Debug|ARM
{D52267B5-396F-424A-BB26-C9E750032846}.Debug|ARM.Build.0 = Debug|ARM
{D52267B5-396F-424A-BB26-C9E750032846}.Debug|ARM.Deploy.0 = Debug|ARM
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -468,7 +468,7 @@ private IViewManager ResolveViewManager(int tag)
return viewManager;
}

private void AddRootViewGroup(int tag, Panel view, ThemedReactContext themedContext)
private void AddRootViewGroup(int tag, FrameworkElement view, ThemedReactContext themedContext)
{
DispatcherHelpers.AssertOnDispatcher();
_tagsToViews.Add(tag, view);
Expand Down
2 changes: 1 addition & 1 deletion ReactWindows/ReactNative/UIManager/RootViewManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public override string Name
/// </summary>
/// <param name="reactContext">The react context.</param>
/// <returns>The view instance.</returns>
protected override Panel CreateViewInstance(ThemedReactContext reactContext)
protected override FrameworkElement CreateViewInstance(ThemedReactContext reactContext)
{
return new SizeMonitoringFrameLayout();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ namespace ReactNative.UIManager
/// <summary>
/// allows registering for size change events. The main purpose for this class is to hide complexity of ReactRootView
/// </summary>
public partial class SizeMonitoringFrameLayout : Panel
public partial class SizeMonitoringFrameLayout : ContentControl
{
public SizeMonitoringFrameLayout() : base()
{
Expand Down
2 changes: 1 addition & 1 deletion ReactWindows/ReactNative/UIManager/ViewGroupManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ namespace ReactNative.UIManager
/// Class providing child management API for view managers of classes
/// extending <see cref="Panel"/>.
/// </summary>
public abstract class ViewGroupManager : ViewManager<Panel, LayoutShadowNode>
public abstract class ViewGroupManager : ViewManager<FrameworkElement, LayoutShadowNode>
{
/// <summary>
/// Signals whether the view type needs to handle laying out its own
Expand Down
2 changes: 1 addition & 1 deletion ReactWindows/ReactNative/Views/ReactRootView.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ namespace ReactNative.Views
/// 1. Add support for events(i.e. define the sendEvents method)
/// 2. Add lifecycle functions to ensure the bundle is only loaded once
/// </summary>
public sealed partial class ReactRootView : SizeMonitoringFrameLayout, IRootView
public sealed partial class ReactRootView : IRootView
{
private IReactInstanceManager _ReactInstanceManager;
private string _JSModuleName;
Expand Down