Skip to content

Instantly share code, notes, and snippets.

KongKong XuQK

Block or report user

Report or block XuQK

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
@XuQK
XuQK / <SCHEMA_ID>.custom.yaml
Created Nov 23, 2012
Rime输入法特殊符号输入。
View <SCHEMA_ID>.custom.yaml
#只弄了我需要的,自己有需求的可以添加,我还另外改了几个标点符号,便于我自己使用
#建议直接复制进你的custom文档。
#欲使用本文件,你需要把文字候选数设置为7个,当然你也可以改变选择特殊符号的按键。
#作者E-mail:xuqiankun_66@qq.com
# Rime specific symbol settings
# encoding: utf-8无BOM
patch:
"punctuator/half_shape":
@XuQK
XuQK / getCellphoneNumberThroughName.java
Last active Nov 19, 2016
通过联系人名字获取其行动电话号码
View getCellphoneNumberThroughName.java
public static String getNumberThroughName(String name) {
//获取联系人的 ID 标识
Uri contactUri = ContactsContract.Contacts.CONTENT_URI;
String[] queryNameField = new String[] {name};
// 将 Contacts 表里 _ID 这一列,对应 DISPLAY_NAME 为 name 的一行单独提取出来组成数据表
Cursor contactCursor = getActivity().getContentResolver().query(contactUri,
new String[] {ContactsContract.Contacts._ID},
ContactsContract.Contacts.DISPLAY_NAME + " = ?",
queryNameField,
null);
View init.coffee
# initialization file (not found)
@XuQK
XuQK / AndroidBug5497Workaround.java
Created May 2, 2018
解决全屏模式下"adjustResize"失效,软键盘会遮挡住"EditText"的问题
View AndroidBug5497Workaround.java
public class AndroidBug5497Workaround {
// For more information, see https://issuetracker.google.com/issues/36911528
// To use this class, simply invoke assistActivity() on an Activity that already has its content view set.
public static void assistActivity (View content) {
new AndroidBug5497Workaround(content);
}
private View mChildOfContent;
private int usableHeightPrevious;
You can’t perform that action at this time.