Last active
February 19, 2019 13:10
-
-
Save KucherenkoIhor/95489f55f01c216c0b913a365221f549 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SwitchAction switchAction = new SwitchAction("Test switch", new SwitchAction.Listener() { | |
@Override | |
public void onCheckedChanged(boolean value) { | |
Toast.makeText(MainActivity.this, "Switch checked", Toast.LENGTH_LONG).show(); | |
} | |
}); | |
ButtonAction buttonAction = new ButtonAction("Test button", new ButtonAction.Listener() { | |
@Override | |
public void onClick() { | |
Toast.makeText(MainActivity.this, "Button clicked", Toast.LENGTH_LONG).show(); | |
} | |
}); | |
SpinnerAction < String > spinnerAction = new SpinnerAction < > ( | |
Arrays.asList("First", "Second", "Third"), | |
new SpinnerAction.OnItemSelectedListener < String > () { | |
@Override public void onItemSelected(String value) { | |
Toast.makeText(MainActivity.this, "Spinner item selected - " + value, Toast.LENGTH_LONG).show(); | |
} | |
} | |
); | |
debugDrawer = new DebugDrawer.Builder(this) | |
.modules( | |
new ActionsModule(switchAction, buttonAction, spinnerAction), | |
new FpsModule(Takt.stock(getApplication())), | |
new LocationModule(this), | |
new ScalpelModule(this), | |
new TimberModule(), | |
new OkHttp3Module(okHttpClient), | |
new PicassoModule(picasso), | |
new GlideModule(Glide.get(getContext())), | |
new DeviceModule(this), | |
new BuildModule(this), | |
new NetworkModule(this), | |
new SettingsModule(this) | |
).build(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment