Lessons I've learned throughout the years to keep up with my habits.
Nothing will make you skip your habits more than the lack of motivation
- Believe you can
- Watch motivational videos
| // Extension URL RegEx : https:\/\/console.firebase.google.com\/u\/0\/.+ | |
| var accountIndex = 1 // Auto redirect account index | |
| var newUrl = "https://console.firebase.google.com/u/" | |
| + accountIndex | |
| + window.location.toString().split("/u/0")[1] | |
| window.location = newUrl |
| /** | |
| * Collapsing Toolbar that can be used in a topBar slot of Scaffold. | |
| * It has a back button, default bottom rounded corners | |
| * & a box scope which holds content centered by default. | |
| * You need to implement nestedScrollConnection to set the offset values | |
| * See Usage of this in DashboardScreen or TasksScreen or GoalsScreen | |
| * | |
| * To use this Toolbar without a heading text just make toolbarHeading `null` | |
| * To Disable the back button at the top set showBackButton to false | |
| * |
| <?xml version="1.0" encoding="utf-8"?> | |
| <android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android" | |
| xmlns:app="http://schemas.android.com/apk/res-auto" | |
| xmlns:tools="http://schemas.android.com/tools" | |
| android:layout_width="match_parent" | |
| android:layout_height="match_parent" | |
| tools:context="com.vacuum.app.cinema.MainActivity"> | |
| <!--SOME CODE FOR MY AppBarLayout--> | |
| <!--SOME CODE FOR MY ToolBar--> |
| Initializing... | |
| Note: com.google.android.gms.cast.framework.CastContext calls '(com.google.android.gms.cast.framework.OptionsProvider)Class.forName(variable).newInstance()' | |
| Note: com.google.android.gms.internal.ql: can't find dynamically referenced class com.google.appengine.api.ThreadManager | |
| Note: com.google.android.gms.internal.zzcem: can't find dynamically referenced class android.os.SystemProperties | |
| Note: com.google.protobuf.zzc: can't find dynamically referenced class com.google.protobuf.ExtensionRegistry | |
| Note: com.google.protobuf.zzd: can't find dynamically referenced class com.google.protobuf.Extension | |
| Note: com.google.protobuf.zze: can't find dynamically referenced class libcore.io.Memory | |
| Note: com.google.protobuf.zze: can't find dynamically referenced class org.robolectric.Robolectric | |
| Note: the configuration keeps the entry point 'com.google.ads.mediation.AbstractAdViewAdapter { com.google.android.gms.ads.AdRequest zza(android.content.Context,com.google.android. | |
| gms.ads.mediation.MediationAdRequest,a |
| /* | |
| * Copyright 2017 Google Inc. | |
| * | |
| * Licensed under the Apache License, Version 2.0 (the "License"); | |
| * you may not use this file except in compliance with the License. | |
| * You may obtain a copy of the License at | |
| * | |
| * http://www.apache.org/licenses/LICENSE-2.0 | |
| * | |
| * Unless required by applicable law or agreed to in writing, software |
| /* | |
| * Copyright 2016 Google Inc. | |
| * | |
| * Licensed under the Apache License, Version 2.0 (the "License"); | |
| * you may not use this file except in compliance with the License. | |
| * You may obtain a copy of the License at | |
| * | |
| * http://www.apache.org/licenses/LICENSE-2.0 | |
| * | |
| * Unless required by applicable law or agreed to in writing, software |
| <?xml version="1.0" encoding="utf-8"?> | |
| <!-- | |
| Copyright 2016 Google Inc. | |
| Licensed under the Apache License, Version 2.0 (the "License"); | |
| you may not use this file except in compliance with the License. | |
| You may obtain a copy of the License at | |
| http://www.apache.org/licenses/LICENSE-2.0 |
| public static Action1<Throwable> crashOnError() { | |
| final Throwable checkpoint = new Throwable(); | |
| return throwable -> { | |
| StackTraceElement[] stackTrace = checkpoint.getStackTrace(); | |
| StackTraceElement element = stackTrace[1]; // First element after `crashOnError()` | |
| String msg = String.format("onError() crash from subscribe() in %s.%s(%s:%s)", | |
| element.getClassName(), | |
| element.getMethodName(), | |
| element.getFileName(), | |
| element.getLineNumber()); |
| // Dagger 1 example | |
| @Module( | |
| complete = false, | |
| library = true | |
| ) | |
| public final class ApiModule { | |
| @Provides | |
| @Singleton | |
| Retrofit provideRetrofit(Gson gson, Application app) { | |
| return new Retrofit.Builder() |