Whenever I create new project it always creating appcompat_v7 project with my new project. And when I create new android activity it always extend ActionBarActivity and also create fragment_main.xml. I tried to update adt and s\w also still no luck
and this code also generated in main activity
public static class PlaceholderFragment extends Fragment {
public PlaceholderFragment() {
}
@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState) {
View rootView = inflater.inflate(R.layout.fragment_main, container,
false);
return rootView;
}
}
user3773999
I had the same problem. I have figured out 3 ways hope this helps
- (this may or may not work) Check your android virtual device manager. I would think you have a device that has CPU/ABI selected for "armeabi-v7a". Delete that device and try creating a new project. You would notice that project appcompat_v7 is no longer being created.
- (Works) Another way to avoid this would to create new project through android project through existing codes. Hopeful you have a project you created from before to copy over.
- (Works) Create a blank android project without activity and create the activity later.
来源:https://stackoverflow.com/questions/22250633/eclipse-behaving-differently-while-creating-new-project-activity