diff --git a/app/src/main/java/io/neurolab/activities/MemoryGraphParent.java b/app/src/main/java/io/neurolab/activities/MemoryGraphParent.java
index 9112b538..4899f0ef 100644
--- a/app/src/main/java/io/neurolab/activities/MemoryGraphParent.java
+++ b/app/src/main/java/io/neurolab/activities/MemoryGraphParent.java
@@ -17,6 +17,7 @@ public class MemoryGraphParent extends AppCompatActivity {
private String filePath;
public static final String MEMORY_GRAPH_FLAG = "Memory";
+ private static Fragment defaultProgram = MemoryGraphFragment.newInstance();
@Override
protected void onCreate(Bundle savedInstanceState) {
@@ -49,12 +50,11 @@ protected void onCreate(Bundle savedInstanceState) {
selectedFragment.setArguments(bundle);
FragmentTransaction transaction = getSupportFragmentManager().beginTransaction();
transaction.replace(R.id.frame_layout, selectedFragment);
+ defaultProgram = selectedFragment;
transaction.commit();
return true;
});
-
FragmentTransaction transaction = getSupportFragmentManager().beginTransaction();
- Fragment defaultProgram = MemoryGraphFragment.newInstance();
defaultProgram.setArguments(bundle);
transaction.replace(R.id.frame_layout, defaultProgram);
transaction.commit();
@@ -70,6 +70,7 @@ public boolean onSupportNavigateUp(){
public void onBackPressed() {
super.onBackPressed();
StatisticsFragment.parsedData = null;
+ defaultProgram = MemoryGraphFragment.newInstance();
}
public void setActionBarTitle(String title) {
diff --git a/app/src/main/res/layout/fragment_spectrum.xml b/app/src/main/res/layout/fragment_spectrum.xml
index 3cbd0777..eb4f8302 100644
--- a/app/src/main/res/layout/fragment_spectrum.xml
+++ b/app/src/main/res/layout/fragment_spectrum.xml
@@ -15,61 +15,66 @@
android:textColor="@android:color/white"
android:textSize="@dimen/text_size_small" />
-
-
-
-
-
+ android:background="@color/memory_graph_background">
+ android:layout_height="match_parent"
+ android:background="@color/memory_graph_background"
+ android:orientation="vertical">
+
+
-
+
-
+ android:layout_margin="@dimen/padding_medium"
+ android:orientation="horizontal">
-
+
-
+
-
+
-
+ android:layout_margin="@dimen/padding_medium"
+ android:orientation="horizontal">
-
-
+
+
+
+
+
+
\ No newline at end of file
diff --git a/app/src/main/res/layout/fragment_statistics.xml b/app/src/main/res/layout/fragment_statistics.xml
index 5ee4bbf5..61f5f415 100644
--- a/app/src/main/res/layout/fragment_statistics.xml
+++ b/app/src/main/res/layout/fragment_statistics.xml
@@ -7,6 +7,12 @@
android:layout_height="match_parent"
tools:context=".fragments.StatisticsFragment">
-
+
+
+
+
+
\ No newline at end of file