foundation_fluttify 0.6.0

  • Readme
  • Changelog
  • Example
  • Installing
  • 85

Fluttify基础设施 #

所有基于Fluttify的插件公共的部分, 当然不基于Fluttify的插件理论上也可以使用.

主要实现一些基础设施和系统类的实现.

0.6.0 #

  • enhance: [breaking change] Ref类内的方法和属性都加上__后缀, 防止和子类冲突

0.5.1 #

  • feat: NSError增加获取code和description的方法

0.5.0 #

  • enhance: [breaking change] tag -> tag__

0.4.18 #

  • feat: 增加UIViewController

0.4.17 #

  • feat: 使用System.identityHashCode代替hashCode方法
  • feat: 增加android.view.View.OnClickListener类
  • feat: 增加startActivity/presentViewController方法

0.4.16 #

  • feat: 增加NSValue类

0.4.15 #

  • enhance: 简化platform方法
  • enhance: 补上漏掉的log开关
  • enhance: 迁移创建方法到对应类的handler里去
  • feat: 增加android.app.Notification类

0.4.14 #

  • enhance: CLLocationCoordinate2D增加批量创建方法

0.4.13 #

  • enhance: 优化批量释放日志
  • feat: UIView增加hidden和setHidden

0.4.12 #

  • enhance: 优化platform方法里的释放逻辑

0.4.11 #

  • enhance: Ref增加批处理释放对象方法

0.4.10 #

  • feat: 增加org_json_JSONObject类

0.4.9 #

  • feat: 增加android_view_View_OnApplyWindowInsetsListener类

0.4.8 #

  • feat: Bitmap增加批量创建方法

0.4.7 #

  • refactor: PlatformFactory统一为PlatformService
  • feat: 增加ns_operation类

0.4.6 #

  • feat: 增加一些通用的typedef

0.4.5+1 #

  • fix: onAttachedToEngine中的Plugin对象应该使用this

0.4.5 #

  • fix: PlatformFactory的activity是可选类型;
  • enhance: android_util_Pair获取first和second都返回Object

0.4.4 #

  • enhance: 适配新版embedding
  • refactor: method channel放到objects文件里

0.4.3 #

  • feat: 增加为对象动态添加属性的方法(目前仅限ios端, android理论上可以再加全局Map实现,但是目前没有碰到此类需求)

0.4.2 #

  • feat: 增加java_io_Serializable

0.4.1 #

  • feat: 增加android_os_Binder

0.4.0 #

  • refactor: 可以放进类的静态方法替换全局函数

0.3.0 #

  • refactor: 函数代替类
  • chore: 提升gradle相关版本

0.2.7 #

  • feat: 增加pending_intent类

0.2.6 #

  • feat: android端增加BroadcastReceiver统一接收广播

0.2.5 #

  • feat: CLHeading实现magneticHeading,trueHeading,headingAccuracy

0.2.4 #

  • feat: android_location_Location增加bearing, altitude, accuracy, speed

0.2.3 #

  • feat: 增加android_content_ContentProvider

0.2.2 #

  • feat: 实现UIEdgeInsets的属性

0.2.1 #

  • fix: [objc] 每个.h文件都import <Flutter/Flutter.h>

0.2.0 #

  • [breaking change] 整理工厂方法

0.1.5 #

  • feat: 增加cgpoint的创建支持,获取x和y

0.1.4 #

  • feat: 增加android_graphics_Point的创建, getX, getY的支持

0.1.3 #

feat: 增加NSData

0.1.2 #

  • 新增android.app.Activity#getIntent()
  • feat: android端的Intent处理容器

0.1.1 #

  • 增加android.content.Intent

example/lib/main.dart

import 'package:decorated_flutter/decorated_flutter.dart';
import 'package:flutter/material.dart';
import 'package:foundation_fluttify/foundation_fluttify.dart';
import 'package:foundation_fluttify_example/src/demo/type/core/core.screen.dart';
import 'package:foundation_fluttify_example/src/demo/type/platform/platform.screen.dart';
import 'package:foundation_fluttify_example/src/widget/function_group.widget.dart';
import 'package:foundation_fluttify_example/src/widget/function_item.widget.dart';

void main() => runApp(MyApp());

class MyApp extends StatefulWidget {
  @override
  _MyAppState createState() => _MyAppState();
}

class _MyAppState extends State<MyApp> {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        appBar: AppBar(title: const Text('Plugin example app')),
        body: DecoratedColumn(
          itemSpacing: kSpaceBig,
          children: <Widget>[
            FunctionGroup(
              headLabel: 'Type Demo',
              children: <Widget>[
                FunctionItem(
                  label: 'Core Type Demo',
                  sublabel: 'CoreScreen',
                  target: CoreScreen(),
                ),
                FunctionItem(
                  label: 'Platform Type Demo',
                  sublabel: 'PlatformScreen',
                  target: PlatformScreen(),
                ),
              ],
            ),
            FunctionGroup(
              headLabel: 'Object Demo',
              children: <Widget>[],
            ),
            FunctionGroup(
              headLabel: 'Function Demo',
              children: <Widget>[],
            ),
          ],
        ),
      ),
    );
  }

  Future<void> _testAddProperty() async {
    final target = await CGPoint.create(225, 556);
    final target1 = await CGPoint.create(112, 556);
    await target.addProperty__(1, target1);

    final result = await target.getProperty__(1);
    final target1Result = CGPoint()..refId = result.refId;
    debugPrint('结果: ${await target1Result.x}');
  }
}

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  foundation_fluttify: ^0.6.0

2. Install it

You can install packages from the command line:

with Flutter:


$ flutter pub get

Alternatively, your editor might support flutter pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:foundation_fluttify/foundation_fluttify.dart';
  
Popularity:
Describes how popular the package is relative to other packages. [more]
78
Health:
Code health derived from static analysis. [more]
100
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
80
Overall:
Weighted score of the above. [more]
85
Learn more about scoring.

We analyzed this package on Apr 7, 2020, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.7.1
  • pana: 0.13.6
  • Flutter: 1.12.13+hotfix.8

Maintenance suggestions

The package description is too short. (-20 points)

Add more detail to the description field of pubspec.yaml. Use 60 to 180 characters to describe the package, what it does, and its target use case.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.6.0 <3.0.0
flutter 0.0.0
Transitive dependencies
collection 1.14.11 1.14.12
meta 1.1.8
sky_engine 0.0.99
typed_data 1.1.6
vector_math 2.0.8
Dev dependencies
flutter_test