[iitcm] tweaks to fullscreen menu item
Use other icon for returning from fullscreen if shown as action. If shown in the action overflow, provide a chechbox to show current state.
This commit is contained in:
parent
fae1482498
commit
79569d36b0
BIN
mobile/res/drawable-hdpi/ic_action_return_from_full_screen.png
Normal file
BIN
mobile/res/drawable-hdpi/ic_action_return_from_full_screen.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 663 B |
BIN
mobile/res/drawable-mdpi/ic_action_return_from_full_screen.png
Normal file
BIN
mobile/res/drawable-mdpi/ic_action_return_from_full_screen.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 477 B |
BIN
mobile/res/drawable-xhdpi/ic_action_return_from_full_screen.png
Normal file
BIN
mobile/res/drawable-xhdpi/ic_action_return_from_full_screen.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 761 B |
BIN
mobile/res/drawable-xxhdpi/ic_action_return_from_full_screen.png
Normal file
BIN
mobile/res/drawable-xxhdpi/ic_action_return_from_full_screen.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.1 KiB |
@ -22,6 +22,7 @@
|
||||
android:title="@string/menu_layer_chooser"/>
|
||||
<item
|
||||
android:id="@+id/toggle_fullscreen"
|
||||
android:checkable="true"
|
||||
android:icon="@drawable/ic_action_full_screen"
|
||||
android:orderInCategory="110"
|
||||
android:showAsAction="ifRoom"
|
||||
|
@ -205,7 +205,7 @@
|
||||
</string-array>
|
||||
|
||||
<string name="menu_reload">Reload IITC</string>
|
||||
<string name="menu_toggle_fullscreen">Toggle fullscreen</string>
|
||||
<string name="menu_toggle_fullscreen">Fullscreen</string>
|
||||
<string name="menu_layer_chooser">Layer Chooser</string>
|
||||
<string name="menu_locate">Get Location</string>
|
||||
<string name="menu_clear_cookies">Clear Cookies</string>
|
||||
|
@ -535,6 +535,13 @@ public class IITC_Mobile extends Activity
|
||||
item.setVisible(true);
|
||||
break;
|
||||
|
||||
case R.id.toggle_fullscreen:
|
||||
item.setChecked(mIitcWebView.isInFullscreen());
|
||||
item.setIcon(mIitcWebView.isInFullscreen()
|
||||
? R.drawable.ic_action_return_from_full_screen
|
||||
: R.drawable.ic_action_full_screen);
|
||||
break;
|
||||
|
||||
case R.id.locate:
|
||||
item.setVisible(enabled && visible);
|
||||
item.setEnabled(!mIsLoading);
|
||||
|
@ -221,6 +221,7 @@ public class IITC_WebView extends WebView {
|
||||
loadUrl("javascript: $('#updatestatus').show();");
|
||||
}
|
||||
mIitc.getWindow().setAttributes(attrs);
|
||||
mIitc.invalidateOptionsMenu();
|
||||
}
|
||||
|
||||
void updateFullscreenStatus() {
|
||||
|
Loading…
x
Reference in New Issue
Block a user