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-03-24 17:48:09 +0200
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
a90468bbe7cde437d77f469aeff4263d53512d35
a90468bb
1 parent
0976806f
minor addition 2
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
1 deletions
warply_android_sdk/src/main/java/ly/warp/sdk/activities/CouponInfoActivity.java
warply_android_sdk/src/main/java/ly/warp/sdk/activities/CouponInfoActivity.java
View file @
a90468b
...
...
@@ -2,11 +2,13 @@ package ly.warp.sdk.activities;
import
android.app.Activity
;
import
android.app.Dialog
;
import
android.content.Intent
;
import
android.graphics.Paint
;
import
android.os.Bundle
;
import
android.view.View
;
import
android.widget.Button
;
import
android.widget.ImageView
;
import
android.widget.LinearLayout
;
import
android.widget.TextView
;
import
ly.warp.sdk.R
;
...
...
@@ -23,7 +25,8 @@ public class CouponInfoActivity extends Activity implements View.OnClickListener
// ===========================================================
private
ImageView
mIvBack
;
private
TextView
mTvTerms
;
private
TextView
mTvTerms
,
mTvCouponCode
;
private
LinearLayout
mLlGiftIt
;
// ===========================================================
// Methods for/from SuperClass/Interfaces
...
...
@@ -36,6 +39,8 @@ public class CouponInfoActivity extends Activity implements View.OnClickListener
mIvBack
=
findViewById
(
R
.
id
.
iv_coupon_info_back
);
mTvTerms
=
findViewById
(
R
.
id
.
tv_terms
);
mLlGiftIt
=
findViewById
(
R
.
id
.
ll_gift_it
);
mTvCouponCode
=
findViewById
(
R
.
id
.
textView16
);
initViews
();
}
...
...
@@ -49,6 +54,13 @@ public class CouponInfoActivity extends Activity implements View.OnClickListener
public
void
onClick
(
View
view
)
{
if
(
view
.
getId
()
==
R
.
id
.
iv_coupon_info_back
)
{
onBackPressed
();
return
;
}
if
(
view
.
getId
()
==
R
.
id
.
ll_gift_it
)
{
Intent
intent
=
new
Intent
(
android
.
content
.
Intent
.
ACTION_SEND
);
intent
.
setType
(
"text/plain"
);
intent
.
putExtra
(
android
.
content
.
Intent
.
EXTRA_TEXT
,
"Link: https://cosmote.page.link /referal\n\nΧρησιμοποίησε τον κωδικό "
+
mTvCouponCode
.
getText
().
toString
()
+
" για εκπτωτικό κουπόνι 4€ στο BOX: XMAS4"
);
startActivity
(
Intent
.
createChooser
(
intent
,
"Άνοιγμα με"
));
}
}
...
...
@@ -59,6 +71,7 @@ public class CouponInfoActivity extends Activity implements View.OnClickListener
private
void
initViews
()
{
mIvBack
.
setOnClickListener
(
this
);
mTvTerms
.
setPaintFlags
(
mTvTerms
.
getPaintFlags
()
|
Paint
.
UNDERLINE_TEXT_FLAG
);
mLlGiftIt
.
setOnClickListener
(
this
);
}
// ===========================================================
...
...
Please
register
or
login
to post a comment