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
/** | |
* These hooks re-implement the now removed useBlocker and usePrompt hooks in 'react-router-dom'. | |
* Thanks for the idea @piecyk https://github.com/remix-run/react-router/issues/8139#issuecomment-953816315 | |
* Source: https://github.com/remix-run/react-router/commit/256cad70d3fd4500b1abcfea66f3ee622fb90874#diff-b60f1a2d4276b2a605c05e19816634111de2e8a4186fe9dd7de8e344b65ed4d3L344-L381 | |
*/ | |
import { useContext, useEffect, useCallback } from 'react'; | |
import { UNSAFE_NavigationContext as NavigationContext } from 'react-router-dom'; | |
/** | |
* Blocks all navigation attempts. This is useful for preventing the page from | |
* changing until some condition is met, like saving form data. |
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
#!/usr/bin/env python3 | |
import argparse | |
import asyncio | |
import websockets | |
import ssl | |
# Since we are sending messages to wss://localhost, we need to bypass SSL verification, | |
# hence initialising SSL context for that | |
ssl_context = ssl.create_default_context() |
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 React, { useContext, useState } from "react"; | |
import useMousePosition from "./useMousePosition"; | |
import { CursorContext } from "./CursorContextProvider"; | |
import isTouchDevice from "./isTouchDevice"; | |
const Cursor = () => { | |
if (isTouchDevice) { | |
return null; | |
} | |
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
btn Button chk CheckBox ckl CheckedListBox | |
cmb ComboBox dtp DateTimePicker lbl Label | |
llb LinkLabel lst ListBox lvw ListView | |
mtx MaskedTextBox cdr MonthCalendar icn NotifyIcon | |
nud NumeircUpDown pic PictureBox prg ProgressBar | |
rdo RadioButton rtx RichTextBox txt TextBox | |
tip ToolTip tvw TreeView wbs WebBrowser | |
?? | |
flp FlowLayoutPanel grp GroupBox pnl Panel |
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
namespace SimpleHttpServer | |
{ | |
using System; | |
using System.Net; | |
using System.Net.Sockets; | |
using System.Text; | |
public static class Program | |
{ | |
public static void Main(string[] args) |
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
I was able to find a VERY QUICK AND DIRTY way to use the media-autobuild suite to compile my own 64-bit static FFmpeg for Windows with the NDI library. | |
Download it and extract to a place on your computer, and keep note of the path. I put it in "D:\ndi\media-autobuild_suite-master", so for the sake of these instructions when you see "<autobuild>", you need to substitute whatever path you've put it in. | |
During the initial setup process, request to use the static build and add whatever else you'd like to have in your ffmpeg, then pause what you're doing when the on-screen prompts tell you the ffmpeg_options file has been written, then go into <autobuild>\build\ffmpeg_options.txt and add somewhere a line with | |
Code: | |
--enable-libndi_newtek | |
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
@echo off | |
REM IN YOUR SSL FOLDER, SAVE THIS FILE AS: makeCERT.bat | |
REM AT COMMAND LINE IN YOUR SSL FOLDER, RUN: makecert | |
REM IT WILL CREATE THESE FILES: example.cnf, example.crt, example.key | |
REM IMPORT THE .crt FILE INTO CHROME Trusted Root Certification Authorities | |
REM REMEMBER TO RESTART APACHE OR NGINX AFTER YOU CONFIGURE FOR THESE FILES | |
REM PLEASE UPDATE THE FOLLOWING VARIABLES FOR YOUR NEEDS. | |
SET HOSTNAME=example |
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
// Shinobi (http://shinobi.video) - FFMPEG FLV over HTTP Test | |
// How to Use | |
// 1. Navigate to directory where this file is. | |
// 2. Run `npm install express` | |
// 3. Start with `node ffmpegToWeb.js` | |
// 4. Get the IP address of the computer where you did step 1. Example : 127.0.0.1 | |
// 5. Open `http://127.0.0.1:8001/` in your browser. | |
var child = require('child_process'); | |
var events = require('events'); |
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
using System; | |
using System.Collections.Generic; | |
using System.IO; | |
using System.Net; | |
using System.Text; | |
namespace DumpHttpRequests | |
{ | |
internal class Program | |
{ |
NewerOlder