Skip to content

Instantly share code, notes, and snippets.

xrandr --newmode "1368x768_60.00" 85.25 1368 1440 1576 1784 768 771 781 798 -hsync +vsync
xrandr --addmode VGA1 "1368x768_60.00"
xrandr --output LVDS1 --mode 1366x768
xrandr --output VGA1 --mode "1368x768_60.00" --left-of LVDS1
@fei-ke
fei-ke / 0_reuse_code.js
Created October 16, 2013 07:04
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
public EdgeEffect(Context context) {
final Resources res = context.getResources();
mEdge = res.getDrawable(R.drawable.overscroll_edge);
mGlow = res.getDrawable(R.drawable.overscroll_glow);
/*
* Copyright (C) 2014 Chris Banes
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
@fei-ke
fei-ke / eclipse.xml
Created August 7, 2014 01:31
Eclipse color scheme for IntelliJ IDEA from http://return0x0000.blogspot.com/2009/02/eclipse-color-scheme-for-intellij-idea.html path /home/{your_account_name}/.IntelliJIdea{your_version}/config/colors Just save it like eclipse.icls
<?xml version="1.0" encoding="UTF-8"?>
<scheme name="eclipse" version="124" parent_scheme="Default">
<option name="LINE_SPACING" value="1.2" />
<option name="EDITOR_FONT_SIZE" value="15" />
<option name="CONSOLE_FONT_NAME" value="Courier New" />
<option name="CONSOLE_FONT_SIZE" value="12" />
<option name="EDITOR_FONT_NAME" value="Consolas" />
<colors>
<option name="CARET_ROW_COLOR" value="e8f2fe" />
</colors>
@fei-ke
fei-ke / AbsItemAdapter.java
Last active August 29, 2015 14:05
适用于ItemView的列表适配器
/**
* 适用于ItemView的列表适配器
* Created by fei-ke on 2014/8/19.
*/
public class AbsItemAdapter<T extends IItemView, K extends IItemBean> extends BaseAdapter {
private List<K> mData;
private Class<T> itemViewClass;
public AbsItemAdapter(Class<T> itemViewClass) {
@fei-ke
fei-ke / renameapk
Last active August 29, 2015 14:11 — forked from fredgrott/renameapk
// in your android.applicationVariants.all { variant ->
// or in your android.libraryVariants.all { variant ->
// code block put this:
if (variant.productFlavors[0] == null){
variant.outputs[0].outputFile = new File(variant.outputs[0].outputFile.parent,
project.ext.ourProjectName + "_"
+ variant.buildType.name + "_"
+ android.defaultConfig.versionCode + "_"
+ android.defaultConfig.versionName + ".apk")
}else{
@fei-ke
fei-ke / wo.txt
Last active January 18, 2019 03:33
联通沃宽提速接口
提速:
http://bj.wokuan.cn/web/improvespeed.php?ContractNo=宽带帐号&up=09&old=07&round=29
恢复: http://bj.wokuan.cn/web/lowerspeed.php?ContractNo=宽带帐号&round=85
上面up old表示提升和本来的两种宽带类型
09是100M
07是10M
round是随机数
@fei-ke
fei-ke / google_paly_region
Created March 21, 2015 16:39
change google paly region,copy from http://pastebin.com/rmWfDeGH
Hello XXX,
Thank you for contacting Google! I understand you contacted us today because you are wanting to change the region of your Google Play Store. I can definitely feel where you're coming from here, but rest assured, I'd be more than happy to help you out.
We use the billing address of your default payment instrument in Google Wallet to help determine your home country for accessing the Play Store. Our collection of content can vary by country, so your view of the Play Store may differ from what others are seeing when you travel outside of the country listed on your default payment method's billing address.
Please note that you must have a valid payment method with a billing address located inside a country in order to access that country's Play Store.
If you're having issues viewing your intended country's Play Store and would like to change your default payment method or update an existing billing address in Google Wallet, please use the following steps:
@fei-ke
fei-ke / adball.bat
Created March 30, 2015 16:25
windows bat file, support multiple devices 'adb' command
@echo off
for /f %%i in ('adb devices^|findstr /e "device"') do (
if "%1" == "shell" (
start cmd /k adb -s %%i %*
) else (
adb -s %%i %*
)
)