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
ext.densityCodes = ['mdpi': 1, 'hdpi': 2, 'xhdpi': 3] | |
import com.android.build.OutputFile | |
android { | |
..... | |
android.applicationVariants.all { variant -> | |
variant.outputs.each { output -> |
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
android { | |
..... | |
splits { | |
density { | |
enable true | |
reset() | |
include "mdpi", "xhdpi" | |
} | |
abi { |
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
android { | |
... | |
splits { | |
abi { | |
enable true | |
reset() | |
include "x86", "mips" | |
universalApk false | |
} |
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
android { | |
....... | |
....... | |
splits { | |
density { | |
enable true | |
exclude "mdpi", "xxxhdpi" | |
compatibleScreens 'small', 'normal', 'large', 'xlarge' | |
} | |
} |
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
public class LocationListenerActivity extends Activity implements LocationUpdate{ | |
@Override | |
public void onLocationChange(Location location){ | |
} | |
@Override | |
public void onStart(){ | |
LocationListener.get().register(this); |
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
public class MainActivity extends AppCompatActivity { | |
TextView textView; | |
AsyncTask asyncTask; | |
@Override | |
protected void onCreate(Bundle savedInstanceState) { | |
super.onCreate(savedInstanceState); | |
setContentView(R.layout.activity_main); | |
textView = (TextView) findViewById(R.id.textView); |
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
public class MainActivity extends AppCompatActivity { | |
private static Button button; //NEVER USE LIKE THIS | |
private static Context context; //NEVER USE LIKE THIS TOO | |
} |
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
<activity android:name=".ui.splash.SplashActivity"> | |
<intent-filter> | |
<action android:name="android.intent.action.MAIN" /> | |
<category android:name="android.intent.category.LAUNCHER" /> | |
</intent-filter> | |
</activity> |
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
<application | |
android:name=".MvpApp" | |
...... | |
...... | |
...... | |
...... | |
</application> |
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
public class MvpApp extends Application { | |
DataManager dataManager; | |
@Override | |
public void onCreate() { | |
super.onCreate(); | |
SharedPrefsHelper sharedPrefsHelper = new SharedPrefsHelper(getApplicationContext()); | |
dataManager = new DataManager(sharedPrefsHelper); |
NewerOlder