小编Bay*_*ter的帖子

OnClick的蓝色叠加

当我在Android WebView中显示一个html页面时,点击的元素上总是有一个蓝色的叠加层,它有一个挂钩的href或javascript函数.如何摆脱这种蓝色叠加?

在此输入图像描述

源代码

<html>
    <head>
    <title>Blue Overlay</title>
    <style>
    *{margin:0;padding:0;/* get rid of the default 2 pixels margin */
    } 
    body{background-color: #000000;}

    /* button-related CSS */
    a.button{
        background: url("img/icon_bt.png") no-repeat scroll center center transparent;
        display: block;
        text-decoration: none;/*remove the blue underline*/
        width: 70px;
        height: 70px;
        margin: 50px;
    }
    a.button:active{
        background-image: url("img/icon_bt_pressed.png");
    }

    </style>
</head>
<body>
    <a class="button" href="#"></a>
    </body>
</html> 
Run Code Online (Sandbox Code Playgroud)

javascript html5 android webview

9
推荐指数
1
解决办法
3898
查看次数

标签 统计

android ×1

html5 ×1

javascript ×1

webview ×1