Skip to content

Instantly share code, notes, and snippets.

Avatar
💭
well-dressed well-behaved gentooman

Alexander Mishurov mishurov

💭
well-dressed well-behaved gentooman
View GitHub Profile
@mishurov
mishurov / touchAndDragDelay.c
Last active Sep 2, 2019
Remove the delay in macOS' touch and drag mode. It still doesn't fire events during the delay yet it removes the sticky effect.
View touchAndDragDelay.c
// clang -o touchAndDragDelay touchAndDragDelay.c -framework ApplicationServices -F/System/Library/PrivateFrameworks -framework MultitouchSupport
/*
~/Library/LaunchAgents/uk.co.mishurov.touchndrag.plist
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>uk.co.mishurov.touchndrag</string>
<key>Program</key>
@mishurov
mishurov / syntax.s
Last active Jan 22, 2022
AT&T assembly syntax and IA-32 instructions
View syntax.s
# --------
# Hardware
# --------
# Opcode - operational code
# Assebly mnemonic - abbreviation for an operation
# Instruction Code Format (IA-32)
# - Optional instruction prefix
# - Operational code
@mishurov
mishurov / qt.mak
Last active Aug 3, 2021
Makefile to build QT projects (Linux) without qmake
View qt.mak
CC=g++
MOC=moc-qt4
CFLAGS=-Wall
SOURCES=hello.cc hello_cls.cc
MOC_HEADERS=hello_cls.h
EXECUTABLE=hello
INCDIRS=-I/usr/include/qt4 -I/usr/include/qt4/QtGui -I/usr/include/qt4/QtCore
LIBS=-lQtCore -lQtGui
# Change postfixes
MOC_SOURCES=$(MOC_HEADERS:.h=.moc.cc)