This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
red=`tput setaf 1` | |
green=`tput setaf 2` | |
nc=`tput sgr0` | |
echo "${green}*** Preparing flutter SDK...${nc}" >/dev/stderr | |
if [[ $# -eq 1 ]]; then | |
ref=$1 | |
echo "${green}*** Using flutter SDK ref \"${ref}\"${nc}" >/dev/stderr |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class MouseCursorPainter extends CustomPainter { | |
MouseCursorPainter({required this.offset, this.factor = 64.0}); | |
final Offset offset; | |
final double factor; | |
@override | |
void paint(Canvas canvas, Size size) { | |
final path = ui.Path() | |
..moveTo(offset.dx, offset.dy) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'dart:async'; | |
import 'dart:typed_data'; | |
import 'dart:ui' as ui; | |
import 'package:flutter/foundation.dart'; | |
import 'package:flutter/material.dart'; | |
import 'package:flutter/rendering.dart'; | |
import 'package:flutter/scheduler.dart'; | |
import 'package:flutter/services.dart'; | |
import 'package:tuple/tuple.dart'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#define _GNU_SOURCE | |
#include <assert.h> | |
#include <stdlib.h> | |
#include <stdio.h> | |
#include <unistd.h> | |
#include <string.h> | |
#include <time.h> | |
#include <pthread.h> | |
#include <errno.h> | |
#include <sys/eventfd.h> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class TouchPositionPainter extends CustomPainter { | |
TouchPositionPainter(this.points); | |
final Set<Offset> points; | |
static final _whitePaint = Paint() | |
..color = Colors.white | |
..style = PaintingStyle.fill; | |
static final _blackPaint = Paint() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <fcntl.h> | |
#include <stdio.h> | |
#include <stdint.h> | |
#include <string.h> | |
#include <stdlib.h> | |
#include <errno.h> | |
#include <time.h> | |
#include <xf86drm.h> | |
#include <xf86drmMode.h> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
function prettyEcho { | |
_date=$(date '+%d.%m.%Y %X') | |
echo -e "[$_date] \e[92m$1\e[0m" | |
echo "[$_date] $1" >> /home/hannes/develd/upgrade.log | |
} | |
function prettyTime { | |
time (($@) && echo "run-time:") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/widgets.dart'; | |
class FakeDevicePixelRatio extends StatelessWidget { | |
final num fakeDevicePixelRatio; | |
final Widget child; | |
FakeDevicePixelRatio({this.fakeDevicePixelRatio, this.child}) : assert(fakeDevicePixelRatio != null); | |
@override | |
Widget build(BuildContext context) { |