Questions tagged [android-moxy]
13 questions
4
votes
2 answers
How to get context in moxy presenter android
How do I can get activity context from Moxy presenter?
At first sight it's very easy...: 1. Add Context getMvpActivity (); into MvpView interface and implement it in Acivity.
2. And in a presenter call getViewState().getMvpActivity().
But Moxy don't…

picKit
- 412
- 1
- 4
- 14
4
votes
2 answers
Moxy: How pass params to Presenter?
Here my implementation of MVP:
public class OfferDetailsPdfActivity extends AppCompatActivity implements OnPageChangeListener, OfferDetailsPdfMvp.View {
private PdfPresenterImpl presenter;
@Override
protected void onCreate(@Nullable…

Alex
- 705
- 1
- 9
- 18
3
votes
0 answers
Is it okay to use objects which implement Parcelable in Presenters?
Is it okay to use objects which implement Parcelable in Presenters?
If i have some object in presenter that implements Parcelable does it means that my presenter depends on android sdk object(Parcelable)?

Outofdate
- 635
- 5
- 16
3
votes
0 answers
Moxy inject UseCase into Presenter
How can I inject UseCase into Moxy Presenter?
@InjectViewState
class LoginPresenter @Inject constructor() : BasePresenter() {
@Inject lateinit var facebookLoginBehavior: FlowBehavior
@Inject…

Pasha Shkaran
- 1,433
- 2
- 23
- 41
2
votes
1 answer
Moxy Fatal Exception - Exception from call site #0 bootstrap method
Sample code from Moxy doesn't work
https://github.com/moxy-community/Moxy
Source code is separated to different files, but now presented for less complicated view
Empty application (without anything with MVP, it only has one empty screen) works
But…

Aroize
- 61
- 6
1
vote
1 answer
Kapt dependency issue
I have project that was initially started with Java(contains dagger and moxy frameworks).
I have added room dependency and I have create all room components in kotlin so as dependency I using:
implementation "androidx.room:room-runtime:2.2.6"
kapt…

Pavel Poley
- 5,307
- 4
- 35
- 66
0
votes
1 answer
Using @provide and @Inject in the same class
I try library cicerone.
The sample use MOXY.
I cant undestend why we should use @ProvidePresenter and @InjectPresenter in the same class, and dont use it anywhere.
@InjectPresenter
StartActivityPresenter presenter;
private Navigator navigator = new…

RodGers
- 175
- 1
- 9
0
votes
1 answer
MVP with Moxy. Presenter's callback methods in Fragment not called (getViewState() is not null)
I have a difficulties with MVP realization using Moxy library. I read Moxy's github pages and checked examples, but any solution doesn't helps me.
In MyFragment the callbacks of MyFragmentView methods not called, but in MyFragmentPresenter…

Roman
- 1
- 2
0
votes
1 answer
Why are two items showed in Spinner at once?
Items in one of my dropdown lists are starting to double themselves after orientation change for some reason.
Here are two pictures: one with the bug (after changing to horizontal and back) and one without it.
Here's my code:
Activity class:…

Filipp Maksimov
- 97
- 1
- 1
- 5
0
votes
2 answers
Best solution for my task: Thread, AsyncTask or Service?
I have an Android application that creates and edits requisitions. All the data is going to be stored at my server.
A problem is: the app should regulary get information from the server on existence of some records by generating queries. Time…

Kurowsky
- 154
- 1
- 9
0
votes
0 answers
Creating options menu using Moxy library (Android)
I'm building an Android app using Moxy MVP library.
When I try to build the project, I get compilation error:
"Activity contains non-void method "onCreateOptionsMenu" that return type is boolean"
That is simple onCreateOptionsMenu methdod to…

Bord81
- 525
- 2
- 8
- 23
0
votes
2 answers
Kotlin: resolve generic inheritance
After reading same articles I still cannot solve generics problem:
I have BaseActivity:
abstract class BaseActivity : MvpAppCompatActivity(), BaseView {
abstract fun getPresenter():BasePresenter
}
BaseView interface for it
interface…

Andrey Danilov
- 6,194
- 5
- 32
- 56
0
votes
1 answer
NullPointerException in (MVP) Moxy's getViewState()
I installed Moxy to my project, and set annotations according to docs. But, when i launch the app, it crashes with:
FATAL EXCEPTION: main
Process: com.example.project, PID: 709
…

Koroqe
- 67
- 7