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
mAnimation = new TranslateAnimation(0, -720, 0, 0); //use size of screen! | |
//mAnimation = new TranslateAnimation(fromXDelta, toXDelta, fromYDelta, toYDelta) | |
mAnimation.setDuration(300); | |
mAnimation.setFillAfter(true); | |
mAnimation.setRepeatCount(0); | |
//mAnimation.setRepeatMode(Animation.REVERSE); | |
myUIelement.setAnimation(mAnimation); | |
myUIelement.startAnimation(mAnimation); |
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
RelativeLayout.LayoutParams params = (RelativeLayout.LayoutParams) listViewSubItem.getLayoutParams(); | |
params.leftMargin = 300; | |
//params.topMargin = 10; | |
listViewSubItem.setLayoutParams(params); |
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
// listViewItem.setVisibility(View.VISIBLE); | |
listViewItem.setVisibility(View.INVISIBLE); | |
//setVisibility(View.GONE) on the Spinners as needed to hide them. GONE means totally gone |
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
1. creo list view en xml | |
2. lo llamo en el fragment mi list view [inflaiter] | |
3. adapter custom xml | |
4. dapter custom CategoryAdapter.java |
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
//centro vertical | |
android:gravity="center_vertical" |
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
myLayout.setDescendantFocusability(ViewGroup.FOCUS_BEFORE_DESCENDANTS); | |
myLayout.setFocusableInTouchMode(true); |
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
textField | |
. iOS : UITextField | |
. android: 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
JSONObject json; | |
Object intervention; | |
JSONArray interventionJsonArray; | |
JSONObject interventionObject; | |
json = RestManager.getJSONfromURL(myuri); // retrieve the entire json stream | |
Object intervention = json.get("intervention"); | |
if (intervention instanceof JSONArray) { | |
// It's an array | |
interventionJsonArray = (JSONArray)intervention; |
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
#server | |
# TCP Server Code | |
#host="127.0.0.1" # Set the server address to variable host | |
host="127.168.2.75" # Set the server address to variable host | |
port=4446 # Sets the variable port to 4444 | |
from socket import * # Imports socket module | |
s=socket(AF_INET, SOCK_STREAM) | |
s.bind((host,port)) # Binds the socket. Note that the input to |
OlderNewer