Skip to content

Instantly share code, notes, and snippets.

View stephanschuler's full-sized avatar
💤
zzzZZZzzzZZZ

Stephan Schuler stephanschuler

💤
zzzZZZzzzZZZ
View GitHub Profile
(function () {
function wrapConstructor(OriginalClass, OnInitFunc) {
const functionBody = `
const WrappereClass = function () {
OriginalClass.apply(this, arguments);
if (OnInitFunc) OnInitFunc.call(this);
};
WrappereClass.prototype = Object.create(OriginalClass.prototype);
WrappereClass.prototype.constructor = WrappereClass;
return WrappereClass;
try
tell application "System Events"
tell process "Telefon"
if menu item "Mikrofon an" of menu 1 of menu bar item "Anruf" of menu bar 1 exists then
set frontmost to true
click menu item "Mikrofon an" of menu 1 of menu bar item "Anruf" of menu bar 1
else
if menu item "Mikrofon aus" of menu 1 of menu bar item "Anruf" of menu bar 1 exists then
set frontmost to true
click menu item "Mikrofon aus" of menu 1 of menu bar item "Anruf" of menu bar 1
<?php
namespace Netlogix\Nxseobasics\Domain\Service;
/***************************************************************
* Copyright notice
*
* (c) 2015 Stephan Schuler <[email protected]>, netlogix GmbH & Co. KG
*
* All rights reserved
*
#!/bin/sh
################################################################
# Individual channel setting per distinct AP
case `uci get system.@system[0].hostname` in
"ap1")
CHANNELS="36 1"
;;
"ap2")
@stephanschuler
stephanschuler / compress.php
Created January 15, 2020 13:39
mysql_compress and mysql_uncompress
<?php
declare(strict_types=1);
function mysql_compress($base64 = null): string
{
if (!$base64) {
return '';
}
$size = pack('V', strlen((string)$base64));
<?php
declare(strict_types=1);
/*
* Event Dispatcher and Emitter are separate objects
* =================================================
*
* The dispatcher is meant to only receiver events:
* That's what the producing side holds.
*