isTablet static method

bool isTablet()

判断是否是平板尺寸(宽度大于等于600dp且小于1200dp)

返回结果: bool 是否为平板尺寸

示例:

if (DScreenUtil.isTablet()) print('当前设备为平板');

Implementation

static bool isTablet() {
  final width = Get.width;
  return width >= 600 && width < 1200;
}