Skip to content

Instantly share code, notes, and snippets.

@auycro
auycro / MouseWheelInvert.ahk
Last active January 12, 2017 09:26
AHK(Auto Hot Key), mouse-invert
WheelUp::
Send {WheelDown}
Return
WheelDown::
Send {WheelUp}
Return
@auycro
auycro / MultipleLineTStringGridCell.pas
Created February 3, 2015 03:40
DrawMultipleLine in TStringGrid Delphi
//グリッドのセルを作成
procedure TForm1.StringGrid1DrawCell(Sender: TObject; ACol, ARow: Integer;
Rect: TRect; State: TGridDrawState);
begin
if Pos(#13#10, StringGrid1.Cells[ACol, ARow]) > 0 then
begin
StringGrid1.Canvas.FillRect(Rect);
Inc(Rect.Left, 2);
Inc(Rect.Top, 2);
DrawText(StringGrid1.Canvas.Handle, PChar(StringGrid1.Cells[ACol, ARow]), -1, Rect, DT_NOPREFIX or DT_WORDBREAK);
// YourProject-Bridging-Header.h
#import <FacebookSDK/FacebookSDK.h>
// AppDelegate.swift
import UIKit
@UIApplicationMain
class AppDelegate: UIResponder, UIApplicationDelegate {
.
@auycro
auycro / reformatSQL.go
Created March 18, 2015 13:42
reformat sql interbase to DB2
package main
import (
"bufio"
"fmt"
"log"
"os"
"strings"
//"time"
)
@auycro
auycro / FacebookSDKTestScript.html
Last active August 29, 2015 14:19
FacebookSDK login friends send request
<!html>
<head>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script>
</head>
<body>
<script language="javascript" type="text/javascript">
//Check Login State
function checkLoginState() {
console.log("CheckLoginState");
var http = require('http');
var WebSocketServer = require('ws').Server;
var wss = new WebSocketServer({ port : 9001 });
http.createServer(function(req, res) {
res.end([
'<script>',
'var ws = new WebSocket("ws://localhost:9001");',
'ws.onmessage = function(ev) {',
' console.log("received message: " + ev.data);',
//Copyright (c) 2015 Gumpanat Keardkeawfa
//Licensed under the MIT license
//Websocket Jslib for UnityWebgl
//We will save this file as *.jslib for using in UNITY
var WebSocketJsLib = {
Hello: function(){
window.alert("Hello,world!");
},
InitWebSocket: function(url){
//Copyright (c) 2015 Gumpanat Keardkeawfa
//Licensed under the MIT license
//Websocket C# for UnityWebgl
using UnityEngine;
using System.Collections;
using System.Collections.Generic;
using System.Runtime.InteropServices;
public class WebSocket : MonoBehaviour {
@auycro
auycro / PlistPostProcess.cs
Last active October 29, 2021 11:40
Unity update info.plist
//Copyright (c) 2015 Gumpanat Keardkeawfa
//Licensed under the MIT license
using System.IO;
using UnityEngine;
using UnityEditor;
using UnityEditor.Callbacks;
using UnityEditor.iOS.Xcode;
public static class XCodePostProcess
//Copyright (c) 2015 Gumpanat Keardkeawfa
//Licensed under the MIT license
//LED VAR
const int ledPin = 13;
//Read VAR
boolean nodeconnect = false;
boolean messageComplete = false;
String inputString = "";