Home
last modified time | relevance | path

Searched refs:max (Results 1 – 25 of 150) sorted by relevance

123456

/packages/apps/MusicFX/src/com/android/musicfx/seekbar/
DAbsSeekBar.java172 public synchronized void setMax(int max) {
173 super.setMax(max);
178 setKeyProgressIncrement(Math.max(1, Math.round((float) getMax() / 20)));
238 int max = getMax();
239 float scale = max > 0 ? (float) getProgress() / (float) max : 0;
269 int max = getMax();
270 float scale = max > 0 ? (float) getProgress() / (float) max : 0;
372 dw = Math.max(mMinWidth, Math.min(mMaxWidth, d.getIntrinsicWidth()));
373 dh = Math.max(mMinHeight, Math.min(mMaxHeight, d.getIntrinsicHeight()));
374 dh = Math.max(thumbHeight, dh);
[all …]
DProgressBar.java764 public synchronized void setMax(int max) { in setMax() argument
765 if (max < 0) { in setMax()
766 max = 0; in setMax()
768 if (max != mMax) { in setMax()
769 mMax = max; in setMax()
772 if (mProgress > max) { in setMax()
773 mProgress = max; in setMax()
987 dw = Math.max(mMinWidth, Math.min(mMaxWidth, d.getIntrinsicWidth())); in onMeasure()
988 dh = Math.max(mMinHeight, Math.min(mMaxHeight, d.getIntrinsicHeight())); in onMeasure()
/packages/apps/Camera/jni/feature_stab/db_vlvm/
Ddb_utilities_random.h57 inline int db_RandomInt(int &r,int max) in db_RandomInt() argument
61 dtemp=db_QuickRandomDouble(r)*(max+1); in db_RandomInt()
64 if(itemp>=max) return(max); in db_RandomInt()
/packages/apps/Gallery2/src/com/android/gallery3d/ui/
DScrollerHelper.java74 public void fling(int velocity, int min, int max) { in fling() argument
79 min, max, // minX, maxX in fling()
85 public int startScroll(int distance, int min, int max) { in startScroll() argument
88 int newPosition = Utils.clamp(finalPosition + distance, min, max); in startScroll()
DEdgeEffect.java197 mEdgeAlpha = mEdgeAlphaStart = Math.max(PULL_EDGE_BEGIN, Math.min(distance, MAX_ALPHA)); in onPull()
198 mEdgeScaleY = mEdgeScaleYStart = Math.max( in onPull()
214 mGlowScaleY = mGlowScaleYStart = Math.min(MAX_GLOW_HEIGHT, Math.max( in onPull()
263 velocity = Math.max(MIN_VELOCITY, Math.abs(velocity)); in onAbsorb()
279 mEdgeAlphaFinish = Math.max(0, Math.min(velocity * VELOCITY_EDGE_FACTOR, 1)); in onAbsorb()
281 mEdgeScaleYFinish = Math.max( in onAbsorb()
290 mGlowAlphaFinish = Math.max( in onAbsorb()
313 mGlow.setAlpha((int) (Math.max(0, Math.min(mGlowAlpha, 1)) * 255)); in draw()
329 mEdge.setAlpha((int) (Math.max(0, Math.min(mEdgeAlpha, 1)) * 255)); in draw()
DProgressSpinner.java39 mWidth = Math.max(mOuter.getWidth(), mInner.getWidth()); in ProgressSpinner()
40 mHeight = Math.max(mOuter.getHeight(), mInner.getHeight()); in ProgressSpinner()
/packages/apps/Settings/src/com/android/settings/widget/
DChartDataUsageView.java217 final long max = mVertMax; in updateVertAxisBounds() local
224 newMax = max * 11 / 10; in updateVertAxisBounds()
227 newMax = max * 9 / 10; in updateVertAxisBounds()
229 newMax = max; in updateVertAxisBounds()
234 final long maxSweep = Math.max(mSweepWarning.getValue(), mSweepLimit.getValue()); in updateVertAxisBounds()
235 final long maxSeries = Math.max(mSeries.getMaxVisible(), mDetailSeries.getMaxVisible()); in updateVertAxisBounds()
236 final long maxVisible = Math.max(maxSeries, maxSweep) * 12 / 10; in updateVertAxisBounds()
237 final long maxDefault = Math.max(maxVisible, 2 * GB_IN_BYTES); in updateVertAxisBounds()
238 newMax = Math.max(maxDefault, newMax); in updateVertAxisBounds()
407 : Math.max(visibleStart, historyStart); in setVisibleRange()
[all …]
DInvertedChartAxis.java34 public boolean setBounds(long min, long max) { in setBounds() argument
35 return mWrapped.setBounds(min, max); in setBounds()
/packages/inputmethods/OpenWnn/libs/libwnnDictionary/include/
Dnjd.h63 #define NORMALIZE_HINDO(freq, max, min) \ argument
64 (((freq) < (min)) ? (min) : (((freq) > (max)) ? (max) : (freq)))
/packages/apps/Gallery2/gallerycommon/src/com/android/gallery3d/common/
DUtils.java115 public static int clamp(int x, int min, int max) { in clamp() argument
116 if (x > max) return max; in clamp()
122 public static float clamp(float x, float min, float max) { in clamp() argument
123 if (x > max) return max; in clamp()
129 public static long clamp(long x, long min, long max) { in clamp() argument
130 if (x > max) return max; in clamp()
DBitmapUtils.java80 return Math.max(sampleSize, lowerBound); in computeInitialSampleSize()
88 int initialSize = Math.max(w / minSideLength, h / minSideLength); in computeSampleSizeLarger()
109 int initialSize = Math.max(1, (int) Math.ceil(1 / scale)); in computeSampleSize()
163 float scale = Math.max( in resizeDownIfTooBig()
193 float scale = Math.max((float) size / bitmap.getWidth(), in resizeDownAndCropCenter()
/packages/inputmethods/OpenWnn/libs/libwnnDictionary/engine/
Dndldic.c96 #define NEXT_QUE(que, max) ( ((que) < ((max) - 1)) ? ((que) + 1) : 0 ) argument
98 #define PREV_QUE(que, max) ( ((que) == 0) ? ((max) - 1) : ((que) - 1) ) argument
389 NJ_UINT16 max, end; in is_continued() local
392 max = GET_LEARN_MAX_WORD_COUNT(handle); in is_continued()
395 for (i = 0; i < max; i++) { in is_continued()
436 NJ_UINT16 max, end; in continue_cnt() local
440 max = GET_LEARN_MAX_WORD_COUNT(handle); in continue_cnt()
443 for (i = 0; i < max; i++) { in continue_cnt()
445 if (que_id >= max) { in continue_cnt()
482 NJ_UINT16 max; in search_next_que() local
[all …]
/packages/apps/Contacts/src/com/android/contacts/quickcontact/
DFloatingChildLayout.java128 private static int clampDimension(int value, int size, int max) { in clampDimension() argument
130 if (size > max) { in clampDimension()
131 return (max - size) / 2; in clampDimension()
135 return Math.min(Math.max(value, 0), max - size); in clampDimension()
/packages/apps/Launcher2/src/com/android/launcher2/
DAppWidgetResizeFrame.java168 mDeltaX = Math.max(-mBaselineX, deltaX); in updateDeltas()
172 mDeltaX = Math.max(-mBaselineWidth + 2 * mTouchTargetWidth, mDeltaX); in updateDeltas()
176 mDeltaY = Math.max(-mBaselineY, deltaY); in updateDeltas()
180 mDeltaY = Math.max(-mBaselineHeight + 2 * mTouchTargetWidth, mDeltaY); in updateDeltas()
242 cellXInc = Math.max(-mExpandability[LEFT], hSpanInc); in resizeWidgetIfNeeded()
246 hSpanInc = Math.max(-(lp.cellHSpan - mMinHSpan), hSpanInc); in resizeWidgetIfNeeded()
250 hSpanInc = Math.max(-(lp.cellHSpan - mMinHSpan), hSpanInc); in resizeWidgetIfNeeded()
255 cellYInc = Math.max(-mExpandability[TOP], vSpanInc); in resizeWidgetIfNeeded()
259 vSpanInc = Math.max(-(lp.cellVSpan - mMinVSpan), vSpanInc); in resizeWidgetIfNeeded()
263 vSpanInc = Math.max(-(lp.cellVSpan - mMinVSpan), vSpanInc); in resizeWidgetIfNeeded()
DSmoothPagedView.java130 whichPage = Math.max(0, Math.min(whichPage, getChildCount() - 1)); in snapToPageWithVelocity()
132 final int screenDelta = Math.max(1, Math.abs(whichPage - mCurrentPage)); in snapToPageWithVelocity()
/packages/apps/Exchange/src/com/android/exchange/adapter/
DProvisionParser.java242 int max = getValueInt(); in parseProvisionDocWbxml() local
243 if (max > 0) { in parseProvisionDocWbxml()
244 policy.mMaxAttachmentSize = max; in parseProvisionDocWbxml()
274 max = getValueInt(); in parseProvisionDocWbxml()
276 if (max != 0) { in parseProvisionDocWbxml()
278 policy.mMaxCalendarLookback = max; in parseProvisionDocWbxml()
281 policy.mMaxEmailLookback = max; in parseProvisionDocWbxml()
293 max = Integer.parseInt(value); in parseProvisionDocWbxml()
295 policy.mMaxTextTruncationSize = max; in parseProvisionDocWbxml()
298 policy.mMaxHtmlTruncationSize = max; in parseProvisionDocWbxml()
/packages/apps/Browser/src/com/android/browser/view/
DBasePieView.java100 mChildWidth = Math.max(mChildWidth, view.getMeasuredWidth()); in buildViews()
101 mChildHeight = Math.max(mChildHeight, view.getMeasuredHeight()); in buildViews()
143 setCurrent(Math.max(0, Math.min(mViews.size() -1, in onTouchEvent()
/packages/apps/Camera/src/com/android/camera/panorama/
DPanoProgressBar.java141 mProgress = Math.min(mWidth, Math.max(0, mProgress)); in setProgress()
144 mRightMostProgress = Math.max(mRightMostProgress, mProgress); in setProgress()
173 l = Math.max(mProgress - mIndicatorWidth, 0f); in onDraw()
/packages/apps/Settings/src/com/android/settings/
DChooseLockPassword.java157 mRequestedQuality = Math.max(intent.getIntExtra(LockPatternUtils.PASSWORD_TYPE_KEY, in onCreate()
159 mPasswordMinLength = Math.max( in onCreate()
163 mPasswordMinLetters = Math.max(intent.getIntExtra(PASSWORD_MIN_LETTERS_KEY, in onCreate()
165 mPasswordMinUpperCase = Math.max(intent.getIntExtra(PASSWORD_MIN_UPPERCASE_KEY, in onCreate()
167 mPasswordMinLowerCase = Math.max(intent.getIntExtra(PASSWORD_MIN_LOWERCASE_KEY, in onCreate()
169 mPasswordMinNumeric = Math.max(intent.getIntExtra(PASSWORD_MIN_NUMERIC_KEY, in onCreate()
171 mPasswordMinSymbols = Math.max(intent.getIntExtra(PASSWORD_MIN_SYMBOLS_KEY, in onCreate()
173 mPasswordMinNonLetter = Math.max(intent.getIntExtra(PASSWORD_MIN_NONLETTER_KEY, in onCreate()
DTrustedCredentialsSettings.java226 int max = aliases.size(); in doInBackground() local
228 List<CertHolder> certHolders = new ArrayList<CertHolder>(max); in doInBackground()
236 publishProgress(++progress, max); in doInBackground()
243 int max = progressAndMax[1]; in onProgressUpdate() local
244 if (max != mProgressBar.getMax()) { in onProgressUpdate()
245 mProgressBar.setMax(max); in onProgressUpdate()
/packages/apps/QuickSearchBox/src/com/android/quicksearchbox/
DRankAwarePromoter.java80 int stripeSize = Math.max(1, slotsToFill / highRankingSuggestions.size()); in promoteTopSuggestions()
105 int stripeSize = Math.max(1, slotsLeft / suggestions.size()); in promoteEquallyFromEachCorpus()
151 return Math.max(0, maxPromoted - promoted.getCount()); in getSlotsLeft()
/packages/apps/Gallery2/src/com/android/gallery3d/gadget/
DWidgetUtils.java63 scale = Math.max((float) sStackPhotoWidth / w, in createWidgetBitmap()
66 scale = Math.max((float) sStackPhotoWidth / h, in createWidgetBitmap()
/packages/apps/Gallery2/src/com/android/gallery3d/photoeditor/
DBitmapUtils.java155 int sampleSize = Math.max(bounds.width() / width, bounds.height() / height); in decodeBitmap()
157 Math.max(bounds.width() / height, bounds.height() / width)); in decodeBitmap()
160 options.inSampleSize = Math.max(sampleSize, 1); in decodeBitmap()
182 scale = Math.max(scale, Math.min((float) height / bitmap.getWidth(), in decodeBitmap()
/packages/apps/Contacts/src/com/android/contacts/datepicker/
DDatePicker.java442 int max = cal.getActualMaximum(Calendar.DAY_OF_MONTH); in updateDaySpinner() local
444 mDayPicker.setMaxValue(max); in updateDaySpinner()
469 int max = cal.getActualMaximum(Calendar.DAY_OF_MONTH); in adjustMaxDay() local
470 if (mDay > max) { in adjustMaxDay()
471 mDay = max; in adjustMaxDay()
/packages/apps/Gallery2/src/com/android/gallery3d/photoeditor/actions/
DCropView.java148 : Math.max(displayBounds.left - cropped.left, deltaX); in moveEdges()
150 : Math.max(displayBounds.top - cropped.top, deltaY); in moveEdges()
163 cropped.right = Math.max(cropped.right + deltaX, cropped.left + minWidth); in moveEdges()
166 cropped.bottom = Math.max(cropped.bottom + deltaY, cropped.top + minHeight); in moveEdges()

123456