Merge "Allow more scaling values to be tuned in resource overlays" into jb-mr1-dev
This commit is contained in:
@@ -17,6 +17,7 @@
|
||||
package android.view;
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.res.Resources;
|
||||
import android.os.SystemClock;
|
||||
import android.util.FloatMath;
|
||||
|
||||
@@ -162,9 +163,11 @@ public class ScaleGestureDetector {
|
||||
mContext = context;
|
||||
mListener = listener;
|
||||
mSpanSlop = ViewConfiguration.get(context).getScaledTouchSlop() * 2;
|
||||
mTouchMinMajor =
|
||||
(int) (context.getResources().getDisplayMetrics().density * TOUCH_MIN_MAJOR + 0.5f);
|
||||
mMinSpan = context.getResources().getDimensionPixelSize(
|
||||
|
||||
final Resources res = context.getResources();
|
||||
mTouchMinMajor = res.getDimensionPixelSize(
|
||||
com.android.internal.R.dimen.config_minScalingTouchMajor);
|
||||
mMinSpan = res.getDimensionPixelSize(
|
||||
com.android.internal.R.dimen.config_minScalingSpan);
|
||||
}
|
||||
|
||||
|
||||
@@ -941,6 +941,10 @@
|
||||
reported by the hardware. -->
|
||||
<dimen name="config_minScalingSpan">27mm</dimen>
|
||||
|
||||
<!-- Minimum accepted value for touchMajor while scaling. This may be tuned
|
||||
per-device in overlays. -->
|
||||
<dimen name="config_minScalingTouchMajor">48dp</dimen>
|
||||
|
||||
<!-- Safe headphone volume index. When music stream volume is below this index
|
||||
the SPL on headphone output is compliant to EN 60950 requirements for portable music
|
||||
players. -->
|
||||
|
||||
@@ -1150,6 +1150,7 @@
|
||||
<java-symbol type="string" name="bluetooth_a2dp_audio_route_name" />
|
||||
|
||||
<java-symbol type="dimen" name="config_minScalingSpan" />
|
||||
<java-symbol type="dimen" name="config_minScalingTouchMajor" />
|
||||
|
||||
<!-- From android.policy -->
|
||||
<java-symbol type="anim" name="app_starting_exit" />
|
||||
|
||||
Reference in New Issue
Block a user