If I’m trying to make my App work on older devices, I use the Support Libary and ActionBarSherlock.
Of Course, they also work on newer devices. But should i use them on new OS versions, or change the code and resource files so that 4.0 devices for example all use the stock classes and not the support ones.
For example (pseudocode):
if (running 4.0+){
ActionBar= getActionBar();
}else{
ActionBar= getSupportActionBar();
}
or just use this one on all versions:
ActionBar= getSupportActionBar();
What are best pratices, and does that affect stability and perfomance ?
You answered yourself already: “Of Course, they also work on newer devices“. If it works then it works. Compatibility lib is just portion of Android framework separated from Honeycomb+ code and offered as .jar for use on older devices. If you target older devices, with pre 3.x Androids and HC+ devices at the same time, then if you still want to use fragments and stuff you got no other choice anyway. And you also need compatibility library for ActionBarSherlock, as it needs it as well.