Android View Animations这个项目收集了各种有趣的动画效果。所有效果:AttensionFlash,Pulse,RubberBand,Shake,Swing,Wobble,Bounce,Tada,StandUp,WaveSpecialHinge,RollIn,RollOut,La...
分类:
移动开发 时间:
2014-09-19 19:07:25
阅读次数:
243
做过一个小项目,其中实现了摇一摇功能和刮一刮功能还有播放背景音乐等
摇一摇功能主要用到加速度传感器:Sensor.TYPE_ACCELEROMETER
摇一摇功能主要是监听手机加速度变化,当超过设定的某一值时,即触发事件。
/**
* FileName: MainActivity.java
* @desc 该类是用于显示摇一摇界面
* @author HTP...
分类:
移动开发 时间:
2014-08-24 12:57:42
阅读次数:
242
问题描述:The doggie found a bone in an ancient maze, which fascinated him a lot. However, when he picked it up, the maze began to shake, and the doggie co...
分类:
其他好文 时间:
2014-08-09 15:49:08
阅读次数:
292
大家好,又到了随机文章的时间,请使用手机打开演示站点,然后像摇妹子一样摇晃手机,你会发现非常牛逼的事情,炫酷吧。该功能已经集成在Oconnor1.8中。本文主要讲解这货的原理。首先需要下载shake.js,shake.js github地址,我们只需要里面的shake.js,然后引入。添加“摇一摇”...
分类:
Web程序 时间:
2014-07-31 20:25:07
阅读次数:
2826
var SHAKE_THRESHOLD = 800;//摇动强度var lastUpdate = 0;var x, y, z, last_x, last_y, last_z;var canshake = false;function deviceMotionHandler(eventData) { ...
分类:
移动开发 时间:
2014-07-23 12:51:46
阅读次数:
260
Problem Description
The doggie found a bone in an ancient maze, which fascinated him a lot. However, when he picked it up, the maze began to shake, and the doggie could feel the ground sinking. He ...
分类:
其他好文 时间:
2014-07-18 22:25:05
阅读次数:
246
实现效果:整理思路:1、控件:文字TextView和 右箭头ImageView2、因为考虑到点击效果,设计为:最外层为全圆角,内层有四种情况,分别为上圆角、无圆角、下圆角和全圆角。3、内层样式效果:需要初始样式、和点击样式4、需要知识:结合style、shake、selector组合样式布局: 1 ...
分类:
移动开发 时间:
2014-07-11 18:11:50
阅读次数:
244
给按钮做抖动效果,可以这样做,建立anim文件夹在res下面,创建一个button_shake.xml
<rotate xmlns:android="http://schemas.android.com/apk/res/android"
android:duration="120"
android:fromDegrees="-3"
android:pivotX="100...
分类:
移动开发 时间:
2014-07-10 22:47:01
阅读次数:
319
介绍EditText颤抖的动画效果
Animation1.java
/*
* Copyright (C) 2007 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except...
分类:
其他好文 时间:
2014-05-15 18:12:00
阅读次数:
345
摇头效果类似与wordpress登录失败后登录框可爱的左右晃动效果// 2011-07-17
更新artDialog.fn.shake = function (){ var style = this.DOM.wrap[0].style, p = [4,
8, 4, 0, -4, ...
分类:
Web程序 时间:
2014-04-29 16:37:46
阅读次数:
725