Skip to content

Commit

Permalink
chore(sdk-1194) format clevertap_plugin.dart and main.dart
Browse files Browse the repository at this point in the history
  • Loading branch information
william-ct committed Dec 1, 2021
1 parent 9829fda commit 684cb6f
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 10 deletions.
15 changes: 7 additions & 8 deletions example/lib/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@ class _MyAppState extends State<MyApp> {
initPlatformState();
activateCleverTapFlutterPluginHandlers();
CleverTapPlugin.setDebugLevel(3);
CleverTapPlugin.createNotificationChannel("fluttertest", "Flutter Test", "Flutter Test", 3, true);
CleverTapPlugin.createNotificationChannel(
"fluttertest", "Flutter Test", "Flutter Test", 3, true);
CleverTapPlugin.initializeInbox();
CleverTapPlugin.registerForPush(); //only for iOS
//var initialUrl = CleverTapPlugin.getInitialUrl();
Expand Down Expand Up @@ -146,12 +147,12 @@ class _MyAppState extends State<MyApp> {
print("Product Config Activated");
this.setState(() async {
String? stringvar =
await CleverTapPlugin.getProductConfigString("StringKey");
await CleverTapPlugin.getProductConfigString("StringKey");
print("PC String = " + stringvar.toString());
int? intvar = await CleverTapPlugin.getProductConfigLong("IntKey");
print("PC int = " + intvar.toString());
double? doublevar =
await CleverTapPlugin.getProductConfigDouble("DoubleKey");
await CleverTapPlugin.getProductConfigDouble("DoubleKey");
print("PC double = " + doublevar.toString());
});
}
Expand Down Expand Up @@ -241,7 +242,6 @@ class _MyAppState extends State<MyApp> {
),
),
),

Card(
color: Colors.grey.shade300,
child: Padding(
Expand Down Expand Up @@ -494,7 +494,7 @@ class _MyAppState extends State<MyApp> {
child: ListTile(
title: Text("Push Inbox Message Clicked"),
subtitle:
Text("Pushes/Records inbox message clicked event"),
Text("Pushes/Records inbox message clicked event"),
onTap: pushInboxNotificationClickedEventForId,
),
),
Expand All @@ -506,7 +506,7 @@ class _MyAppState extends State<MyApp> {
child: ListTile(
title: Text("Push Inbox Message Viewed"),
subtitle:
Text("Pushes/Records inbox message viewed event"),
Text("Pushes/Records inbox message viewed event"),
onTap: pushInboxNotificationViewedEventForId,
),
),
Expand Down Expand Up @@ -711,7 +711,6 @@ class _MyAppState extends State<MyApp> {
),
),
),

Card(
color: Colors.grey.shade300,
child: Padding(
Expand Down Expand Up @@ -760,7 +759,7 @@ class _MyAppState extends State<MyApp> {
child: ListTile(
title: Text("Set Opt Out"),
subtitle:
Text("Used to opt out of sending data to CleverTap"),
Text("Used to opt out of sending data to CleverTap"),
onTap: setOptOut,
),
),
Expand Down
8 changes: 6 additions & 2 deletions lib/clevertap_plugin.dart
Original file line number Diff line number Diff line change
Expand Up @@ -426,14 +426,18 @@ class CleverTapPlugin {
'setLocation', {'latitude': latitude, 'longitude': longitude});
}

@Deprecated("This method is deprecated since v1.3.0. Use getCleverTapID() instead")
@Deprecated(
"This method is deprecated since v1.3.0. Use getCleverTapID() instead")

/// Returns a unique CleverTap identifier suitable for use with install attribution providers.
static Future<String?> profileGetCleverTapAttributionIdentifier() async {
return await _channel
.invokeMethod('profileGetCleverTapAttributionIdentifier', {});
}

@Deprecated("This method is deprecated since v1.3.0. Use getCleverTapID() instead")
@Deprecated(
"This method is deprecated since v1.3.0. Use getCleverTapID() instead")

/// Returns a unique identifier by which CleverTap identifies this user.
static Future<String?> profileGetCleverTapID() async {
return await _channel.invokeMethod('profileGetCleverTapID', {});
Expand Down

0 comments on commit 684cb6f

Please sign in to comment.