DialogService

适用平台:所有
功能说明:弹出专有钉钉样式的Dialog
线程说明:创建的dialog在执行show和hide时请务必保证在UI线程中执行,为此,建议使用
‒ DialogService.safeShow()
‒ DialogService.safeHide()

使用示例:

  1. DialogService service = MainBundle.getBundleContext().getService(DialogService.class);
  2. Dialog dialog = service.createDialogBuilder((Activity)jsRequest.context)
  3. .setMessage("hello, world!")
  4. .create(jsRequest.context);
  5. service.safeShow((Activity)jsRequest.context, dialog);