This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class IntroductionAdapter extends RecyclerView.Adapter<IntroductionAdapter.MyViewHolder> { | |
private List<Introduction> introductionList; | |
Context context; // changes | |
public IntroductionAdapter(Context context, List<Introduction> introductionList) { // changes | |
this.context = context; // changes(here you can see context) | |
this.introductionList = introductionList; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class Education { | |
public static final int UNIVERSITY_TYPE=0; | |
public static final int INTERNET_TYPE = 1; | |
public static final int SUBJECT_TYPE=2; | |
public int type; | |
public int image; | |
public String words; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class IntroductionItem extends AppCompatActivity { | |
public RealmList<Introduction> introductionList; | |
Context context; | |
protected void onCreate(Bundle savedInstanceState) { | |
super.onCreate(savedInstanceState); | |
setContentView(R.layout.introduction); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" | |
xmlns:app="http://schemas.android.com/apk/res-auto" | |
android:layout_width="match_parent" | |
android:layout_height="match_parent" | |
android:background="@color/colorBlust" | |
android:orientation="vertical" | |
android:padding="30dp"> | |
<com.mikhaellopez.circularimageview.CircularImageView |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class DetailActivity extends AppCompatActivity { | |
@Override | |
protected void onCreate(Bundle savedInstanceState) { | |
super.onCreate(savedInstanceState); | |
setContentView(R.layout.activity_detail); | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class CustomAlertDialog(context: Context) : AlertDialog(context, R.style.AppTheme_FullScreenDialogStyle), CustomAlertDialogBuilder.CustomDialogInterface { | |
var dismissListener: CustomAlertDialogBuilder.OnDismissListener? = null | |
private var cancelableDialog = true | |
var alertDialogInfo = CustomAlertDialogBuilder.AlertDialogInfo() | |
override fun onCreate(savedInstanceState: Bundle?) { | |
super.onCreate(savedInstanceState) | |
setContentView(R.layout.custom_dialog) | |
if (cancelableDialog) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Override | |
public void showError(String errorMessage) { | |
if (errorMessage == null || errorMessage.trim().isEmpty()) | |
errorMessage = getString(R.string.default_error_message); | |
AlertDialog dialog = new CustomAlertDialogBuilder(this) | |
.addMessage(errorMessage) | |
.setPositiveButton("OK", DialogInterface::dismiss) | |
.build(); | |
try { | |
if (dialog != null) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
lass StartSessionFragment : BaseMvpFragment(), StartSessionView { | |
companion object { | |
const val THERAPY_PACKAGE_ID = "THERAPY_PACKAGE_ID" | |
} | |
private var autoPlay: Boolean = true | |
private var isActivityDestroyed: Boolean = false | |
private val presenter = StartSessionPresenter(this) | |
private var activeTherapyPackage: TherapyPackage? = null | |
private var preSelectedTherapyPackageId: Int? = null |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android" | |
xmlns:app="http://schemas.android.com/apk/res-auto" | |
xmlns:tools="http://schemas.android.com/tools" | |
android:layout_width="match_parent" | |
android:layout_height="match_parent" | |
app:layout_behavior="@string/appbar_scrolling_view_behavior" | |
tools:context="com.empowered.healo.ui.activities.auth.AuthActivity" | |
tools:showIn="@layout/activity_auth"> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class CustomAlertDialogBuilder(val context: Context?) { | |
private var alertDialogInfo = AlertDialogInfo() | |
fun addMessage(message: String?): CustomAlertDialogBuilder { | |
this.alertDialogInfo.message = message | |
return this | |
} | |
fun addMessage(@StringRes message: Int): CustomAlertDialogBuilder { |
OlderNewer