-
Notifications
You must be signed in to change notification settings - Fork 6
wip(android): add Android SDK and FlexHybridApp-Android #25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
16e1adc
to
bca838e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@KevinGrafstrom let's separate the example from the library project and move it into example
.
} | ||
|
||
android { | ||
namespace = "com.chatkitty.chatkittyui" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's change the namespace (including subpackages) from com.chatkitty.chatkittyui
to com.chatkitty.ui
.
} | ||
|
||
defaultConfig { | ||
applicationId = "com.chatkitty.chatkittyui" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same here
android:name=".MainActivity" | ||
android:exported="true" | ||
android:label="@string/app_name" | ||
android:theme="@style/Theme.ChatKittyUI"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's rename the theme to ChatUi
@@ -0,0 +1,62 @@ | |||
package com.chatkitty.chatkittyui |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be under examples/android
@@ -0,0 +1,3 @@ | |||
<resources> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"ChatUi Example"
publishing { | ||
publications { | ||
create<MavenPublication>("mavenJava") { | ||
groupId = "com.chatkitty.uie" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
uie
-> ui
|
||
override fun <T : Any> onMessage(id: String?, type: FlexStompXEventType, payload: T) { | ||
flexWebView.evalFlexFunc("onMessage", messageToBase64(FlexStompXMessage(id, type.value, payload))) | ||
Log.i("gnw", "onMessage finished with a payload: ${payload}") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's remove these logs.
} else { | ||
"standalone" | ||
} | ||
val connection = "shared" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please revert this
cfba439
to
9abb993
Compare
ChatKitty's Chat UI should be easily usable in other people's Android apps. To make it easier, we are making an Android library so that other developers can simply add the Chat UI component to their app. This pull request adds an Android Studio project which contains the Android Chat UI component. This pull request also adds the FlexHybridApp-Android library since its repository has not been updated in years. For that reason, we want to include it in our repository so that we can maintain it. FlexHybridApp-Android is a library which allows for communication between a Web View and the native Android device. It is used in the Android Chat UI component to deliver notifications from the Phoenix app in the Web View to the Android device.