登录
首页 » Android » activity之间的切换

activity之间的切换

于 2022-10-17 发布 文件大小:340.42 kB
0 155
下载积分: 2 下载次数: 1

代码说明:

这是一款适合新手学习和使用的代码,能让你轻松的在各个activity之间进行切换

下载说明:请别用迅雷下载,失败请重下,重下不扣分!

发表评论

0 个回复

  • android open gl 示例代码下载
    [实例简介]Open GL 入门级示例 [实例截图] [核心代码]package com.china.gltry;import javax.microedition.khronos.egl.EGL10;import javax.microedition.khronos.egl.EGL11;import javax.microedition.khronos.egl.EGLConfig;import javax.microedition.khronos.egl.EGLContext;import javax.microedition.khronos.egl.EGLDisplay;import javax.microedition.khronos.egl.EGLSurface;import javax.microedition.khronos.opengles.GL;import android.view.SurfaceHolder;/** * An EGL helper class. */public class EGLHelper{ public EGLHelper() { } /** * Initialize EGL for a given configuration spec. * @param configSpec */ public void start(int[] configSpec){ /* * Get an EGL instance */ mEgl = (EGL10) EGLContext.getEGL(); /* * Get to the default display. */ mEglDisplay = mEgl.eglGetDisplay(EGL10.EGL_DEFAULT_DISPLAY); /* * We can now initialize EGL for that display */ int[] version = new int[2]; mEgl.eglInitialize(mEglDisplay, version); EGLConfig[] configs = new EGLConfig[1]; int[] num_config = new int[1]; mEgl.eglChooseConfig(mEglDisplay, configSpec, configs, 1, num_config); mEglConfig = configs[0]; /* * Create an OpenGL ES context. This must be done only once, an * OpenGL context is a somewhat heavy object. */ mEglContext = mEgl.eglCreateContext(mEglDisplay, mEglConfig, EGL10.EGL_NO_CONTEXT, null); mEglSurface = null; } /* * Create and return an OpenGL surface */ public GL createSurface(SurfaceHolder holder) { /* * The window size has changed, so we need to create a new * surface. */ if (mEglSurface != null) { /* * Unbind and destroy the old EGL surface, if * there is one. */ mEgl.eglMakeCurrent(mEglDisplay, EGL10.EGL_NO_SURFACE, EGL10.EGL_NO_SURFACE, EGL10.EGL_NO_CONTEXT); mEgl.eglDestroySurface(mEglDisplay, mEglSurface); } /* * Create an EGL surface we can render into. */ mEglSurface = mEgl.eglCreateWindowSurface(mEglDisplay, mEglConfig, holder, null); /* * Before we can issue GL commands, we need to make sure * the context is current and bound to a surface. */ mEgl.eglMakeCurrent(mEglDisplay, mEglSurface, mEglSurface, mEglContext); GL gl = mEglContext.getGL(); return gl; } /** * Display the current render surface. * @return false if the context has been lost. */ public boolean swap() { mEgl.eglSwapBuffers(mEglDisplay, mEglSurface); /* * Always check for EGL_CONTEXT_LOST, which means the context * and all associated data were lost (For instance because * the device went to sleep). We need to sleep until we * get a new surface. */ return mEgl.eglGetError() != EGL11.EGL_CONTEXT_LOST; } public void finish() { if (mEglSurface != null) { mEgl.eglMakeCurrent(mEglDisplay, EGL10.EGL_NO_SURFACE, EGL10.EGL_NO_SURFACE, EGL10.EGL_NO_CONTEXT); mEgl.eglDestroySurface(mEglDisplay, mEglSurface); mEglSurface = null; } if (mEglContext != null) { mEgl.eglDestroyContext(mEglDisplay, mEglContext); mEglContext = null; } if (mEglDisplay != null) { mEgl.eglTerminate(mEglDisplay); mEglDisplay = null; } } EGL10 mEgl; EGLDisplay mEglDisplay; EGLSurface mEglSurface; EGLConfig mEglConfig; EGLContext mEglContext;}
    2015-04-06下载
    积分:1
  • A300 1.21开发文档+DEMO
    【实例简介】A300 1.21开发文档 DEMO android 平台连接 汉印移动式打印机 进行快递单等热敏打印操作app demo
    2022-01-10 00:31:47下载
    积分:1
  • Android的NDK随手记工程
    学习Android、NDK及JNI过程中写的一些DEMO,有需要的可以大概看下。包含Base64、MD5,以及Java的JNI代码实现。
    2022-11-04 12:50:03下载
    积分:1
  • 基于stm32f103c8t6 spi-flash
    基于stm32f103c8t6 spi-flash
    2021-05-06下载
    积分:1
  • 芳的源代码 1
    这个应用程序是有关 SMS 发送和接收应用程序,可以手动或自动控制的 sheudulled。
    2022-03-25 22:31:22下载
    积分:1
  • xmpp通信
    用于xmpp通信协议的  安卓客户端程序,便于开发者迅速使用,而且可以直接导入到eclipse中,非常方便,代码的质量很高
    2022-03-14 16:59:40下载
    积分:1
  • Viewpager 可自动滑动和手动滑动
    Viewpager 可自动滑动和手动滑动
    2013-08-19下载
    积分:1
  • 仿饿了么源码
    用apicloud模仿饿了么做的,这个APP页面比较简单,更多的是试用了APICloud的模块化开发, 滑动式的页面很容易就可以调用,还有定位时的baidulocation,都很方便, 其中有俩页面调用的是外链,所以确保联网了哈~
    2023-03-30 22:50:04下载
    积分:1
  • 视频验证
    登陆需要视频验证,这样比较安全,android平台结合云通讯音视频验证平台,正确即可通过,需要输入手机号码
    2022-03-05 18:49:14下载
    积分:1
  • src
    利用安卓中的MediaRecorder进行录音的源代码(Andrews in use MediaRecorder for recording the source code)
    2013-08-08 12:40:30下载
    积分:1
  • 696516资源总数
  • 106914会员总数
  • 0今日下载