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
/** | |
* 把小边放大至要求值,同时限制大边不超过要求值 | |
* | |
* @param bitmap | |
* @param shortSideGoal | |
* 短边需要放大到的目标值 | |
* @param longSideLimit | |
* 长边需要被限制的值得 | |
* @return | |
*/ |
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
/** | |
* Multi touch event listener | |
* | |
* @author viyu | |
* | |
*/ | |
public abstract class OnMultiTouchListener implements OnTouchListener { | |
/** | |
* last touch time |
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
/** | |
* 专门用来存储key-value的表格,shared preferences的db版 | |
* From db version 1 | |
* @author viyu | |
*/ | |
public final class KeyValueTable { | |
/** | |
* @param key |
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 interface IMessage { | |
} |
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 GridItemView { | |
private View mView = null; | |
private FrameLayout mContentLayout = null; | |
private View mTopLine = null; | |
private View mBottomLine = null; | |
private View mLeftLine = null; | |
private View mRightLine = null; | |
public GridItemView(LayoutInflater inflater, int contentLayoutResId) { |
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.msyd.client.ui.viewadapter; | |
import java.util.ArrayList; | |
import java.util.List; | |
import android.support.v4.view.PagerAdapter; | |
import android.util.SparseArray; | |
import android.view.View; | |
import android.view.ViewGroup; |
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
/** | |
* | |
* @author viyu | |
* | |
*/ | |
public class MenuPopWindow extends PopupWindow implements OnClickListener { | |
private Activity mActivity = null; | |
private CustomView mContentView = null; | |
private TextView mItemQuit = null; |
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 boolean isGPSIsOn() { | |
LocationManager locationManager = (LocationManager) mContext | |
.getSystemService(Context.LOCATION_SERVICE); | |
return locationManager.isProviderEnabled(LocationManager.GPS_PROVIDER); | |
} | |
public void openGPSSettingPage() { | |
Intent intent = new Intent(); | |
intent.setAction(Settings.ACTION_LOCATION_SOURCE_SETTINGS); | |
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK); |
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.demo.led; | |
import java.util.HashMap; | |
import java.util.Map; | |
import android.app.Activity; | |
import android.app.Notification; | |
import android.app.NotificationManager; | |
import android.graphics.Color; | |
import android.os.Bundle; |
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.viyu.draganddropdemo; | |
import com.viyu.dradanddropdemo.R; | |
import android.app.Activity; | |
import android.content.ClipData; | |
import android.content.ClipDescription; | |
import android.os.Bundle; | |
import android.util.Log; | |
import android.view.DragEvent; |