Skip to content

Commit

Permalink
Pushing version 4.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
Christian Wolf Olov Johannsen committed Dec 11, 2024
1 parent 21b7796 commit 9cb3769
Show file tree
Hide file tree
Showing 5 changed files with 45 additions and 12 deletions.
12 changes: 12 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
# Changelog

## 4.0.1

### Fixed

* Improved rendering performance of Mapbox Map view especially when pinch zooming.

### Changed

* Updated Mapsindoors SDKs:
* iOS to 4.8.0


## 4.0.0

See the [migration guide](https://docs.mapsindoors.com/sdks-and-frameworks/flutter/migration-guide).
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ This plugin is based on the MapsIndoors V4 SDK for Android and iOS.
Add MapsIndoors to your `pubspec.yaml`.

```yaml
mapsindoors_mapbox: ^4.0.0
mapsindoors_mapbox: ^4.0.1
```
### Android
Expand Down
32 changes: 25 additions & 7 deletions lib/core/mapsindoors_widget.dart
Original file line number Diff line number Diff line change
Expand Up @@ -414,17 +414,35 @@ class _MapsIndoorsState extends State<MapsIndoorsWidget> {
} else if (Platform.isIOS) {
MapcontrolPlatform.instance.setFloorSelector(floorSelector, false);
}
final StatefulWidget ret;
final StatefulWidget miView;

if (Platform.isAndroid) {
ret = AndroidView(
miView = PlatformViewLink(
viewType: viewType,
layoutDirection: TextDirection.ltr,
creationParams: creationParams,
creationParamsCodec: const StandardMessageCodec(),
surfaceFactory: (context, controller) {
return AndroidViewSurface(
controller: controller as AndroidViewController,
gestureRecognizers: const <Factory<OneSequenceGestureRecognizer>>{},
hitTestBehavior: PlatformViewHitTestBehavior.opaque,
);
},
onCreatePlatformView: (params) {
return PlatformViewsService.initSurfaceAndroidView(
id: params.id,
viewType: viewType,
layoutDirection: TextDirection.ltr,
creationParams: creationParams,
creationParamsCodec: const StandardMessageCodec(),
onFocus: () {
params.onFocusChanged(true);
},
)
..addOnPlatformViewCreatedListener(params.onPlatformViewCreated)
..create();
},
);
} else if (Platform.isIOS) {
ret = UiKitView(
miView = UiKitView(
viewType: viewType,
layoutDirection: TextDirection.ltr,
creationParams: creationParams,
Expand All @@ -438,7 +456,7 @@ class _MapsIndoorsState extends State<MapsIndoorsWidget> {
fit: FlexFit.tight,
flex: 1,
child: Stack(children: [
ret,
miView,
Align(
alignment: widget.floorSelectorAlignment ?? Alignment.centerRight,
child: floorSelector,
Expand Down
3 changes: 3 additions & 0 deletions lib/mapsindoors.dart
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ library mapsindoors;
import 'dart:async';
import 'dart:convert';

import 'package:flutter/foundation.dart';
import 'package:flutter/gestures.dart';
import 'package:flutter/rendering.dart';
import 'package:flutter/services.dart';
import 'package:flutter/material.dart';
import 'dart:io' show Platform;
Expand Down
8 changes: 4 additions & 4 deletions pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: mapsindoors_mapbox
description: A MapsIndoors flutter plugin using the Mapbox platform for Android and iOS app usage.
version: 4.0.0
version: 4.0.1
repository: https://github.com/MapsPeople/mapsindoors_flutter_mapbox
homepage: https://www.mapsindoors.com/

Expand All @@ -19,9 +19,9 @@ flutter:
dependencies:
flutter:
sdk: flutter
mapsindoors_mapbox_android: ^4.0.0
mapsindoors_mapbox_ios: ^4.0.0
mapsindoors_platform_interface: ^4.0.0
mapsindoors_mapbox_android: ^4.0.1
mapsindoors_mapbox_ios: ^4.0.1
mapsindoors_platform_interface: ^4.0.1


dev_dependencies:
Expand Down

0 comments on commit 9cb3769

Please sign in to comment.