2 new revisions:
Revision: 4f012aa954c7
Author: Torne (Richard Coles) <
to...@wolfpuppy.org.uk>
Date: Sun Nov 11 06:32:20 2012
Log: Make v14 styles match v11....
http://code.google.com/p/connectbot/source/detail?r=4f012aa954c7
Revision: 5197f24b7038
Author: Torne (Richard Coles) <
to...@wolfpuppy.org.uk>
Date: Sun Nov 11 06:33:06 2012
Log: Make the action bar home button work....
http://code.google.com/p/connectbot/source/detail?r=5197f24b7038
==============================================================================
Revision: 4f012aa954c7
Author: Torne (Richard Coles) <
to...@wolfpuppy.org.uk>
Date: Sun Nov 11 06:32:20 2012
Log: Make v14 styles match v11.
The revert of the previous change to disable targeting v14 left the styles
inconsistent making the action bar not an overlay. Fix by copying the style
changes over.
http://code.google.com/p/connectbot/source/detail?r=4f012aa954c7
Modified:
/res/values-v14/styles.xml
=======================================
--- /res/values-v14/styles.xml Sun Oct 28 12:52:48 2012
+++ /res/values-v14/styles.xml Sun Nov 11 06:32:20 2012
@@ -20,5 +20,11 @@
<resources>
<style name="NoTitle" parent="android:Theme.DeviceDefault">
<item name="android:windowContentOverlay">@null</item>
+ <item name="android:windowActionBarOverlay">true</item>
+ <item name="android:actionBarStyle">@style/SolidActionBar</item>
+ </style>
+
+ <style name="SolidActionBar" parent="android:Widget.Holo.ActionBar">
+ <item name="android:background">#222222</item>
</style>
</resources>
==============================================================================
Revision: 5197f24b7038
Author: Torne (Richard Coles) <
to...@wolfpuppy.org.uk>
Date: Sun Nov 11 06:33:06 2012
Log: Make the action bar home button work.
Hook up the action bar home button on ConsoleActivity to return to the host
list.
http://code.google.com/p/connectbot/source/detail?r=5197f24b7038
Modified:
/src/org/connectbot/ActionBarWrapper.java
/src/org/connectbot/ConsoleActivity.java
=======================================
--- /src/org/connectbot/ActionBarWrapper.java Sat Oct 27 13:21:48 2012
+++ /src/org/connectbot/ActionBarWrapper.java Sun Nov 11 06:33:06 2012
@@ -42,6 +42,9 @@
public void addOnMenuVisibilityListener(OnMenuVisibilityListener
listener) {
}
+
+ public void setDisplayHomeAsUpEnabled(boolean showHomeAsUp) {
+ }
private static class DummyActionBar extends ActionBarWrapper {
}
@@ -71,5 +74,10 @@
}
});
}
+
+ @Override
+ public void setDisplayHomeAsUpEnabled(boolean showHomeAsUp) {
+ actionBar.setDisplayHomeAsUpEnabled(showHomeAsUp);
+ }
}
}
=======================================
--- /src/org/connectbot/ConsoleActivity.java Sat Oct 27 13:21:48 2012
+++ /src/org/connectbot/ConsoleActivity.java Sun Nov 11 06:33:06 2012
@@ -404,6 +404,7 @@
});
actionBar = ActionBarWrapper.getActionBar(this);
+ actionBar.setDisplayHomeAsUpEnabled(true);
actionBar.hide();
actionBar.addOnMenuVisibilityListener(new
ActionBarWrapper.OnMenuVisibilityListener() {
public void onMenuVisibilityChanged(boolean isVisible) {
@@ -826,6 +827,19 @@
return true;
}
+
+ @Override
+ public boolean onOptionsItemSelected(MenuItem item) {
+ switch (item.getItemId()) {
+ case android.R.id.home:
+ Intent intent = new Intent(this, HostListActivity.class);
+ intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);
+ startActivity(intent);
+ return true;
+ default:
+ return super.onOptionsItemSelected(item);
+ }
+ }
@Override
public void onOptionsMenuClosed(Menu menu) {