summaryrefslogtreecommitdiff
path: root/Xamarin.Forms.Platform.Tizen/Renderers
diff options
context:
space:
mode:
authorKangho Hur <kangho.hur@samsung.com>2017-04-24 18:33:06 +0900
committerKangho Hur <kangho.hur@samsung.com>2017-07-10 11:11:23 +0900
commit977f9f9705404ce7ab77d0c9513939864d140001 (patch)
treef726057a54df07dbf4a810d1d1851453f0e4c278 /Xamarin.Forms.Platform.Tizen/Renderers
parent209182425d6e8200d287d9b57186c569eef6c638 (diff)
downloadxamarin-forms-977f9f9705404ce7ab77d0c9513939864d140001.tar.gz
xamarin-forms-977f9f9705404ce7ab77d0c9513939864d140001.tar.bz2
xamarin-forms-977f9f9705404ce7ab77d0c9513939864d140001.zip
Remove InternalsVissibleTo from Core to XF.Platforms.Tizen
- Please refer to prior patch (#782)
Diffstat (limited to 'Xamarin.Forms.Platform.Tizen/Renderers')
-rw-r--r--[-rwxr-xr-x]Xamarin.Forms.Platform.Tizen/Renderers/ListViewRenderer.cs8
-rw-r--r--Xamarin.Forms.Platform.Tizen/Renderers/NavigationPageRenderer.cs13
-rw-r--r--[-rwxr-xr-x]Xamarin.Forms.Platform.Tizen/Renderers/VisualElementRenderer.cs8
-rw-r--r--Xamarin.Forms.Platform.Tizen/Renderers/WebViewRenderer.cs6
4 files changed, 19 insertions, 16 deletions
diff --git a/Xamarin.Forms.Platform.Tizen/Renderers/ListViewRenderer.cs b/Xamarin.Forms.Platform.Tizen/Renderers/ListViewRenderer.cs
index 1fed8a31..d2b325af 100755..100644
--- a/Xamarin.Forms.Platform.Tizen/Renderers/ListViewRenderer.cs
+++ b/Xamarin.Forms.Platform.Tizen/Renderers/ListViewRenderer.cs
@@ -1,5 +1,6 @@
using System;
using System.Collections.Specialized;
+using Xamarin.Forms.Internals;
using ElmSharp;
using EProgressBar = ElmSharp.ProgressBar;
using ERect = ElmSharp.Rect;
@@ -17,6 +18,9 @@ namespace Xamarin.Forms.Platform.Tizen
/// </summary>
public class ListViewRenderer : ViewRenderer<ListView, Native.ListView>, IDisposable
{
+ IListViewController Controller => Element;
+ ITemplatedItemsView<Cell> TemplatedItemsView => Element;
+
/// <summary>
/// Event handler for ScrollToRequested.
/// </summary>
@@ -184,7 +188,7 @@ namespace Xamarin.Forms.Platform.Tizen
int position;
var scrollArgs = (ITemplatedItemsListScrollToRequestedEventArgs)e;
- var templatedItems = Element.TemplatedItems;
+ var templatedItems = TemplatedItemsView.TemplatedItems;
if (Element.IsGroupingEnabled)
{
var results = templatedItems.GetGroupAndIndexOfItem(scrollArgs.Group, scrollArgs.Item);
@@ -417,7 +421,7 @@ namespace Xamarin.Forms.Platform.Tizen
}
else
{
- var templatedItems = Element.TemplatedItems;
+ var templatedItems = TemplatedItemsView.TemplatedItems;
var results = templatedItems.GetGroupAndIndexOfItem(Element.SelectedItem);
if (results.Item1 != -1 && results.Item2 != -1)
{
diff --git a/Xamarin.Forms.Platform.Tizen/Renderers/NavigationPageRenderer.cs b/Xamarin.Forms.Platform.Tizen/Renderers/NavigationPageRenderer.cs
index fb17b31e..a0cca4ed 100644
--- a/Xamarin.Forms.Platform.Tizen/Renderers/NavigationPageRenderer.cs
+++ b/Xamarin.Forms.Platform.Tizen/Renderers/NavigationPageRenderer.cs
@@ -442,20 +442,17 @@ namespace Xamarin.Forms.Platform.Tizen
GetNaviItemForPage(nre.Page).Delete();
}
- async void InsertPageBeforeRequestedHandler(object sender, NavigationRequestedEventArgs nre)
+ void InsertPageBeforeRequestedHandler(object sender, NavigationRequestedEventArgs nre)
{
- TaskCompletionSource<bool> tcs = new TaskCompletionSource<bool>();
- if (Element.CurrentNavigationTask != null && !Element.CurrentNavigationTask.IsCompleted)
- {
- await Element.CurrentNavigationTask;
- }
- Element.CurrentNavigationTask = tcs.Task;
+ if (nre.BeforePage == null)
+ throw new ArgumentNullException("before");
+ if (nre.Page == null)
+ throw new ArgumentNullException("page");
Device.StartTimer(TimeSpan.FromMilliseconds(0), () =>
{
EvasObject page = Platform.GetOrCreateRenderer(nre.Page).NativeView;
_naviFrame.InsertBefore(GetNaviItemForPage(nre.BeforePage), page, SpanTitle(nre.Page.Title));
- tcs.SetResult(true);
UpdateHasNavigationBar(nre.Page);
return false;
diff --git a/Xamarin.Forms.Platform.Tizen/Renderers/VisualElementRenderer.cs b/Xamarin.Forms.Platform.Tizen/Renderers/VisualElementRenderer.cs
index 8b288698..512e3047 100755..100644
--- a/Xamarin.Forms.Platform.Tizen/Renderers/VisualElementRenderer.cs
+++ b/Xamarin.Forms.Platform.Tizen/Renderers/VisualElementRenderer.cs
@@ -1,7 +1,7 @@
using System;
using System.Collections.Generic;
-using System.Diagnostics;
using System.ComponentModel;
+using Xamarin.Forms.Internals;
using ElmSharp;
using ESize = ElmSharp.Size;
using ERect = ElmSharp.Rect;
@@ -718,7 +718,7 @@ namespace Xamarin.Forms.Platform.Tizen
Layout layout = Element as Layout;
if (layout != null)
{
- layout.InvalidateMeasureInternal(Internals.InvalidationTrigger.MeasureChanged);
+ layout.InvalidateMeasureNonVirtual(InvalidationTrigger.MeasureChanged);
layout.ForceLayout();
}
}
@@ -742,8 +742,8 @@ namespace Xamarin.Forms.Platform.Tizen
/// <param name="effect">The effect to register.</param>
void OnRegisterEffect(PlatformEffect effect)
{
- effect.Container = Element.Parent == null ? null : Platform.GetRenderer(Element.Parent).NativeView;
- effect.Control = NativeView;
+ effect.SetContainer(Element.Parent == null ? null : Platform.GetRenderer(Element.Parent).NativeView);
+ effect.SetControl(NativeView);
}
void OnMoved(object sender, EventArgs e)
diff --git a/Xamarin.Forms.Platform.Tizen/Renderers/WebViewRenderer.cs b/Xamarin.Forms.Platform.Tizen/Renderers/WebViewRenderer.cs
index 56579fb7..cb61aa5f 100644
--- a/Xamarin.Forms.Platform.Tizen/Renderers/WebViewRenderer.cs
+++ b/Xamarin.Forms.Platform.Tizen/Renderers/WebViewRenderer.cs
@@ -12,6 +12,8 @@ namespace Xamarin.Forms.Platform.Tizen
WebNavigationEvent _eventState;
TWebView _control = null;
+ IWebViewController ElementController => Element;
+
public void LoadHtml(string html, string baseUrl)
{
_control.LoadHtml(html, baseUrl);
@@ -170,8 +172,8 @@ namespace Xamarin.Forms.Platform.Tizen
void UpdateCanGoBackForward()
{
- Element.CanGoBack = _control.CanGoBack();
- Element.CanGoForward = _control.CanGoForward();
+ ElementController.CanGoBack = _control.CanGoBack();
+ ElementController.CanGoForward = _control.CanGoForward();
}
}
} \ No newline at end of file