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
E/AndroidRuntime( 2118): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.joelapenna.foursquared/com.joelapenna.foursquared.app.FragmentShellActivity}: android.support.v4.app.Fragment$InstantiationException: Unable to instantiate fragment com.joelapenna.foursquared.fragments.photos.o: make sure class name exists, is public, and has an empty constructor that is public | |
E/AndroidRuntime( 2118): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2306) | |
E/AndroidRuntime( 2118): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2358) | |
E/AndroidRuntime( 2118): at android.app.ActivityThread.access$600(ActivityThread.java:156) | |
E/AndroidRuntime( 2118): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1340) | |
E/AndroidRuntime( 2118): at android.os.Handler.dispatchMessage(Handler.java:99) | |
E/AndroidRuntime( 2118): at android.os.Looper.loop(Looper.java:153) | |
E/AndroidRuntime( 2118): at android.app.Ac |
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
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" | |
android:layout_width="250dp" | |
android:layout_height="wrap_content" | |
android:layout_gravity="center_horizontal" | |
android:gravity="center" | |
android:orientation="vertical" | |
android:layout_marginTop="16dp" | |
> | |
<EditText |
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 saveAsParcel implements Parcelable { | |
private String myStringValue; | |
public PassableObject() {} | |
public PassableObject(Parcel inParcel) { | |
myStringValue = inParcel.readString(); | |
} | |
@Override |
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
if((getResources().getConfiguration().screenLayout & Configuration.SCREENLAYOUT_SIZE_LARGE) == Configuration.SCREENLAYOUT_SIZE_LARGE){ | |
//load a large screen layout | |
}else{ | |
//load a default screen layout | |
} |
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 MyApplication extends Application { | |
private Typeface normalFont; | |
private Typeface boldFont; | |
//FontSetter fontSetter = (FontSetter) getApplication(); | |
//TextView myTextView = (TextView) findViewById(R.id.my_textview); | |
//application.setTypeface(myTextView); | |
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
dependencies { | |
compile 'org.springframework.android:spring-android-rest-template:1.0.1.RELEASE' | |
compile 'org.springframework.android:spring-android-auth:1.0.1.RELEASE' | |
compile 'org.springframework.android:spring-android-core:1.0.1.RELEASE' | |
} |
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_VERSION": 1.5, | |
"APP_VERSION_CODE": 8, | |
"APP_VERSION_NAME": 1.3, | |
"AVAILABLE_MEM_SIZE": 181972992, | |
"BRAND": "generic", | |
"BUILD": { | |
"BOARD": "unknown", | |
"BRAND": "generic", | |
"DEVICE": "generic", |
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
Typeface tf = Typeface.createFromAsset(getAssets(),"fonts/Roboto-Black.ttf"); | |
TextView tv = (TextView) findViewById(R.id.FontTextView); | |
tv.setTypeface(tf); |
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
<?php | |
$storage = $_SERVER['DOCUMENT_ROOT'].'/droid/uploads/'; | |
#check uploaded file status | |
if(is_uploaded_file($_FILES['uploaded_file']['tmp_name'])){ | |
echo "\nfile successfully uploaded!\n"; | |
}else{ | |
echo "\nfile not uploaded!\n"; | |
exit; |
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 static void uploadFile(String filePath, String serverURL) throws IOException { | |
HttpClient httpClient = new DefaultHttpClient(); | |
//post request to send file | |
HttpPost httpPost = new HttpPost(serverURL); | |
// StrictMode.ThreadPolicy policy = new StrictMode.ThreadPolicy.Builder().permitAll().build(); | |
// StrictMode.setThreadPolicy(policy); | |
FileBody uploadFile = new FileBody(new File(filePath)); | |
MultipartEntity reqEntity = new MultipartEntity(); | |
// reqEntity.addPart("the args. the server takes", uploadFile); |