ITeye博客

2016 年文章归档

共 11 篇文章

抽屉菜单沉浸式状态

1、 <style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar"> <!-- Customize your theme here. --> <item name="colorPrimary">@color/colorPrimary</item> <item name="colorPrimaryDark">@color/colorPrimary</item> <item name="colorAccent">@color/colorAccent</item> <item name="windowActionBar">f…

2016-10-11 15:40 · Andriod

html5编辑器

怎么让Eclipse Adt支持HTML5新增的标签 http://bbs.phonegap100.com/thread-385-1-1.html (出处: PhoneGap中文网) 插件:http://download.aptana.com/studio3/plugin/install

2016-09-26 12:31 · Andriod

23种设计模式

1、工厂设计模式: 凡是出现了大量的产品需要创建,并且具有共同的接口时,可以通过工厂方法模式进行创建。 共同的代码: public interface Sender { void send(); } public class MailSender implements Sender { @Override public void send() { System.out.println("MailSender发送send方法"); } } public class SmsSender implements Sender { @Override public void send() { Syst…

2016-08-23 23:57 · Java

ScaleType

ScaleType图解

2016-07-07 17:56 · Andriod

拨打电话

拨打电话; Intent intent = new Intent(Intent.ACTION_CALL,Uri.parse("tel:" + editText.getText())); startActivity(intent);

2016-06-23 18:34 · Andriod

设置状态栏是否显示或者设置为透明的

全屏显示不透明: // getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN,WindowManager.LayoutParams.FLAG_FULLSCREEN); 全屏显示并透明: getWindow().requestFeature(Window.FEATURE_NO_TITLE); if(VERSION.SDK_INT >= VERSION_CODES.LOLLIPOP) { Window window = getWindow(); window.clearFlags(WindowManager.LayoutP…

2016-06-07 11:45 · Andriod

http://blog.csdn.net/h7870181/article/details/8332991

显示软键盘

2016-05-04 09:45 · Andriod

代码设置大小

代码设置大小: Resources r = getResources(); mUnderlineHeight = (int)TypedValue.applyDimension(TypedValue.COMPLEX_UNIT_DIP, 2, r.getDisplayMetrics());

2016-04-27 15:47 · Andriod

软键盘的操作

关闭软键盘:(hideSoftKeyboard) void hideSoftKeyboard() { if(getWindow().getAttributes().softInputMode != WindowManager.LayoutParams.SOFT_INPUT_STATE_HIDDEN){ if(getCurrentFocus() != null){ inputMethodManager.hideSoftInputFromWindow(getCurrentFocus().getWindowToken(), InputMethodManager.HIDE_NOT_ALWAYS); …

2016-04-22 17:22 · Andriod · 软键盘的操作

百度地图开发中的主要知识点

<?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:map="http://schemas.android.com/apk/res-auto" android:layout_width="match_parent" android:layout_height="match_parent" android:orientation="vertical" > <LinearLayout android:layout_…

2016-02-23 10:51 · Andriod

测量ScrollView的相关高度(监听滑动到顶端和底部)

private void init() { mScrollView = (ScrollView) findViewById(R.id.scrollview); mScrollView.setOnTouchListener(new TouchListenerImpl()); } class TouchListenerImpl implements OnTouchListener { @Override public boolean onTouch(View v, MotionEvent event) { switch (event.getAction()) { case MotionEvent…

2016-01-03 15:00 · Andriod