123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960 |
- /// conversion_sdk_info_widget.dart
- ///
- /// Copyright © 2014-2023 PDF Technologies, Inc. All Rights Reserved.
- ///
- /// THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
- /// AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
- /// UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
- /// This notice may not be removed from this file.
- import 'package:flutter/material.dart';
- import 'package:kmpdfkit_conversion_flutter/cpdf_converter.dart';
- import 'package:provider/provider.dart';
- import '../states/convert_task_queue_provider.dart';
- class ConversionSdkInfoWidget extends StatefulWidget {
- const ConversionSdkInfoWidget({Key? key}) : super(key: key);
- @override
- State<ConversionSdkInfoWidget> createState() =>
- _ConversionSdkInfoWidgetState();
- }
- class _ConversionSdkInfoWidgetState extends State<ConversionSdkInfoWidget> {
- String conversionSDKVersion = "Version:";
- String convertFileOutputPath = "";
- @override
- void initState() {
- super.initState();
- CPDFConverter.getSDKBuildTag().then((value) {
- setState(() {
- conversionSDKVersion = "Version:$value";
- });
- });
- context.read<ConvertTaskQueueProvider>().getOutputDir().then((value) {
- setState(() {
- convertFileOutputPath = value ?? "";
- });
- });
- }
- @override
- Widget build(BuildContext context) {
- return Column(
- crossAxisAlignment: CrossAxisAlignment.start,
- children: [
- Text(
- conversionSDKVersion,
- style: const TextStyle(fontSize: 13),
- ),
- Text(
- 'OutputPath:$convertFileOutputPath',
- style: const TextStyle(fontSize: 13),
- )
- ],
- );
- }
- }
|