惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Help Net Security
Help Net Security
G
Google Developers Blog
雷峰网
雷峰网
WordPress大学
WordPress大学
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
Engineering at Meta
Engineering at Meta
Security Latest
Security Latest
T
Threat Research - Cisco Blogs
AWS News Blog
AWS News Blog
F
Full Disclosure
C
Cybersecurity and Infrastructure Security Agency CISA
T
The Exploit Database - CXSecurity.com
J
Java Code Geeks
U
Unit 42
C
Cyber Attacks, Cyber Crime and Cyber Security
V
V2EX
C
Cisco Blogs
博客园 - 司徒正美
Project Zero
Project Zero
L
LINUX DO - 热门话题
阮一峰的网络日志
阮一峰的网络日志
Blog — PlanetScale
Blog — PlanetScale
Scott Helme
Scott Helme
A
About on SuperTechFans
Hugging Face - Blog
Hugging Face - Blog
S
Securelist
小众软件
小众软件
aimingoo的专栏
aimingoo的专栏
S
Schneier on Security
G
GRAHAM CLULEY
酷 壳 – CoolShell
酷 壳 – CoolShell
Cyberwarzone
Cyberwarzone
MongoDB | Blog
MongoDB | Blog
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
博客园 - 叶小钗
T
Threatpost
Recorded Future
Recorded Future
C
CXSECURITY Database RSS Feed - CXSecurity.com
宝玉的分享
宝玉的分享
N
News and Events Feed by Topic
人人都是产品经理
人人都是产品经理
The Register - Security
The Register - Security
S
Security Archives - TechRepublic
博客园 - Franky
N
News | PayPal Newsroom
Simon Willison's Weblog
Simon Willison's Weblog
S
SegmentFault 最新的问题
W
WeLiveSecurity
A
Arctic Wolf
B
Blog

博客园 - TopCoder.NET

内存操作的几个函数 Windows消息目录 映射网络驱动器命令 均值、中位数、众数 修改Android 界面颜色 设置Android程序图标和程序标题 - TopCoder.NET 解决spring boot中rest接口404,500等错误返回统一的json格式 UTF-8的BOM含义 详解BOM头以及去掉BOM头的方法 2017年总结 Unknown SSL protocol error in connection to xxx:443 - TopCoder.NET springmvc请求参数获取的几种方法 - TopCoder.NET 苹果手机输入中文不会触发onkeyup事件 LVS负载均衡DR模式部署 pycharm激活 Mac 终端命令行颜色高亮显示 windows7环境下使用pip安装MySQLdb python 国内镜像 mui 单页面下拉刷新 - TopCoder.NET
Android中的EditText默认时不弹出软键盘的方法
TopCoder.NET · 2018-03-30 · via 博客园 - TopCoder.NET

方法一:
  在 AndroidMainfest.xml中选择哪个activity,设置windowSoftInputMode属性为 adjustUnspecified|stateHidden

1 <activity android:name=".Main"
2       android:label="@string/app_name"
3       android:windowSoftInputMode="adjustUnspecified|stateHidden"
4       android:configChanges="orientation|keyboardHidden">
5   <intent-filter>
6       <action android:name="android.intent.action.MAIN" />
7       <category android:name="android.intent.category.LAUNCHER"/>
8   </intent-filter>
9 </activity>

方法二:

    让 EditText失去焦点,使用EditText的clearFocus方法

EditText edit = (EditText)findViewById(R.id.edit);
edit.clearFocus();

方法三:

    强制隐藏Android输入法窗口

EditText edit=(EditText)findViewById(R.id.edit);
InputMethodManager imm = (InputMethodManager)getSystemService(Context.INPUT_METHOD_SERVICE);
imm.hideSoftInputFromWindow(edit.getWindowToken(),0);