mirror of
https://github.com/bggRGjQaUbCoE/PiliPlus.git
synced 2026-04-20 11:08:03 +08:00
17 lines
442 B
Dart
17 lines
442 B
Dart
import 'dart:ui' show Color;
|
|
|
|
import 'package:canvas_danmaku/models/danmaku_content_item.dart'
|
|
show DanmakuItemType;
|
|
|
|
abstract class DmUtils {
|
|
static Color decimalToColor(int decimalColor) =>
|
|
Color(decimalColor | 0xFF000000);
|
|
|
|
static DanmakuItemType getPosition(int mode) => switch (mode) {
|
|
4 => DanmakuItemType.bottom,
|
|
5 => DanmakuItemType.top,
|
|
7 => DanmakuItemType.special,
|
|
_ => DanmakuItemType.scroll,
|
|
};
|
|
}
|