我很难设法在屏幕上叠加位图.我也可以获得触摸输入,但它可以在屏幕上获得每个地方的触摸输入.
我想知道我怎么能检查触摸是否在我的位图上,这在屏幕上是可见的.
服务和视图类如下.我有想过和想过,但我想不出办法:(
package <package>;
import android.app.NotificationManager;
import android.app.PendingIntent;
import android.app.Service;
import android.content.Context;
import android.content.Intent;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.graphics.Canvas;
import android.graphics.Color;
import android.graphics.Paint;
import android.graphics.PixelFormat;
import android.graphics.Rect;
import android.os.IBinder;
import android.support.v4.app.NotificationCompat;
import android.view.Gravity;
import android.view.MotionEvent;
import android.view.ViewGroup;
import android.view.WindowManager;
import android.widget.Toast;
public class MyService extends Service {
ButtonView mView;
Bitmap bit;
@Override
public IBinder onBind(Intent intent) {
return null;
}
@Override
public void onCreate() {
super.onCreate();
bit = BitmapFactory.decodeResource(getResources(), R.drawable.button);
NotificationCompat.Builder builder = new NotificationCompat.Builder(
this);
builder.setContentTitle("Ingress Tools …
Run Code Online (Sandbox Code Playgroud) 我已经下载了java jdk和android sdk安装程序,但是当我运行android sdk安装程序时,它工作正常,直到它检查java jdk的屏幕.
它开始没有响应,然后在大约15秒后,弹出一个崩溃消息.
有什么帮助解决这个问题?
我有2个数组:
$array1 = array(1 => '12', 2 => '4', 3 => '54');
$array2 = array(1 => '12', 2 => '4', 3 => '54', 4 => '124');
Run Code Online (Sandbox Code Playgroud)
我将如何制作$array2
具有相同数量的键$array1
,并在最后删除任何键.
所以,我最终会:
$array2 = array(1 => '12', 2 => '4', 3 => '54');
Run Code Online (Sandbox Code Playgroud)
意识到第一个数组可能包含不同数量的键.
我最近不得不重新安装我的操作系统 - 一个完整的安装.
我复制了我的eclipse工作区文件夹,以保留所有数据.
当我再次设置所有设置时,7个项目中有2个项目上有红色感叹号.
为什么是这样?我已经检查了我所知道的所有构建路径,并且我没有发现任何错误,并且实际代码中没有错误 - 所以问题是什么?
我是一名应用程序开发人员,最近我不得不重新安装Windows,所以我丢失了所有应用程序数据:(
我有市场上的应用程序,所以可以获得APK,但我的问题是:
我可以将它们反编译回日食,还是我必须从头开始重新制作它们?
谢谢你的回答,利亚姆
所以,制作一个应用程序.我添加了大量新代码,现在它已经打开了FC :(
这是logcat:
07-25 16:59:12.490: D/AndroidRuntime(26121): Shutting down VM
07-25 16:59:12.495: W/dalvikvm(26121): threadid=1: thread exiting with uncaught exception (group=0x40a641f8)
07-25 16:59:12.495: E/AndroidRuntime(26121): FATAL EXCEPTION: main
07-25 16:59:12.495: E/AndroidRuntime(26121): java.lang.RuntimeException: Unable to instantiate activity ComponentInfo{com.liamwli.smsbusy/com.liamwli.smsbusy.Sms_busyActivity}: java.lang.NullPointerException
07-25 16:59:12.495: E/AndroidRuntime(26121): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1993)
07-25 16:59:12.495: E/AndroidRuntime(26121): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2104)
07-25 16:59:12.495: E/AndroidRuntime(26121): at android.app.ActivityThread.access$600(ActivityThread.java:132)
07-25 16:59:12.495: E/AndroidRuntime(26121): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1157)
07-25 16:59:12.495: E/AndroidRuntime(26121): at android.os.Handler.dispatchMessage(Handler.java:99)
07-25 16:59:12.495: E/AndroidRuntime(26121): at android.os.Looper.loop(Looper.java:137)
07-25 16:59:12.495: E/AndroidRuntime(26121): at android.app.ActivityThread.main(ActivityThread.java:4575)
07-25 16:59:12.495: E/AndroidRuntime(26121): at java.lang.reflect.Method.invokeNative(Native Method)
07-25 16:59:12.495: E/AndroidRuntime(26121): at …
Run Code Online (Sandbox Code Playgroud) 这是logcat.有人可以告诉我为什么会这样吗:
07-29 18:20:44.109: D/AndroidRuntime(8836): Shutting down VM
07-29 18:20:44.109: W/dalvikvm(8836): threadid=1: thread exiting with uncaught exception (group=0x41443300)
07-29 18:20:44.109: E/AndroidRuntime(8836): FATAL EXCEPTION: main
07-29 18:20:44.109: E/AndroidRuntime(8836): java.lang.RuntimeException: Unable to instantiate activity ComponentInfo{com.liamwli.parent.trap/com.liamwli.parent.trap.ParentTrap}: java.lang.ClassCastException: com.liamwli.parent.trap.ParentTrap cannot be cast to android.app.Activity
07-29 18:20:44.109: E/AndroidRuntime(8836): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2096)
07-29 18:20:44.109: E/AndroidRuntime(8836): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2207)
07-29 18:20:44.109: E/AndroidRuntime(8836): at android.app.ActivityThread.access$600(ActivityThread.java:139)
07-29 18:20:44.109: E/AndroidRuntime(8836): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1205)
07-29 18:20:44.109: E/AndroidRuntime(8836): at android.os.Handler.dispatchMessage(Handler.java:99)
07-29 18:20:44.109: E/AndroidRuntime(8836): at android.os.Looper.loop(Looper.java:137)
07-29 18:20:44.109: E/AndroidRuntime(8836): at android.app.ActivityThread.main(ActivityThread.java:4896)
07-29 18:20:44.109: E/AndroidRuntime(8836): at java.lang.reflect.Method.invokeNative(Native Method) …
Run Code Online (Sandbox Code Playgroud) 这是不起作用的代码,当我尝试在浏览器中查看此页面(chrome)时,我收到500内部错误.有人可以帮忙吗?
<?php
$user = $_POST["user"];
$pass = $_POST["pass"];
$name = someuser;
$passw = somepassword;
if (!isset($_POST['login_button'])) {
} else {
if (&user == $name) {
if ($pass == $passw) {
setcookie('liamblogprox', 'hi', );
header.location('http://liamwli.co.uk/proxy/proxy.php');
} else {
echo "Invalid User or Pass!"; }
}else {
echo "Invalid User or Pass!"; }
}
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<link rel="stylesheet" type="text/css" href="style2.css" media="screen,projection" />
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta name="generator" content="GiffHost - …
Run Code Online (Sandbox Code Playgroud)