174 MKV 화면이 맨 처음 화면이 아니어도 (홈 화면 = 탐색기 등) MKV 아이콘이 "지금 여기"
- 위쪽 아이콘 줄이 MKV 를 맨 처음 화면일 때만 알아봐, 홈 화면이 다른 화면인 사용자는 MKV 화면에서 아무것도 파랗지 않았다 - 다른 화면처럼 MKV 화면이 스스로 알린다 (AppNavButtons onMkvPage) - 시험: 다른 화면 위에 연 MKV 화면에서 MKV 아이콘이 지금 여기 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>묶음3
parent
746082db22
commit
cc05fcad3c
|
|
@ -98,13 +98,17 @@ class AppNavButtons extends StatelessWidget {
|
||||||
|
|
||||||
/// AI 그림 화면 자신 (123)
|
/// AI 그림 화면 자신 (123)
|
||||||
final bool onAiPage;
|
final bool onAiPage;
|
||||||
|
|
||||||
|
/// 174: MKV 화면 자신 - 홈 화면이 탐색기 등이면 MKV 화면이 맨 처음 화면이 아닐 수 있어 따로 알린다
|
||||||
|
final bool onMkvPage;
|
||||||
const AppNavButtons(
|
const AppNavButtons(
|
||||||
{super.key,
|
{super.key,
|
||||||
this.onDownloadsPage = false,
|
this.onDownloadsPage = false,
|
||||||
this.onBrowserPage = false,
|
this.onBrowserPage = false,
|
||||||
this.onExplorerPage = false,
|
this.onExplorerPage = false,
|
||||||
this.onRsyncPage = false,
|
this.onRsyncPage = false,
|
||||||
this.onAiPage = false});
|
this.onAiPage = false,
|
||||||
|
this.onMkvPage = false});
|
||||||
|
|
||||||
/// 버튼 줄의 가장 넓은 폭 (JJ · 화면 6개 · 뒤로)
|
/// 버튼 줄의 가장 넓은 폭 (JJ · 화면 6개 · 뒤로)
|
||||||
static const double width = 8 * 40;
|
static const double width = 8 * 40;
|
||||||
|
|
@ -214,7 +218,7 @@ class AppNavButtons extends StatelessWidget {
|
||||||
? 'rsync'
|
? 'rsync'
|
||||||
: onAiPage
|
: onAiPage
|
||||||
? 'aiimage'
|
? 'aiimage'
|
||||||
: atRoot
|
: onMkvPage || atRoot
|
||||||
? 'mkv'
|
? 'mkv'
|
||||||
: '';
|
: '';
|
||||||
final pages = scope == null ? const <AppComponent>[] : pagesOf(scope);
|
final pages = scope == null ? const <AppComponent>[] : pagesOf(scope);
|
||||||
|
|
|
||||||
|
|
@ -264,7 +264,7 @@ class _TopBar extends StatelessWidget {
|
||||||
VoidCallback? build0() =>
|
VoidCallback? build0() =>
|
||||||
!canBuild ? null : (batch.isEmpty ? () => _confirmBuildAll(context) : () => c.buildVideos(batch));
|
!canBuild ? null : (batch.isEmpty ? () => _confirmBuildAll(context) : () => c.buildVideos(batch));
|
||||||
return AppTopBar(
|
return AppTopBar(
|
||||||
nav: const AppNavButtons(),
|
nav: const AppNavButtons(onMkvPage: true),
|
||||||
actions: AppActions(c: c, onExit: onExit, showUsage: false),
|
actions: AppActions(c: c, onExit: onExit, showUsage: false),
|
||||||
middle: SingleChildScrollView(
|
middle: SingleChildScrollView(
|
||||||
scrollDirection: Axis.horizontal,
|
scrollDirection: Axis.horizontal,
|
||||||
|
|
@ -315,7 +315,7 @@ class _TopBar extends StatelessWidget {
|
||||||
|
|
||||||
return AppTopBar(
|
return AppTopBar(
|
||||||
// 모든 화면 공통: [JJ 홈] [MKV 화면] [뒤로] [다운로드 목록]
|
// 모든 화면 공통: [JJ 홈] [MKV 화면] [뒤로] [다운로드 목록]
|
||||||
nav: const AppNavButtons(),
|
nav: const AppNavButtons(onMkvPage: true),
|
||||||
// 화면 크기 · 환경 설정 · 종료: 모든 화면에서 같은 자리
|
// 화면 크기 · 환경 설정 · 종료: 모든 화면에서 같은 자리
|
||||||
actions: AppActions(c: c, onExit: onExit, showUsage: usage),
|
actions: AppActions(c: c, onExit: onExit, showUsage: usage),
|
||||||
middle: Row(
|
middle: Row(
|
||||||
|
|
|
||||||
|
|
@ -137,4 +137,23 @@ void main() {
|
||||||
expect(AppSettings().browserSwipeHinted, isFalse);
|
expect(AppSettings().browserSwipeHinted, isFalse);
|
||||||
expect(AppSettings.fromJson((AppSettings()..browserSwipeHinted = true).toJson()).browserSwipeHinted, isTrue);
|
expect(AppSettings.fromJson((AppSettings()..browserSwipeHinted = true).toJson()).browserSwipeHinted, isTrue);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
testWidgets('174: MKV 화면이 맨 처음 화면이 아니어도 (홈 화면 = 탐색기 등) MKV 아이콘이 "지금 여기"', (tester) async {
|
||||||
|
tester.view.physicalSize = const Size(1500, 900);
|
||||||
|
tester.view.devicePixelRatio = 1;
|
||||||
|
addTearDown(tester.view.reset);
|
||||||
|
final c = _plain();
|
||||||
|
c.settings
|
||||||
|
..components = ['mkv', 'explorer']
|
||||||
|
..navOrder = ['mkv', 'explorer'];
|
||||||
|
final navKey = GlobalKey<NavigatorState>();
|
||||||
|
await tester.pumpWidget(MaterialApp(
|
||||||
|
navigatorKey: navKey,
|
||||||
|
builder: (context, child) => AppScope(controller: c, child: child!),
|
||||||
|
home: const Scaffold(body: Text('맨 처음 화면')),
|
||||||
|
));
|
||||||
|
navKey.currentState!.push(MaterialPageRoute<void>(builder: (_) => HomePage(c: c)));
|
||||||
|
await tester.pumpAndSettle();
|
||||||
|
expect(find.byTooltip('MKV 화면 (지금 여기)'), findsOneWidget);
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue