This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"sig":"42125a0301111017592d6f9c5a504017e45d98f5cbd6d5119c25953d09adbe44a1f44b6a2c427b9a238c4a25b5385eaf52421cbd431a5be1d457b813f6297b8d0","msghash":"279b64f374e68b4fcfa508ce86fb1deab4b3ca323afe02d77846f1f1c54a8f71"} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
# -*- coding: utf-8 -*- | |
import logging | |
import requests | |
''' | |
A module for helping you to finish the daily task on Neteasy Music | |
''' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public void getSignature(View view) { | |
String pkgname = et_pkgname.getText().toString(); | |
boolean isEmpty = TextUtils.isEmpty(pkgname); | |
if (isEmpty) { | |
Toast.makeText(this, "应用程序的包名不能为空!", Toast.LENGTH_SHORT); | |
} else { | |
try { | |
/** 通过包管理器获得指定包名包含签名的包信息 **/ | |
packageInfo = manager.getPackageInfo(pkgname, PackageManager.GET_SIGNATURES); | |
/******* 通过返回的包信息获得签名数组 *******/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class MyActivityLifecycleCallbacks implements Application.ActivityLifecycleCallbacks { | |
private int foregroundActivities; | |
private boolean hasSeenFirstActivity; | |
private boolean isChangingConfiguration; | |
@Override public void onActivityCreated(Activity activity, Bundle savedInstanceState) { | |
} | |
@Override public void onActivityStarted(Activity activity) { | |
mForegroundActivities++; | |
if (hasSeenFirstActivity && foregroundActivities == 1 && !isChangingConfiguration) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import android.content.Context; | |
import android.text.Editable; | |
import android.text.Selection; | |
import android.text.Spannable; | |
import android.text.TextWatcher; | |
import android.util.AttributeSet; | |
import android.widget.EditText; | |
public class ContainsEmojiEditText extends EditText { | |
//输入表情前的光标位置 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.autoupdate; | |
import java.io.File; | |
import java.io.FileOutputStream; | |
import java.io.InputStream; | |
import java.net.URL; | |
import java.net.URLConnection; | |
import android.app.Activity; | |
import android.app.AlertDialog; | |
import android.app.ProgressDialog; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import android.app.Activity; | |
import android.content.res.Resources; | |
import android.view.View; | |
import android.view.View.OnClickListener; | |
import android.view.Window; | |
import android.widget.CompoundButton; | |
import android.widget.CompoundButton.OnCheckedChangeListener; | |
import android.widget.ImageView; | |
import android.widget.TextView; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class JsonArrayPostRequest extends Request<JSONArray>{ | |
private Map<String,String> mParam; | |
private Listener<JSONArray> mListener; | |
public JsonArrayPostRequest(String url,Listener<JSONArray> listener, ErrorListener errorListener,Map param) { | |
super(Request.Method.POST, url, errorListener); | |
mListener=listener; | |
mParam=param; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class JsonObjectPostRequest extends Request<JSONObject>{ | |
private Map<String,String> mParam; | |
private Listener<JSONObject> mListener; | |
public JsonObjectPostRequest(String url,Listener<JSONObject> listener, ErrorListener errorListener,Map param) { | |
super(Request.Method.POST, url, errorListener); | |
mListener=listener; | |
mParam=param; | |