Skip to content

Instantly share code, notes, and snippets.

View ObserverHerb's full-sized avatar

Herb ObserverHerb

View GitHub Profile
@ObserverHerb
ObserverHerb / Main.vb
Created July 20, 2016 01:43
Coder Radio 214 Coding Challenge
Public Class Main
Dim legend As Dictionary(Of String, String)
Dim dealerHand() As String
Dim playChart As Dictionary(Of String, String())
Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
legend = New Dictionary(Of String, String) From {
{"H", "Hit"},
{"S", "Stand"},
{"D", "Double if allowed, otherwise Hit"},
@ObserverHerb
ObserverHerb / index.html
Created July 27, 2016 02:24
Coder Radio 215 Coding Challenge
<html>
<head>
<style>
body, div.block, div.video {
margin: 0;
padding: 0;
}
body {
background-color: black;
@ObserverHerb
ObserverHerb / HighlightCalendar.xaml
Created November 7, 2016 01:59
Highlighted WPF Calendar Control
<Window x:Class="HighlightCalendar.HighlightCalendarWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:HighlightCalendar"
mc:Ignorable="d"
Title="HighlightCalendarWindow" Height="350" Width="525" Loaded="Window_Loaded">
<Grid>
<Viewbox VerticalAlignment="Stretch" HorizontalAlignment="Stretch">
@ObserverHerb
ObserverHerb / virtualbox-modules-5.1.8-get_user_pages.patch
Created November 19, 2016 09:22
Kernel 4.9-rc5 vs. app-emulation/virtualbox-modules-5.1.8
--- work/vboxdrv/r0drv/linux/memobj-r0drv-linux.c 2016-08-17 04:35:26.000000000 -0400
+++ work/vboxdrv/r0drv/linux/memobj-r0drv-linux.cb 2016-11-19 03:45:05.024142802 -0500
@@ -1045,12 +1045,20 @@
/*
* Get user pages.
*/
+
+ unsigned int flags = 0;
+
+ if (fWrite)
@ObserverHerb
ObserverHerb / qt-creator-3.6.1-variablechooser.patch
Created November 23, 2016 22:04
Correct dev-qt/qt-creator-3.6.1 segfault
--- qt-creator-opensource-src-3.6.1/src/plugins/coreplugin/variablechooser.cpp 2016-03-08 06:30:19.000000000 -0500
+++ qt-creator-opensource-src-3.6.1/src/plugins/coreplugin/variablechooser.cppb 2016-11-22 22:00:19.583860319 -0500
@@ -250,9 +250,9 @@
m_defaultDescription = VariableChooser::tr("Select a variable to insert.");
m_variableTree = new VariableTreeView(q, this);
- m_variableTree->setModel(&m_model);
-
m_variableDescription = new QLabel(q);
+
--- library/forms/gtk/src/lf_popover.orig.cpp 2017-01-09 11:05:22.343877181 -0500
+++ library/forms/gtk/src/lf_popover.cpp 2017-01-09 11:09:04.029863968 -0500
@@ -380,7 +380,7 @@
if (_style == mforms::PopoverStyleTooltip)
{
Glib::RefPtr<Gdk::Window> wnd = this->get_window();
- if (wnd != 0)
+ if (wnd)
{
int xx;
@ObserverHerb
ObserverHerb / vaapi.patch
Created January 23, 2017 04:26
Connect <video> tag to gstreamer vaapisink
diff --git a/Source/WebCore/platform/graphics/gstreamer/ImageGStreamer.h b/Source/WebCore/platform/graphics/gstreamer/ImageGStreamer.h
index f952ad6..c8249b2 100644
--- a/Source/WebCore/platform/graphics/gstreamer/ImageGStreamer.h
+++ b/Source/WebCore/platform/graphics/gstreamer/ImageGStreamer.h
@@ -60,7 +60,8 @@ class ImageGStreamer : public RefCounted<ImageGStreamer> {
}
private:
- ImageGStreamer(GstSample*);
+ ImageGStreamer(GstBuffer* buffer, GstCaps* caps);
@ObserverHerb
ObserverHerb / nvidia.patch
Created March 31, 2017 04:54
nvidia-driver-375.39 vs. kernel-4.11.0-rc4
diff -ru NVIDIA-Linux-x86_64-375.39/kernel/common/inc/nv-mm.h NVIDIA-Linux-x86_64-375.39-r1/kernel/common/inc/nv-mm.h
--- NVIDIA-Linux-x86_64-375.39/kernel/common/inc/nv-mm.h 2017-01-31 21:50:37.000000000 -0500
+++ NVIDIA-Linux-x86_64-375.39-r1/kernel/common/inc/nv-mm.h 2017-03-30 23:36:39.392964700 -0400
@@ -131,11 +131,7 @@
#if defined(NV_VM_FAULT_PRESENT)
static inline unsigned long nv_page_fault_va(struct vm_fault *vmf)
{
- #if defined(NV_VM_FAULT_HAS_ADDRESS)
return vmf->address;
- #else
@ObserverHerb
ObserverHerb / virtualbox-modules-5.1.22-page-table.patch
Created May 28, 2017 22:10
Build VirtualBox kernel modules against kernel 4.12.0-rc2
--- work/vboxdrv/r0drv/linux/memobj-r0drv-linux.c 2017-01-12 10:04:01.000000000 -0500
+++ work/vboxdrv/r0drv/linux/memobj-r0drv-linux.cb 2017-05-28 18:04:25.607775983 -0400
@@ -1,4 +1,4 @@
-/* $Id: memobj-r0drv-linux.c 112804 2017-01-12 15:03:51Z fmehnert $ */
+/* $Id: memobj-r0drv-linux.c 66930 2017-05-17 10:45:48Z vboxsync $ */
/** @file
* IPRT - Ring-0 Memory Objects, Linux.
*/
@@ -902,6 +902,9 @@
union
@ObserverHerb
ObserverHerb / virtualbox-modules-5.1.22-wait-queue.patch
Created July 5, 2017 04:23
Fix wait_queue_t change that prevents VirtualBox modules from building against kernel 4.12.0 final
--- work/vboxdrv/r0drv/linux/waitqueue-r0drv-linux.h 2017-05-28 17:18:48.486626052 -0400
+++ work/vboxdrv/r0drv/linux/waitqueue-r0drv-linux.hb 2017-07-04 23:38:48.235213259 -0400
@@ -46,7 +46,7 @@
typedef struct RTR0SEMLNXWAIT
{
/** The wait queue entry. */
- wait_queue_t WaitQE;
+ wait_queue_entry_t WaitQE;
/** The absolute timeout given as nano seconds since the start of the
* monotonic clock. */