Ksh Aggarwal

Greenhorn
+ Follow
since Sep 16, 2009
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Ksh Aggarwal

Im trying to prepare a set of guidelines and project template for my future Android projects. Im already implementing the basic MVC architecture modularity. Im trying to have add more advanced level of design to my Android projects to make my development easier and maintainable.

For example can someone suggest me a way to make Intent calls to Activity without explicitly mentioning the class while creating the Intent. Im trying to loose couple the intent calls and hopefully use AndroidManifest to assign action to an activity which then can be called globally within the application.

Any other type of suggestions are welcome.

Also please suggest any kind of coding conventions that you might be using yourself.
14 years ago
Hi Monu,
Thanks a lot for the list. I also found example for lazy loading lists in the API demos. I guess its the last 2 exampls the the list section.

Could you maybe have a look on those and provide your point of view?

Thanks again

14 years ago
Hi,

Can anybody tell me some good links to go over the lazy loading list concept. And any code samples that i can use.

thanks
14 years ago
Found the problem.

Apparently Android Webview component has a bug due to which it randomly stops responding to touch events.
For more details http://code.google.com/p/android/issues/detail?id=929

Bug is due to the attribute android:layout_height="wrap_content" in the web view component. Workaround can be any other value for this attribute instead of wrap_content
14 years ago
Hi,

Im using an embedded webview to display a webpage which is made up of image thumbnails. These thumbnails are links to further webpages. Now my application randomly stops responding to my touch events on these thumbnails. It happens more frequently when the device wakes up from a standby. but this problem is fixed when i load some other page and come back to the thumbnails page.

I tried adding an onClickListener to the webview but it never return anything, even when the application is running fine.

Thanks in advance
14 years ago
Thanks Monu
14 years ago
Hi,

Can someone suggest some good books on Android for both beginner and advanced level.
14 years ago
Hi,

I want to add haptic feedback to my application buttons and control them problematically to show button state (enabled and disabled) The default haptic feedback setter works only for long press. How can i make it work for simple button clicks.

And is there a way to have haptic feedback on events like touch fling??
14 years ago

Monu Tripathi wrote:Ran this under default emulator settings(320 x 480 HVGA):

I created an Activity that had only one custom View with Height and Width as "fill_parent". The Activity had both the default title bars;

I printed View#getHeight() and View#getWidth() inside onDraw of the View and got following values for Height and Width:
H: 430
W: 320

I get same values on Hero too. So, IMO that's the answer you want.



Thanks Monu
14 years ago
What is the effective screen available (Height) for an application without removing any default bars on the top.

480 - (both bars at the top) = ?
14 years ago
You can set the Height and Width of your button to a common value to stop auto resizing.

P.S. Caution: Fixing size of UI elements 'might' create problems with compatibility with devices of different screen size & density
14 years ago

Muhammad Imad Qureshi wrote:How can I make my text field non editable but use it to display results from my calculations? I want a look similar to EditText and that's why I don't want to use TextView.



I suppose you can set the editable property to true or false in the layout xml file
14 years ago
Thread class & runnable interface are the same.the difference is just that of a class and an interface and usage depends on design decision.

Objects of class implementing runnable don't act as threads. they have to b given to Thread objects which actually spawn a new thread.
for general usage we put the required code block in a Runnable implementing class. Now this becomes service which needs to b executed. its object is then given to actual Thread object to create a thread and run this service.

Extend thread only when you want to add functionality to Thread class
14 years ago

raja pulleboina wrote:
please exaplin the real time senario where we can use abstract and interface in java ...???



interface is basically a pure abstract class. interface only specifies the methods that should be present in any class which is implementing that interface.
abstract classes on other hand can have non-abstract methods i.e. methods which are already implemented. these methods can then be directly used in class extending the abstract class.

now the real life difference that comes is basically how you want to implement a certain design problem. interfaces generally define the behavior that a class needs to follow. abstract classes on other hand shows what type of class it is. this is also the difference in extending a class and implementing an interface.
14 years ago
Just restart the emulator and eclipse. Youll be fine
14 years ago