Intent简介
Android基本的设计理念是鼓励减少组件间的耦合,因此Android提供了Intent (意图) ,Intent提供了一种通用的消息系统,它允许在你的应用程序与其它的应用程序间传递Intent来执行动作和产生事件。使用Intent可以激活Android应用的三个核心组件:活动、服务和广播接收器。
在一个Activity中可以使用系统提供的startActi...
分类:
其他好文 时间:
2014-06-05 12:35:54
阅读次数:
356
一、Activity的使用:package com.example.activity;
import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;
import androi...
分类:
移动开发 时间:
2014-06-05 09:36:01
阅读次数:
276
通过intent调用打电话,打开地图、打开浏览器,创建邮件,创建事件的操作
截图:
代码
package com.example.hellointent;
import java.util.Calendar;
import java.util.List;
import org.apache.http.protocol.HTTP;
import android.net.Uri;
...
分类:
其他好文 时间:
2014-06-05 08:01:16
阅读次数:
281
由于需求,要实现在应用中实现分享文字+图片到微信朋友圈。在网上找了一些资料,总结如下:
思路
1.使用android的intent实现应用程序之间的通信,将信息通过intent传递给微信(文章后面资源链接中有案例)。这种方式的局限性在于
a.只能发送图片,而不是(文字或者图片+文字)。
b.设备必须安装微信才能实现分享。
2.使用微信的官方sdk包,实现发...
分类:
微信 时间:
2014-06-05 07:56:45
阅读次数:
485
??
IntentService is a base class for Services
that handle asynchronous requests (expressed as Intents)
on demand. Clients send requests through startService(Intent) calls;
the service is starte...
分类:
其他好文 时间:
2014-06-05 03:03:46
阅读次数:
262
网上好多说法 但实际上说到点上的没有 不想写太长 直接进入正题Intent intent =
new
Intent(Intent.ACTION_VIEW);intent.addCategory(Intent.CATEGORY_DEFAULT);intent.setDataAndType(Uri.fr...
分类:
移动开发 时间:
2014-05-31 12:42:34
阅读次数:
283
1、import java.util.List;import
android.os.Parcel;import android.os.Parcelable;/** * 1)writeToParcel
方法。该方法将类的数据写入外部提供的Parcel中。 * 2)describeContents方法。...
分类:
移动开发 时间:
2014-05-31 01:43:27
阅读次数:
531
使用内置的Camera应用程序捕获图像
所有带有合适硬件(摄像头)的原版Android设备都会附带Camera应用程序。Camera应用程序包含一个意图过滤器(intent
filter),它使得开发人员能够提供与Camera应用程序同等的图像捕获能力,而不必构建他们自己的定制捕获例程。Camera...
分类:
移动开发 时间:
2014-05-30 00:12:48
阅读次数:
272
Android主要有四大主要组件组成:Activity、ContentProvider、Service、Intent组成。Android文件的运行主要需要读写四大组件的文件。本文将介绍如何读写Android文件,希望对正在进行Android开发的朋友有所帮助。
文件存放位置 在Android中文.....
分类:
移动开发 时间:
2014-05-29 16:31:00
阅读次数:
337
intent大全:1.从google搜索内容Intent intent = new
Intent();intent.setAction(Intent.ACTION_WEB_SEARCH);intent.putExtra(SearchManager.QUERY,"searchString")start...
分类:
移动开发 时间:
2014-05-29 15:41:29
阅读次数:
430