共 9 篇文章 |
|
阅129 转1 评0 公众公开 17-02-10 11:16 |
#ifdef LOG_TAG#undef LOG_TAG#endif#define LOG_TAG "testCallback"class MySetupCallback : public BBinder{public:MySetupCallback(){mydescriptor = String16("android.os.ISetupCallback");}protected:virtual status_t onTransact( uint32_t code, const Parcel& data, Parcel* reply, uint32_t flags = 0){LOGD... 阅83 转0 评0 公众公开 16-12-28 17:02 |
Android Studio 创建 Android Library.然而 Android library 可以被编译成 AAR(Android Archive) 文件被 Android 应用模块 依赖,却不能被编译成APK在设备上运行。库模块(library module)在下列情况下有用:当你添加库到一个应用模块,库的 ProGuard 文件将被追加到应用模块的 ProGuard 配置文件中(proguard.txt)。当 Android 应用模块运行 ProG... 阅917 转0 评0 公众公开 16-11-30 14:22 |
在Android的NDK中使用jsoncpp在Android的NDK中使用jsoncpp(2015-04-13 08:58:16)转载▼。 阅845 转4 评0 公众公开 16-10-24 13:45 |
ImageBtn 8 android:id="@+id/btn_right" 9 android:layout_height="wrap_content" 10 android:layout_width="wrap_content"11 android:background="@drawable/btn" 12 />13 14 <cn.com.karl.view.ImageBtn15 android:id="@+id/btn_error"16 android:layout_marginLeft="5dp&quo... 阅8 转自天海544 公众公开 15-06-09 14:41 |
Android 中屏幕点击事件的实现。在android下,事件的发生是在监听器下进行,android系统可以响应按键事件和触摸屏事件,事件说明如下:import android.view.在Android中,onClick、onLongClick的触发是和ACTION_DOWN及ACTION_UP相关的,在时序上,如果我们在一个View中同时覆写了onClick、onLongClick及onTouchEvent的话,onTouchEvent是最先捕... 阅3287 转3 评0 公众公开 14-11-08 20:24 |
Activity的两种启动模式:FLAG_ACTIVITY_CLEAR_TOP和FLAG_ACTIVITY_REORDER_TO_FRONT.在D Activity里,我们要跳到B Activity,同时希望C finish掉,可以在startActivity(intent)里的intent里添加flags标记,如下所示:Java代码 Intent intent = new Intent(this, B.class); intent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP); startAct... 阅585 转2 评0 公众公开 13-04-12 17:56 |
Android开发小技巧总结Android开发小技巧总结。Intent intent = new Intent("android.media.action.IMAGE_CAPTURE");protected void onActivityResult(int requestCode, int resultCode, Intent data) {public Bitmap zoomImage(Bitmap bgimage, int newWidth, int newHeight) {> arg0, View arg1, int arg2,long arg3) {public V... 阅150 转0 评0 公众公开 13-03-15 11:23 |