Android物联网应用程序开发(智慧城市)—— 摄像头监控界面开发「建议收藏」

Android物联网应用程序开发(智慧城市)—— 摄像头监控界面开发「建议收藏」效果:布局代码:<?xmlversion=”1.0″encoding=”utf-8″?><RelativeLayoutxmlns:android=”http://schemas.android.com/apk/res/android”xmlns:app=”http://schemas.android.com/apk/res-auto”xmlns:tools=”http://schemas.android.com/tools”android

大家好,又见面了,我是你们的朋友全栈君。

效果:

Android物联网应用程序开发(智慧城市)—— 摄像头监控界面开发「建议收藏」

布局代码:

<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="fill_parent"
    android:layout_height="fill_parent"
    tools:context=".CameraMonitoring">
    <!--视频监视文字图片-->
    <ImageView
        android:id="@+id/imageView1"
        android:layout_width="20dp"
        android:layout_height="70dp"
        android:layout_marginLeft="20dp"
        android:layout_marginTop="30dp"
        android:src="@drawable/bg_environment"/>
    <!--总体布局-->
    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:background="@drawable/bg_environment"
        android:padding="30dp"
        android:layout_marginTop="20dp"
        android:layout_marginRight="20dp"
        android:layout_marginBottom="20dp"
        android:layout_toRightOf="@+id/imageView1"
        android:orientation="horizontal">
        <!--两个线性布局管理器中的左边一个-->
        <LinearLayout
            android:layout_width="0.0dp"
            android:layout_height="fill_parent"
            android:layout_weight="2">
            <!--WebView控件-->
            <WebView
                android:id="@+id/webView1"
                android:layout_width="match_parent"
                android:layout_height="match_parent">
            </WebView>
        </LinearLayout>
        <!--两个线性布局管理器中的右边一个-->
        <LinearLayout
            android:layout_width="0.0dp"
            android:layout_height="fill_parent"
            android:layout_weight="1"
            android:orientation="vertical"
            android:gravity="center">
            <!--相对布局管理器,添加4个ImageView控制上下左右-->
            <RelativeLayout
                android:layout_width="150dp"
                android:layout_height="150dp"
                android:background="@drawable/btn__presss_bg">
                <!--右-->
                <ImageView
                    android:layout_width="32dp"
                    android:layout_height="32dp"
                    android:layout_alignParentLeft="true"
                    android:layout_centerVertical="true"
                    android:layout_marginLeft="10dp"
                    android:src="@drawable/btn_left_direction"/>
                <!--下-->
                <ImageView
                    android:layout_width="32dp"
                    android:layout_height="32dp"
                    android:layout_alignParentBottom="true"
                    android:layout_centerHorizontal="true"
                    android:layout_marginBottom="10dp"
                    android:src="@drawable/btn_down_presss"/>
                <!--上-->
                <ImageView
                    android:layout_width="32dp"
                    android:layout_height="32dp"
                    android:layout_alignParentTop="true"
                    android:layout_centerHorizontal="true"
                    android:layout_marginTop="10dp"
                    android:src="@drawable/btn_up_press"/>
                <!--左-->
                <ImageView
                    android:layout_width="32dp"
                    android:layout_height="32dp"
                    android:layout_alignParentRight="true"
                    android:layout_centerVertical="true"
                    android:layout_marginRight="10dp"
                    android:src="@drawable/btn_right_presss"/>
            </RelativeLayout>
            <!--拍照按钮-->
            <Button
                android:layout_width="wrap_content"
                android:layout_height="35dp"
                android:background="@color/red"
                android:textColor="@color/white"
                android:layout_marginTop="20dp"
                android:text="拍照"/>
        </LinearLayout>
    </LinearLayout>
</RelativeLayout>

 

版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请联系我们举报,一经查实,本站将立刻删除。

发布者:全栈程序员-站长,转载请注明出处:https://javaforall.net/150457.html原文链接:https://javaforall.net

(0)
全栈程序员-站长的头像全栈程序员-站长


相关推荐

  • ubuntu clion激活码【2021.8最新】[通俗易懂]

    (ubuntu clion激活码)这是一篇idea技术相关文章,由全栈君为大家提供,主要知识点是关于2021JetBrains全家桶永久激活码的内容IntelliJ2021最新激活注册码,破解教程可免费永久激活,亲测有效,下面是详细链接哦~https://javaforall.net/100143.html1STL5S9V8F-eyJsa…

    2022年3月27日
    115
  • Android项目ViewPager+Fragment的基本使用[通俗易懂]

    Android项目ViewPager+Fragment的基本使用[通俗易懂]Android项目ViewPager+Fragment的简单使用

    2022年7月22日
    12
  • 十折交叉验证 matlab,Matlab 十折交叉验证

    十折交叉验证 matlab,Matlab 十折交叉验证十折交叉验证(1)英文名叫做10-foldcross-validation,用来测试算法准确性,是常用的测试方法。(2)将数据集分成十份,轮流将其中9份作为训练数据,1份作为测试数据,进行试验。每次试验都会得出相应的正确率(或差错率)。(3)10次的结果的正确率(或差错率)的平均值作为对算法精度的估计,一般还需要进行多次10折交叉验证(例如10次10折交叉验证),再求其均值,作为对算法准确性的估…

    2025年8月11日
    2
  • javascript Date format(js日期格式化)

    javascript Date format(js日期格式化)这个很不错,好像是csdn的Meizz写的://对Date的扩展,将Date转化为指定格式的String//月(M)、日(d)、小时(h)、分(m)、秒(s)、季度(q)可以用1-2个占位符,//年(y)可以用1-4个占位符,毫秒(S)只能用1个占位符(是1-3位的数字)//例子://(newDate()).Format(“yyyy-MM-ddhh:mm:ss.S”)==>2006-07-0208:09:04.423//(newDate())

    2022年4月30日
    38
  • Redis集群搭建(非常详细)

    Redis集群搭建(非常详细)https blog csdn net article details redis 集群搭建在开始 redis 集群搭建之前 我们先简单回顾一下 redis 单机版的搭建过程 下载 redis 压缩包 然后解压压缩文件 进入到解压缩后的 redis 文件目录 此时可以看到 Makefile 文件 编译 redis 源文件 把编译好的 redis 源文件安装到 usr local redis 目录下 如果 local 目录下没有 redis 目录 会自动新建 r

    2025年10月28日
    3
  • vim 经典插件大全 转自:http://blog.csdn.net/tge7618291「建议收藏」

    vim 经典插件大全 转自:http://blog.csdn.net/tge7618291「建议收藏」1#============================================================================= 21.查看key相关信息说明的命令 :helpkeycodes 3#========================================================================

    2022年5月30日
    42

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注

关注全栈程序员社区公众号