Skip to content

Instantly share code, notes, and snippets.

bstaint

Block or report user

Report or block bstaint

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View absl.pri
INCLUDEPATH += $$PWD
contains(absl, dynamic_annotations) {
SOURCES += \
$$PWD/absl/base/dynamic_annotations.cc \
}
contains(absl, spinlock_wait) {
SOURCES += \
$$PWD/absl/base/internal/spinlock_posix.inc \
View map-unite-grep.vim
nnoremap <silent> [unite]g :<C-u>exe 'UniteWithCursorWord grep:. -buffer-name=grep_'.expand('<cword>')<CR>
nnoremap [unite]r :<C-u>UniteResume grep<Tab>
View run.vim
function! s:RunFunc(flag)
let cmdline = { 'c': 'gcc', 'cpp': 'g++' }
if exists('cmdline[&ft]')
exec 'VimProcBang '.cmdline[&ft].' %:t -Wall -g -o %:t:r.exe'
let output = expand('%:t:r').'.exe'
" 确保编译成功且生成exe
if a:flag == 1 && vimproc#get_last_status() == 0
\ && filereadable(output)
echo vimproc#cmd#system(output)
View fasd.vim
function s:FasdFunc(cmd, words)
let ret = ''
if a:cmd == 'e'
let ret = system('fasd -f ' . a:words)
elseif a:cmd == 'cd'
let ret = system('fasd -d ' . a:words)
endif
if len(ret) > 0
exec printf(':%s %s', a:cmd, ret)
View GIFAnimate_PreCreate.cpp
void CGIFAnimate::PreCreate(CREATESTRUCT &cs)
{
// 添加自绘样式 CButton 是BS_OWNERDRAW
cs.style |= SS_OWNERDRAW;
}
View GIFAnimate_Test.cpp
m_Gif.Create(*this);
m_Gif.SetDlgCtrlID(IDC_GIF1);
m_Gif.Load(L"../1.gif");
m_Gif.SetWindowPos(NULL, CRect(0,0,50,50), SWP_SHOWWINDOW);
m_Gif.Play();
m_Gif2.Create(*this);
m_Gif2.SetDlgCtrlID(IDC_GIF2);
m_Gif2.Load(L"../1000.gif");
m_Gif2.SetWindowPos(NULL, CRect(50,0,100,50), SWP_SHOWWINDOW);
View GIFAnimate.cpp
#include "GIFAnimate.h"
CGIFAnimate::CGIFAnimate()
: m_pImage(NULL),
m_pDimensionID(NULL),
m_pItem(NULL),
m_CurrentFrame(1)
{
// Initialize GDI+.
GdiplusStartupInput gdiplusStartupInput;
View GIFAnimate.h
define CGIFANIMATE_H
#include <gdiplus.h>
#include "precompile.h"
using namespace Gdiplus;
class CGIFAnimate : public CStatic
{
public:
View MyChrome.ahk
hash := ""
exe := "D:\Portable\CentBrowser\chrome.exe"
Loop HKEY_LOCAL_MACHINE,SOFTWARE\RegisteredApplications, 1, 1
{
If (A_LoopRegType <> "KEY")
RegRead Value
StringGetPos, pos, A_LoopRegName, Cent Browser
if(pos >= 0)
You can’t perform that action at this time.