// Path: app/src/main/java/com/ragdroid/dahaka/activity/home/HomeActivity.java
// public class HomeActivity extends BaseUserActivity<HomeContract.Presenter> {
// 
// 
//     @Inject ProfileFragment profileFragment;
//     @Inject StatsFragment statsFragment;
//     @Inject MovesFragment movesFragment;
// 
//     private ActivityHomeBinding viewDataBinding;
// 
//     private BottomNavigationView.OnNavigationItemSelectedListener navigationListener
//             = new BottomNavigationView.OnNavigationItemSelectedListener() {
// 
//         @Override
//         public boolean onNavigationItemSelected(@NonNull MenuItem item) {
//             int itemId = item.getItemId();
//             if (viewDataBinding.bottomNavigation.getSelectedItemId() == itemId) {
//                 //do nothing if reselected
//                 return true;
//             }
//             return openFragment(itemId);
//         }
// 
//     };
// 
//     private boolean openFragment(int itemId) {
//         Fragment fragment = null;
//         switch (itemId) {
//             case R.id.action_profile:
//                 fragment = profileFragment;
//                 break;
//             case R.id.action_moves:
//                 fragment = movesFragment;
//                 break;
//             case R.id.action_stats:
//                 fragment = statsFragment;
//                 break;
//         }
// 
//         if (fragment != null) {
//             getSupportFragmentManager()
//                     .beginTransaction()
//                     .replace(R.id.fragment_container, fragment)
//                     .commit();
//             return true;
//         }
//         return false;
//     }
// 
//     @Override
//     protected void onCreate(Bundle savedInstanceState) {
//         super.onCreate(savedInstanceState);
//         viewDataBinding = DataBindingUtil.setContentView(this, R.layout.activity_home);
//         viewDataBinding.bottomNavigation.setOnNavigationItemSelectedListener(navigationListener);
//         viewDataBinding.bottomNavigation.setSelectedItemId(R.id.action_profile);
//         openFragment(R.id.action_profile);
//     }
// 
//     @Override
//     public boolean onCreateOptionsMenu(Menu menu) {
//         getMenuInflater().inflate(R.menu.menu_home, menu);
//         return super.onCreateOptionsMenu(menu);
//     }
// 
//     @Override
//     public boolean onOptionsItemSelected(MenuItem item) {
//         if (item.getItemId() == R.id.action_log_out) {
//             logoutUser();
//             return true;
//         } else if (item.getItemId() == R.id.action_items) {
//             openItemsActivity();
//             return true;
//         }
//         return super.onOptionsItemSelected(item);
//     }
// 
//     private void openItemsActivity() {
//         Intent intent = new Intent(this, ItemsActivity.class);
//         startActivity(intent);
//     }
// 
// 
// }
// 
// Path: app/src/main/java/com/ragdroid/dahaka/activity/home/HomeModule.java
// @Module
// public abstract class HomeModule {
// 
//     @ContributesAndroidInjector
//     abstract ProfileFragment profileFragment();
// 
//     @ContributesAndroidInjector
//     abstract MovesFragment movesFragment();
// 
//     @ContributesAndroidInjector
//     abstract StatsFragment statisticsFragment();
// 
// 
//     @Binds
//     public abstract HomeContract.Presenter provideHomePresenter(HomePresenter presenter);
// 
//     @Binds
//     public abstract ProfileContract.Presenter provideProfilePresenter(ProfilePresenter presenter);
// 
//     @Binds
//     public abstract StatsContract.Presenter provideStatsPresenter(StatsPresenter presenter);
// 
//     @Binds
//     public abstract MovesContract.Presenter provideMovesPresenter(MovesPresenter presenter);
// 
// }
// 
// Path: app/src/main/java/com/ragdroid/dahaka/activity/items/ItemsActivity.java
// public class ItemsActivity extends BaseUserActivity<ItemsContract.Presenter> implements ItemsContract.View {
// 
//     @Inject ItemsAdapter adapter;
//     @Inject LinearLayoutManager linearLayoutManager;
//     @Inject DividerItemDecoration dividerItemDecoration;
//     private ActivityItemsBinding binding;
// 
// 
//     @Override
//     protected void onCreate(@Nullable Bundle savedInstanceState) {
//         binding = DataBindingUtil.setContentView(this, R.layout.activity_items);
//         super.onCreate(savedInstanceState);
//         Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar);
//         setSupportActionBar(toolbar);
//         toolbar.setNavigationIcon(R.drawable.ic_arrow_back);
//         toolbar.setNavigationOnClickListener(view -> finish());
//     }
// 
//     @Override
//     public void showModel(ItemsModel model) {
//         binding.itemsRecyclerView.setAdapter(adapter);
//         binding.itemsRecyclerView.addItemDecoration(dividerItemDecoration);
//         binding.itemsRecyclerView.setLayoutManager(linearLayoutManager);
//         adapter.updateList(model.items);
//     }
// }
// 
// Path: app/src/main/java/com/ragdroid/dahaka/activity/items/ItemsModule.java
// @Module
// public class ItemsModule {
// 
//     @Provides
//     static ItemsContract.Presenter provideHomePresenter(ItemsPresenter presenter) {
//         return presenter;
//     }
// 
//     @Provides
//     static ItemsAdapter provideItemsAdapter() {
//         return new ItemsAdapter();
//     }
// 
//     @Provides
//     static LinearLayoutManager provideLayoutManager(ItemsActivity activity) {
//         return new LinearLayoutManager(activity);
//     }
// 
//     @Provides
//     static DividerItemDecoration provideDividerItemDecoration(ItemsActivity activity) {
//         return new DividerItemDecoration(activity, DividerItemDecoration.VERTICAL);
//     }
// 
// }


import com.ragdroid.dahaka.activity.home.HomeActivity;
import com.ragdroid.dahaka.activity.home.HomeModule;
import com.ragdroid.dahaka.activity.items.ItemsActivity;
import com.ragdroid.dahaka.activity.items.ItemsModule;
import dagger.Module;
import dagger.android.ContributesAndroidInjector;
import dagger.android.support.AndroidSupportInjectionModule;
package com.ragdroid.dahaka.user;




/**
 * Created by garimajain on 13/08/17.
 */
@Module
public abstract class UserBindingModule {


// Path: app/src/main/java/com/ragdroid/dahaka/activity/home/HomeActivity.java
// public class HomeActivity extends BaseUserActivity<HomeContract.Presenter> {
// 
// 
//     @Inject ProfileFragment profileFragment;
//     @Inject StatsFragment statsFragment;
//     @Inject MovesFragment movesFragment;
// 
//     private ActivityHomeBinding viewDataBinding;
// 
//     private BottomNavigationView.OnNavigationItemSelectedListener navigationListener
//             = new BottomNavigationView.OnNavigationItemSelectedListener() {
// 
//         @Override
//         public boolean onNavigationItemSelected(@NonNull MenuItem item) {
//             int itemId = item.getItemId();
//             if (viewDataBinding.bottomNavigation.getSelectedItemId() == itemId) {
//                 //do nothing if reselected
//                 return true;
//             }
//             return openFragment(itemId);
//         }
// 
//     };
// 
//     private boolean openFragment(int itemId) {
//         Fragment fragment = null;
//         switch (itemId) {
//             case R.id.action_profile:
//                 fragment = profileFragment;
//                 break;
//             case R.id.action_moves:
//                 fragment = movesFragment;
//                 break;
//             case R.id.action_stats:
//                 fragment = statsFragment;
//                 break;
//         }
// 
//         if (fragment != null) {
//             getSupportFragmentManager()
//                     .beginTransaction()
//                     .replace(R.id.fragment_container, fragment)
//                     .commit();
//             return true;
//         }
//         return false;
//     }
// 
//     @Override
//     protected void onCreate(Bundle savedInstanceState) {
//         super.onCreate(savedInstanceState);
//         viewDataBinding = DataBindingUtil.setContentView(this, R.layout.activity_home);
//         viewDataBinding.bottomNavigation.setOnNavigationItemSelectedListener(navigationListener);
//         viewDataBinding.bottomNavigation.setSelectedItemId(R.id.action_profile);
//         openFragment(R.id.action_profile);
//     }
// 
//     @Override
//     public boolean onCreateOptionsMenu(Menu menu) {
//         getMenuInflater().inflate(R.menu.menu_home, menu);
//         return super.onCreateOptionsMenu(menu);
//     }
// 
//     @Override
//     public boolean onOptionsItemSelected(MenuItem item) {
//         if (item.getItemId() == R.id.action_log_out) {
//             logoutUser();
//             return true;
//         } else if (item.getItemId() == R.id.action_items) {
//             openItemsActivity();
//             return true;
//         }
//         return super.onOptionsItemSelected(item);
//     }
// 
//     private void openItemsActivity() {
//         Intent intent = new Intent(this, ItemsActivity.class);
//         startActivity(intent);
//     }
// 
// 
// }
// 
// Path: app/src/main/java/com/ragdroid/dahaka/activity/home/HomeModule.java
// @Module
// public abstract class HomeModule {
// 
//     @ContributesAndroidInjector
//     abstract ProfileFragment profileFragment();
// 
//     @ContributesAndroidInjector
//     abstract MovesFragment movesFragment();
// 
//     @ContributesAndroidInjector
//     abstract StatsFragment statisticsFragment();
// 
// 
//     @Binds
//     public abstract HomeContract.Presenter provideHomePresenter(HomePresenter presenter);
// 
//     @Binds
//     public abstract ProfileContract.Presenter provideProfilePresenter(ProfilePresenter presenter);
// 
//     @Binds
//     public abstract StatsContract.Presenter provideStatsPresenter(StatsPresenter presenter);
// 
//     @Binds
//     public abstract MovesContract.Presenter provideMovesPresenter(MovesPresenter presenter);
// 
// }
// 
// Path: app/src/main/java/com/ragdroid/dahaka/activity/items/ItemsActivity.java
// public class ItemsActivity extends BaseUserActivity<ItemsContract.Presenter> implements ItemsContract.View {
// 
//     @Inject ItemsAdapter adapter;
//     @Inject LinearLayoutManager linearLayoutManager;
//     @Inject DividerItemDecoration dividerItemDecoration;
//     private ActivityItemsBinding binding;
// 
// 
//     @Override
//     protected void onCreate(@Nullable Bundle savedInstanceState) {
//         binding = DataBindingUtil.setContentView(this, R.layout.activity_items);
//         super.onCreate(savedInstanceState);
//         Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar);
//         setSupportActionBar(toolbar);
//         toolbar.setNavigationIcon(R.drawable.ic_arrow_back);
//         toolbar.setNavigationOnClickListener(view -> finish());
//     }
// 
//     @Override
//     public void showModel(ItemsModel model) {
//         binding.itemsRecyclerView.setAdapter(adapter);
//         binding.itemsRecyclerView.addItemDecoration(dividerItemDecoration);
//         binding.itemsRecyclerView.setLayoutManager(linearLayoutManager);
//         adapter.updateList(model.items);
//     }
// }
// 
// Path: app/src/main/java/com/ragdroid/dahaka/activity/items/ItemsModule.java
// @Module
// public class ItemsModule {
// 
//     @Provides
//     static ItemsContract.Presenter provideHomePresenter(ItemsPresenter presenter) {
//         return presenter;
//     }
// 
//     @Provides
//     static ItemsAdapter provideItemsAdapter() {
//         return new ItemsAdapter();
//     }
// 
//     @Provides
//     static LinearLayoutManager provideLayoutManager(ItemsActivity activity) {
//         return new LinearLayoutManager(activity);
//     }
// 
//     @Provides
//     static DividerItemDecoration provideDividerItemDecoration(ItemsActivity activity) {
//         return new DividerItemDecoration(activity, DividerItemDecoration.VERTICAL);
//     }
// 
// }


// Path: app/src/main/java/com/ragdroid/dahaka/user/UserBindingModule.java
import com.ragdroid.dahaka.activity.home.HomeActivity;
import com.ragdroid.dahaka.activity.home.HomeModule;
import com.ragdroid.dahaka.activity.items.ItemsActivity;
import com.ragdroid.dahaka.activity.items.ItemsModule;
import dagger.Module;
import dagger.android.ContributesAndroidInjector;
import dagger.android.support.AndroidSupportInjectionModule;

package com.ragdroid.dahaka.user;




/**
 * Created by garimajain on 13/08/17.
 */
@Module
public abstract class UserBindingModule {


    @ContributesAndroidInjector(modules = {HomeModule.class, AndroidSupportInjectionModule.class})