From be6416b736326b1c3d6f77b8dd7d6141cf4364d9 Mon Sep 17 00:00:00 2001 From: iwgeric Date: Thu, 2 Apr 2015 13:12:08 -0400 Subject: [PATCH] SDK: Add layout.xml and strings.xml to Important Files node in Android projects. Useful to quickly modify the layout for the upcoming switch to Android Fragments. --- .../com/jme3/gde/android/AndroidImportantFiles.java | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/sdk/jme3-android/src/com/jme3/gde/android/AndroidImportantFiles.java b/sdk/jme3-android/src/com/jme3/gde/android/AndroidImportantFiles.java index cbfb487cc..b96bb769c 100644 --- a/sdk/jme3-android/src/com/jme3/gde/android/AndroidImportantFiles.java +++ b/sdk/jme3-android/src/com/jme3/gde/android/AndroidImportantFiles.java @@ -67,6 +67,18 @@ public class AndroidImportantFiles implements ImportantFiles { node.setDisplayName("Android Properties"); list.add(node); } + FileObject layout = project.getProjectDirectory().getFileObject("mobile/res/layout/main.xml"); + if (layout != null) { + Node node = DataObject.find(layout).getNodeDelegate(); + node.setDisplayName("Android Layout"); + list.add(node); + } + FileObject strings = project.getProjectDirectory().getFileObject("mobile/res/values/strings.xml"); + if (strings != null) { + Node node = DataObject.find(strings).getNodeDelegate(); + node.setDisplayName("Android Strings"); + list.add(node); + } } catch (DataObjectNotFoundException ex) { Exceptions.printStackTrace(ex); }