Skip to content
This repository was archived by the owner on Feb 26, 2023. It is now read-only.
This repository was archived by the owner on Feb 26, 2023. It is now read-only.

Incompatibility with otto library since 3.1 #1133

@arnaudruffin

Description

@arnaudruffin

Hi everyone and thanks for this great framework

I haven't been able to use otto library with androidannotation since the 3.1 is out (I was silly enough to put 3.+ version in my gradle file, and was going crazy not understanding why my project was suddenly not working)

Posting event to the bus event doesn't trigger anything...

OttoVersion=1.3.5
AndroidAnnotationsVersion=3.0.1

Here is an example

My bus event is declared in a EBean

@EBean(scope = EBean.Scope.Singleton)
public class DebugBusProxy {

    protected final Bus bus = new Bus();
....

And a test activity example:

@EActivity(R.layout.activity_my)
public class MyActivity extends Activity {

    @Bean
    DebugBusProxy bus;

    public static class MyEvent{}

    @Override
    protected void onResume() {
        super.onResume();
        bus.register(this);
        bus.post(new MyEvent());
    }

    @Subscribe
    public void myMethodActivity(MyEvent e){
        Log.d(MyActivity.class.getName(),"Never called.. :(");
    }
}

I'm willing to contribute, and may have a look in the next few days. Just posting it there in case someone already have an idea or is facing the same problem...

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions