Get Homebrew installed on your mac if you don't already have it
Install highlight. "brew install highlight". (This brings down Lua and Boost as well)
protected void onCreate(Bundle savedInstanceState) { | |
super.onCreate(savedInstanceState); | |
setContentView(R.layout.activity_main); | |
ButterKnife.bind(this); |
public class MainActivity extends AppCompatActivity { | |
@BindView(R.id.login_et) | |
EditText mLogin; | |
@BindView(R.id.password_et) | |
EditText mPassword; | |
@BindView(R.id.login_bt) | |
Button mLoginButton; |
<ScrollView | |
xmlns:android="http://schemas.android.com/apk/res/android" | |
android:layout_width="fill_parent" | |
android:layout_height="fill_parent" | |
android:fitsSystemWindows="true" | |
xmlns:tools="http://schemas.android.com/tools" | |
tools:context=".MainActivity" | |
android:background="@color/colorPrimary"> | |
<LinearLayout | |
android:orientation="vertical" |
Subscription buttonSub = RxView.clicks(mLoginButton).subscribe(aVoid -> { | |
//handle on click here | |
}); |
Get Homebrew installed on your mac if you don't already have it
Install highlight. "brew install highlight". (This brings down Lua and Boost as well)
mPicasso = new Picasso.Builder(getApplicationContext()) | |
.downloader(new OkHttp3Downloader(okClient)) | |
.loggingEnabled(true) | |
.build(); | |
if (BuildConfig.DEBUG) { | |
Stetho.initialize( | |
Stetho.newInitializerBuilder(this) | |
.enableDumpapp(Stetho.defaultDumperPluginsProvider(this)) | |
.enableWebKitInspector(RealmInspectorModulesProvider.builder(this).build()) |
compile 'com.facebook.stetho:stetho:1.4.1' | |
compile 'com.facebook.stetho:stetho-okhttp3:1.4.1' | |
compile 'com.uphyca:stetho_realm:0.9.0' |
allprojects { | |
repositories { | |
jcenter() | |
maven { url "https://jitpack.io" } | |
maven { url "https://github.com/uPhyca/stetho-realm/raw/master/maven-repo" } | |
} | |
} |
mPicasso.load(ICON_URL + "&" + position) | |
.placeholder(R.mipmap.ic_launcher) | |
.into(viewHolder.mIcon); |
OkHttpClient okClient = new OkHttpClient | |
.Builder() | |
.addNetworkInterceptor(new StethoInterceptor()) | |
.build(); | |
mPicasso = new Picasso.Builder(getApplicationContext()) | |
.downloader(new OkHttp3Downloader(okClient)) | |
.loggingEnabled(true) | |
.build(); |