1
0
mirror of https://github.com/moparisthebest/k-9 synced 2024-11-27 19:52:17 -05:00

At Jesse's suggestion, avoid the use of the Android term-of-art "density". Instead use "Compact layouts" to refer, both internally and externally, to the feature of elminating minimum sizes on UI elements and other minor layout changes for maximizing information quantity to be displayed on a page.

Others are free to adjust the user-facing text further.
This commit is contained in:
Dan Applebaum 2011-02-04 17:01:22 +00:00 committed by Jesse Vincent
parent 945fd2ab71
commit e31d218dc5
6 changed files with 20 additions and 20 deletions

View File

@ -903,8 +903,8 @@ Welcome to K-9 Mail setup. K-9 is an open source mail client for Android origin
<string name="gestures_title">Gestures</string>
<string name="gestures_summary">Accept gesture control</string>
<string name="high_density_title">High density</string>
<string name="high_density_summary">Adjust layouts to display more on each page</string>
<string name="compact_layouts_title">Compact layouts</string>
<string name="compact_layouts_summary">Adjust layouts to display more on each page</string>
<string name="volume_navigation_title">Volume key navigation</string>
<string name="volume_navigation_summary">Flip through items using the volume controls</string>

View File

@ -69,9 +69,9 @@
<CheckBoxPreference
android:persistent="false"
android:key="high_density"
android:title="@string/high_density_title"
android:summary="@string/high_density_summary" />
android:key="compact_layouts"
android:title="@string/compact_layouts_title"
android:summary="@string/compact_layouts_summary" />
</PreferenceCategory>

View File

@ -176,7 +176,7 @@ public class K9 extends Application
private static boolean mQuietTimeEnabled = false;
private static String mQuietTimeStarts = null;
private static String mQuietTimeEnds = null;
private static boolean highDensity = false;
private static boolean compactLayouts = false;
@ -455,7 +455,7 @@ public class K9 extends Application
editor.putBoolean("keyguardPrivacy", mKeyguardPrivacy);
editor.putBoolean("highDensity", highDensity);
editor.putBoolean("compactLayouts", compactLayouts);
fontSizes.save(editor);
}
@ -507,7 +507,7 @@ public class K9 extends Application
mKeyguardPrivacy = sprefs.getBoolean("keyguardPrivacy", false);
highDensity = sprefs.getBoolean("highDensity", false);
compactLayouts = sprefs.getBoolean("compactLayouts", false);
fontSizes.load(sprefs);
@ -1042,14 +1042,14 @@ public class K9 extends Application
mKeyguardPrivacy = state;
}
public static boolean isHighDensity()
public static boolean useCompactLayouts()
{
return highDensity;
return compactLayouts;
}
public static void setHighDensity(boolean highDensity)
public static void setCompactLayouts(boolean compactLayouts)
{
K9.highDensity = highDensity;
K9.compactLayouts = compactLayouts;
}
/**

View File

@ -1081,11 +1081,11 @@ public class Accounts extends K9ListActivity implements OnItemClickListener, OnC
holder.description.setTextSize(TypedValue.COMPLEX_UNIT_DIP, mFontSizes.getAccountName());
holder.email.setTextSize(TypedValue.COMPLEX_UNIT_DIP, mFontSizes.getAccountDescription());
if (K9.isHighDensity())
if (K9.useCompactLayouts())
{
holder.accountsItemLayout.setMinimumHeight(0);
}
if (account instanceof SearchAccount || K9.isHighDensity())
if (account instanceof SearchAccount || K9.useCompactLayouts())
{
holder.folders.setVisibility(View.GONE);

View File

@ -1404,7 +1404,7 @@ public class FolderList extends K9ListActivity
{
holder.flaggedMessageCount.setVisibility(View.GONE);
}
if (K9.isHighDensity() && holder.folderListItemLayout != null)
if (K9.useCompactLayouts() && holder.folderListItemLayout != null)
{
holder.folderListItemLayout.setMinimumHeight(0);
}

View File

@ -61,7 +61,7 @@ public class Prefs extends K9PreferenceActivity
private static final String PREFERENCE_MESSAGELIST_SHOW_CONTACT_NAME = "messagelist_show_contact_name";
private static final String PREFERENCE_MESSAGELIST_CONTACT_NAME_COLOR = "messagelist_contact_name_color";
private static final String PREFERENCE_MESSAGEVIEW_FIXEDWIDTH = "messageview_fixedwidth_font";
private static final String PREFERENCE_HIGH_DENSITY = "high_density";
private static final String PREFERENCE_COMPACT_LAYOUTS = "compact_layouts";
private static final String PREFERENCE_MESSAGEVIEW_RETURN_TO_LIST = "messageview_return_to_list";
private static final String PREFERENCE_MESSAGEVIEW_ZOOM_CONTROLS_ENABLED = "messageview_zoom_controls";
@ -104,7 +104,7 @@ public class Prefs extends K9PreferenceActivity
private CheckBoxPreference mUseGalleryBugWorkaround;
private CheckBoxPreference mDebugLogging;
private CheckBoxPreference mSensitiveLogging;
private CheckBoxPreference highDensity;
private CheckBoxPreference compactLayouts;
private CheckBoxPreference mQuietTimeEnabled;
private com.fsck.k9.preferences.TimePickerPreference mQuietTimeStarts;
@ -173,8 +173,8 @@ public class Prefs extends K9PreferenceActivity
mGestures = (CheckBoxPreference)findPreference(PREFERENCE_GESTURES);
mGestures.setChecked(K9.gesturesEnabled());
highDensity = (CheckBoxPreference)findPreference(PREFERENCE_HIGH_DENSITY);
highDensity.setChecked(K9.isHighDensity());
compactLayouts = (CheckBoxPreference)findPreference(PREFERENCE_COMPACT_LAYOUTS);
compactLayouts.setChecked(K9.useCompactLayouts());
mVolumeNavigation = (CheckBoxListPreference)findPreference(PREFERENCE_VOLUME_NAVIGATION);
mVolumeNavigation.setItems(new CharSequence[] {getString(R.string.volume_navigation_message), getString(R.string.volume_navigation_list)});
@ -316,7 +316,7 @@ public class Prefs extends K9PreferenceActivity
K9.setK9Theme(mTheme.getValue().equals("dark") ? android.R.style.Theme : android.R.style.Theme_Light);
K9.setAnimations(mAnimations.isChecked());
K9.setGesturesEnabled(mGestures.isChecked());
K9.setHighDensity(highDensity.isChecked());
K9.setCompactLayouts(compactLayouts.isChecked());
K9.setUseVolumeKeysForNavigation(mVolumeNavigation.getCheckedItems()[0]);
K9.setUseVolumeKeysForListNavigation(mVolumeNavigation.getCheckedItems()[1]);
K9.setManageBack(mManageBack.isChecked());