Code Monkey home page Code Monkey logo

matdialog's Introduction

MatDialog

Maven

Material Design Dialog README on GitHub

示范 Demo

Demo.apk

效果图 Preview

Review Review

使用说明 Usage

  • 添加依赖
compile 'cn.byk.pandora:matdialog:1.2'
MatDialog.with(this)
         .title("Hello")
         .content("Life is...")
         .show();
  • 通用方法说明
MatDialog.Builder
方法名 说明
title() 标题
content() 内容
detailTxt() 内容末尾的跳转链接,网址格式默认直接跳转
icon() 标题左边的图标
positiveTxt() 确定按钮文字
neutralTxt() 中立按钮文字
negativeTxt() 取消按钮文字
heightWeight() 对话框高度屏占权重
themeColor() 主体颜色设置
hideTop() 隐藏头部标题栏
hideBottom() 隐藏底部按钮栏
autoDismiss() 点击按钮后自动关闭对话框
cancelable() 按后退键是否退出
cancelOnTouchOutside() 点击对话框外围是否退出
cancelWithParent() 按后退键,相应的页面是否一起退出(主要用于强制加载进度框)
ableProgressMode() 加载进度框模式
show() 显示对话框
customView(View) 自定义内容View
setOnBtnClickListener(BtnClickCallback) 自定义按钮事件
  • BtnClickCallback自定义按钮事件说明
MatDialog.BtnClickCallback
方法名 说明
onClick() 任何按钮事件都会触发
onPositive() 确定按钮事件
onNeutral() 中立按钮事件
onNegative() 取消按钮事件
onDetailLink() 内容末尾的跳转链接点击事件
onPreClose() 对话框关闭时触发

联系方式 Support or Contact

matdialog's People

Contributors

bluesofy avatar blueyuki avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.