feat: initial Cutdex application
Add the Flutter video editing application with project management, media import, timeline editing, preview, AI assistance, diagnostics and settings. Include shared UI and native host packages, platform runners, application tests and release tooling. Provide usage and contribution guides, the MIT license and third-party notices. Exclude local credentials, build outputs and validation data.
This commit is contained in:
commit
27e77fff39
718 files changed
+183958
No files matched your search
@@ -0,0 +1,79 @@
|
||||
import 'package:cutdex/persistence/app_settings_repositories.dart';
|
||||
import 'package:cutdex/workspace/project_state.dart';
|
||||
import 'package:cutdex/workspace/persistence/recent_projects.dart';
|
||||
|
||||
class MemoryProjectLocationSettingsRepository
|
||||
implements ProjectLocationSettingsRepository {
|
||||
MemoryProjectLocationSettingsRepository([this.value]);
|
||||
|
||||
String? value;
|
||||
|
||||
@override
|
||||
Future<String?> load() async => value;
|
||||
|
||||
@override
|
||||
Future<void> save(String directory) async => value = directory;
|
||||
}
|
||||
|
||||
class MemoryResourceLocationSettingsRepository
|
||||
implements ResourceLocationSettingsRepository {
|
||||
MemoryResourceLocationSettingsRepository(this.value);
|
||||
|
||||
String? value;
|
||||
|
||||
@override
|
||||
Future<String?> load() async => value;
|
||||
|
||||
@override
|
||||
Future<void> save(String directory) async => value = directory;
|
||||
}
|
||||
|
||||
class MemoryMcpSettingsRepository implements McpSettingsRepository {
|
||||
McpSettingsValue? value;
|
||||
bool failWrites = false;
|
||||
|
||||
@override
|
||||
Future<McpSettingsValue?> load() async => value;
|
||||
|
||||
@override
|
||||
Future<void> save(McpSettingsValue configuration) async {
|
||||
if (failWrites) throw StateError('write failed');
|
||||
value = configuration;
|
||||
}
|
||||
}
|
||||
|
||||
class MemoryAppearanceSettingsRepository
|
||||
implements AppearanceSettingsRepository {
|
||||
AppAppearance value = AppAppearance.system;
|
||||
bool failWrites = false;
|
||||
|
||||
@override
|
||||
Future<AppAppearance> load() async => value;
|
||||
|
||||
@override
|
||||
Future<void> save(AppAppearance mode) async {
|
||||
if (failWrites) throw StateError('write failed');
|
||||
value = mode;
|
||||
}
|
||||
}
|
||||
|
||||
class MemoryRecentProjectsRepository implements RecentProjectsRepository {
|
||||
List<RecentProject> recent = [];
|
||||
final projects = <String, String>{};
|
||||
|
||||
@override
|
||||
Future<List<RecentProject>> load() async => List.of(recent);
|
||||
|
||||
@override
|
||||
Future<void> save(List<RecentProject> projects) async {
|
||||
recent = List.of(projects);
|
||||
}
|
||||
|
||||
@override
|
||||
Future<String?> lastTimeline(String projectId) async => projects[projectId];
|
||||
|
||||
@override
|
||||
Future<void> rememberTimeline(String projectId, String timelineId) async {
|
||||
projects[projectId] = timelineId;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user