Skip to content

Instantly share code, notes, and snippets.

View mishurov's full-sized avatar
💭
well-dressed well-behaved gentooman

Alexander Mishurov mishurov

💭
well-dressed well-behaved gentooman
View GitHub Profile
@mishurov
mishurov / touchAndDragDelay.c
Last active September 2, 2019 20:14
Remove the delay in macOS' touch and drag mode. It still doesn't fire events during the delay yet it removes the sticky effect.
// 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 October 16, 2024 06:51
AT&T assembly syntax and IA-32 instructions
# --------
# 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 October 7, 2024 18:16
Makefile to build QT projects (Linux) without qmake
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)