Styling Changes

This commit is contained in:
2020-10-18 19:20:22 -05:00
parent 1dd29edf62
commit 7c14629227
5 changed files with 30 additions and 25 deletions
+1 -1
View File
@@ -117,7 +117,7 @@ namespace qController
private void SetLightResources() private void SetLightResources()
{ {
Resources["NavigationBarColor"] = Color.FromHex("#71AEFF"); Resources["NavigationBarColor"] = Color.FromHex("#3089ff");
Resources["PageBackgroundColor"] = Color.LightGray; Resources["PageBackgroundColor"] = Color.LightGray;
@@ -83,7 +83,7 @@ namespace qController.UI
HorizontalTextAlignment = TextAlignment.Center, HorizontalTextAlignment = TextAlignment.Center,
VerticalTextAlignment = TextAlignment.Center, VerticalTextAlignment = TextAlignment.Center,
BackgroundColor = Color.Transparent, BackgroundColor = Color.Transparent,
FontSize = Device.GetNamedSize(NamedSize.Large, typeof(Label)) FontSize = App.HeightUnit * 2.75
}; };
name.SetDynamicResource(Label.TextColorProperty, "PrimaryTextColor"); name.SetDynamicResource(Label.TextColorProperty, "PrimaryTextColor");
name.SetBinding(Label.TextProperty, "name", BindingMode.TwoWay); name.SetBinding(Label.TextProperty, "name", BindingMode.TwoWay);
+17 -20
View File
@@ -17,11 +17,10 @@ namespace qController
ChangeToHome(); ChangeToHome();
listView.ItemsSource = items; listView.ItemsSource = items;
listView.RowHeight = (int)(App.HeightUnit * 6);
listView.ItemTemplate = new DataTemplate(() => listView.ItemTemplate = new DataTemplate(() =>
{ {
var grid = new Grid { var grid = new Grid {
Padding = new Thickness(5, 10), Padding = 0,
ColumnDefinitions = ColumnDefinitions =
{ {
new ColumnDefinition{Width = new GridLength(30)}, new ColumnDefinition{Width = new GridLength(30)},
@@ -29,38 +28,36 @@ namespace qController
} }
}; };
var icon = new Label { var icon = new Label {
FontFamily = App.QFont, FontFamily = App.QFont,
HorizontalTextAlignment = TextAlignment.Center, HorizontalTextAlignment = TextAlignment.Center,
VerticalTextAlignment = TextAlignment.Center, VerticalTextAlignment = TextAlignment.Center,
FontSize = App.HeightUnit * 3 FontSize = App.HeightUnit * 2.75
}; };
icon.SetBinding(Label.TextProperty, "Icon"); icon.SetBinding(Label.TextProperty, "Icon");
icon.SetDynamicResource(Label.TextColorProperty, "IconTextColor"); icon.SetDynamicResource(Label.TextColorProperty, "IconTextColor");
var label = new Label { var label = new Label {
VerticalOptions = LayoutOptions.FillAndExpand VerticalOptions = LayoutOptions.FillAndExpand,
VerticalTextAlignment = TextAlignment.Center,
FontSize = App.HeightUnit * 2.75
}; };
label.SetBinding(Label.TextProperty, "Title"); label.SetBinding(Label.TextProperty, "Title");
label.SetDynamicResource(Label.TextColorProperty, "PrimaryTextColor"); label.SetDynamicResource(Label.TextColorProperty, "PrimaryTextColor");
if (label.Text == "Disconnect") //switch (Device.RuntimePlatform)
label.TextColor = Color.DarkRed; //{
// case Device.iOS:
// listView.RowHeight = (int)(App.HeightUnit * 5);
switch (Device.RuntimePlatform) // label.FontSize = App.HeightUnit * 2.75;
{ // break;
case Device.iOS: // case Device.Android:
label.FontSize = App.HeightUnit * 3; // listView.RowHeight = (int)(App.HeightUnit * 5);
break; // label.FontSize = App.HeightUnit * 2.75;
case Device.Android: // break;
label.FontSize = App.HeightUnit * 2.2; //}
break;
}
grid.Children.Add(icon); grid.Children.Add(icon);
grid.Children.Add(label, 1, 0); grid.Children.Add(label, 1, 0);
@@ -12,12 +12,13 @@
<Grid RowSpacing="0"> <Grid RowSpacing="0">
<Grid.RowDefinitions> <Grid.RowDefinitions>
<RowDefinition Height="Auto"/> <RowDefinition Height="Auto"/>
<RowDefinition Height="175"/> <RowDefinition Height="200"/>
<RowDefinition Height="*"/> <RowDefinition Height="*"/>
</Grid.RowDefinitions> </Grid.RowDefinitions>
<!--Ordering is based on the order last is on top seems pretty backwards to me--> <!--Ordering is based on the order last is on top seems pretty backwards to me-->
<ScrollView x:Name="cueListScrollView" <ScrollView x:Name="cueListScrollView"
IsVisible="False"
Grid.Row="2"> Grid.Row="2">
<Grid x:Name="cueListsGrid" <Grid x:Name="cueListsGrid"
RowSpacing="0" RowSpacing="0"
@@ -29,7 +30,8 @@
<qui:QSelectedCueFrame x:Name="selectedCueFrame" <qui:QSelectedCueFrame x:Name="selectedCueFrame"
Grid.Row="1"/> IsVisible="False"
Grid.Row="1"/>
<qui:QNavBar x:Name="qNavBar" <qui:QNavBar x:Name="qNavBar"
Grid.Row="0"/> Grid.Row="0"/>
@@ -109,6 +109,12 @@ namespace qController
}).Wait(); }).Wait();
} }
connectedWorkspace.valueForKey(cue, QOSCKey.PlaybackPositionId); //fetch playback position for cueList once all cue loading is done. connectedWorkspace.valueForKey(cue, QOSCKey.PlaybackPositionId); //fetch playback position for cueList once all cue loading is done.
Device.BeginInvokeOnMainThread(() =>
{
selectedCueFrame.IsVisible = true;
cueListScrollView.IsVisible = true;
});
break; //only load first cue list with cues. break; //only load first cue list with cues.
} }
} }