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
var importantvariable="superimportant!"; | |
asynchronous_api_call( | |
'http://anrops-URL', | |
function (closedOverParam) { | |
return function (response) { | |
alert(closedOverParam); | |
}; | |
}(importantvariable); | |
); |
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
-- IMStatus | |
-- version 2.0, Lantrix (http://techdebug.com) | |
-- idea conceived from script by Jason Kenison "theWebGuy" Blog at: | |
-- http://www.jasonkenison.com/blog.html?id=22 | |
(* | |
Copyright (c) 2008, TechDebug.com | |
Permission to use, copy, modify, and/or distribute this software for any | |
purpose with or without fee is hereby granted, provided that the above |
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 com.example; | |
import android.app.Activity; | |
public class MyActivity extends Activity | |
implements MyFragment.Callbacks { | |
@Override | |
public void onItemClick(Object object) { | |
//Do thing with the passed object |
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 com.example; | |
public class MyItemView extends LinearLayout { | |
public static final MyItem EMPTY = new MyItem(null); | |
private TextView mTitleView; | |
private TextView mDescriptionView; | |
private MyItem item = EMPTY; |
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 CustomViewActivity extends Activity { | |
public void onCreate (Bundle savedInstanceState) { | |
//Get the LayoutInflater for this Activity context | |
//and set the Factory to be our custom view factory | |
LayoutInflater.from(this).setFactory(CustomViewFactory.getInstance()); | |
super.onCreate(savedInstanceState); | |
setContentView(R.layout.layout_with_custom_view); | |
} | |
} |
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
{ | |
"minvals" : [ | |
"DESIGNING WORKHOUSES", | |
"polygenelubricants" | |
], | |
"zerovals": [ | |
"pollinating sandboxes", | |
"amusement & hemophilias", | |
"schoolworks = perversive" | |
] |
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
// Updated to work with newer gradle plugin | |
apply plugin: 'android' | |
targetCompatibility = 1.6 | |
sourceCompatibility = 1.6 | |
android { | |
target = 'android-14' |
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
# Set up adb to use tcpip port | |
adb tcpip 5555 | |
# Default device ip when it's used as a portable hotspot | |
adb connect 192.168.43.1 | |
# List connected devices | |
adb devices |
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
import android.app.Activity; | |
import android.content.Context; | |
import android.view.View; | |
import android.view.WindowManager; | |
import android.view.inputmethod.InputMethodManager; | |
public class KeyboardUtil { | |
public static void hideKeyboard(final Context ctx, final View view) { | |
InputMethodManager imm = (InputMethodManager)ctx.getSystemService(Context.INPUT_METHOD_SERVICE); |
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 you get a lot of linking errors like this: | |
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.8/libstdc++.a | |
you probably need to | |
sudo apt-get install g++-multilib |
OlderNewer