Move editor UI into the app and release verified Core dependencies (#14)
Gitea CI / Assemble and validate CI artifacts (push) Successful in 1m47s
Gitea CI / Check code and tests (push) Successful in 7m15s
Gitea CI / Build Android APK (push) Successful in 4m6s
Gitea CI / Build Windows x64 app (push) Successful in 3m34s
Gitea CI / Audit and package Windows x64 (push) Successful in 1m29s
Gitea CI / Gitea CI passed (push) Successful in 1s
Gitea Release / Prepare draft Release (push) Failing after 8s
Gitea Release / Upload Android to draft Release (push) Skipped
Gitea Release / Upload Windows to draft Release (push) Skipped
Gitea Release / Verify and publish Release (push) Skipped
Gitea CI / Assemble and validate CI artifacts (push) Successful in 1m47s
Gitea CI / Check code and tests (push) Successful in 7m15s
Gitea CI / Build Android APK (push) Successful in 4m6s
Gitea CI / Build Windows x64 app (push) Successful in 3m34s
Gitea CI / Audit and package Windows x64 (push) Successful in 1m29s
Gitea CI / Gitea CI passed (push) Successful in 1s
Gitea Release / Prepare draft Release (push) Failing after 8s
Gitea Release / Upload Android to draft Release (push) Skipped
Gitea Release / Upload Windows to draft Release (push) Skipped
Gitea Release / Verify and publish Release (push) Skipped
This commit was merged in pull request #14.
This commit is contained in:
1 parent
abc1868550
commit
06f1c26681
452 files changed
+43806
-2329
No files matched your search
@@ -6,11 +6,11 @@ import 'dart:async';
|
||||
|
||||
import 'package:cutdex/features/properties/canvas_presets.dart';
|
||||
import 'package:cutdex/l10n/l10n.dart';
|
||||
import 'package:cutdex_sdk/editor.dart';
|
||||
import 'package:cutdex_sdk/preview.dart';
|
||||
import 'package:cutdex_sdk/project.dart';
|
||||
import 'package:cutdex_sdk/runtime.dart';
|
||||
import 'package:cutdex_sdk/timeline/model.dart';
|
||||
import 'package:cutdex_core/editor.dart';
|
||||
import 'package:cutdex_preview/cutdex_preview.dart';
|
||||
import 'package:cutdex_core/project.dart';
|
||||
import 'package:cutdex_native_flutter/cutdex_native_flutter.dart';
|
||||
import 'package:cutdex_core/timeline/model.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:flutter_riverpod/flutter_riverpod.dart';
|
||||
@@ -228,6 +228,8 @@ class _EditorPreviewContent extends ConsumerWidget {
|
||||
select: () => (
|
||||
activeController.positionTick,
|
||||
activeController.selectedVisualIds.isNotEmpty,
|
||||
activeController.distortionEditingElement,
|
||||
activeController.distortionPerspective,
|
||||
activeController.maskEditingElement,
|
||||
activeController.obscureEditingElement,
|
||||
),
|
||||
@@ -621,6 +623,22 @@ class _PreviewToolbar extends StatelessWidget {
|
||||
final PreviewController? controller;
|
||||
final SourcePreviewController? source;
|
||||
|
||||
ButtonStyle? _compactButtonStyle(BuildContext context) =>
|
||||
AppTheme.isDesktop(context)
|
||||
? IconButton.styleFrom(
|
||||
fixedSize: const Size.square(AppInspectorMetrics.action),
|
||||
minimumSize: const Size.square(AppInspectorMetrics.action),
|
||||
maximumSize: const Size.square(AppInspectorMetrics.action),
|
||||
padding: EdgeInsets.zero,
|
||||
tapTargetSize: MaterialTapTargetSize.shrinkWrap,
|
||||
shape: const RoundedRectangleBorder(
|
||||
borderRadius: BorderRadius.all(
|
||||
Radius.circular(AppInspectorMetrics.radius),
|
||||
),
|
||||
),
|
||||
)
|
||||
: null;
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
if (PreviewFullscreenScope.of(context)?.fullscreen == true) {
|
||||
@@ -661,7 +679,7 @@ class _PreviewToolbar extends StatelessWidget {
|
||||
try {
|
||||
final time = CommandTime(tick, TimelineClock.ticksPerSecond);
|
||||
if (source case final source?) {
|
||||
await source.control(SourcePreviewAction.seek, at: time);
|
||||
await source.seekInteractive(tick);
|
||||
} else if (preview?.activeSequence() case final sequence?) {
|
||||
await preview!.controlPreview(sequence, PreviewAction.seek, at: time);
|
||||
}
|
||||
@@ -705,12 +723,25 @@ class _PreviewToolbar extends StatelessWidget {
|
||||
);
|
||||
},
|
||||
icon: Icon(direction < 0 ? AppIcons.previousFrame : AppIcons.nextFrame),
|
||||
style: _compactButtonStyle(context),
|
||||
),
|
||||
);
|
||||
|
||||
Widget _build(BuildContext context) {
|
||||
final preview = controller;
|
||||
final playing = source?.playing ?? preview?.playing ?? false;
|
||||
final timeTextStyle = AppTheme.isDesktop(context)
|
||||
? Theme.of(context).textTheme.bodyMedium?.copyWith(
|
||||
fontFamily: 'packages/cutdex_ui/Inter',
|
||||
fontSize: AppInspectorMetrics.fontSize,
|
||||
height:
|
||||
AppInspectorMetrics.lineHeight / AppInspectorMetrics.fontSize,
|
||||
fontVariations: const [FontVariation('wght', 450)],
|
||||
letterSpacing: AppInspectorMetrics.fontSize * .005,
|
||||
fontFeatures: [const FontFeature.tabularFigures()],
|
||||
)
|
||||
: Theme.of(context).textTheme.bodySmall
|
||||
?.copyWith(fontFeatures: [const FontFeature.tabularFigures()]);
|
||||
final frameDuration =
|
||||
source?.frameDuration ??
|
||||
preview?.frameDuration ??
|
||||
@@ -762,7 +793,9 @@ class _PreviewToolbar extends StatelessWidget {
|
||||
? AppDesktopMetrics.playbackBar
|
||||
: AppControlSize.panelHeader,
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: AppSpacing.compact),
|
||||
padding: const EdgeInsets.symmetric(
|
||||
horizontal: AppInspectorMetrics.padding,
|
||||
),
|
||||
child: LayoutBuilder(
|
||||
builder: (context, constraints) {
|
||||
final controls = Row(
|
||||
@@ -803,13 +836,14 @@ class _PreviewToolbar extends StatelessWidget {
|
||||
),
|
||||
maxLines: 1,
|
||||
overflow: TextOverflow.ellipsis,
|
||||
style: Theme.of(context).textTheme.bodySmall?.copyWith(
|
||||
fontFeatures: [const FontFeature.tabularFigures()],
|
||||
),
|
||||
style: timeTextStyle,
|
||||
),
|
||||
),
|
||||
),
|
||||
if (AppTheme.isDesktop(context)) _frameButton(context, -1),
|
||||
if (AppTheme.isDesktop(context)) ...[
|
||||
const SizedBox(width: AppSpacing.small),
|
||||
_frameButton(context, -1),
|
||||
],
|
||||
ListenableSelector(
|
||||
listenable: source ?? preview,
|
||||
select: () => (
|
||||
@@ -826,10 +860,14 @@ class _PreviewToolbar extends StatelessWidget {
|
||||
? preview.togglePlayback
|
||||
: null,
|
||||
icon: Icon(playing ? AppIcons.pause : AppIcons.play),
|
||||
style: _compactButtonStyle(context),
|
||||
);
|
||||
},
|
||||
),
|
||||
if (AppTheme.isDesktop(context)) _frameButton(context, 1),
|
||||
if (AppTheme.isDesktop(context)) ...[
|
||||
_frameButton(context, 1),
|
||||
const SizedBox(width: AppSpacing.small),
|
||||
],
|
||||
Expanded(
|
||||
child: ListenableSelector(
|
||||
listenable: source ?? preview,
|
||||
@@ -854,8 +892,9 @@ class _PreviewToolbar extends StatelessWidget {
|
||||
tooltip: context.l10n.retryPreview,
|
||||
onPressed: preview.busy ? null : preview.retry,
|
||||
icon: const Icon(AppIcons.refresh),
|
||||
style: _compactButtonStyle(context),
|
||||
),
|
||||
const SizedBox(width: AppSpacing.gap),
|
||||
const SizedBox(width: AppSpacing.small),
|
||||
],
|
||||
if (source == null &&
|
||||
PreviewFullscreenScope.of(context)?.fullscreen !=
|
||||
@@ -865,6 +904,25 @@ class _PreviewToolbar extends StatelessWidget {
|
||||
emptyLabel: context.l10n.noMatchingOptions,
|
||||
label: context.l10n.canvasRatio,
|
||||
outlined: false,
|
||||
controlHeight: AppTheme.isDesktop(context)
|
||||
? AppInspectorMetrics.input
|
||||
: null,
|
||||
textStyle: AppTheme.isDesktop(context)
|
||||
? Theme.of(
|
||||
context,
|
||||
).textTheme.bodyMedium?.copyWith(
|
||||
fontFamily: 'packages/cutdex_ui/Inter',
|
||||
fontSize: AppInspectorMetrics.fontSize,
|
||||
height:
|
||||
AppInspectorMetrics.lineHeight /
|
||||
AppInspectorMetrics.fontSize,
|
||||
fontVariations: const [
|
||||
FontVariation('wght', 450),
|
||||
],
|
||||
letterSpacing:
|
||||
AppInspectorMetrics.fontSize * .005,
|
||||
)
|
||||
: null,
|
||||
value:
|
||||
preview?.canvas ?? ProjectCanvas.widescreen,
|
||||
onChanged: preview?.setCanvas,
|
||||
@@ -894,6 +952,7 @@ class _PreviewToolbar extends StatelessWidget {
|
||||
? AppIcons.exitFullscreen
|
||||
: AppIcons.fullscreen,
|
||||
),
|
||||
style: _compactButtonStyle(context),
|
||||
),
|
||||
],
|
||||
),
|
||||
|
||||
Reference in new issue
Block a user