All Downloads are FREE. Search and download functionalities are using the official Maven repository.

archetype-resources.src.TabC Maven / Gradle / Ivy

There is a newer version: 1.4.0
Show newest version
package ${package};

import com.github.rtyley.android.sherlock.roboguice.fragment.RoboSherlockFragment;

import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;

import oak.widget.TextViewWithFont;
import roboguice.inject.InjectResource;
import roboguice.inject.InjectView;

public class TabC extends RoboSherlockFragment {

    @InjectView(R.id.display_text)
        private TextViewWithFont displayText;
    @InjectResource(R.color.custom_blue)
        private int customBlue;

    @Override
    public View onCreateView(LayoutInflater inflater, ViewGroup container,
            Bundle savedInstanceState) {

        View newView = inflater.inflate(R.layout.tab_template,container,false);
        return newView;
    }

    @Override
    public void onViewCreated(View view, Bundle savedInstanceState) {
        super.onViewCreated(view, savedInstanceState);
        //Injection occurs in onViewCreated

        displayText.setText("And then there is tab C");
        displayText.setTextColor(customBlue);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy