renaming to Thermion
This commit is contained in:
@@ -0,0 +1,35 @@
|
||||
import 'dart:async';
|
||||
|
||||
import 'package:thermion_dart/thermion_dart/abstract_filament_viewer.dart';
|
||||
import 'package:plugin_platform_interface/plugin_platform_interface.dart';
|
||||
import 'thermion_flutter_texture.dart';
|
||||
|
||||
abstract class ThermionFlutterPlatform extends PlatformInterface {
|
||||
ThermionFlutterPlatform() : super(token: _token);
|
||||
|
||||
static final Object _token = Object();
|
||||
|
||||
static late ThermionFlutterPlatform _instance;
|
||||
|
||||
static ThermionFlutterPlatform get instance => _instance;
|
||||
|
||||
static set instance(ThermionFlutterPlatform instance) {
|
||||
PlatformInterface.verifyToken(instance, _token);
|
||||
_instance = instance;
|
||||
}
|
||||
|
||||
AbstractFilamentViewer get viewer;
|
||||
|
||||
Future initialize({String? uberArchivePath});
|
||||
|
||||
Future<ThermionFlutterTexture?> createTexture(
|
||||
int width, int height, int offsetLeft, int offsetRight);
|
||||
|
||||
Future destroyTexture(ThermionFlutterTexture texture);
|
||||
|
||||
@override
|
||||
Future<ThermionFlutterTexture?> resizeTexture(ThermionFlutterTexture texture,
|
||||
int width, int height, int offsetLeft, int offsetRight);
|
||||
|
||||
void dispose();
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
class ThermionFlutterTexture {
|
||||
final int width;
|
||||
final int height;
|
||||
final int? flutterTextureId;
|
||||
final int? hardwareTextureId;
|
||||
final int? surfaceAddress;
|
||||
bool get usesBackingWindow => flutterTextureId == null;
|
||||
|
||||
ThermionFlutterTexture(this.flutterTextureId, this.hardwareTextureId,
|
||||
this.width, this.height, this.surfaceAddress) {
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
name: thermion_flutter_platform_interface
|
||||
description: A common platform interface for the thermion_flutter plugin.
|
||||
repository: https://github.com/nmfisher/thermion_flutter/thermion_flutter
|
||||
version: 0.0.1
|
||||
|
||||
environment:
|
||||
sdk: ">=3.3.0 <4.0.0"
|
||||
flutter: ">=3.0.0"
|
||||
|
||||
dependencies:
|
||||
flutter:
|
||||
sdk: flutter
|
||||
plugin_platform_interface: ^2.1.0
|
||||
thermion_dart:
|
||||
path: ../../thermion_dart
|
||||
|
||||
dev_dependencies:
|
||||
flutter_test:
|
||||
sdk: flutter
|
||||
mockito: ^5.0.0
|
||||
Reference in New Issue
Block a user