Skip to content

Instantly share code, notes, and snippets.

View Redth's full-sized avatar
🏠
Working from home

Jonathan Dick Redth

🏠
Working from home
View GitHub Profile
@Redth
Redth / MainPage.xaml
Last active March 6, 2021 23:11
Meadow Graphics Xamarin.Forms Tester app
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://xamarin.com/schemas/2014/forms"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
xmlns:meadowgraphicstester="clr-namespace:MeadowGraphicsTester"
x:Class="MeadowGraphicsTester.MainPage"
Title="Meadow Graphics"
Padding="20">
<Grid RowDefinitions="Auto, Auto, Auto, *" RowSpacing="20">
<Label Text="240 x 240" HorizontalOptions="Center" FontSize="Title" Grid.Row="0" />
<Grid ColumnDefinitions="*,*" RowDefinitions="*,Auto">
<Button Text="Abort"
Grid.Column="0"
Grid.Row="1"
BackgroundColor="Blue"
TextColor="White"
Margin="10, 0, 5, 15"
CornerRadius="4" />
<Button Text="OK"

Napoleon Torte

Pastries

  • 1 cup sour cream
  • 6 tbsp butter
  • 2 eggs
  • 1/2 cup sugar
  • 2 1/2 cups flour
  • 1 tsp vanilla
import Foundation
import Mapbox
class MapViewDelegate : NSObject, MGLMapViewDelegate
{
var callback:MapboxWrapperCallback
public var mapStyle:MGLStyle
public init(callback:MapboxWrapperCallback)
{
using System;
using Android.App;
using Android.OS;
using Android.Runtime;
using Android.Support.Design.Widget;
using Android.Support.V7.App;
using Android.Views;
using Android.Widget;
// <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
@Redth
Redth / gradle-copy-dependencies.gradle
Last active September 17, 2020 15:21
Gradle task for getting dependencies copied locally
// Add this to your module's build.gradle
// then run:
// gradlew :module-name:copyImpl
// The deps will be in the /module-name/downloadedlibs/* dir
configurations.implementation.setCanBeResolved(true)
configurations.api.setCanBeResolved(true)
task copyImpl(type: Copy) {
from configurations.implementation
into "downloadedlibs"
#include <ESP8266WiFi.h>
#include <ESP8266mDNS.h> // Include the mDNS library
const char* ssid = "JJAGD";
const char* password = "";
// Assign output variables to GPIO pins
const int pinHeater = 4;
const int pinPump1 = 5;
const int pinPump2 = 12;
- platform: Android
outputBasePath: "../PoolMathApp.Droid/Resources"
assets:
- file: "./dropdown.svg"
size: 12x12
- file: "./google.svg"
size: 20x20
- file: "./facebook.svg"
size: 20x20
- file: "./twitter.svg"
// Nuget: Xamarin.Android.Arch.Work.Runtime
var r = PeriodicWorkRequest.Builder.From<MyWorker>(TimeSpan.FromSeconds(5))
.SetConstraints(new Constraints.Builder()
.SetRequiresCharging(true)
.SetRequiredNetworkType(NetworkType.Unmetered)
.Build())
.Build();
WorkManager.Instance.Enqueue(r);
///////////////////////////////////////////////////////////////////////////////
// COMMAND LINE ARGUMENTS
//
// --localSource [a directory path or URL to a NuGet source]
// This can be used to provide access to the build
// artifacts to use as the base for the fat
// packages.
// --packagesPath [a directory path to download NuGet packages to]
// This can be used to change where the existing
// packages get downloaded to temporarily.