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
2022-09-28 19:25:35 +0300
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
2012f83d6ca1fbb5c22ca8013b467862fb15d7f4
2012f83d
1 parent
694576d9
new keys
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
17 changed files
with
94 additions
and
65 deletions
warply_android_sdk/build.gradle
warply_android_sdk/src/main/java/ly/warp/sdk/activities/GiftsForYouActivity.java
warply_android_sdk/src/main/java/ly/warp/sdk/activities/MoreForYouActivity.java
warply_android_sdk/src/main/java/ly/warp/sdk/utils/WarplyManagerHelper.java
warply_android_sdk/src/main/java/ly/warp/sdk/views/WarpView.java
warply_android_sdk/src/main/res/layout/activity_active_coupons.xml
warply_android_sdk/src/main/res/layout/activity_active_gifts.xml
warply_android_sdk/src/main/res/layout/activity_contextual.xml
warply_android_sdk/src/main/res/layout/activity_coupon_info.xml
warply_android_sdk/src/main/res/layout/activity_coupon_share.xml
warply_android_sdk/src/main/res/layout/activity_couponset_info.xml
warply_android_sdk/src/main/res/layout/activity_gifts_for_you.xml
warply_android_sdk/src/main/res/layout/activity_loyalty_analysis.xml
warply_android_sdk/src/main/res/layout/activity_loyalty_wallet.xml
warply_android_sdk/src/main/res/layout/activity_more_for_you.xml
warply_android_sdk/src/main/res/layout/activity_shops.xml
warply_android_sdk/src/main/res/layout/activity_telco.xml
warply_android_sdk/build.gradle
View file @
2012f83
...
...
@@ -2,7 +2,7 @@ apply plugin: 'com.android.library'
ext
{
PUBLISH_GROUP_ID
=
'ly.warp'
PUBLISH_VERSION
=
'4.5.4-cosbeta7
6
'
PUBLISH_VERSION
=
'4.5.4-cosbeta7
7
'
PUBLISH_ARTIFACT_ID
=
'warply-android-sdk'
}
...
...
warply_android_sdk/src/main/java/ly/warp/sdk/activities/GiftsForYouActivity.java
View file @
2012f83
This diff is collapsed. Click to expand it.
warply_android_sdk/src/main/java/ly/warp/sdk/activities/MoreForYouActivity.java
View file @
2012f83
...
...
@@ -38,6 +38,7 @@ import ly.warp.sdk.utils.WarpJSONParser;
import
ly.warp.sdk.utils.WarpUtils
;
import
ly.warp.sdk.utils.WarplyManagerHelper
;
import
ly.warp.sdk.utils.managers.WarplyEventBusManager
;
import
ly.warp.sdk.utils.managers.WarplyManager
;
import
ly.warp.sdk.views.adapters.MergedMoreAdapter
;
import
ly.warp.sdk.views.adapters.MoreCampaignAdapter
;
import
ly.warp.sdk.views.adapters.MoreContextualAdapter
;
...
...
@@ -211,7 +212,7 @@ public class MoreForYouActivity extends Activity implements View.OnClickListener
// initViews2();
/** New Implementation */
initViewsNew2
(
);
runOnUiThread
(
this
::
initViewsNew2
);
/** New Implementation */
}
}
...
...
@@ -518,10 +519,11 @@ public class MoreForYouActivity extends Activity implements View.OnClickListener
if
(
extraFields
.
has
(
"type"
)
&&
extraFields
.
optString
(
"type"
).
equals
(
"telco"
))
{
for
(
LoyaltyContextualOfferModel
ccms
:
WarplyManagerHelper
.
getCCMSLoyaltyCampaigns
())
{
if
(
ccms
.
getLoyaltyCampaignId
().
equals
(
moreItem
.
getSessionUUID
()))
{
WarplyManager
.
getSingleCampaign
(
moreItem
.
getSessionUUID
());
Intent
intent
=
new
Intent
(
MoreForYouActivity
.
this
,
TelcoActivity
.
class
);
intent
.
putExtra
(
"ccms"
,
ccms
);
intent
.
putExtra
(
"loyalty"
,
(
Serializable
)
moreItem
);
startActivity
(
intent
);
startActivity
ForResult
(
intent
,
1003
);
break
;
}
}
...
...
warply_android_sdk/src/main/java/ly/warp/sdk/utils/WarplyManagerHelper.java
View file @
2012f83
...
...
@@ -25,6 +25,7 @@
package
ly
.
warp
.
sdk
.
utils
;
import
android.app.ActivityManager
;
import
android.content.Context
;
import
android.content.Intent
;
import
android.content.pm.PackageManager
;
...
...
@@ -79,6 +80,7 @@ import ly.warp.sdk.io.request.WarplyIntegrationRequest;
import
ly.warp.sdk.io.request.WarplyUserCouponsRequest
;
import
ly.warp.sdk.services.EventService
;
import
ly.warp.sdk.services.FCMBaseMessagingService
;
import
ly.warp.sdk.services.WarplyHealthService
;
import
ly.warp.sdk.utils.managers.WarplyEventBusManager
;
import
ly.warp.sdk.utils.managers.WarplyManager
;
...
...
@@ -1230,6 +1232,23 @@ public class WarplyManagerHelper {
}
public
static
void
logoutUser
()
{
if
(
isMyServiceRunning
(
WarplyHealthService
.
class
))
{
Intent
stepsServiceIntent
=
new
Intent
(
Warply
.
getWarplyContext
(),
WarplyHealthService
.
class
);
Warply
.
getWarplyContext
().
stopService
(
stepsServiceIntent
);
}
}
private
static
boolean
isMyServiceRunning
(
Class
<?>
serviceClass
)
{
ActivityManager
manager
=
(
ActivityManager
)
Warply
.
getWarplyContext
().
getSystemService
(
Context
.
ACTIVITY_SERVICE
);
for
(
ActivityManager
.
RunningServiceInfo
service
:
manager
.
getRunningServices
(
Integer
.
MAX_VALUE
))
{
if
(
serviceClass
.
getName
().
equals
(
service
.
service
.
getClassName
()))
{
return
true
;
}
}
return
false
;
}
// ===========================================================
// Inner and Anonymous Classes
// ===========================================================
...
...
warply_android_sdk/src/main/java/ly/warp/sdk/views/WarpView.java
View file @
2012f83
...
...
@@ -532,7 +532,7 @@ public class WarpView extends WebView {
WarplyManagerHelper
.
mMetersWebview
=
0.0d
;
WarpViewActivity
.
getMetersHandler
().
postDelayed
(
this
,
300
);
}
},
1000
);
},
3000
);
//TODO: change it back to 1000
if
(
url
.
contains
(
"about:blank"
))
{
WarpView
.
this
.
clearHistory
();
...
...
warply_android_sdk/src/main/res/layout/activity_active_coupons.xml
View file @
2012f83
...
...
@@ -10,24 +10,24 @@
<androidx.constraintlayout.widget.ConstraintLayout
android:id=
"@+id/cl_bill_header"
android:layout_width=
"match_parent"
android:layout_height=
"
50
dp"
android:layout_height=
"
48
dp"
android:background=
"@android:color/white"
>
<ImageView
android:id=
"@+id/iv_coupons_close"
android:layout_width=
"26dp"
android:layout_height=
"25dp"
android:layout_marginStart=
"24dp"
android:layout_marginTop=
"4dp"
android:layout_width=
"48dp"
android:layout_height=
"48dp"
android:layout_marginStart=
"16dp"
android:src=
"@drawable/ic_back"
android:scaleType=
"centerInside"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toTopOf=
"parent"
/>
<TextView
android:id=
"@+id/textView3"
android:layout_width=
"
206dp
"
android:layout_height=
"
32dp
"
android:layout_width=
"
wrap_content
"
android:layout_height=
"
wrap_content
"
android:gravity=
"center"
android:text=
"@string/cos_active_all_coupons"
android:textColor=
"@color/grey"
...
...
warply_android_sdk/src/main/res/layout/activity_active_gifts.xml
View file @
2012f83
...
...
@@ -10,23 +10,24 @@
<androidx.constraintlayout.widget.ConstraintLayout
android:id=
"@+id/cl_bill_header"
android:layout_width=
"match_parent"
android:layout_height=
"
80
dp"
android:layout_height=
"
48
dp"
android:background=
"@android:color/white"
>
<ImageView
android:id=
"@+id/iv_list_close"
android:layout_width=
"
26
dp"
android:layout_height=
"
25
dp"
android:layout_marginStart=
"
24
dp"
android:
layout_marginTop=
"4dp
"
android:layout_width=
"
48
dp"
android:layout_height=
"
48
dp"
android:layout_marginStart=
"
16
dp"
android:
scaleType=
"centerInside
"
android:src=
"@drawable/ic_back"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toTopOf=
"
@+id/textView3
"
/>
app:layout_constraintTop_toTopOf=
"
parent
"
/>
<TextView
android:id=
"@+id/textView3"
android:layout_width=
"
206dp
"
android:layout_height=
"
32dp
"
android:layout_width=
"
wrap_content
"
android:layout_height=
"
wrap_content
"
android:gravity=
"center"
android:textColor=
"@color/grey"
android:textSize=
"17sp"
...
...
@@ -34,8 +35,7 @@
android:text=
"@string/cos_active_gifts_title"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintEnd_toEndOf=
"parent"
app:layout_constraintHorizontal_bias=
"0.356"
app:layout_constraintStart_toEndOf=
"@+id/iv_list_close"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toTopOf=
"parent"
/>
</androidx.constraintlayout.widget.ConstraintLayout>
...
...
warply_android_sdk/src/main/res/layout/activity_contextual.xml
View file @
2012f83
...
...
@@ -8,15 +8,16 @@
<androidx.constraintlayout.widget.ConstraintLayout
android:id=
"@+id/cl_loyalty_wallet_header"
android:layout_width=
"match_parent"
android:layout_height=
"
50
dp"
android:layout_height=
"
48
dp"
android:background=
"@android:color/white"
>
<ImageView
android:id=
"@+id/iv_contextual_back"
android:layout_width=
"
26
dp"
android:layout_height=
"
25
dp"
android:layout_width=
"
48
dp"
android:layout_height=
"
48
dp"
android:layout_marginStart=
"16dp"
android:src=
"@drawable/ic_back"
android:scaleType=
"centerInside"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toTopOf=
"parent"
/>
...
...
warply_android_sdk/src/main/res/layout/activity_coupon_info.xml
View file @
2012f83
...
...
@@ -8,15 +8,16 @@
<androidx.constraintlayout.widget.ConstraintLayout
android:id=
"@+id/cl_loyalty_wallet_header"
android:layout_width=
"match_parent"
android:layout_height=
"
50
dp"
android:layout_height=
"
48
dp"
android:background=
"@android:color/white"
>
<ImageView
android:id=
"@+id/iv_coupon_info_back"
android:layout_width=
"
26
dp"
android:layout_height=
"
25
dp"
android:layout_width=
"
48
dp"
android:layout_height=
"
48
dp"
android:layout_marginStart=
"16dp"
android:src=
"@drawable/ic_back"
android:scaleType=
"centerInside"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toTopOf=
"parent"
/>
...
...
warply_android_sdk/src/main/res/layout/activity_coupon_share.xml
View file @
2012f83
...
...
@@ -8,15 +8,16 @@
<androidx.constraintlayout.widget.ConstraintLayout
android:id=
"@+id/cl_loyalty_wallet_header"
android:layout_width=
"match_parent"
android:layout_height=
"
50
dp"
android:layout_height=
"
48
dp"
android:background=
"@android:color/white"
>
<ImageView
android:id=
"@+id/iv_coupon_share_back"
android:layout_width=
"
26
dp"
android:layout_height=
"
25
dp"
android:layout_width=
"
48
dp"
android:layout_height=
"
48
dp"
android:layout_marginStart=
"16dp"
android:src=
"@drawable/ic_back"
android:scaleType=
"centerInside"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toTopOf=
"parent"
/>
...
...
warply_android_sdk/src/main/res/layout/activity_couponset_info.xml
View file @
2012f83
...
...
@@ -8,15 +8,16 @@
<androidx.constraintlayout.widget.ConstraintLayout
android:id=
"@+id/cl_loyalty_wallet_header"
android:layout_width=
"match_parent"
android:layout_height=
"
50
dp"
android:layout_height=
"
48
dp"
android:background=
"@android:color/white"
>
<ImageView
android:id=
"@+id/iv_couponset_info_back"
android:layout_width=
"
26
dp"
android:layout_height=
"
25
dp"
android:layout_width=
"
48
dp"
android:layout_height=
"
48
dp"
android:layout_marginStart=
"16dp"
android:src=
"@drawable/ic_back"
android:scaleType=
"centerInside"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toTopOf=
"parent"
/>
...
...
warply_android_sdk/src/main/res/layout/activity_gifts_for_you.xml
View file @
2012f83
...
...
@@ -11,23 +11,24 @@
<androidx.constraintlayout.widget.ConstraintLayout
android:id=
"@+id/cl_bill_header"
android:layout_width=
"match_parent"
android:layout_height=
"
80
dp"
android:layout_height=
"
48
dp"
android:background=
"@android:color/white"
>
<ImageView
android:id=
"@+id/iv_list_close"
android:layout_width=
"
26
dp"
android:layout_height=
"
25
dp"
android:layout_marginStart=
"
24
dp"
android:
layout_marginTop=
"4dp
"
android:layout_width=
"
48
dp"
android:layout_height=
"
48
dp"
android:layout_marginStart=
"
16
dp"
android:
scaleType=
"centerInside
"
android:src=
"@drawable/ic_back"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toTopOf=
"
@+id/textView3
"
/>
app:layout_constraintTop_toTopOf=
"
parent
"
/>
<TextView
android:id=
"@+id/textView3"
android:layout_width=
"
206dp
"
android:layout_height=
"
32dp
"
android:layout_width=
"
wrap_content
"
android:layout_height=
"
wrap_content
"
android:gravity=
"center"
android:textColor=
"@color/grey"
android:textSize=
"17sp"
...
...
@@ -35,8 +36,7 @@
android:text=
"@string/cos_gifts_title"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintEnd_toEndOf=
"parent"
app:layout_constraintHorizontal_bias=
"0.356"
app:layout_constraintStart_toEndOf=
"@+id/iv_list_close"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toTopOf=
"parent"
/>
</androidx.constraintlayout.widget.ConstraintLayout>
...
...
warply_android_sdk/src/main/res/layout/activity_loyalty_analysis.xml
View file @
2012f83
...
...
@@ -10,15 +10,16 @@
<androidx.constraintlayout.widget.ConstraintLayout
android:id=
"@+id/cl_loyalty_analysis_header"
android:layout_width=
"match_parent"
android:layout_height=
"
50
dp"
android:layout_height=
"
48
dp"
android:background=
"@android:color/white"
>
<ImageView
android:id=
"@+id/iv_loyalty_analysis_close"
android:layout_width=
"
26
dp"
android:layout_height=
"
25
dp"
android:layout_width=
"
48
dp"
android:layout_height=
"
48
dp"
android:layout_marginStart=
"16dp"
android:src=
"@drawable/ic_back"
android:scaleType=
"centerInside"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toTopOf=
"parent"
/>
...
...
warply_android_sdk/src/main/res/layout/activity_loyalty_wallet.xml
View file @
2012f83
...
...
@@ -8,15 +8,16 @@
<androidx.constraintlayout.widget.ConstraintLayout
android:id=
"@+id/cl_loyalty_wallet_header"
android:layout_width=
"match_parent"
android:layout_height=
"
50
dp"
android:layout_height=
"
48
dp"
android:background=
"@android:color/white"
>
<ImageView
android:id=
"@+id/iv_back"
android:layout_width=
"
26
dp"
android:layout_height=
"
25
dp"
android:layout_width=
"
48
dp"
android:layout_height=
"
48
dp"
android:layout_marginStart=
"16dp"
android:src=
"@drawable/ic_back"
android:scaleType=
"centerInside"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toTopOf=
"parent"
/>
...
...
warply_android_sdk/src/main/res/layout/activity_more_for_you.xml
View file @
2012f83
...
...
@@ -10,32 +10,32 @@
<androidx.constraintlayout.widget.ConstraintLayout
android:id=
"@+id/cl_more_header"
android:layout_width=
"match_parent"
android:layout_height=
"
80
dp"
android:layout_height=
"
48
dp"
app:layout_constraintTop_toTopOf=
"parent"
>
<ImageView
android:id=
"@+id/iv_list_close"
android:layout_width=
"
26
dp"
android:layout_height=
"
25
dp"
android:layout_marginStart=
"
24
dp"
android:
layout_marginTop=
"4dp
"
android:layout_width=
"
48
dp"
android:layout_height=
"
48
dp"
android:layout_marginStart=
"
16
dp"
android:
scaleType=
"centerInside
"
android:src=
"@drawable/ic_back"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toTopOf=
"
@+id/textView3
"
/>
app:layout_constraintTop_toTopOf=
"
parent
"
/>
<TextView
android:id=
"@+id/textView3"
fontPath=
"fonts/pf_square_sans_pro_bold.ttf"
android:layout_width=
"
206dp
"
android:layout_height=
"
32dp
"
android:layout_width=
"
wrap_content
"
android:layout_height=
"
wrap_content
"
android:gravity=
"center"
android:text=
"@string/cos_more_title"
android:textColor=
"@color/grey"
android:textSize=
"17sp"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintEnd_toEndOf=
"parent"
app:layout_constraintHorizontal_bias=
"0.356"
app:layout_constraintStart_toEndOf=
"@+id/iv_list_close"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toTopOf=
"parent"
/>
</androidx.constraintlayout.widget.ConstraintLayout>
...
...
warply_android_sdk/src/main/res/layout/activity_shops.xml
View file @
2012f83
...
...
@@ -8,15 +8,16 @@
<androidx.constraintlayout.widget.ConstraintLayout
android:id=
"@+id/cl_loyalty_wallet_header"
android:layout_width=
"match_parent"
android:layout_height=
"
50
dp"
android:layout_height=
"
48
dp"
android:background=
"@android:color/white"
>
<ImageView
android:id=
"@+id/iv_shops_back"
android:layout_width=
"
26
dp"
android:layout_height=
"
25
dp"
android:layout_width=
"
48
dp"
android:layout_height=
"
48
dp"
android:layout_marginStart=
"16dp"
android:src=
"@drawable/ic_back"
android:scaleType=
"centerInside"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toTopOf=
"parent"
/>
...
...
warply_android_sdk/src/main/res/layout/activity_telco.xml
View file @
2012f83
...
...
@@ -8,15 +8,16 @@
<androidx.constraintlayout.widget.ConstraintLayout
android:id=
"@+id/cl_loyalty_wallet_header"
android:layout_width=
"match_parent"
android:layout_height=
"
50
dp"
android:layout_height=
"
48
dp"
android:background=
"@android:color/white"
>
<ImageView
android:id=
"@+id/iv_telco_back"
android:layout_width=
"
22
dp"
android:layout_height=
"
22
dp"
android:layout_width=
"
48
dp"
android:layout_height=
"
48
dp"
android:layout_marginStart=
"16dp"
android:src=
"@drawable/ic_close"
android:scaleType=
"centerInside"
app:layout_constraintBottom_toBottomOf=
"parent"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toTopOf=
"parent"
/>
...
...
Please
register
or
login
to post a comment