Search in sources :

Example 1 with WeatherCard

use of it.gmariotti.cardslib.demo.extras.cards.WeatherCard in project cardslib by gabrielemariotti.

the class CardWithListFragment method initCard.

/**
     * This method builds a simple card
     */
private void initCard() {
    //Weather Card
    card = new WeatherCard(getActivity());
    card.init();
    //Set card in the cardView
    CardView cardView = (CardView) getActivity().findViewById(R.id.carddemo_weathercard);
    cardView.setCard(card);
    //May know card
    GoogleKnowwithList card2 = new GoogleKnowwithList(getActivity());
    card2.init();
    //Set card in the cardView
    CardView cardView2 = (CardView) getActivity().findViewById(R.id.carddemo_mayknowcard);
    cardView2.setCard(card2);
}
Also used : GoogleKnowwithList(it.gmariotti.cardslib.demo.extras.cards.GoogleKnowwithList) WeatherCard(it.gmariotti.cardslib.demo.extras.cards.WeatherCard) CardView(it.gmariotti.cardslib.library.view.CardView)

Aggregations

GoogleKnowwithList (it.gmariotti.cardslib.demo.extras.cards.GoogleKnowwithList)1 WeatherCard (it.gmariotti.cardslib.demo.extras.cards.WeatherCard)1 CardView (it.gmariotti.cardslib.library.view.CardView)1