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
// unlimited viewpager | |
// http://stackoverflow.com/questions/16583848/unlimited-dynamic-viewpager-in-both-directions | |
public static class MyAdapter extends FragmentPagerAdapter { | |
public MyAdapter(FragmentManager fm) { | |
super(fm); | |
} | |
@Override | |
public int getCount() { | |
return Integer.MAX_VALUE; |
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
/** | |
* @see https://github.com/GoogleChrome/chromium-webview-samples/blob/master/input-file-example/app/src/main/java/inputfilesample/android/chrome/google/com/inputfilesample/MainFragment.java | |
*/ | |
// SETTING VALUES | |
private static final Logger logger = LoggerFactory.getLogger(DefaultWindow.class); | |
private CommonDialogs mDialog; | |
private ValueCallback<Uri[]> mFilePathCallback; | |
private String mCameraPhotoPath; | |
public static final int INPUT_FILE_REQUEST_CODE = 1; |
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
package arabiannight.tistory.com; | |
import java.io.File; | |
import android.app.Activity; | |
import android.os.Bundle; | |
import android.os.Environment; | |
import android.util.Log; | |
public class TestRootingCheckActivity extends 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
<item name="android:windowContentOverlay">@null</item> | |
<item name="android:windowIsTranslucent">true</item> |
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
// 기존 | |
view.setOnClickListener(new View.OnClickListener { | |
@Override | |
public void onClick(View view) { | |
// TODO | |
} | |
}); | |
// 람다 | |
view.setOnClickListener(v -> { |
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
apply plugin: 'maven' | |
dependencies { | |
deployerJars "org.apache.maven.wagon:wagon-http:2.2" | |
} | |
uploadArchives { | |
repositories.mavenDeployer { | |
configuration = configurations.deployerJars | |
repository(url: "https://my.example.com/content/repositories/com.example/") { |
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 LockScrollView extends ScrollView { | |
protected boolean mIsScrollLock; | |
private TouchUpListener mListener; | |
public LockScrollView(Context context) { | |
super(context); | |
initLayout(); | |
} | |
public LockScrollView(Context context, AttributeSet attrs) { |
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 void testAlert() { | |
new AsyncTask<Void, Void, Boolean>() { | |
AlertDialog dlg; | |
boolean dismiss = true; | |
@Override | |
protected void onPreExecute() { | |
super.onPreExecute(); | |
dlg = new AlertDialog.Builder(MainActivity.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
class ViewHolder { | |
TextView name; | |
TextView title; | |
CheckBox checkbox; | |
} | |
class TestAdapter extends android.widget.BaseAdapter { | |
int count; | |
public TestAdapter(int count) { |
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
<resources> | |
<style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar"> | |
<!-- Customize your theme here. --> | |
<item name="colorPrimary">@color/colorPrimary</item> | |
<item name="colorPrimaryDark">@color/colorPrimaryDark</item> | |
<item name="colorAccent">@color/colorAccent</item> | |
<item name="android:windowContentOverlay">@null</item> | |
<item name="android:windowIsTranslucent">true</item> | |
</style> |
OlderNewer