Okhelp.cz

Recepty, články, nápady, programování. Dříve dum-zahrada, finance, internet a know-how.okhelp.cz Pro lepší výsledky hledání používejte i diakritiku.

Problem in parsing the package Android 2.1


AD MOB

Eclipse.
If install on device signed with proguard *.apk package and try to reinstall it by only signed package get error in parsing the package.
Uninstall the first application with bigger size from device and try install signed package which has a smaller size. Delete from download list previous downloaded *.apk.
This problem occurs when that your downloaded apk file size is less than the
size of the original apk.

397LW NO topic_id




AD

Další témata ....(Topics)


352

How to test dual panels - panes fragments on small device screen Android | how-to-test-dual-panels-fragments-on-small-device-screen-android


If You have old PC (Android in emulator with high screen resolution uses a lot of memory) or your testing phone have small screen, You can try this trick.
Rename layout folder for small device screen f.g. from layout into layout-swXXXdp and a large layout-sw600dp into layout.
Your phone with small screnn will do select xml file from renamed layout folder (for small screen).
You can to testing rotation with device en stability of fragments if an application changed orientation.
If you have old pc, you can try to make a new virtual device running on older version of Android, which uses less memory of computer.
For testing of rotation stability - application orientation changed - use on emulator Ctrl+F11, Ctrl+F12 key (Windows).

Important
Before the release of application, you have to rename layout folder to older name layout-sw600dp and layout-swXXXdp to layout.
347

Android Google Maps Night Mode | android-google-maps-night-mode


If you want save battery, select "Satelite map" from map menu and reduce the brightness of the display.

android-google-maps-night-mode-as-satelite-map.jpg
208

Zipalign ADT Eclipse | zipalign-adt-eclipse


Zipalign.exe path on Windows:
c:\Program Files\Android\android-sdk-windows\tools\zipalign.exe

zipalign [-f] [-v] <alignment> infile.apk outfile.apk

// command line in Total Commander
zipalign.exe -f -v 4 infile.apk outfile.apk

When using Eclipse with the ADT plugin, the Export Wizard will automatically zipalign your .apk after it signs it with your private key.


How do signs .apk with your private key - image:


signs-apk-with-eclipse-android-1

signs-apk-with-eclipse-android-1

signs-apk-with-eclipse-android-1

signs-apk-with-eclipse-android-1

signs-apk-with-eclipse-android-1

More about Zipalign android.com
6

Show keyboard | show-keyboard


Show keyboard Android phone apps development example source code.

// ActivityClass.java
InputMethodManager showSoftInput;
Button hBtnKeyboardShow ;
//onCreate
showSoftInput = (InputMethodManager)this.getSystemService(Context.INPUT_METHOD_SERVICE);

hBtnKeyboardShow = (Button)findViewById(R.id.btnKeyboardShow);
hBtnKeyboardShow.setOnClickListener(myButtonListener);
// END onCreate

//button listener
private OnClickListener myButtonListener = new OnClickListener() {
     public void onClick(View v) {
     	 try {
     		 showSoftInput.getInputMethodList();
                 showSoftInput.toggleSoftInput(showSoftInput.SHOW_FORCED, 0);	
		} catch (Exception e) {
			Log.e("Keyboard show ", e.getMessage());
			
		}
     }
};


262

Font Family change on View dynamically Android Example | font-family-change-on-view-android-example


TypeFace, setTypeface, font, font family, array of String, Button create dynamically

@Override
protected void onStart() {
LinearLayout.LayoutParams p = new LinearLayout.LayoutParams(
  48,
  55
);	
Typeface typeFace = Typeface.MONOSPACE;	
String [] ar = {"A","B","C","D","E","F","G","H","J","K"};
for (int i = 0; i < ar.length; i++) {
Button buttonView = new Button(this);
buttonView.setText(Html.fromHtml("<b>"+ar[i]+"</b>"));
buttonView.setTextColor(Color.BLUE);
buttonView.setTextSize(27.f);
buttonView.setTypeface(typeFace,Typeface.BOLD);
buttonView.setOnClickListener(mThisButtonListener);
if(i%2==0)
	mLayoutButtons.addView(buttonView, p);
else
	mLayoutButtonsNextRow.addView(buttonView, p);
	
_listOfButtons.add(buttonView);
}

	super.onStart();
}

//////// xml file
<TextView
    android:id="@+id/text01"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:textSize="20dp"
    android:fontFamily="Arial"
 />


Editace: 2014-02-15 20:45:48
Počet článků v kategorii: 397
Url:problem-in-parsing-the-package-android-2-1

AD
11 Share
Share
Tweet