Suppose,you are writing an application which is targeted to SAMSUNG GALAXY TABLET version,unfortunately you don't have a real device.
Developing for Samsung GALAXY Tab is no different from developing for
any other Android based device.
By utilizing only public APIs provided in
the Android SDK and follow the guidelines and tips below,
applications will not just work on the GALAXY Tab but also scale
correctly.
If you test the application in android 2.2 emulator it was not perfect and if you run the same in real device,you will unexpected results.
In this case,you can test in ORIGINAL samsung galaxy tablet emulator which is avaliable in SAMSUNG developer portal.
It is with a 7” device and a screen resolution of 1024x600 the Samsung GALAXY Tab
provides a perfect form factor to optimize applications, by implementing UI and UX
enhancements previously not possible.
Samsung GALAXY Tab Add-on Installation Guidelines
1) Run AVD Manager on Eclipse IDE.
2) Select Available Packages in the left panel of AVD Manager.
3) Click “Add ADD-on Site” and enter the URL below.
4) Check Samsung GALAXY Tab Add-on packages and click install button.
5) Check Samsung GALAXY Tab Add-on license & Click install button.
6) After downloading and installation of GALAXY Tab Add-on, you should restart ADB (Android Debug Bridge) or Eclipse.
Now,you can see the installed addon in Installed Packages of AVD manager and in list of targets available.
You can create samsung galaxy tablet emulator by selecting samsung galaxy as Target device.
And output is as shown below:
Quick Guide Tips:
Samsung GALAXY Tab is a 7” inch device with 1024x600(WSVGA) resolution
running Android 2.2 (Froyo). The following guidelines will help
developers optimize applications for the best possible user experience.
Make sure that high density display (HDPI) resources
are in the application package, as the tablet display requires these
resources. Most Android devices are API level 4 or greater. We
recommend porting over our application with minSDKVersion=4
or greater. This allows you to add HPDI resources in the application package. If the system cannot find the
HPDI resources and android:anyDensity=”true”
has been set, the existing resources will be scaled which may not give the user the best experience.
The following are values are default for the Samsung Android Tablet:
DeviceMetrics.density = 240
DeviceMetrics.xdpi = 168
DeviceMetrics.ydpi = 168
The density system property value has been set as
[ro.sf.lcd_density]:[240]
When using bitmap resources like advertisement banners,
work with your ad vendor to get the correct banner size.
Scale the bitmap programmatically by getting the device height and width at runtime as follows:
WindowManager mWMgr =
(WindowManager)context.getSystemService(Context.WINDOW_SERVICE);
int width = mWMgr.getDefaultDisplay().getWidth();
int height - mWMgr.getDefaultDisplay().getHeight();
Android Market filters out applications based on the values specified in the AndroidManifest.xml file.
The 7” inch tablet is a “large” screen.
So, for applications which have minSDKVersion=3, define support-screens tag explicitly as:
Follow the recommended generic compatibility guidelines, such as:
- In XML layout, Use wrap_content, fill_parent
- Use FrameLayout instead of AbsoluteLayout
- NEVER use hard-coding for pixel value, use dip (density independent pixel)
- Use resources according to each density, resolution category.