mirror of
https://github.com/k0shk0sh/FastHub.git
synced 2026-01-25 14:47:05 +00:00
some enhancements
This commit is contained in:
parent
a145da1b97
commit
2649bbc5e3
@ -11,7 +11,7 @@ public class CommitRequestModel {
|
||||
private String sha;
|
||||
private String branch;
|
||||
|
||||
public CommitRequestModel(String message, String content, String sha,String branch) {
|
||||
public CommitRequestModel(String message, String content, String sha, String branch) {
|
||||
this.message = message;
|
||||
this.content = content;
|
||||
this.sha = sha;
|
||||
|
||||
@ -27,7 +27,7 @@ class EmojiBottomSheet : BaseMvpBottomSheetDialogFragment<EmojiMvp.View, EmojiPr
|
||||
var emojiCallback: EmojiMvp.EmojiCallback? = null
|
||||
|
||||
|
||||
@OnTextChanged(value = R.id.editText, callback = OnTextChanged.Callback.AFTER_TEXT_CHANGED)
|
||||
@OnTextChanged(value = [(R.id.editText)], callback = OnTextChanged.Callback.AFTER_TEXT_CHANGED)
|
||||
fun onTextChange(text: Editable) {
|
||||
adapter.filter.filter(text)
|
||||
}
|
||||
|
||||
@ -45,7 +45,7 @@ class DonateActivity : BaseActivity<BaseMvp.FAView, BasePresenter<BaseMvp.FAView
|
||||
val priceText = bundle.getString(BundleConstant.EXTRA_FIVE)
|
||||
subscription = RxHelper.getSingle<Purchase>(RxBillingService.getInstance(this, BuildConfig.DEBUG)
|
||||
.purchase(ProductType.IN_APP, productKey, "inapp:com.fastaccess.github:" + productKey))
|
||||
.subscribe({ p: Purchase?, throwable: Throwable? ->
|
||||
.subscribe({ _: Purchase?, throwable: Throwable? ->
|
||||
if (throwable == null) {
|
||||
FabricProvider.logPurchase(productKey, price, priceText)
|
||||
showMessage(R.string.success, R.string.success_purchase_message)
|
||||
|
||||
@ -225,7 +225,7 @@ public class RepoFilesFragment extends BaseFragment<RepoFilesMvp.View, RepoFiles
|
||||
|
||||
@Override public void onActivityResult(int requestCode, int resultCode, Intent data) {
|
||||
super.onActivityResult(requestCode, resultCode, data);
|
||||
if (resultCode == Activity.RESULT_OK && requestCode == EditRepoFileActivity.Companion.getEDIT_RQ()) {
|
||||
if (resultCode == Activity.RESULT_OK && requestCode == EditRepoFileActivity.EDIT_RQ) {
|
||||
onRefresh();
|
||||
}
|
||||
}
|
||||
|
||||
@ -129,7 +129,7 @@ class EditRepoFileActivity : BaseActivity<EditRepoFileMvp.View, EditRepoFilePres
|
||||
}
|
||||
|
||||
companion object {
|
||||
val EDIT_RQ = 2017
|
||||
const val EDIT_RQ = 2017
|
||||
|
||||
fun startForResult(activity: Activity, model: EditRepoFileModel, isEnterprise: Boolean) {
|
||||
val bundle = Bundler.start()
|
||||
|
||||
@ -45,8 +45,8 @@ class ThemeCodeActivity : BaseActivity<ThemeCodeMvp.View, ThemeCodePresenter>(),
|
||||
override fun onInitAdapter(list: List<String>) {
|
||||
val adapter = SpinnerAdapter<String>(this, list)
|
||||
spinner.adapter = adapter
|
||||
var theme_position = list.indexOf(PrefGetter.getCodeTheme())
|
||||
spinner.setSelection(theme_position)
|
||||
val themePosition = list.indexOf(PrefGetter.getCodeTheme())
|
||||
if (themePosition >= 0) spinner.setSelection(themePosition)
|
||||
}
|
||||
|
||||
@OnItemSelected(R.id.themesList) fun onItemSelect() {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user