THREAD: [ASK A GURU] Android Development Tutorials!
  1. 06-22-2016, 03:30 AM
    Mr Smithy x's Avatar
    Mr Smithy x
    Former Staff
    Mr Smithy x's Avatar
    Mr Smithy x
    Former Staff
    Nov 2013
    Jump ahead into Android Development; it's a awesome platform to create applications in.
    If you do not know, Android native language is Java and android developers design their layouts via xml.
    You need a decent Java background but C# background should suffice.

    What you need to know:

    #Android has a life cycle (TLDR Version)

    - onCreate: When you first start an activity, you will be able to bind the views (from xml)

    - onRestart: When the activity has been stopped/partially ended, it will restart upon opening the activity

    - onStart: This is where the user can see the content on the screen

    - onResume: THis is where the user see the screen in the foreground and can interact with it, The activity is basically in the forefront.

    - onPause:
    When you are on activity A but opened Activity B, A is now paused

    - onStop: When you press the home button, or when the activity is about to be killed.

    - onDestroy: This is the final call until the activity is completely and utterly destroyed. There is no comming back, This method cleans the garbage up that maybe left over except unmanagable data (ie Left open sockets).

    #Android has a couple thing you will commonly work with:

    Activity (Needed)
    Fragment (Optional)
    DialogFragment (Custom MessageBox) (Optional)
    BottomSheetDialog (Optional)
    AlertDialog (MessageBox) (Optional)

    #Important that you understand interfaces!

    Method 1:

    view.setOnClickListener(new OnClickListener(){

    public void onClick(View view){

    Method 2:

    public interface Callback {
    void OnReceived(String hi);

    public class Dude{
    Callback callback;
    public Dude(Callback callback){
    this.callback = callback;
    public start(String text){

    public class Wow implements Callback{

    public void main(){
    new Dude(this).start("Bro How Are You?");
    void OnReceived(String hi){
    //Outputs: Bro How Are You?

    #Designing Layouts

    Designing layouts can be a little tricky but it takes practice.
    I use to get frustrated when i cant make a good design.

    Design tips:
    LinearLayout/RelativeLayout/_______Layout -> android:padding="16dp"


    android:marginBottom="4dp or 8dp"*
    <!--dont give the last view margin if vertical orientation-->

    # Android MVC Model

    - What is MVC? - Model View Controller

    - Model: Class Object

    - View: Xml View

    - Controller: Adapter

    Model are classes that just stores data that is valuable.

    View is the view that you design in the xml.

    Controller (Adapters) are what controls the content.

    *** Every List needs a Model, View and a Controller to know what to do.

    Common MVC View you will use:


    Spinner (Winform ComboBox Equivalent)

    ListView (Winform ListView Equivalent)


    RecyclerView (Like ListView but more advance)

    Tutorial Series comming soon.
    You must login or register to view this content.
    Intermediate Tutorial Series:

    Basic Series:

    - Networking

    - AsyncTask

    - Threads & Handlers

    - When to use Abstract & Interfaces

    Network Series:

    - Understanding Permissions and Running Code On The Main Thread

    - Network Calls On the Main Thread Vs Asyncronously Network Calls

    - Bypassing Main Thread Errors (Not Reccommended)

    - Json Parsing

    Gradle Series:

    - Importing Libraries

    - Changing SDK Min/Max Version

    Library Series:

    - Getting Familiar with popular libraries and what they do

    - OkHttp

    - Gson

    Advance Tutorial Series:

    - Reflection with Annotations

    - Retrofit

    - AndroidAnnotation

    If you have any request, dont hesistate to ask!
    Last edited by Mr Smithy x ; 07-16-2016 at 01:42 PM.

  2. The Following 2 Users Say Thank You to Mr Smithy x For This Useful Post: