diff --git a/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/CustomRenderers/QueryEditorRenderer.cs b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/CustomRenderers/QueryEditorRenderer.cs new file mode 100644 index 0000000..5041dc2 --- /dev/null +++ b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/CustomRenderers/QueryEditorRenderer.cs @@ -0,0 +1,23 @@ +// +// QueryEditorRenderer.cs +// +// Trevi Awater +// 13-01-2022 +// +// © Xamarin.Neo4j.iOS +// + +using UIKit; +using Xamarin.Forms; +using Xamarin.Forms.Platform.iOS; +using Xamarin.Neo4j.Controls; +using Xamarin.Neo4j.iOS.CustomRenderers; + +[assembly: ExportRenderer(typeof(QueryEditor), typeof(QueryEditorRenderer))] +namespace Xamarin.Neo4j.iOS.CustomRenderers +{ + public class QueryEditorRenderer : EditorRenderer + { + + } +} diff --git a/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/Info.plist b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/Info.plist index b2b5fdb..8bc61f1 100644 --- a/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/Info.plist +++ b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/Info.plist @@ -2,43 +2,43 @@ - UIDeviceFamily - - 1 - 2 - - UISupportedInterfaceOrientations - - UIInterfaceOrientationPortrait - UIInterfaceOrientationLandscapeLeft - UIInterfaceOrientationLandscapeRight - - UISupportedInterfaceOrientations~ipad - - UIInterfaceOrientationPortrait - UIInterfaceOrientationPortraitUpsideDown - UIInterfaceOrientationLandscapeLeft - UIInterfaceOrientationLandscapeRight - - MinimumOSVersion - 14.2 - CFBundleDisplayName - Pocket Graph - CFBundleIdentifier - nl.resoftware.xamarin-neo4j - CFBundleVersion - 1.0 - UILaunchStoryboardName - LaunchScreen - CFBundleName - Pocket Graph - XSAppIconAssets - Assets.xcassets/AppIcon.appiconset - UIAppFonts - - iconize-fontawesome-regular.ttf - iconize-fontawesome-solid.ttf - iconize-fontawesome-brands.ttf - + UIDeviceFamily + + 1 + 2 + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + MinimumOSVersion + 14.2 + CFBundleDisplayName + PocketGraph + CFBundleIdentifier + nl.resoftware.pocketgraph + CFBundleVersion + 1.0.1 + UILaunchStoryboardName + LaunchScreen + CFBundleName + PocketGraph + XSAppIconAssets + Assets.xcassets/AppIcon.appiconset + UIAppFonts + + iconize-fontawesome-regular.ttf + iconize-fontawesome-solid.ttf + iconize-fontawesome-brands.ttf + diff --git a/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/LaunchScreen.storyboard b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/LaunchScreen.storyboard new file mode 100644 index 0000000..bc4ed80 --- /dev/null +++ b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/LaunchScreen.storyboard @@ -0,0 +1,42 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/Resources/LaunchScreen.storyboard b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/Resources/LaunchScreen.storyboard deleted file mode 100644 index a639c2f..0000000 --- a/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/Resources/LaunchScreen.storyboard +++ /dev/null @@ -1,39 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/Resources/logo.png b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/Resources/logo.png new file mode 100644 index 0000000..2ecad28 Binary files /dev/null and b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/Resources/logo.png differ diff --git a/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/Resources/resoftware.png b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/Resources/resoftware.png new file mode 100644 index 0000000..1cc029b Binary files /dev/null and b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/Resources/resoftware.png differ diff --git a/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/Services/ScreenSizeService.cs b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/Services/ScreenSizeService.cs new file mode 100644 index 0000000..91fc48f --- /dev/null +++ b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/Services/ScreenSizeService.cs @@ -0,0 +1,30 @@ +// +// ScreenSizeService.cs +// +// Trevi Awater +// 13-01-2022 +// +// © Xamarin.Neo4j.iOS +// + +using UIKit; +using Xamarin.Forms; +using Xamarin.Neo4j.iOS.Services; +using Xamarin.Neo4j.Services; + +[assembly: Dependency(typeof(ScreenSizeService))] +namespace Xamarin.Neo4j.iOS.Services +{ + public class ScreenSizeService : IScreenSizeService + { + public int GetScreenHeight() + { + return (int)UIScreen.MainScreen.Bounds.Height; + } + + public int GetScreenWidth() + { + return (int)UIScreen.MainScreen.Bounds.Width; + } + } +} diff --git a/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/Xamarin.Neo4j.iOS.csproj b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/Xamarin.Neo4j.iOS.csproj index 2d0b30f..0ac2af9 100644 --- a/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/Xamarin.Neo4j.iOS.csproj +++ b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j.iOS/Xamarin.Neo4j.iOS.csproj @@ -94,8 +94,10 @@ SdkOnly + + @@ -119,7 +121,7 @@ - + false @@ -143,6 +145,8 @@ + + \ No newline at end of file diff --git a/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j/App.xaml b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j/App.xaml index 56b5a4d..9ef1bfc 100644 --- a/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j/App.xaml +++ b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j/App.xaml @@ -2,36 +2,4 @@ - - #e4ecf5 - #31333b - - - - - - - - - - - - - - - - - - - - - - diff --git a/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j/App.xaml.cs b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j/App.xaml.cs index 7344dc9..618c42f 100644 --- a/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j/App.xaml.cs +++ b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j/App.xaml.cs @@ -2,6 +2,7 @@ using Xamarin.Forms; using Xamarin.Forms.Xaml; using Xamarin.Neo4j.Pages; +using Xamarin.Neo4j.Themes; [assembly: XamlCompilation(XamlCompilationOptions.Compile)] @@ -13,9 +14,24 @@ namespace Xamarin.Neo4j { InitializeComponent(); + SetTheme(Current.RequestedTheme); + MainPage = new NavigationPage(new RootPage()); } + + private void SetTheme(OSAppTheme theme) + { + Resources = theme switch + { + OSAppTheme.Dark => new DarkTheme(), + OSAppTheme.Light => new LightTheme(), + + _ => new LightTheme() + }; + } + + protected override void OnStart() { // Handle when your app starts diff --git a/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j/Controls/ConnectionCell.xaml b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j/Controls/ConnectionCell.xaml new file mode 100644 index 0000000..53a88c0 --- /dev/null +++ b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j/Controls/ConnectionCell.xaml @@ -0,0 +1,20 @@ + + + + + + + + + + + diff --git a/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j/Controls/ConnectionCell.xaml.cs b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j/Controls/ConnectionCell.xaml.cs new file mode 100644 index 0000000..3aa7cb7 --- /dev/null +++ b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j/Controls/ConnectionCell.xaml.cs @@ -0,0 +1,35 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +using Xamarin.Forms; +using Xamarin.Forms.Xaml; + +namespace Xamarin.Neo4j.Controls +{ + [XamlCompilation(XamlCompilationOptions.Compile)] + public partial class ConnectionCell : ViewCell + { + public ConnectionCell() + { + InitializeComponent(); + + isActiveIndicator.SetBinding(VisualElement.IsVisibleProperty, new Binding(nameof(IsActive), source: this)); + } + + #region Bindable Properties + + public bool IsActive + { + get => (bool)GetValue(IsActiveProperty); + set => SetValue(IsActiveProperty, value); + } + + public static BindableProperty IsActiveProperty = BindableProperty.Create("IsActive", typeof(bool), + typeof(ConnectionCell), false, BindingMode.OneWay); + + #endregion + } +} diff --git a/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j/Controls/QueryBuilder.xaml b/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j/Controls/QueryBuilder.xaml deleted file mode 100644 index f937c3b..0000000 --- a/Xamarin.Neo4j/Xamarin.Neo4j/Xamarin.Neo4j/Controls/QueryBuilder.xaml +++ /dev/null @@ -1,21 +0,0 @@ - - - - - - - - - - - - -