Toggle navigation
Toggle navigation
This project
Loading...
Sign in
open-source
/
warply_android_sdk_maven_plugin
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
Panagiotis Triantafyllou
2025-05-23 10:23:03 +0300
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
d484f2c7feb3b3643f4eb51548b328e8ab0ada80
d484f2c7
1 parent
e7853572
deh initial commit
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
142 additions
and
7 deletions
app/build.gradle
warply_android_sdk/build.gradle
warply_android_sdk/src/main/AndroidManifest.xml
warply_android_sdk/src/main/java/ly/warp/sdk/activities/HomeActivity.java
warply_android_sdk/src/main/java/ly/warp/sdk/fragments/HomeFragment.java
warply_android_sdk/src/main/java/ly/warp/sdk/utils/WarplyProvider.java
warply_android_sdk/src/main/res/drawable-xhdpi/demo_family.png
warply_android_sdk/src/main/res/drawable-xhdpi/demo_green.png
warply_android_sdk/src/main/res/drawable-xhdpi/demo_home_banner.png
warply_android_sdk/src/main/res/drawable-xhdpi/demo_profile.png
warply_android_sdk/src/main/res/layout/activity_home.xml
warply_android_sdk/src/main/res/values/colors.xml
warply_android_sdk/src/main/res/values/styles.xml
app/build.gradle
View file @
d484f2c
...
...
@@ -8,7 +8,7 @@ android {
defaultConfig
{
applicationId
"warp.ly.android_sdk"
minSdkVersion
23
minSdkVersion
31
targetSdkVersion
34
versionCode
100
versionName
"1.0.0"
...
...
warply_android_sdk/build.gradle
View file @
d484f2c
...
...
@@ -5,7 +5,7 @@ android.buildFeatures.buildConfig = true
ext
{
PUBLISH_GROUP_ID
=
'ly.warp'
PUBLISH_VERSION
=
'4.5.5.4
m2
'
PUBLISH_VERSION
=
'4.5.5.4
deh1
'
PUBLISH_ARTIFACT_ID
=
'warply-android-sdk'
}
...
...
@@ -26,7 +26,7 @@ android {
}
defaultConfig
{
minSdkVersion
23
minSdkVersion
31
targetSdkVersion
34
consumerProguardFiles
'proguard-rules.pro'
vectorDrawables
.
useSupportLibrary
=
true
...
...
warply_android_sdk/src/main/AndroidManifest.xml
View file @
d484f2c
...
...
@@ -33,6 +33,12 @@
android:theme=
"@style/SDKAppTheme"
/>
<activity
android:name=
".activities.HomeActivity"
android:exported=
"false"
android:screenOrientation=
"portrait"
android:theme=
"@style/SDKAppTheme"
/>
<activity
android:name=
".dexter.PermissionsActivity"
android:exported=
"false"
android:launchMode=
"singleInstance"
...
...
warply_android_sdk/src/main/java/ly/warp/sdk/activities/HomeActivity.java
0 → 100644
View file @
d484f2c
package
ly
.
warp
.
sdk
.
activities
;
import
android.app.Activity
;
import
android.os.Bundle
;
import
android.view.View
;
import
android.widget.ImageView
;
import
ly.warp.sdk.R
;
public
class
HomeActivity
extends
Activity
implements
View
.
OnClickListener
{
// ===========================================================
// Constants
// ===========================================================
// ===========================================================
// Fields
// ===========================================================
private
ImageView
mIvBanner
;
// ===========================================================
// Methods for/from SuperClass/Interfaces
// ===========================================================
@Override
public
void
onCreate
(
Bundle
savedInstanceState
)
{
super
.
onCreate
(
savedInstanceState
);
setContentView
(
R
.
layout
.
activity_home
);
mIvBanner
=
findViewById
(
R
.
id
.
banner_icon
);
initViews
();
}
@Override
public
void
onResume
()
{
super
.
onResume
();
}
// ===========================================================
// Methods
// ===========================================================
private
void
initViews
()
{
mIvBanner
.
setOnClickListener
(
this
);
}
@Override
public
void
onClick
(
View
v
)
{
if
(
v
.
getId
()
==
R
.
id
.
banner_icon
)
{
}
}
// ===========================================================
// Inner and Anonymous Classes
// ===========================================================
}
warply_android_sdk/src/main/java/ly/warp/sdk/fragments/HomeFragment.java
View file @
d484f2c
package
ly
.
warp
.
sdk
.
fragments
;
import
android.content.Intent
;
import
android.os.Bundle
;
import
android.view.LayoutInflater
;
import
android.view.View
;
...
...
@@ -20,6 +21,7 @@ import org.json.JSONObject;
import
java.util.ArrayList
;
import
ly.warp.sdk.R
;
import
ly.warp.sdk.activities.HomeActivity
;
import
ly.warp.sdk.db.WarplyDBHelper
;
import
ly.warp.sdk.io.callbacks.CallbackReceiver
;
import
ly.warp.sdk.io.models.Campaign
;
...
...
@@ -113,8 +115,11 @@ public class HomeFragment extends Fragment implements View.OnClickListener, Swip
if
(
view
.
getId
()
==
R
.
id
.
ll_auth_login
)
{
//6012049321, 6012049322, 6012049323, 7000000831 history, 7000000826, 7000000831 shared coupons
//prod 6006552990, prod 6005892749, live 3000184910,prod 7000070282, live 3000136179
mPbLoading
.
setVisibility
(
View
.
VISIBLE
);
WarplyManager
.
getCosmoteUser
(
mEtGuid
.
getText
().
toString
(),
mLoginReceiver
);
// mPbLoading.setVisibility(View.VISIBLE);
// WarplyManager.getCosmoteUser(mEtGuid.getText().toString(), mLoginReceiver);
Intent
myIntent
=
new
Intent
(
getContext
(),
HomeActivity
.
class
);
startActivity
(
myIntent
);
return
;
}
if
(
view
.
getId
()
==
R
.
id
.
ll_auth_logout
)
{
...
...
warply_android_sdk/src/main/java/ly/warp/sdk/utils/WarplyProvider.java
View file @
d484f2c
...
...
@@ -19,7 +19,7 @@ public class WarplyProvider extends ContentProvider {
@Override
public
boolean
onCreate
()
{
//
AppCompatDelegate.setDefaultNightMode(AppCompatDelegate.MODE_NIGHT_NO);
AppCompatDelegate
.
setDefaultNightMode
(
AppCompatDelegate
.
MODE_NIGHT_NO
);
// Initialize the database helper
Context
context
=
getContext
();
...
...
warply_android_sdk/src/main/res/drawable-xhdpi/demo_family.png
0 → 100644
View file @
d484f2c
887 Bytes
warply_android_sdk/src/main/res/drawable-xhdpi/demo_green.png
0 → 100644
View file @
d484f2c
931 Bytes
warply_android_sdk/src/main/res/drawable-xhdpi/demo_home_banner.png
0 → 100644
View file @
d484f2c
253 KB
warply_android_sdk/src/main/res/drawable-xhdpi/demo_profile.png
0 → 100644
View file @
d484f2c
2.29 KB
warply_android_sdk/src/main/res/layout/activity_home.xml
0 → 100644
View file @
d484f2c
<RelativeLayout
xmlns:android=
"http://schemas.android.com/apk/res/android"
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
android:background=
"@color/cos_grey_light"
>
<androidx.core.widget.NestedScrollView
android:id=
"@+id/home_scrollview"
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
android:fillViewport=
"true"
>
<LinearLayout
android:id=
"@+id/home_content_container"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:orientation=
"vertical"
>
<LinearLayout
android:id=
"@+id/header_layout"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_gravity=
"center"
android:background=
"@color/cos_grey_light"
android:orientation=
"horizontal"
android:padding=
"16dp"
>
<LinearLayout
android:layout_width=
"0dp"
android:layout_height=
"wrap_content"
android:layout_gravity=
"center"
android:layout_weight=
"1"
android:orientation=
"horizontal"
>
<ImageView
android:id=
"@+id/green_icon"
android:layout_width=
"52dp"
android:layout_height=
"20dp"
android:layout_marginEnd=
"8dp"
android:src=
"@drawable/demo_green"
/>
<ImageView
android:id=
"@+id/family_icon"
android:layout_width=
"52dp"
android:layout_height=
"20dp"
android:src=
"@drawable/demo_family"
/>
</LinearLayout>
<ImageView
android:id=
"@+id/profile_icon"
android:layout_width=
"40dp"
android:layout_height=
"40dp"
android:layout_gravity=
"center_vertical|end"
android:src=
"@drawable/demo_profile"
/>
</LinearLayout>
<ImageView
android:id=
"@+id/banner_icon"
android:layout_width=
"match_parent"
android:layout_height=
"320dp"
android:scaleType=
"fitXY"
android:src=
"@drawable/demo_home_banner"
/>
</LinearLayout>
</androidx.core.widget.NestedScrollView>
</RelativeLayout>
warply_android_sdk/src/main/res/values/colors.xml
View file @
d484f2c
...
...
@@ -3,8 +3,10 @@
<!-- Used in drawables -->
<color
name=
"cos_cyan"
>
#A3F2DA
</color>
<color
name=
"cos_grey_dark"
>
#787878
</color>
<color
name=
"cos_grey_light"
>
#F2F2F2
</color>
<color
name=
"cos_green12"
>
#0EA600
</color>
<color
name=
"cos_green6_tr"
>
#660EA600
</color>
<color
name=
"cos_orange"
>
#FF9933
</color>
<!-- Used in layouts -->
<color
name=
"cos_skyblue2"
>
#22A9B5
</color>
...
...
warply_android_sdk/src/main/res/values/styles.xml
View file @
d484f2c
...
...
@@ -5,7 +5,7 @@
</style>
<style
name=
"SDKAppTheme"
parent=
"Theme.MaterialComponents.Light.DarkActionBar"
>
<item
name=
"android:statusBarColor"
>
@
android:color/white
</item>
<item
name=
"android:statusBarColor"
>
@
color/cos_grey_light
</item>
<item
name=
"android:windowLightStatusBar"
>
true
</item>
<item
name=
"android:forceDarkAllowed"
tools:targetApi=
"q"
>
false
</item>
</style>
...
...
Please
register
or
login
to post a comment