Some stuff
This commit is contained in:
parent
433f60dac7
commit
de59e2e27f
8 changed files with 13 additions and 36 deletions
4
.idea/libraries/GraphView_3_1_2.xml
generated
4
.idea/libraries/GraphView_3_1_2.xml
generated
|
|
@ -4,8 +4,6 @@
|
|||
<root url="jar://$PROJECT_DIR$/app/libs/GraphView-3.1.2.jar!/" />
|
||||
</CLASSES>
|
||||
<JAVADOC />
|
||||
<SOURCES>
|
||||
<root url="jar://$PROJECT_DIR$/app/libs/GraphView-master.zip!/GraphView-master/src/main/java" />
|
||||
</SOURCES>
|
||||
<SOURCES />
|
||||
</library>
|
||||
</component>
|
||||
|
|
@ -15,6 +15,7 @@ android {
|
|||
release {
|
||||
runProguard false
|
||||
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
|
||||
zipAlign true
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -9,6 +9,7 @@
|
|||
<li>GraphView (<a href="http://android-graphview.org/">http://android-graphview.org/</a>)</li>
|
||||
<li>SweetiePlus Icons (<a href="http://sublink.ca/">http://sublink.ca/</a>)</li>
|
||||
<li>DynamicListView (<a href="https://android.googlesource.com">https://android.googlesource.com</a>)</li>
|
||||
<li>App icon by <a href="http://icons8.com/android-icons">Icons8.com</a></li>
|
||||
</ul>
|
||||
</body>
|
||||
</html>
|
||||
|
|
@ -29,10 +29,6 @@ public class MainActivity extends FragmentActivity
|
|||
private NavigationDrawerFragment navigationDrawerFragment;
|
||||
private StatusFragment statusFragment;
|
||||
|
||||
/**
|
||||
* Used to store the last screen title. For use in {@link #restoreActionBar()}.
|
||||
*/
|
||||
private CharSequence title;
|
||||
private int currentExecutor;
|
||||
|
||||
private static ArrayList<UeControlExecutor> executors;
|
||||
|
|
@ -46,7 +42,6 @@ public class MainActivity extends FragmentActivity
|
|||
getFragmentManager().findFragmentById(R.id.navigation_drawer);
|
||||
statusFragment = (StatusFragment)
|
||||
getFragmentManager().findFragmentById(R.id.status_fragment);
|
||||
title = getTitle();
|
||||
|
||||
// Set up the drawer.
|
||||
navigationDrawerFragment.setUp(
|
||||
|
|
@ -73,42 +68,24 @@ public class MainActivity extends FragmentActivity
|
|||
currentExecutor = position;
|
||||
}
|
||||
|
||||
public void onSectionAttached(int number) {
|
||||
currentExecutor = number;
|
||||
switch (number) {
|
||||
case 1:
|
||||
title = getString(R.string.title_section1);
|
||||
break;
|
||||
case 2:
|
||||
title = getString(R.string.title_section2);
|
||||
break;
|
||||
case 3:
|
||||
title = getString(R.string.title_section3);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
public void restoreActionBar() {
|
||||
ActionBar actionBar = getActionBar();
|
||||
actionBar.setNavigationMode(ActionBar.NAVIGATION_MODE_STANDARD);
|
||||
actionBar.setDisplayShowTitleEnabled(true);
|
||||
actionBar.setTitle(title);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public boolean onCreateOptionsMenu(Menu menu) {
|
||||
if (!navigationDrawerFragment.isDrawerOpen()) {
|
||||
if (navigationDrawerFragment != null && !navigationDrawerFragment.isDrawerOpen()) {
|
||||
// Only show items in the action bar relevant to this screen
|
||||
// if the drawer is not showing. Otherwise, let the drawer
|
||||
// decide what to show in the action bar.
|
||||
getMenuInflater().inflate(R.menu.main, menu);
|
||||
restoreActionBar();
|
||||
|
||||
ActionBar actionBar = getActionBar();
|
||||
actionBar.setNavigationMode(ActionBar.NAVIGATION_MODE_STANDARD);
|
||||
actionBar.setDisplayShowTitleEnabled(true);
|
||||
|
||||
return true;
|
||||
}
|
||||
return super.onCreateOptionsMenu(menu);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public boolean onOptionsItemSelected(MenuItem item) {
|
||||
// Handle action bar item clicks here. The action bar will
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@ public class ConfigureDialog extends DialogFragment {
|
|||
LinearLayout.LayoutParams.MATCH_PARENT));
|
||||
|
||||
TextView label = new TextView(getActivity());
|
||||
label.setText(confParam.getName()+": ");
|
||||
label.setText(confParam.getNiceName()+": ");
|
||||
label.setLayoutParams(new LinearLayout.LayoutParams(
|
||||
LinearLayout.LayoutParams.WRAP_CONTENT,
|
||||
LinearLayout.LayoutParams.WRAP_CONTENT));
|
||||
|
|
|
|||
|
|
@ -91,7 +91,7 @@ public class Configurator {
|
|||
public String getNiceName(){return niceName;}
|
||||
public ConfigType getType(){return type;}
|
||||
|
||||
public String getString(){return (String) value;}
|
||||
public String getString(){return value.toString();}
|
||||
|
||||
public void setString(String v){
|
||||
switch(type){
|
||||
|
|
|
|||
|
|
@ -7,6 +7,6 @@
|
|||
For more on layout aliases, see:
|
||||
http://developer.android.com/training/multiscreen/screensizes.html#TaskUseAliasFilters
|
||||
-->
|
||||
<item name="fragment_item" type="layout">@layout/fragment_item_list</item>
|
||||
<item name="fragment_item" type="layout">@layout/fragment_list</item>
|
||||
|
||||
</resources>
|
||||
Loading…
Add table
Add a link
Reference in a new issue