├── .gitignore ├── LICENSE ├── README.md ├── app ├── .gitignore ├── build.gradle ├── proguard-rules.pro └── src │ ├── androidTest │ └── java │ │ └── com │ │ └── uiresource │ │ └── cookit │ │ └── ExampleInstrumentedTest.java │ ├── main │ ├── AndroidManifest.xml │ ├── assets │ │ └── fonts │ │ │ ├── SourceSansPro-LightIt.otf │ │ │ ├── SourceSansPro-Regular.otf │ │ │ └── SourceSansPro-Semibold.otf │ ├── java │ │ └── com │ │ │ └── uiresource │ │ │ └── cookit │ │ │ ├── BaseActivity.java │ │ │ ├── Detail.java │ │ │ ├── FragmentHome.java │ │ │ ├── Main.java │ │ │ ├── Splash.java │ │ │ ├── recycler │ │ │ ├── CommentsAdapter.java │ │ │ ├── ItemComment.java │ │ │ ├── ItemPreparation.java │ │ │ ├── ItemRecipe.java │ │ │ ├── ItemShopping.java │ │ │ ├── PreparationAdapter.java │ │ │ ├── RecipeAdapter.java │ │ │ ├── RecyclerTouchListener.java │ │ │ ├── SelectableAdapter.java │ │ │ └── ShoppingAdapter.java │ │ │ └── utils │ │ │ ├── AppBarStateChangeListener.java │ │ │ ├── CircleGlide.java │ │ │ ├── CustomTypefaceSpan.java │ │ │ ├── FixedFocusScrollView.java │ │ │ └── SquareImageView.java │ └── res │ │ ├── drawable-hdpi │ │ ├── ic_done.png │ │ ├── ic_facebook.png │ │ ├── ic_google.png │ │ ├── ic_instgram.png │ │ ├── ic_preparation.png │ │ ├── ic_rating_empty.png │ │ ├── ic_rating_full.png │ │ ├── ic_shoppinglist.png │ │ └── ic_twitter.png │ │ ├── drawable-mdpi │ │ ├── ic_done.png │ │ ├── ic_facebook.png │ │ ├── ic_google.png │ │ ├── ic_instgram.png │ │ ├── ic_preparation.png │ │ ├── ic_rating_empty.png │ │ ├── ic_rating_full.png │ │ ├── ic_shoppinglist.png │ │ └── ic_twitter.png │ │ ├── drawable-nodpi │ │ ├── bg.png │ │ └── logo.png │ │ ├── drawable-xhdpi │ │ ├── ic_done.png │ │ ├── ic_facebook.png │ │ ├── ic_google.png │ │ ├── ic_instgram.png │ │ ├── ic_preparation.png │ │ ├── ic_rating_empty.png │ │ ├── ic_rating_full.png │ │ ├── ic_shoppinglist.png │ │ └── ic_twitter.png │ │ ├── drawable-xxhdpi │ │ ├── ic_done.png │ │ ├── ic_facebook.png │ │ ├── ic_google.png │ │ ├── ic_instgram.png │ │ ├── ic_preparation.png │ │ ├── ic_rating_empty.png │ │ ├── ic_rating_full.png │ │ ├── ic_shoppinglist.png │ │ └── ic_twitter.png │ │ ├── drawable-xxxhdpi │ │ ├── ic_done.png │ │ ├── ic_facebook.png │ │ ├── ic_google.png │ │ ├── ic_instgram.png │ │ ├── ic_preparation.png │ │ ├── ic_rating_empty.png │ │ ├── ic_rating_full.png │ │ ├── ic_shoppinglist.png │ │ └── ic_twitter.png │ │ ├── drawable │ │ ├── bg_menu_item_selected.xml │ │ ├── bg_number.xml │ │ ├── bg_snackbar.xml │ │ ├── bg_white_ripple.xml │ │ ├── drawer_item.xml │ │ ├── ic_arrow_back.xml │ │ ├── ic_burger.xml │ │ ├── ic_burger_white.xml │ │ ├── ic_comment_red.xml │ │ ├── ic_comments.xml │ │ ├── ic_favorite.xml │ │ ├── ic_search.xml │ │ ├── ic_time.xml │ │ ├── overlay_white.xml │ │ ├── ratingbar.xml │ │ └── selector_menu.xml │ │ ├── layout │ │ ├── activity_detail.xml │ │ ├── activity_main.xml │ │ ├── activity_splash.xml │ │ ├── app_bar_main.xml │ │ ├── content_main.xml │ │ ├── fragment_home.xml │ │ ├── item_comment.xml │ │ ├── item_preparation.xml │ │ ├── item_recipe.xml │ │ ├── item_shopping.xml │ │ ├── nav_header_main.xml │ │ └── toolbar.xml │ │ ├── menu │ │ ├── activity_main_drawer.xml │ │ ├── main.xml │ │ └── menu_home.xml │ │ ├── mipmap-hdpi │ │ └── ic_launcher.png │ │ ├── mipmap-mdpi │ │ └── ic_launcher.png │ │ ├── mipmap-xhdpi │ │ └── ic_launcher.png │ │ ├── mipmap-xxhdpi │ │ └── ic_launcher.png │ │ ├── mipmap-xxxhdpi │ │ └── ic_launcher.png │ │ ├── values-hdpi │ │ └── dimens.xml │ │ ├── values-mdpi │ │ └── dimens.xml │ │ ├── values-v21 │ │ └── styles.xml │ │ ├── values-w820dp │ │ └── dimens.xml │ │ ├── values-xhdpi │ │ └── dimens.xml │ │ ├── values-xxhdpi │ │ └── dimens.xml │ │ ├── values-xxxhdpi │ │ └── dimens.xml │ │ └── values │ │ ├── colors.xml │ │ ├── dimens.xml │ │ ├── strings.xml │ │ └── styles.xml │ └── test │ └── java │ └── com │ └── uiresource │ └── cookit │ └── ExampleUnitTest.java ├── build.gradle ├── gradle.properties ├── gradle └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat ├── screenshot ├── Screenshot_20170128-162820.png ├── Screenshot_20170128-162831.png ├── Screenshot_20170128-162844.png ├── Screenshot_20170128-162853.png ├── Screenshot_20170128-162900.png ├── Screenshot_20170128-162912.png ├── Screenshot_20170128-162917.png └── Screenshot_20170128-163055.png └── settings.gradle /.gitignore: -------------------------------------------------------------------------------- 1 | # Built application files 2 | *.apk 3 | *.ap_ 4 | 5 | # Files for the ART/Dalvik VM 6 | *.dex 7 | 8 | # Java class files 9 | *.class 10 | 11 | # Generated files 12 | bin/ 13 | gen/ 14 | out/ 15 | 16 | # Gradle files 17 | .gradle/ 18 | build/ 19 | 20 | # Local configuration file (sdk path, etc) 21 | local.properties 22 | 23 | # Proguard folder generated by Eclipse 24 | proguard/ 25 | 26 | # Log Files 27 | *.log 28 | 29 | # Android Studio Navigation editor temp files 30 | .navigation/ 31 | 32 | # Android Studio captures folder 33 | captures/ 34 | 35 | # Intellij 36 | *.iml 37 | .idea/workspace.xml 38 | 39 | # Keystore files 40 | *.jks 41 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2017 Ahmad Nurhidayat 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Cook It Android XML Template 2 | 3 | Buy Me a Coffee at ko-fi.com 4 | 5 | Android xml layout for Cooking/Recipe App. 6 | 7 | Refresh your app recipe with this UI Kit, clean & tasty UI by Alex Dapunt. With this Kit, you can impress your user to make it loving your app. 8 | 9 | [Find it too on uiresource](http://uiresource.com/ui-share/recipe-app-ui-kit/) 10 | 11 | ![Splash](https://github.com/ahmadnurhidayat/Cook-It-Android-XML-Template/blob/master/screenshot/Screenshot_20170128-163055.png "Splash") 12 | ![Home](https://github.com/ahmadnurhidayat/Cook-It-Android-XML-Template/blob/master/screenshot/Screenshot_20170128-162820.png "Home") 13 | ![Drawer](https://github.com/ahmadnurhidayat/Cook-It-Android-XML-Template/blob/master/screenshot/Screenshot_20170128-162831.png "Drawer") 14 | ![Detail Recipe]https://github.com/ahmadnurhidayat/Cook-It-Android-XML-Template/blob/master/screenshot/Screenshot_20170128-162844.png "Detail Recipe") 15 | ![Shopping List](https://github.com/ahmadnurhidayat/Cook-It-Android-XML-Template/blob/master/screenshot/Screenshot_20170128-162853.png "Shopping List") 16 | ![Preparation](https://github.com/ahmadnurhidayat/Cook-It-Android-XML-Template/blob/master/screenshot/Screenshot_20170128-162900.png "Preparation") 17 | ![Share](https://github.com/ahmadnurhidayat/Cook-It-Android-XML-Template/blob/master/screenshot/Screenshot_20170128-162912.png "Share") 18 | ![Comment](https://github.com/ahmadnurhidayat/Cook-It-Android-XML-Template/blob/master/screenshot/Screenshot_20170128-162917.png "Comment") 19 | 20 | -------------------------------------------------------------------------------- /app/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /app/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: 'com.android.application' 2 | 3 | android { 4 | compileSdkVersion 24 5 | buildToolsVersion "25.0.0" 6 | defaultConfig { 7 | applicationId "com.uiresource.cookit" 8 | minSdkVersion 16 9 | targetSdkVersion 24 10 | versionCode 1 11 | versionName "1.0" 12 | testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" 13 | vectorDrawables.useSupportLibrary = true 14 | } 15 | buildTypes { 16 | debug { 17 | minifyEnabled false 18 | proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' 19 | } 20 | release { 21 | minifyEnabled false 22 | proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' 23 | } 24 | } 25 | } 26 | 27 | dependencies { 28 | compile fileTree(dir: 'libs', include: ['*.jar']) 29 | androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', { 30 | exclude group: 'com.android.support', module: 'support-annotations' 31 | }) 32 | compile 'com.android.support:appcompat-v7:24.2.1' 33 | compile 'com.android.support:design:24.2.1' 34 | compile 'uk.co.chrisjenx:calligraphy:2.2.0' 35 | compile 'com.android.support:support-v4:24.2.1' 36 | compile 'com.github.bumptech.glide:glide:3.7.0' 37 | compile 'com.android.support:recyclerview-v7:24.2.1' 38 | compile 'com.android.support:cardview-v7:24.2.1' 39 | testCompile 'junit:junit:4.12' 40 | } 41 | -------------------------------------------------------------------------------- /app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in /Volumes/Macintosh HD/Users/dytstudio/Documents/Development/Android-SDK/adt-bundle-mac-x86_64-20140702/sdk/tools/proguard/proguard-android.txt 4 | # You can edit the include path and order by changing the proguardFiles 5 | # directive in build.gradle. 6 | # 7 | # For more details, see 8 | # http://developer.android.com/guide/developing/tools/proguard.html 9 | 10 | # Add any project specific keep options here: 11 | 12 | # If your project uses WebView with JS, uncomment the following 13 | # and specify the fully qualified class name to the JavaScript interface 14 | # class: 15 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 16 | # public *; 17 | #} 18 | -keep public class * implements com.bumptech.glide.module.GlideModule 19 | -keep public enum com.bumptech.glide.load.resource.bitmap.ImageHeaderParser$** { 20 | **[] $VALUES; 21 | public *; 22 | } 23 | 24 | # for DexGuard only 25 | -keepresourcexmlelements manifest/application/meta-data@value=GlideModule -------------------------------------------------------------------------------- /app/src/androidTest/java/com/uiresource/cookit/ExampleInstrumentedTest.java: -------------------------------------------------------------------------------- 1 | package com.uiresource.cookit; 2 | 3 | import android.content.Context; 4 | import android.support.test.InstrumentationRegistry; 5 | import android.support.test.runner.AndroidJUnit4; 6 | 7 | import org.junit.Test; 8 | import org.junit.runner.RunWith; 9 | 10 | import static org.junit.Assert.*; 11 | 12 | /** 13 | * Instrumentation test, which will execute on an Android device. 14 | * 15 | * @see Testing documentation 16 | */ 17 | @RunWith(AndroidJUnit4.class) 18 | public class ExampleInstrumentedTest { 19 | @Test 20 | public void useAppContext() throws Exception { 21 | // Context of the app under test. 22 | Context appContext = InstrumentationRegistry.getTargetContext(); 23 | 24 | assertEquals("com.uiresource.cookit", appContext.getPackageName()); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 13 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 26 | 29 | 32 | 33 | 34 | 35 | -------------------------------------------------------------------------------- /app/src/main/assets/fonts/SourceSansPro-LightIt.otf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/assets/fonts/SourceSansPro-LightIt.otf -------------------------------------------------------------------------------- /app/src/main/assets/fonts/SourceSansPro-Regular.otf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/assets/fonts/SourceSansPro-Regular.otf -------------------------------------------------------------------------------- /app/src/main/assets/fonts/SourceSansPro-Semibold.otf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/assets/fonts/SourceSansPro-Semibold.otf -------------------------------------------------------------------------------- /app/src/main/java/com/uiresource/cookit/BaseActivity.java: -------------------------------------------------------------------------------- 1 | package com.uiresource.cookit; 2 | 3 | import android.content.Context; 4 | import android.graphics.Color; 5 | import android.os.Build; 6 | import android.support.annotation.ColorInt; 7 | import android.support.annotation.ColorRes; 8 | import android.support.annotation.DrawableRes; 9 | import android.support.annotation.IdRes; 10 | import android.support.v7.app.AppCompatActivity; 11 | import android.support.v7.widget.Toolbar; 12 | import android.view.Window; 13 | import android.view.WindowManager; 14 | import android.widget.TextView; 15 | 16 | import uk.co.chrisjenx.calligraphy.CalligraphyContextWrapper; 17 | 18 | /** 19 | * Created by Dytstudio. 20 | */ 21 | 22 | public class BaseActivity extends AppCompatActivity{ 23 | Toolbar toolbar; 24 | @Override 25 | protected void attachBaseContext(Context newBase) { 26 | super.attachBaseContext(CalligraphyContextWrapper.wrap(newBase)); 27 | } 28 | public void setupToolbar(int toolbarId, String title, @ColorRes int titleColor, @ColorRes int colorBg, @DrawableRes int burger){ 29 | toolbar = (Toolbar) findViewById(toolbarId); 30 | toolbar.setBackgroundColor(getResources().getColor(colorBg)); 31 | setSupportActionBar(toolbar); 32 | TextView pageTitle = (TextView) toolbar.findViewById(R.id.tv_title); 33 | pageTitle.setText(title); 34 | pageTitle.setTextColor(getResources().getColor(titleColor)); 35 | getSupportActionBar().setTitle(""); 36 | getSupportActionBar().setDisplayHomeAsUpEnabled(true); 37 | getSupportActionBar().setHomeAsUpIndicator(burger); 38 | } 39 | public void changeStatusBarColor() { 40 | if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) { 41 | Window window = getWindow(); 42 | window.addFlags(WindowManager.LayoutParams.FLAG_DRAWS_SYSTEM_BAR_BACKGROUNDS); 43 | window.setStatusBarColor(Color.TRANSPARENT); 44 | } 45 | } 46 | } 47 | -------------------------------------------------------------------------------- /app/src/main/java/com/uiresource/cookit/Detail.java: -------------------------------------------------------------------------------- 1 | package com.uiresource.cookit; 2 | 3 | import android.graphics.Color; 4 | import android.graphics.Typeface; 5 | import android.graphics.drawable.Drawable; 6 | import android.net.Uri; 7 | import android.support.design.widget.CollapsingToolbarLayout; 8 | import android.support.design.widget.CoordinatorLayout; 9 | import android.support.design.widget.Snackbar; 10 | import android.support.v4.content.ContextCompat; 11 | import android.support.v4.graphics.drawable.DrawableCompat; 12 | import android.os.Bundle; 13 | import android.support.v7.widget.DefaultItemAnimator; 14 | import android.support.v7.widget.LinearLayoutManager; 15 | import android.support.v7.widget.RecyclerView; 16 | import android.util.Log; 17 | import android.view.Gravity; 18 | import android.view.Menu; 19 | import android.view.MenuInflater; 20 | import android.view.View; 21 | import android.widget.ImageView; 22 | import android.widget.RelativeLayout; 23 | import android.widget.TextView; 24 | 25 | import com.bumptech.glide.Glide; 26 | import com.uiresource.cookit.recycler.CommentsAdapter; 27 | import com.uiresource.cookit.recycler.ItemComment; 28 | import com.uiresource.cookit.recycler.ItemPreparation; 29 | import com.uiresource.cookit.recycler.ItemShopping; 30 | import com.uiresource.cookit.recycler.PreparationAdapter; 31 | import com.uiresource.cookit.recycler.ShoppingAdapter; 32 | import com.uiresource.cookit.utils.CircleGlide; 33 | 34 | import java.util.ArrayList; 35 | import java.util.List; 36 | 37 | public class Detail extends BaseActivity implements PreparationAdapter.ViewHolder.ClickListener{ 38 | private CollapsingToolbarLayout collapsingToolbarLayout; 39 | 40 | private RecyclerView recyclerView; 41 | private ShoppingAdapter mAdapter; 42 | private RecyclerView recyclerViewPreparation; 43 | private PreparationAdapter mAdapterPreparation; 44 | private RecyclerView recyclerViewComments; 45 | private CommentsAdapter mAdapterComments; 46 | private CoordinatorLayout rootView; 47 | 48 | @Override 49 | protected void onCreate(Bundle savedInstanceState) { 50 | super.onCreate(savedInstanceState); 51 | setContentView(R.layout.activity_detail); 52 | rootView = (CoordinatorLayout) findViewById(R.id.rootview); 53 | setupToolbar(R.id.toolbar, "DESSERTS", android.R.color.white, android.R.color.transparent, R.drawable.ic_arrow_back); 54 | 55 | collapsingToolbarLayout = (CollapsingToolbarLayout) findViewById(R.id.collapsing_toolbar); 56 | collapsingToolbarLayout.setTitleEnabled(false); 57 | 58 | recyclerView = (RecyclerView) findViewById(R.id.recyclerShopping); 59 | 60 | mAdapter = new ShoppingAdapter(generateShopping(), this); 61 | LinearLayoutManager mLayoutManager = new LinearLayoutManager(this, LinearLayoutManager.VERTICAL, false); 62 | recyclerView.setLayoutManager(mLayoutManager); 63 | recyclerView.setItemAnimator(new DefaultItemAnimator()); 64 | recyclerView.setAdapter(mAdapter); 65 | 66 | recyclerViewPreparation = (RecyclerView) findViewById(R.id.recyclerPreparation); 67 | 68 | mAdapterPreparation = new PreparationAdapter(getBaseContext(), generatePreparation(),this); 69 | LinearLayoutManager mLayoutManagerPreparation = new LinearLayoutManager(this, LinearLayoutManager.VERTICAL, false); 70 | recyclerViewPreparation.setLayoutManager(mLayoutManagerPreparation); 71 | recyclerViewPreparation.setItemAnimator(new DefaultItemAnimator()); 72 | recyclerViewPreparation.setAdapter(mAdapterPreparation); 73 | 74 | recyclerViewComments = (RecyclerView) findViewById(R.id.recyclerComment); 75 | 76 | mAdapterComments = new CommentsAdapter(generateComments(), this); 77 | LinearLayoutManager mLayoutManagerComment = new LinearLayoutManager(this, LinearLayoutManager.VERTICAL, false); 78 | recyclerViewComments.setLayoutManager(mLayoutManagerComment); 79 | recyclerViewComments.setItemAnimator(new DefaultItemAnimator()); 80 | recyclerViewComments.setAdapter(mAdapterComments); 81 | 82 | 83 | final ImageView imageComment = (ImageView) findViewById(R.id.iv_user); 84 | Glide.with(this) 85 | .load(Uri.parse("https://randomuser.me/api/portraits/women/75.jpg")) 86 | .transform(new CircleGlide(this)) 87 | .into(imageComment); 88 | 89 | final ImageView image = (ImageView) findViewById(R.id.image); 90 | Glide.with(this).load(Uri.parse("https://images.pexels.com/photos/140831/pexels-photo-140831.jpeg?w=1260&h=750&auto=compress&cs=tinysrgb")).into(image); 91 | 92 | } 93 | 94 | @Override 95 | public void onItemClicked(int position) { 96 | 97 | } 98 | 99 | @Override 100 | public boolean onItemLongClicked(int position) { 101 | toggleSelection(position); 102 | return true; 103 | } 104 | 105 | private void toggleSelection(int position) { 106 | mAdapterPreparation.toggleSelection(position); 107 | final RelativeLayout rlShare = (RelativeLayout) findViewById(R.id.rl_share); 108 | if (position == mAdapterPreparation.getItemCount()-1) { 109 | 110 | Log.d("selected", "toggleSelection: "+position+" "+(mAdapterPreparation.getItemCount()-1)); 111 | rlShare.setVisibility(View.VISIBLE); 112 | } 113 | } 114 | @Override 115 | public boolean onCreateOptionsMenu(Menu menu) { 116 | MenuInflater inflater = getMenuInflater(); 117 | inflater.inflate(R.menu.menu_home, menu); 118 | Drawable drawable = menu.findItem(R.id.action_search).getIcon(); 119 | 120 | drawable = DrawableCompat.wrap(drawable); 121 | DrawableCompat.setTint(drawable, ContextCompat.getColor(this,android.R.color.white)); 122 | menu.findItem(R.id.action_search).setIcon(drawable); 123 | return true; 124 | } 125 | 126 | public List generateShopping(){ 127 | List itemList = new ArrayList<>(); 128 | String name[] = {"butter", "brown", "eggs", "flour", "baking powder", "of salt", "buttermilk", "orange juice"}; 129 | String pieces[] = {"200g", "200g", "4", "300g", "2tsp", "1 pinch", "100ml", "50ml"}; 130 | float rating[] = {3, 4, 4, 3, 5, 4, 4, 3}; 131 | 132 | for (int i = 0; i generateComments(){ 141 | List itemList = new ArrayList<>(); 142 | String username[] = {"LAURA MAGNAGO"}; 143 | String date[] = {".27-01-2017"}; 144 | String comments[] = {"Made this for a BBQ today and it was amazing. Bought 2 Madiera cakes from Tesco and cut them Into wedges. Poured the coffee over the top. And used 75ml of Ameretti instead of masala in the cream. Will be making again next week for a gathering and probably many more times! :)"}; 145 | String userphoto[] = {"https://randomuser.me/api/portraits/women/20.jpg"}; 146 | String img1[] = {"https://images.pexels.com/photos/8382/pexels-photo.jpg?h=350&auto=compress&cs=tinysrgb"}; 147 | String img2[] = {"https://images.pexels.com/photos/134574/pexels-photo-134574.jpeg?h=350&auto=compress&cs=tinysrgb"}; 148 | 149 | for (int i = 0; i generatePreparation(){ 163 | List itemList = new ArrayList<>(); 164 | String step[] = {"In a medium saucepan, whisk together egg yolks and sugar until well blended. Whisk in milk and cook over medium heat, stirring constantly, until mixture boils. Boil gently for 1 minute, remove from heat and allow to cool slightly. Cover tightly and chill in refrigerator 1 hour.", 165 | "In a medium bowl, beat cream with vanilla until stiff peaks form. Whisk mascarpone into yolk mixture until smooth.", 166 | "In a small bowl, combine coffee and rum. Split ladyfingers in half lengthwise and drizzle with coffee mixture.", 167 | "Arrange half of soaked ladyfingers in bottom of a 7x11 inch dish. Spread half of mascarpone mixture over ladyfingers, then half of whipped cream over that. Repeat layers and sprinkle with cocoa. Cover and refrigerate 4 to 6 hours, until set."}; 168 | 169 | for (int i = 0; i itemList = new ArrayList<>(); 35 | private RecyclerView recyclerView; 36 | private RecipeAdapter mAdapter; 37 | private AppCompatActivity appCompatActivity; 38 | 39 | public FragmentHome(){ 40 | setHasOptionsMenu(true); 41 | } 42 | public void onCreate(Bundle a){ 43 | super.onCreate(a); 44 | setHasOptionsMenu(true); 45 | } 46 | @Override 47 | public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) { 48 | View view = inflater.inflate(R.layout.fragment_home, null, false); 49 | 50 | ((Main)getActivity()).setupToolbar(R.id.toolbar, "DESSERT", R.color.colorPink, R.color.colorWhiteTrans, R.drawable.ic_burger); 51 | 52 | recyclerView = (RecyclerView) view.findViewById(R.id.recyclerView); 53 | 54 | mAdapter = new RecipeAdapter(setupRecipe(), getActivity()); 55 | RecyclerView.LayoutManager mLayoutManager = new GridLayoutManager(getActivity(), 2); 56 | mLayoutManager.setAutoMeasureEnabled(true); 57 | recyclerView.setLayoutManager(mLayoutManager); 58 | recyclerView.setItemAnimator(new DefaultItemAnimator()); 59 | recyclerView.setAdapter(mAdapter); 60 | 61 | appCompatActivity = (AppCompatActivity) getActivity(); 62 | 63 | recyclerView.addOnItemTouchListener(new RecyclerTouchListener(getActivity(), recyclerView, new RecyclerTouchListener.ClickListener() { 64 | @Override 65 | public void onClick(View view, int position) { 66 | startActivity(new Intent(getActivity(), Detail.class)); 67 | //Detail.navigate(appCompatActivity, view.findViewById(R.id.iv_recipe)); 68 | } 69 | 70 | @Override 71 | public void onLongClick(View view, int position) { 72 | 73 | } 74 | })); 75 | 76 | return view; 77 | } 78 | 79 | private List setupRecipe(){ 80 | itemList = new ArrayList<>(); 81 | String recipe[] = {"BLOOD ORANGE CAKE", "SEMIFREDDO TIRAMISU", "MARBLE CAKE", "RICE PUDDING", "RAINBOW CAKE", "ICE CREAM", "STROWBERRY CAKE", "CUPCAKE FRUIT"}; 82 | String img[] = {"https://images.pexels.com/photos/53468/dessert-orange-food-chocolate-53468.jpeg?h=350&auto=compress&cs=tinysrgb", 83 | "https://images.pexels.com/photos/159887/pexels-photo-159887.jpeg?h=350&auto=compress", 84 | "https://images.pexels.com/photos/136745/pexels-photo-136745.jpeg?w=1260&h=750&auto=compress&cs=tinysrgb", 85 | "https://images.pexels.com/photos/39355/dessert-raspberry-leaf-almond-39355.jpeg?h=350&auto=compress&cs=tinysrgb", 86 | "https://images.pexels.com/photos/239578/pexels-photo-239578.jpeg?w=1260&h=750&auto=compress&cs=tinysrgb", 87 | "https://images.pexels.com/photos/8382/pexels-photo.jpg?w=1260&h=750&auto=compress&cs=tinysrgb", 88 | "https://images.pexels.com/photos/51186/pexels-photo-51186.jpeg?w=1260&h=750&auto=compress&cs=tinysrgb", 89 | "https://images.pexels.com/photos/55809/dessert-strawberry-tart-berry-55809.jpeg?w=1260&h=750&auto=compress&cs=tinysrgb"}; 90 | String time[] = {"1h 5'", "30m", "1h 10'", "50m", "20m", "1h 20'", "20m", "1h 20'"}; 91 | float rating[] = {3, 4, 4, 3, 5, 4, 4, 3}; 92 | 93 | for (int i = 0; i0 ) { 60 | for (int j=0; j = 21) { 21 | getWindow().getDecorView().setSystemUiVisibility(View.SYSTEM_UI_FLAG_LAYOUT_STABLE | View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN); 22 | } 23 | 24 | changeStatusBarColor(); 25 | 26 | new Handler().postDelayed(new Runnable() { 27 | @Override 28 | public void run() { 29 | startActivity(new Intent(Splash.this, Main.class)); 30 | finish(); 31 | } 32 | }, 3*1000); 33 | } 34 | 35 | } 36 | -------------------------------------------------------------------------------- /app/src/main/java/com/uiresource/cookit/recycler/CommentsAdapter.java: -------------------------------------------------------------------------------- 1 | package com.uiresource.cookit.recycler; 2 | 3 | import android.content.Context; 4 | import android.net.Uri; 5 | import android.support.v7.widget.RecyclerView; 6 | import android.view.LayoutInflater; 7 | import android.view.View; 8 | import android.view.ViewGroup; 9 | import android.widget.ImageView; 10 | import android.widget.TextView; 11 | 12 | import com.bumptech.glide.Glide; 13 | import com.uiresource.cookit.R; 14 | import com.uiresource.cookit.utils.CircleGlide; 15 | 16 | import java.util.List; 17 | 18 | /** 19 | * Created by Dytstudio. 20 | */ 21 | 22 | public class CommentsAdapter extends RecyclerView.Adapter { 23 | 24 | private List items; 25 | private Context context; 26 | 27 | public static class MyViewHolder extends RecyclerView.ViewHolder{ 28 | public TextView username, date, comment; 29 | public ImageView img1, img2, userphoto; 30 | 31 | public MyViewHolder(View view) { 32 | super(view); 33 | 34 | username = (TextView) view.findViewById(R.id.tv_username); 35 | date = (TextView) view.findViewById(R.id.tv_date); 36 | comment = (TextView) view.findViewById(R.id.tv_text_comment); 37 | userphoto = (ImageView) view.findViewById(R.id.iv_user); 38 | img1 = (ImageView) view.findViewById(R.id.imageview1); 39 | img2 = (ImageView) view.findViewById(R.id.imageview2); 40 | } 41 | 42 | } 43 | 44 | 45 | public CommentsAdapter(List items, Context context) { 46 | this.items = items; 47 | this.context = context; 48 | } 49 | 50 | @Override 51 | public MyViewHolder onCreateViewHolder(ViewGroup parent, int viewType) { 52 | View itemView = LayoutInflater.from(parent.getContext()) 53 | .inflate(R.layout.item_comment, parent, false); 54 | 55 | return new MyViewHolder(itemView); 56 | } 57 | 58 | @Override 59 | public void onBindViewHolder(MyViewHolder holder, int position) { 60 | ItemComment itemComment = items.get(position); 61 | holder.username.setText(itemComment.getUsername()); 62 | holder.date.setText(itemComment.getDate()); 63 | holder.comment.setText(itemComment.getComments()); 64 | 65 | Glide.with(context) 66 | .load(Uri.parse(itemComment.getUserphoto())) 67 | .transform(new CircleGlide(context)) 68 | .into(holder.userphoto); 69 | Glide.with(context) 70 | .load(Uri.parse(itemComment.getImg1())) 71 | .centerCrop() 72 | .into(holder.img1); 73 | Glide.with(context) 74 | .load(Uri.parse(itemComment.getImg2())) 75 | .centerCrop() 76 | .into(holder.img2); 77 | } 78 | 79 | @Override 80 | public int getItemCount() { 81 | return items.size(); 82 | } 83 | } 84 | -------------------------------------------------------------------------------- /app/src/main/java/com/uiresource/cookit/recycler/ItemComment.java: -------------------------------------------------------------------------------- 1 | package com.uiresource.cookit.recycler; 2 | 3 | /** 4 | * Created by Dytstudio. 5 | */ 6 | 7 | public class ItemComment { 8 | String username, date, userphoto, comments, img1, img2; 9 | 10 | public void setComments(String comments) { 11 | this.comments = comments; 12 | } 13 | 14 | public String getComments() { 15 | return comments; 16 | } 17 | 18 | public void setDate(String date) { 19 | this.date = date; 20 | } 21 | 22 | public String getDate() { 23 | return date; 24 | } 25 | 26 | public void setImg1(String img1) { 27 | this.img1 = img1; 28 | } 29 | 30 | public String getImg1() { 31 | return img1; 32 | } 33 | 34 | public void setImg2(String img2) { 35 | this.img2 = img2; 36 | } 37 | 38 | public String getImg2() { 39 | return img2; 40 | } 41 | 42 | public void setUsername(String username) { 43 | this.username = username; 44 | } 45 | 46 | public String getUsername() { 47 | return username; 48 | } 49 | 50 | public String getUserphoto() { 51 | return userphoto; 52 | } 53 | 54 | public void setUserphoto(String userphoto) { 55 | this.userphoto = userphoto; 56 | } 57 | } 58 | -------------------------------------------------------------------------------- /app/src/main/java/com/uiresource/cookit/recycler/ItemPreparation.java: -------------------------------------------------------------------------------- 1 | package com.uiresource.cookit.recycler; 2 | 3 | /** 4 | * Created by Dytstudio. 5 | */ 6 | 7 | public class ItemPreparation { 8 | String step; 9 | String number; 10 | 11 | public void setStep(String step) { 12 | this.step = step; 13 | } 14 | 15 | public String getStep() { 16 | return step; 17 | } 18 | 19 | public void setNumber(String number) { 20 | this.number = number; 21 | } 22 | 23 | public String getNumber() { 24 | return number; 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /app/src/main/java/com/uiresource/cookit/recycler/ItemRecipe.java: -------------------------------------------------------------------------------- 1 | package com.uiresource.cookit.recycler; 2 | 3 | /** 4 | * Created by Dytstudio. 5 | */ 6 | 7 | public class ItemRecipe { 8 | String time, recipe, img; 9 | float rating; 10 | 11 | public void setTime(String time) { 12 | this.time = time; 13 | } 14 | 15 | public String getTime() { 16 | return time; 17 | } 18 | 19 | public void setRating(float rating) { 20 | this.rating = rating; 21 | } 22 | 23 | public float getRating() { 24 | return rating; 25 | } 26 | 27 | public String getRecipe() { 28 | return recipe; 29 | } 30 | 31 | public void setRecipe(String recipe) { 32 | this.recipe = recipe; 33 | } 34 | 35 | public void setImg(String img) { 36 | this.img = img; 37 | } 38 | 39 | public String getImg() { 40 | return img; 41 | } 42 | } 43 | -------------------------------------------------------------------------------- /app/src/main/java/com/uiresource/cookit/recycler/ItemShopping.java: -------------------------------------------------------------------------------- 1 | package com.uiresource.cookit.recycler; 2 | 3 | /** 4 | * Created by Dytstudio. 5 | */ 6 | 7 | public class ItemShopping { 8 | String name, pieces; 9 | 10 | public void setName(String name) { 11 | this.name = name; 12 | } 13 | 14 | public String getName() { 15 | return name; 16 | } 17 | 18 | public void setPieces(String pieces) { 19 | this.pieces = pieces; 20 | } 21 | 22 | public String getPieces() { 23 | return pieces; 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /app/src/main/java/com/uiresource/cookit/recycler/PreparationAdapter.java: -------------------------------------------------------------------------------- 1 | package com.uiresource.cookit.recycler; 2 | 3 | import android.content.Context; 4 | import android.os.Build; 5 | import android.support.v7.widget.RecyclerView; 6 | import android.view.LayoutInflater; 7 | import android.view.Menu; 8 | import android.view.View; 9 | import android.view.ViewGroup; 10 | import android.widget.CheckBox; 11 | import android.widget.ImageView; 12 | import android.widget.TextView; 13 | 14 | import com.uiresource.cookit.R; 15 | 16 | import java.util.List; 17 | 18 | /** 19 | * Created by Dytstudio. 20 | */ 21 | 22 | public class PreparationAdapter extends SelectableAdapter { 23 | 24 | private List mArrayList; 25 | private Context mContext; 26 | private ViewHolder.ClickListener clickListener; 27 | 28 | 29 | 30 | public PreparationAdapter (Context context, List arrayList,ViewHolder.ClickListener clickListener) { 31 | this.mArrayList = arrayList; 32 | this.mContext = context; 33 | this.clickListener = clickListener; 34 | 35 | } 36 | 37 | // Create new views 38 | @Override 39 | public PreparationAdapter.ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) { 40 | 41 | View itemLayoutView = LayoutInflater.from(parent.getContext()).inflate( 42 | R.layout.item_preparation, null); 43 | 44 | ViewHolder viewHolder = new ViewHolder(itemLayoutView,clickListener); 45 | 46 | return viewHolder; 47 | } 48 | 49 | @Override 50 | public void onBindViewHolder(ViewHolder viewHolder, int position) { 51 | 52 | viewHolder.tvStep.setText(mArrayList.get(position).getStep()); 53 | if (isSelected(position)) { 54 | viewHolder.done.setVisibility(View.VISIBLE); 55 | viewHolder.tvStep.setTextColor(mContext.getResources().getColor(R.color.colorTextGrey)); 56 | }else{ 57 | viewHolder.tvStep.setTextColor(mContext.getResources().getColor(R.color.colorTextDark)); 58 | viewHolder.tvNumber.setText(mArrayList.get(position).getNumber()); 59 | viewHolder.done.setVisibility(View.GONE); 60 | } 61 | 62 | 63 | } 64 | 65 | @Override 66 | public int getItemCount() { 67 | return mArrayList.size(); 68 | } 69 | 70 | public static class ViewHolder extends RecyclerView.ViewHolder implements View.OnClickListener,View.OnLongClickListener { 71 | 72 | public TextView tvStep; 73 | public TextView tvNumber; 74 | public ImageView done; 75 | 76 | private ClickListener listener; 77 | //private final View selectedOverlay; 78 | 79 | 80 | public ViewHolder(View itemLayoutView,ClickListener listener) { 81 | super(itemLayoutView); 82 | 83 | this.listener = listener; 84 | 85 | tvStep = (TextView) itemLayoutView.findViewById(R.id.tv_step); 86 | tvNumber = (TextView) itemLayoutView.findViewById(R.id.tv_number); 87 | done = (ImageView) itemLayoutView.findViewById(R.id.iv_done); 88 | itemLayoutView.setOnClickListener(this); 89 | 90 | itemLayoutView.setOnLongClickListener (this); 91 | } 92 | 93 | @Override 94 | public void onClick(View v) { 95 | if (listener != null) { 96 | listener.onItemClicked(getAdapterPosition ()); 97 | } 98 | } 99 | @Override 100 | public boolean onLongClick (View view) { 101 | if (listener != null) { 102 | return listener.onItemLongClicked(getAdapterPosition ()); 103 | } 104 | return false; 105 | } 106 | 107 | public interface ClickListener { 108 | public void onItemClicked(int position); 109 | 110 | public boolean onItemLongClicked(int position); 111 | 112 | boolean onCreateOptionsMenu(Menu menu); 113 | } 114 | } 115 | } 116 | -------------------------------------------------------------------------------- /app/src/main/java/com/uiresource/cookit/recycler/RecipeAdapter.java: -------------------------------------------------------------------------------- 1 | package com.uiresource.cookit.recycler; 2 | 3 | import android.content.Context; 4 | import android.net.Uri; 5 | import android.support.v7.widget.RecyclerView; 6 | import android.view.LayoutInflater; 7 | import android.view.Menu; 8 | import android.view.View; 9 | import android.view.ViewGroup; 10 | import android.widget.ImageView; 11 | import android.widget.RatingBar; 12 | import android.widget.TextView; 13 | 14 | import com.bumptech.glide.Glide; 15 | import com.uiresource.cookit.R; 16 | import com.uiresource.cookit.utils.CircleGlide; 17 | 18 | import java.util.List; 19 | 20 | /** 21 | * Created by Dytstudio. 22 | */ 23 | 24 | public class RecipeAdapter extends RecyclerView.Adapter { 25 | 26 | private List items; 27 | private Context context; 28 | private boolean active; 29 | 30 | public static class MyViewHolder extends RecyclerView.ViewHolder{ 31 | public TextView recipe, time; 32 | public RatingBar ratingBar; 33 | public ImageView imageView; 34 | 35 | public MyViewHolder(View view) { 36 | super(view); 37 | 38 | recipe = (TextView) view.findViewById(R.id.tv_recipe_name); 39 | time = (TextView) view.findViewById(R.id.tv_time); 40 | ratingBar = (RatingBar) view.findViewById(R.id.ratingBar); 41 | imageView = (ImageView) view.findViewById(R.id.iv_recipe); 42 | } 43 | 44 | 45 | } 46 | 47 | 48 | public RecipeAdapter(List items, Context context) { 49 | this.items = items; 50 | this.context = context; 51 | } 52 | 53 | @Override 54 | public MyViewHolder onCreateViewHolder(ViewGroup parent, int viewType) { 55 | View itemView = LayoutInflater.from(parent.getContext()) 56 | .inflate(R.layout.item_recipe, parent, false); 57 | 58 | return new MyViewHolder(itemView); 59 | } 60 | 61 | @Override 62 | public void onBindViewHolder(MyViewHolder holder, int position) { 63 | ItemRecipe itemRecipe = items.get(position); 64 | holder.recipe.setText(itemRecipe.getRecipe()); 65 | holder.time.setText(itemRecipe.getTime()); 66 | holder.ratingBar.setRating(itemRecipe.getRating()); 67 | Glide.with(context) 68 | .load(Uri.parse(itemRecipe.getImg())) 69 | .transform(new CircleGlide(context)) 70 | .into(holder.imageView); 71 | } 72 | 73 | @Override 74 | public int getItemCount() { 75 | return items.size(); 76 | } 77 | } -------------------------------------------------------------------------------- /app/src/main/java/com/uiresource/cookit/recycler/RecyclerTouchListener.java: -------------------------------------------------------------------------------- 1 | package com.uiresource.cookit.recycler; 2 | 3 | import android.content.Context; 4 | import android.support.v7.widget.RecyclerView; 5 | import android.view.GestureDetector; 6 | import android.view.MotionEvent; 7 | import android.view.View; 8 | 9 | /** 10 | * Created by Ravi Tamada on 03/09/16. 11 | * www.androidhive.info 12 | */ 13 | public class RecyclerTouchListener implements RecyclerView.OnItemTouchListener { 14 | 15 | private GestureDetector gestureDetector; 16 | private ClickListener clickListener; 17 | 18 | public RecyclerTouchListener(Context context, final RecyclerView recyclerView, final ClickListener clickListener) { 19 | this.clickListener = clickListener; 20 | gestureDetector = new GestureDetector(context, new GestureDetector.SimpleOnGestureListener() { 21 | @Override 22 | public boolean onSingleTapUp(MotionEvent e) { 23 | return true; 24 | } 25 | 26 | @Override 27 | public void onLongPress(MotionEvent e) { 28 | View child = recyclerView.findChildViewUnder(e.getX(), e.getY()); 29 | if (child != null && clickListener != null) { 30 | clickListener.onLongClick(child, recyclerView.getChildPosition(child)); 31 | } 32 | } 33 | }); 34 | } 35 | 36 | @Override 37 | public boolean onInterceptTouchEvent(RecyclerView rv, MotionEvent e) { 38 | 39 | View child = rv.findChildViewUnder(e.getX(), e.getY()); 40 | if (child != null && clickListener != null && gestureDetector.onTouchEvent(e)) { 41 | clickListener.onClick(child, rv.getChildPosition(child)); 42 | } 43 | return false; 44 | } 45 | 46 | @Override 47 | public void onTouchEvent(RecyclerView rv, MotionEvent e) { 48 | } 49 | 50 | @Override 51 | public void onRequestDisallowInterceptTouchEvent(boolean disallowIntercept) { 52 | 53 | } 54 | 55 | public interface ClickListener { 56 | void onClick(View view, int position); 57 | 58 | void onLongClick(View view, int position); 59 | } 60 | } -------------------------------------------------------------------------------- /app/src/main/java/com/uiresource/cookit/recycler/SelectableAdapter.java: -------------------------------------------------------------------------------- 1 | package com.uiresource.cookit.recycler; 2 | 3 | import android.support.v7.widget.RecyclerView; 4 | import android.util.SparseBooleanArray; 5 | 6 | import java.util.ArrayList; 7 | import java.util.List; 8 | 9 | /** 10 | * Created by Dytstudio. 11 | */ 12 | 13 | public abstract class SelectableAdapter extends RecyclerView.Adapter { 14 | @SuppressWarnings("unused") 15 | private static final String TAG = SelectableAdapter.class.getSimpleName(); 16 | 17 | private SparseBooleanArray selectedItems; 18 | 19 | public SelectableAdapter() { 20 | selectedItems = new SparseBooleanArray(); 21 | } 22 | 23 | /** 24 | * Indicates if the item at position position is selected 25 | * @param position Position of the item to check 26 | * @return true if the item is selected, false otherwise 27 | */ 28 | public boolean isSelected(int position) { 29 | return getSelectedItems().contains(position); 30 | } 31 | 32 | /** 33 | * Toggle the selection status of the item at a given position 34 | * @param position Position of the item to toggle the selection status for 35 | */ 36 | public void toggleSelection(int position) { 37 | if (selectedItems.get(position, false)) { 38 | selectedItems.delete(position); 39 | } else { 40 | selectedItems.put(position, true); 41 | } 42 | notifyItemChanged(position); 43 | } 44 | 45 | /** 46 | * Clear the selection status for all items 47 | */ 48 | public void clearSelection() { 49 | List selection = getSelectedItems(); 50 | selectedItems.clear(); 51 | for (Integer i : selection) { 52 | notifyItemChanged(i); 53 | } 54 | } 55 | 56 | /** 57 | * Count the selected items 58 | * @return Selected items count 59 | */ 60 | public int getSelectedItemCount() { 61 | return selectedItems.size(); 62 | } 63 | 64 | /** 65 | * Indicates the list of selected items 66 | * @return List of selected items ids 67 | */ 68 | public List getSelectedItems() { 69 | List items = new ArrayList<>(selectedItems.size()); 70 | for (int i = 0; i < selectedItems.size(); ++i) { 71 | items.add(selectedItems.keyAt(i)); 72 | } 73 | return items; 74 | } 75 | } -------------------------------------------------------------------------------- /app/src/main/java/com/uiresource/cookit/recycler/ShoppingAdapter.java: -------------------------------------------------------------------------------- 1 | package com.uiresource.cookit.recycler; 2 | 3 | import android.content.Context; 4 | import android.net.Uri; 5 | import android.support.v7.widget.RecyclerView; 6 | import android.view.LayoutInflater; 7 | import android.view.View; 8 | import android.view.ViewGroup; 9 | import android.widget.ImageView; 10 | import android.widget.RatingBar; 11 | import android.widget.TextView; 12 | 13 | import com.bumptech.glide.Glide; 14 | import com.uiresource.cookit.R; 15 | import com.uiresource.cookit.utils.CircleGlide; 16 | 17 | import java.util.List; 18 | 19 | /** 20 | * Created by Dytstudio. 21 | */ 22 | 23 | public class ShoppingAdapter extends RecyclerView.Adapter { 24 | 25 | private List items; 26 | private Context context; 27 | 28 | public static class MyViewHolder extends RecyclerView.ViewHolder{ 29 | public TextView pieces, name; 30 | 31 | public MyViewHolder(View view) { 32 | super(view); 33 | 34 | pieces = (TextView) view.findViewById(R.id.tv_pieces); 35 | name = (TextView) view.findViewById(R.id.tv_name); 36 | } 37 | 38 | } 39 | 40 | 41 | public ShoppingAdapter(List items, Context context) { 42 | this.items = items; 43 | this.context = context; 44 | } 45 | 46 | @Override 47 | public ShoppingAdapter.MyViewHolder onCreateViewHolder(ViewGroup parent, int viewType) { 48 | View itemView = LayoutInflater.from(parent.getContext()) 49 | .inflate(R.layout.item_shopping, parent, false); 50 | 51 | return new ShoppingAdapter.MyViewHolder(itemView); 52 | } 53 | 54 | @Override 55 | public void onBindViewHolder(ShoppingAdapter.MyViewHolder holder, int position) { 56 | ItemShopping itemShopping = items.get(position); 57 | holder.name.setText(itemShopping.getName()); 58 | holder.pieces.setText(itemShopping.getPieces()); 59 | } 60 | 61 | @Override 62 | public int getItemCount() { 63 | return items.size(); 64 | } 65 | } -------------------------------------------------------------------------------- /app/src/main/java/com/uiresource/cookit/utils/AppBarStateChangeListener.java: -------------------------------------------------------------------------------- 1 | package com.uiresource.cookit.utils; 2 | 3 | import android.support.design.widget.AppBarLayout; 4 | 5 | /** 6 | * Created by Dytstudio. 7 | */ 8 | 9 | public abstract class AppBarStateChangeListener implements AppBarLayout.OnOffsetChangedListener { 10 | 11 | public enum State { 12 | EXPANDED, 13 | COLLAPSED, 14 | IDLE 15 | } 16 | 17 | private State mCurrentState = State.IDLE; 18 | 19 | @Override 20 | public final void onOffsetChanged(AppBarLayout appBarLayout, int i) { 21 | if (i == 0) { 22 | if (mCurrentState != State.EXPANDED) { 23 | onStateChanged(appBarLayout, State.EXPANDED); 24 | } 25 | mCurrentState = State.EXPANDED; 26 | } else if (Math.abs(i) >= appBarLayout.getTotalScrollRange()) { 27 | if (mCurrentState != State.COLLAPSED) { 28 | onStateChanged(appBarLayout, State.COLLAPSED); 29 | } 30 | mCurrentState = State.COLLAPSED; 31 | } else { 32 | if (mCurrentState != State.IDLE) { 33 | onStateChanged(appBarLayout, State.IDLE); 34 | } 35 | mCurrentState = State.IDLE; 36 | } 37 | } 38 | 39 | public abstract void onStateChanged(AppBarLayout appBarLayout, State state); 40 | } -------------------------------------------------------------------------------- /app/src/main/java/com/uiresource/cookit/utils/CircleGlide.java: -------------------------------------------------------------------------------- 1 | package com.uiresource.cookit.utils; 2 | 3 | import android.content.Context; 4 | import android.graphics.Bitmap; 5 | import android.graphics.BitmapShader; 6 | import android.graphics.Canvas; 7 | import android.graphics.Paint; 8 | 9 | import com.bumptech.glide.load.engine.bitmap_recycle.BitmapPool; 10 | import com.bumptech.glide.load.resource.bitmap.BitmapTransformation; 11 | 12 | /** 13 | * Created by Dytstudio. 14 | */ 15 | 16 | public class CircleGlide extends BitmapTransformation { 17 | public CircleGlide(Context context) { 18 | super(context); 19 | } 20 | 21 | @Override protected Bitmap transform(BitmapPool pool, Bitmap toTransform, int outWidth, int outHeight) { 22 | return circleCrop(pool, toTransform); 23 | } 24 | 25 | private static Bitmap circleCrop(BitmapPool pool, Bitmap source) { 26 | if (source == null) return null; 27 | 28 | int size = Math.min(source.getWidth(), source.getHeight()); 29 | int x = (source.getWidth() - size) / 2; 30 | int y = (source.getHeight() - size) / 2; 31 | 32 | // TODO this could be acquired from the pool too 33 | Bitmap squared = Bitmap.createBitmap(source, x, y, size, size); 34 | 35 | Bitmap result = pool.get(size, size, Bitmap.Config.ARGB_8888); 36 | if (result == null) { 37 | result = Bitmap.createBitmap(size, size, Bitmap.Config.ARGB_8888); 38 | } 39 | 40 | Canvas canvas = new Canvas(result); 41 | Paint paint = new Paint(); 42 | paint.setShader(new BitmapShader(squared, BitmapShader.TileMode.CLAMP, BitmapShader.TileMode.CLAMP)); 43 | paint.setAntiAlias(true); 44 | float r = size / 2f; 45 | canvas.drawCircle(r, r, r, paint); 46 | return result; 47 | } 48 | 49 | @Override public String getId() { 50 | return getClass().getName(); 51 | } 52 | } -------------------------------------------------------------------------------- /app/src/main/java/com/uiresource/cookit/utils/CustomTypefaceSpan.java: -------------------------------------------------------------------------------- 1 | package com.uiresource.cookit.utils; 2 | 3 | import android.graphics.Paint; 4 | import android.graphics.Typeface; 5 | import android.text.TextPaint; 6 | import android.text.style.TypefaceSpan; 7 | 8 | /** 9 | * Created by Dytstudio. 10 | */ 11 | 12 | public class CustomTypefaceSpan extends TypefaceSpan { 13 | 14 | private final Typeface newType; 15 | 16 | public CustomTypefaceSpan(String family, Typeface type) { 17 | super(family); 18 | newType = type; 19 | } 20 | 21 | @Override 22 | public void updateDrawState(TextPaint ds) { 23 | applyCustomTypeFace(ds, newType); 24 | } 25 | 26 | @Override 27 | public void updateMeasureState(TextPaint paint) { 28 | applyCustomTypeFace(paint, newType); 29 | } 30 | 31 | private static void applyCustomTypeFace(Paint paint, Typeface tf) { 32 | int oldStyle; 33 | Typeface old = paint.getTypeface(); 34 | if (old == null) { 35 | oldStyle = 0; 36 | } else { 37 | oldStyle = old.getStyle(); 38 | } 39 | 40 | int fake = oldStyle & ~tf.getStyle(); 41 | if ((fake & Typeface.BOLD) != 0) { 42 | paint.setFakeBoldText(true); 43 | } 44 | 45 | if ((fake & Typeface.ITALIC) != 0) { 46 | paint.setTextSkewX(-0.25f); 47 | } 48 | 49 | paint.setTypeface(tf); 50 | } 51 | } -------------------------------------------------------------------------------- /app/src/main/java/com/uiresource/cookit/utils/FixedFocusScrollView.java: -------------------------------------------------------------------------------- 1 | package com.uiresource.cookit.utils; 2 | 3 | import android.content.Context; 4 | import android.support.v4.widget.NestedScrollView; 5 | import android.util.AttributeSet; 6 | import android.view.View; 7 | import android.widget.ScrollView; 8 | 9 | import java.util.ArrayList; 10 | 11 | /** 12 | * Created by Dytstudio. 13 | */ 14 | 15 | public class FixedFocusScrollView extends NestedScrollView { 16 | 17 | public FixedFocusScrollView(Context context, AttributeSet attrs, int defStyle) { 18 | super(context, attrs, defStyle); 19 | } 20 | 21 | public FixedFocusScrollView(Context context, AttributeSet attrs) { 22 | super(context, attrs); 23 | } 24 | 25 | public FixedFocusScrollView(Context context) { 26 | super(context); 27 | } 28 | 29 | @Override 30 | public ArrayList getFocusables(int direction) { 31 | return new ArrayList(); 32 | } 33 | 34 | } -------------------------------------------------------------------------------- /app/src/main/java/com/uiresource/cookit/utils/SquareImageView.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2015 Antonio Leiva 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | package com.uiresource.cookit.utils; 18 | 19 | import android.content.Context; 20 | import android.util.AttributeSet; 21 | import android.widget.ImageView; 22 | 23 | public class SquareImageView extends ImageView { 24 | 25 | public SquareImageView(Context context) { 26 | super(context); 27 | } 28 | 29 | public SquareImageView(Context context, AttributeSet attrs) { 30 | super(context, attrs); 31 | } 32 | 33 | public SquareImageView(Context context, AttributeSet attrs, int defStyleAttr) { 34 | super(context, attrs, defStyleAttr); 35 | } 36 | 37 | @Override 38 | protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) { 39 | super.onMeasure(widthMeasureSpec, heightMeasureSpec); 40 | 41 | int width = getMeasuredWidth(); 42 | setMeasuredDimension(width, width); 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_done.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-hdpi/ic_done.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_facebook.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-hdpi/ic_facebook.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_google.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-hdpi/ic_google.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_instgram.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-hdpi/ic_instgram.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_preparation.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-hdpi/ic_preparation.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_rating_empty.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-hdpi/ic_rating_empty.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_rating_full.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-hdpi/ic_rating_full.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_shoppinglist.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-hdpi/ic_shoppinglist.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_twitter.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-hdpi/ic_twitter.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-mdpi/ic_done.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-mdpi/ic_done.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-mdpi/ic_facebook.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-mdpi/ic_facebook.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-mdpi/ic_google.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-mdpi/ic_google.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-mdpi/ic_instgram.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-mdpi/ic_instgram.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-mdpi/ic_preparation.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-mdpi/ic_preparation.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-mdpi/ic_rating_empty.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-mdpi/ic_rating_empty.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-mdpi/ic_rating_full.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-mdpi/ic_rating_full.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-mdpi/ic_shoppinglist.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-mdpi/ic_shoppinglist.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-mdpi/ic_twitter.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-mdpi/ic_twitter.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-nodpi/bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-nodpi/bg.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-nodpi/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-nodpi/logo.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/ic_done.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xhdpi/ic_done.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/ic_facebook.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xhdpi/ic_facebook.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/ic_google.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xhdpi/ic_google.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/ic_instgram.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xhdpi/ic_instgram.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/ic_preparation.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xhdpi/ic_preparation.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/ic_rating_empty.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xhdpi/ic_rating_empty.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/ic_rating_full.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xhdpi/ic_rating_full.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/ic_shoppinglist.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xhdpi/ic_shoppinglist.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/ic_twitter.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xhdpi/ic_twitter.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/ic_done.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xxhdpi/ic_done.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/ic_facebook.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xxhdpi/ic_facebook.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/ic_google.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xxhdpi/ic_google.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/ic_instgram.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xxhdpi/ic_instgram.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/ic_preparation.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xxhdpi/ic_preparation.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/ic_rating_empty.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xxhdpi/ic_rating_empty.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/ic_rating_full.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xxhdpi/ic_rating_full.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/ic_shoppinglist.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xxhdpi/ic_shoppinglist.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/ic_twitter.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xxhdpi/ic_twitter.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxxhdpi/ic_done.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xxxhdpi/ic_done.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxxhdpi/ic_facebook.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xxxhdpi/ic_facebook.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxxhdpi/ic_google.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xxxhdpi/ic_google.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxxhdpi/ic_instgram.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xxxhdpi/ic_instgram.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxxhdpi/ic_preparation.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xxxhdpi/ic_preparation.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxxhdpi/ic_rating_empty.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xxxhdpi/ic_rating_empty.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxxhdpi/ic_rating_full.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xxxhdpi/ic_rating_full.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxxhdpi/ic_shoppinglist.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xxxhdpi/ic_shoppinglist.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxxhdpi/ic_twitter.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dytlabs/Cook-It-Android-XML-Template/3a33211a66e636e08b8f58c7b744ccfae953e5a0/app/src/main/res/drawable-xxxhdpi/ic_twitter.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/bg_menu_item_selected.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/bg_number.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/bg_snackbar.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/bg_white_ripple.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/drawer_item.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_arrow_back.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_burger.xml: -------------------------------------------------------------------------------- 1 | 6 | 11 | 12 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_burger_white.xml: -------------------------------------------------------------------------------- 1 | 6 | 11 | 12 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_comment_red.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_comments.xml: -------------------------------------------------------------------------------- 1 | 6 | 11 | 16 | 21 | 22 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_favorite.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_search.xml: -------------------------------------------------------------------------------- 1 | 6 | 11 | 12 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_time.xml: -------------------------------------------------------------------------------- 1 | 6 | 11 | 12 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/overlay_white.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ratingbar.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 6 | 9 | 12 | 13 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/selector_menu.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/layout/activity_detail.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 15 | 28 | 29 | 36 | 41 | 42 | 56 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 76 | 77 | 80 | 81 | 88 | 98 | 108 | 113 | 123 | 134 | 145 | 146 | 157 | 165 | 166 | 174 |