summaryrefslogtreecommitdiff
path: root/Xamarin.Forms.Platform.Tizen/TizenPlatformServices.cs
diff options
context:
space:
mode:
authorKangho Hur <kangho.hur@samsung.com>2017-01-20 14:05:56 +0900
committerKangho Hur <kangho.hur@samsung.com>2017-04-24 13:36:51 +0900
commit088af2334ebfd716e3f4ade55d1a29f15a2f61f7 (patch)
treee150f5081aa4e0c8d6405b0b67041d43e90acfd9 /Xamarin.Forms.Platform.Tizen/TizenPlatformServices.cs
parenta0336a7783ee77ca8cf44a1c67c67672e0b455f5 (diff)
downloadxamarin-forms-088af2334ebfd716e3f4ade55d1a29f15a2f61f7.tar.gz
xamarin-forms-088af2334ebfd716e3f4ade55d1a29f15a2f61f7.tar.bz2
xamarin-forms-088af2334ebfd716e3f4ade55d1a29f15a2f61f7.zip
Consider TV profile as TargetIdiom
- Currently, We assumed TV as TargetIdiom.Desktop. This is because there is no TargetIdiom.TV in Xamarin.Forms mainstream. - I'll do a PR to adding TargetIdiom.TV. Also, I'll fix it correctly when TargetIdio.TV is merged. Change-Id: Idb7b1cd2510f9d4cecb70bd1e9d4dae1c2a61b05
Diffstat (limited to 'Xamarin.Forms.Platform.Tizen/TizenPlatformServices.cs')
-rw-r--r--Xamarin.Forms.Platform.Tizen/TizenPlatformServices.cs20
1 files changed, 16 insertions, 4 deletions
diff --git a/Xamarin.Forms.Platform.Tizen/TizenPlatformServices.cs b/Xamarin.Forms.Platform.Tizen/TizenPlatformServices.cs
index bb7183a9..3fa4e756 100644
--- a/Xamarin.Forms.Platform.Tizen/TizenPlatformServices.cs
+++ b/Xamarin.Forms.Platform.Tizen/TizenPlatformServices.cs
@@ -79,17 +79,29 @@ namespace Xamarin.Forms.Platform.Tizen
public double GetNamedSize(NamedSize size, Type targetElementType, bool useOldSizes)
{
+ double baseSize = 10;
+ double baseSizeSpan = 2;
+
+ // TODO: Fix me when TargetIdiom.TV avaialbe on mainline
+ // In case of TV profile The base named size sholud be lager than mobile profile
+ if (Device.Idiom == TargetIdiom.Desktop)
+ {
+ // TODO: These valuse should be updated when TV profile UX guideline released.
+ baseSize = 60;
+ baseSizeSpan = 5;
+ }
+
switch (size)
{
case NamedSize.Micro:
- return 10;
+ return baseSize;
case NamedSize.Small:
- return 12;
+ return baseSize + baseSizeSpan;
case NamedSize.Default:
case NamedSize.Medium:
- return 14;
+ return baseSize + (baseSizeSpan * 2);
case NamedSize.Large:
- return 18;
+ return baseSize + (baseSizeSpan * 4);
default:
throw new ArgumentOutOfRangeException();
}