mirror of
				https://github.com/mihonapp/mihon.git
				synced 2025-10-31 14:27:57 +01:00 
			
		
		
		
	Added add to library dialog when downloading from catalogue (#618)
* Now show snackbar when adding from catalogue * Code cleanup + added manga favorite event to update favorite drawable when added via snack * Update SettingsAdvancedFragment.kt Forgot to check optimize import. I think(hope) I got them all ;). * Now uses PublishRelay. Manga favorite is now handled in info presenter * Update MangaInfoFragment.kt
This commit is contained in:
		
				
					committed by
					
						 inorichi
						inorichi
					
				
			
			
				
	
			
			
			
						parent
						
							07cae4d684
						
					
				
				
					commit
					72f8c4d5e2
				
			| @@ -0,0 +1,28 @@ | ||||
| package eu.kanade.tachiyomi.widget | ||||
|  | ||||
| import android.content.Context | ||||
| import android.support.annotation.StringRes | ||||
| import android.util.AttributeSet | ||||
| import android.widget.LinearLayout | ||||
| import android.widget.RelativeLayout | ||||
| import eu.kanade.tachiyomi.R | ||||
| import kotlinx.android.synthetic.main.dialog_with_checkbox.view.* | ||||
|  | ||||
| class DialogCheckboxView @JvmOverloads constructor(context: Context, attrs: AttributeSet? = null) : | ||||
|         LinearLayout(context, attrs) { | ||||
|     init { | ||||
|         RelativeLayout.inflate(context, R.layout.dialog_with_checkbox, this) | ||||
|     } | ||||
|  | ||||
|     fun setDescription(@StringRes id: Int){ | ||||
|         description.text = context.getString(id) | ||||
|     } | ||||
|  | ||||
|     fun setOptionDescription(@StringRes id: Int){ | ||||
|         checkbox_option.text = context.getString(id) | ||||
|     } | ||||
|  | ||||
|     fun isChecked(): Boolean { | ||||
|         return checkbox_option.isChecked | ||||
|     } | ||||
| } | ||||
		Reference in New Issue
	
	Block a user