Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@

# 3.12.4
- Fixes breaking change on Flutter 3.29.0 by removing v1 embedding

# 3.12.3
- Improves edge-case handling of replayed locations.
- Expands functionality of notification analytics.
Expand Down
2 changes: 1 addition & 1 deletion android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ android {
minSdkVersion 16
targetSdkVersion 31
versionCode 1
versionName '3.12.3'
versionName '3.12.4'
}
lintOptions {
disable 'InvalidPackage'
Expand Down
14 changes: 1 addition & 13 deletions android/src/main/java/io/radar/flutter/RadarFlutterPlugin.java
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,6 @@
import io.flutter.plugin.common.MethodChannel.Result;
import io.flutter.plugin.common.PluginRegistry;
import io.flutter.plugin.common.PluginRegistry.RequestPermissionsResultListener;
import io.flutter.plugin.common.PluginRegistry.Registrar;
import io.flutter.view.FlutterMain;

import io.radar.sdk.Radar;
import io.radar.sdk.RadarReceiver;
Expand All @@ -63,7 +61,6 @@
import io.flutter.embedding.engine.dart.DartExecutor;
import io.flutter.embedding.engine.dart.DartExecutor.DartCallback;

import io.flutter.view.FlutterNativeView;
import io.flutter.view.FlutterRunArguments;
import io.flutter.view.FlutterCallbackInformation;

Expand Down Expand Up @@ -117,15 +114,6 @@ public void onReattachedToActivityForConfigChanges(ActivityPluginBinding binding
binding.addRequestPermissionsResultListener(this);
}

public static void registerWith(Registrar registrar) {
mContext = registrar.context();
mActivity = registrar.activity();

channel = new MethodChannel(registrar.messenger(), "flutter_radar");
callHandler = new RadarMethodCallHandler();
channel.setMethodCallHandler(callHandler);
}

private static void runOnMainThread(final Runnable runnable) {
Handler handler = new Handler(Looper.getMainLooper());
handler.post(runnable);
Expand Down Expand Up @@ -294,7 +282,7 @@ private static void initialize(MethodCall call, Result result) {
String publishableKey = call.argument("publishableKey");
SharedPreferences.Editor editor = mContext.getSharedPreferences("RadarSDK", Context.MODE_PRIVATE).edit();
editor.putString("x_platform_sdk_type", "Flutter");
editor.putString("x_platform_sdk_version", "3.12.3");
editor.putString("x_platform_sdk_version", "3.12.4");
editor.apply();
Radar.initialize(mContext, publishableKey);
Radar.setReceiver(new RadarFlutterReceiver(channel));
Expand Down
13 changes: 5 additions & 8 deletions example/android/app/build.gradle
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
plugins {
id "com.android.application"
id "dev.flutter.flutter-gradle-plugin"
}

def localProperties = new Properties()
def localPropertiesFile = rootProject.file('local.properties')
if (localPropertiesFile.exists()) {
Expand All @@ -6,11 +11,6 @@ if (localPropertiesFile.exists()) {
}
}

def flutterRoot = localProperties.getProperty('flutter.sdk')
if (flutterRoot == null) {
throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.")
}

def flutterVersionCode = localProperties.getProperty('flutter.versionCode')
if (flutterVersionCode == null) {
flutterVersionCode = '1'
Expand All @@ -21,9 +21,6 @@ if (flutterVersionName == null) {
flutterVersionName = '1.0'
}

apply plugin: 'com.android.application'
apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"

android {
compileSdkVersion 34

Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,7 @@
package io.radar.example;

import io.flutter.embedding.android.FlutterActivity;
import io.flutter.embedding.engine.FlutterEngine;
import io.flutter.plugins.GeneratedPluginRegistrant;

public class MainActivity extends FlutterActivity {

@Override
public void configureFlutterEngine(FlutterEngine flutterEngine) {
GeneratedPluginRegistrant.registerWith(flutterEngine);
}

}
9 changes: 0 additions & 9 deletions example/android/build.gradle
Original file line number Diff line number Diff line change
@@ -1,13 +1,4 @@
buildscript {
repositories {
google()
jcenter()
}

dependencies {
classpath 'com.android.tools.build:gradle:7.4.2'
}
}

allprojects {
repositories {
Expand Down
30 changes: 22 additions & 8 deletions example/android/settings.gradle
Original file line number Diff line number Diff line change
@@ -1,11 +1,25 @@
include ':app'
pluginManagement {
def flutterSdkPath = {
def properties = new Properties()
file("local.properties").withInputStream { properties.load(it) }
def flutterSdkPath = properties.getProperty("flutter.sdk")
assert flutterSdkPath != null, "flutter.sdk not set in local.properties"
return flutterSdkPath
}()

def localPropertiesFile = new File(rootProject.projectDir, "local.properties")
def properties = new Properties()
includeBuild("$flutterSdkPath/packages/flutter_tools/gradle")

assert localPropertiesFile.exists()
localPropertiesFile.withReader("UTF-8") { reader -> properties.load(reader) }
repositories {
google()
mavenCentral()
gradlePluginPortal()
}
}

def flutterSdkPath = properties.getProperty("flutter.sdk")
assert flutterSdkPath != null, "flutter.sdk not set in local.properties"
apply from: "$flutterSdkPath/packages/flutter_tools/gradle/app_plugin_loader.gradle"
plugins {
id "dev.flutter.flutter-plugin-loader" version "1.0.0"
id "com.android.application" version "7.4.2" apply false
// id "org.jetbrains.kotlin.android" version "1.8.21" apply false
}

include ":app"
2 changes: 1 addition & 1 deletion ios/Classes/RadarFlutterPlugin.m
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ - (void)initialize:(FlutterMethodCall *)call withResult:(FlutterResult)result {

NSString *publishableKey = argsDict[@"publishableKey"];
[[NSUserDefaults standardUserDefaults] setObject:@"Flutter" forKey:@"radar-xPlatformSDKType"];
[[NSUserDefaults standardUserDefaults] setObject:@"3.12.3" forKey:@"radar-xPlatformSDKVersion"];
[[NSUserDefaults standardUserDefaults] setObject:@"3.12.4" forKey:@"radar-xPlatformSDKVersion"];
[Radar initializeWithPublishableKey:publishableKey];
result(nil);
}
Expand Down
2 changes: 1 addition & 1 deletion ios/flutter_radar.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = 'flutter_radar'
s.version = '3.12.3'
s.version = '3.12.4'
s.summary = 'Flutter package for Radar, the leading geofencing and location tracking platform'
s.description = 'Flutter package for Radar, the leading geofencing and location tracking platform'
s.homepage = 'http://example.com'
Expand Down
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: flutter_radar
description: Flutter package for Radar, the leading geofencing and location tracking platform
version: 3.12.3
version: 3.12.4
homepage: https://github.com/radarlabs/flutter-radar

environment:
Expand Down