Home
last modified time | relevance | path

Searched refs:lp (Results 1 – 25 of 117) sorted by relevance

12345

/packages/apps/Settings/src/com/android/settings/widget/
DMatchParentShrinkingLinearLayout.java337 final LayoutParams lp = (LayoutParams) child.getLayoutParams(); in drawDividersVertical() local
338 final int top = child.getTop() - lp.topMargin - mDividerHeight; in drawDividersVertical()
350 final LayoutParams lp = (LayoutParams) child.getLayoutParams(); in drawDividersVertical() local
351 bottom = child.getBottom() + lp.bottomMargin; in drawDividersVertical()
365 final LayoutParams lp = (LayoutParams) child.getLayoutParams(); in drawDividersHorizontal() local
368 position = child.getRight() + lp.rightMargin; in drawDividersHorizontal()
370 position = child.getLeft() - lp.leftMargin - mDividerWidth; in drawDividersHorizontal()
387 final LayoutParams lp = (LayoutParams) child.getLayoutParams(); in drawDividersHorizontal() local
389 position = child.getLeft() - lp.leftMargin - mDividerWidth; in drawDividersHorizontal()
391 position = child.getRight() + lp.rightMargin; in drawDividersHorizontal()
[all …]
/packages/services/Car/tests/CarDeveloperOptions/src/com/android/car/developeroptions/widget/
DMatchParentShrinkingLinearLayout.java337 final LayoutParams lp = (LayoutParams) child.getLayoutParams(); in drawDividersVertical() local
338 final int top = child.getTop() - lp.topMargin - mDividerHeight; in drawDividersVertical()
350 final LayoutParams lp = (LayoutParams) child.getLayoutParams(); in drawDividersVertical() local
351 bottom = child.getBottom() + lp.bottomMargin; in drawDividersVertical()
365 final LayoutParams lp = (LayoutParams) child.getLayoutParams(); in drawDividersHorizontal() local
368 position = child.getRight() + lp.rightMargin; in drawDividersHorizontal()
370 position = child.getLeft() - lp.leftMargin - mDividerWidth; in drawDividersHorizontal()
387 final LayoutParams lp = (LayoutParams) child.getLayoutParams(); in drawDividersHorizontal() local
389 position = child.getLeft() - lp.leftMargin - mDividerWidth; in drawDividersHorizontal()
391 position = child.getRight() + lp.rightMargin; in drawDividersHorizontal()
[all …]
/packages/apps/Launcher3/src/com/android/launcher3/
DShortcutAndWidgetContainer.java67 CellLayout.LayoutParams lp = (CellLayout.LayoutParams) child.getLayoutParams(); in getChildAt() local
69 if ((lp.cellX <= x) && (x < lp.cellX + lp.cellHSpan) && in getChildAt()
70 (lp.cellY <= y) && (y < lp.cellY + lp.cellVSpan)) { in getChildAt()
94 CellLayout.LayoutParams lp = (CellLayout.LayoutParams) child.getLayoutParams(); in setupLp() local
97 lp.setup(mCellWidth, mCellHeight, invertLayoutHorizontally(), mCountX, in setupLp()
100 lp.setup(mCellWidth, mCellHeight, invertLayoutHorizontally(), mCountX); in setupLp()
115 CellLayout.LayoutParams lp = (CellLayout.LayoutParams) child.getLayoutParams(); in measureChild() local
119 lp.setup(mCellWidth, mCellHeight, invertLayoutHorizontally(), mCountX, in measureChild()
123 lp.setup(mCellWidth, mCellHeight, invertLayoutHorizontally(), mCountX); in measureChild()
126 int cellPaddingY = (int) Math.max(0, ((lp.height - cHeight) / 2f)); in measureChild()
[all …]
DCellLayout.java577 final LayoutParams lp = params; in addViewToCellLayout() local
590 if (lp.cellX >= 0 && lp.cellX <= mCountX - 1 && lp.cellY >= 0 && lp.cellY <= mCountY - 1) { in addViewToCellLayout()
593 if (lp.cellHSpan < 0) lp.cellHSpan = mCountX; in addViewToCellLayout()
594 if (lp.cellVSpan < 0) lp.cellVSpan = mCountY; in addViewToCellLayout()
600 mShortcutsAndWidgets.addView(child, index, lp); in addViewToCellLayout()
874 final LayoutParams lp = (LayoutParams) child.getLayoutParams(); in animateChildToPosition() local
878 if (mReorderAnimators.containsKey(lp)) { in animateChildToPosition()
879 mReorderAnimators.get(lp).cancel(); in animateChildToPosition()
880 mReorderAnimators.remove(lp); in animateChildToPosition()
883 final int oldX = lp.x; in animateChildToPosition()
[all …]
DAppWidgetResizeFrame.java236 DragLayer.LayoutParams lp = (DragLayer.LayoutParams) getLayoutParams(); in visualizeResizeForDelta() local
239 lp.x = mTempRange1.start; in visualizeResizeForDelta()
240 lp.width = mTempRange1.size(); in visualizeResizeForDelta()
244 lp.y = mTempRange1.start; in visualizeResizeForDelta()
245 lp.height = mTempRange1.size(); in visualizeResizeForDelta()
253 lp.width = sTmpRect.width() + sTmpRect.left - lp.x; in visualizeResizeForDelta()
256 lp.height = sTmpRect.height() + sTmpRect.top - lp.y; in visualizeResizeForDelta()
259 lp.x = sTmpRect.left; in visualizeResizeForDelta()
262 lp.y = sTmpRect.top; in visualizeResizeForDelta()
287 CellLayout.LayoutParams lp = (CellLayout.LayoutParams) mWidgetView.getLayoutParams(); in resizeWidgetIfNeeded() local
[all …]
DWorkspaceLayoutManager.java102 CellLayout.LayoutParams lp; in addInScreen() local
104 lp = new CellLayout.LayoutParams(x, y, spanX, spanY); in addInScreen()
106 lp = (CellLayout.LayoutParams) genericLp; in addInScreen()
107 lp.cellX = x; in addInScreen()
108 lp.cellY = y; in addInScreen()
109 lp.cellHSpan = spanX; in addInScreen()
110 lp.cellVSpan = spanY; in addInScreen()
114 lp.isLockedToGrid = false; in addInScreen()
122 if (!layout.addViewToCellLayout(child, -1, childId, lp, markCellsAsOccupied)) { in addInScreen()
126 … Log.e(TAG, "Failed to add to item at (" + lp.cellX + "," + lp.cellY + ") to CellLayout"); in addInScreen()
DDropTargetBar.java82 FrameLayout.LayoutParams lp = (FrameLayout.LayoutParams) getLayoutParams(); in setInsets() local
86 lp.leftMargin = insets.left; in setInsets()
87 lp.topMargin = insets.top; in setInsets()
88 lp.bottomMargin = insets.bottom; in setInsets()
89 lp.rightMargin = insets.right; in setInsets()
93 lp.width = grid.dropTargetBarSizePx; in setInsets()
94 lp.height = grid.availableHeightPx - 2 * grid.edgeMarginPx; in setInsets()
95 lp.gravity = grid.isSeascape() ? Gravity.RIGHT : Gravity.LEFT; in setInsets()
109 lp.width = grid.availableWidthPx - 2 * gap; in setInsets()
111 lp.topMargin += grid.edgeMarginPx; in setInsets()
[all …]
DHotseat.java81 FrameLayout.LayoutParams lp = (FrameLayout.LayoutParams) getLayoutParams(); in setInsets() local
86 lp.height = ViewGroup.LayoutParams.MATCH_PARENT; in setInsets()
88 lp.gravity = Gravity.LEFT; in setInsets()
89 lp.width = grid.hotseatBarSizePx + insets.left; in setInsets()
91 lp.gravity = Gravity.RIGHT; in setInsets()
92 lp.width = grid.hotseatBarSizePx + insets.right; in setInsets()
95 lp.gravity = Gravity.BOTTOM; in setInsets()
96 lp.width = ViewGroup.LayoutParams.MATCH_PARENT; in setInsets()
97 lp.height = grid.hotseatBarSizePx + insets.bottom; in setInsets()
102 setLayoutParams(lp); in setInsets()
DInsettableFrameLayout.java26 final LayoutParams lp = (LayoutParams) child.getLayoutParams(); in setFrameLayoutChildInsets() local
30 } else if (!lp.ignoreInsets) { in setFrameLayoutChildInsets()
31 lp.topMargin += (newInsets.top - oldInsets.top); in setFrameLayoutChildInsets()
32 lp.leftMargin += (newInsets.left - oldInsets.left); in setFrameLayoutChildInsets()
33 lp.rightMargin += (newInsets.right - oldInsets.right); in setFrameLayoutChildInsets()
34 lp.bottomMargin += (newInsets.bottom - oldInsets.bottom); in setFrameLayoutChildInsets()
36 child.setLayoutParams(lp); in setFrameLayoutChildInsets()
86 public LayoutParams(ViewGroup.LayoutParams lp) { in LayoutParams() argument
87 super(lp); in LayoutParams()
DLauncherAnimUtils.java73 public Integer get(LayoutParams lp) {
74 return lp.width;
78 public void set(LayoutParams lp, Integer width) {
79 lp.width = width;
86 public Integer get(LayoutParams lp) {
87 return lp.height;
91 public void set(LayoutParams lp, Integer height) {
92 lp.height = height;
DLauncherRootView.java91 MarginLayoutParams lp = (MarginLayoutParams) mAlignedView.getLayoutParams(); in handleSystemWindowInsets() local
92 if (lp.leftMargin != mConsumedInsets.left || lp.rightMargin != mConsumedInsets.right || in handleSystemWindowInsets()
93 lp.bottomMargin != mConsumedInsets.bottom) { in handleSystemWindowInsets()
94 lp.leftMargin = mConsumedInsets.left; in handleSystemWindowInsets()
95 lp.rightMargin = mConsumedInsets.right; in handleSystemWindowInsets()
96 lp.topMargin = mConsumedInsets.top; in handleSystemWindowInsets()
97 lp.bottomMargin = mConsumedInsets.bottom; in handleSystemWindowInsets()
98 mAlignedView.setLayoutParams(lp); in handleSystemWindowInsets()
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/keyboard/emoji/
DEmojiLayoutParams.java64 final LinearLayout.LayoutParams lp = (LinearLayout.LayoutParams) vp.getLayoutParams(); in setPagerProperties() local
65 lp.height = mEmojiKeyboardHeight; in setPagerProperties()
66 lp.bottomMargin = mEmojiPagerBottomMargin; in setPagerProperties()
67 vp.setLayoutParams(lp); in setPagerProperties()
71 final LinearLayout.LayoutParams lp = (LinearLayout.LayoutParams) v.getLayoutParams(); in setCategoryPageIdViewProperties() local
72 lp.height = mEmojiCategoryPageIdViewHeight; in setCategoryPageIdViewProperties()
73 v.setLayoutParams(lp); in setCategoryPageIdViewProperties()
81 final LinearLayout.LayoutParams lp = (LinearLayout.LayoutParams) ll.getLayoutParams(); in setActionBarProperties() local
82 lp.height = getActionBarHeight(); in setActionBarProperties()
83 ll.setLayoutParams(lp); in setActionBarProperties()
[all …]
/packages/apps/Launcher3/src/com/android/launcher3/views/
DFloatingIconView.java215 LayoutParams lp = (LayoutParams) getLayoutParams(); in update() local
216 float dX = rect.left - lp.leftMargin; in update()
217 float dY = rect.top - lp.topMargin; in update()
221 float minSize = Math.min(lp.width, lp.height); in update()
314 final LayoutParams lp = new LayoutParams( in matchPositionOf() local
317 updatePosition(rotation, positionOut, lp); in matchPositionOf()
318 setLayoutParams(lp); in matchPositionOf()
321 private void updatePosition(float rotation, RectF position, LayoutParams lp) { in updatePosition() argument
324 lp.ignoreInsets = true; in updatePosition()
326 lp.leftMargin = Math.round(position.left); in updatePosition()
[all …]
DBaseDragLayer.java63 public Integer get(LayoutParams lp) {
64 return lp.x;
68 public void set(LayoutParams lp, Integer x) {
69 lp.x = x;
76 public Integer get(LayoutParams lp) {
77 return lp.y;
81 public void set(LayoutParams lp, Integer y) {
82 lp.y = y;
498 public LayoutParams(ViewGroup.LayoutParams lp) { in LayoutParams() argument
499 super(lp); in LayoutParams()
[all …]
/packages/apps/Gallery2/src/com/android/gallery3d/filtershow/editors/
DEditorColorBorderTabletUI.java93 LinearLayout lp = (LinearLayout) inflater.inflate( in EditorColorBorderTabletUI() local
98 LinearLayout buttonContainer = (LinearLayout) lp.findViewById(R.id.listStyles); in EditorColorBorderTabletUI()
100 mCBCornerSizeSeekBar = (SeekBar) lp.findViewById(R.id.colorBorderCornerSizeSeekBar); in EditorColorBorderTabletUI()
101 mCBCornerSizeValue = (TextView) lp.findViewById(R.id.colorBorderCornerValue); in EditorColorBorderTabletUI()
102 mCBSizeSeekBar = (SeekBar) lp.findViewById(R.id.colorBorderSizeSeekBar); in EditorColorBorderTabletUI()
104 mCBSizeValue = (TextView) lp.findViewById(R.id.colorBorderSizeValue); in EditorColorBorderTabletUI()
105 setupCBSizeSeekBar(lp); in EditorColorBorderTabletUI()
106 setupCBCornerSizeSeekBar(lp); in EditorColorBorderTabletUI()
107 setupColor(lp, res); in EditorColorBorderTabletUI()
110 private void setupCBSizeSeekBar(LinearLayout lp) { in setupCBSizeSeekBar() argument
[all …]
DEditorDrawTabletUI.java89 public EditorDrawTabletUI(EditorDraw editorDraw, Context context, LinearLayout lp) { in EditorDrawTabletUI() argument
95 LinearLayout buttonContainer = (LinearLayout) lp.findViewById(R.id.listStyles); in EditorDrawTabletUI()
97 mdrawSizeSeekBar = (SeekBar) lp.findViewById(R.id.drawSizeSeekBar); in EditorDrawTabletUI()
98 mDrawSizeValue = (TextView) lp.findViewById(R.id.drawSizeValue); in EditorDrawTabletUI()
100 Button clearButton = (Button) lp.findViewById(R.id.clearButton); in EditorDrawTabletUI()
157 final LinearLayout ctls = (LinearLayout) lp.findViewById(R.id.controls); in EditorDrawTabletUI()
158 final LinearLayout pick = (LinearLayout) lp.findViewById(R.id.colorPicker); in EditorDrawTabletUI()
159 Button b = (Button) lp.findViewById(R.id.draw_color_popupbutton); in EditorDrawTabletUI()
175 mColorButton[i] = (Button) lp.findViewById(ids[i]); in EditorDrawTabletUI()
210 mHueView = (ColorHueView) lp.findViewById(R.id.ColorHueView); in EditorDrawTabletUI()
[all …]
/packages/services/Car/tests/CarDeveloperOptions/src/com/android/car/developeroptions/wfd/
DWifiDisplaySettings.java405 ListPreference lp = new ListPreference(getPrefContext()); in buildCertificationMenu() local
406 lp.setOnPreferenceChangeListener(new OnPreferenceChangeListener() { in buildCertificationMenu()
427 lp.setKey("wps"); in buildCertificationMenu()
428 lp.setTitle(R.string.wifi_display_wps_config); in buildCertificationMenu()
429 lp.setEntries(wpsEntries); in buildCertificationMenu()
430 lp.setEntryValues(wpsValues); in buildCertificationMenu()
431 lp.setValue("" + mWpsConfig); in buildCertificationMenu()
432 lp.setSummary("%1$s"); in buildCertificationMenu()
433 mCertCategory.addPreference(lp); in buildCertificationMenu()
436 lp = new ListPreference(getPrefContext()); in buildCertificationMenu()
[all …]
/packages/apps/Launcher3/src/com/android/launcher3/dragndrop/
DDragLayer.java255 CellLayout.LayoutParams lp = (CellLayout.LayoutParams) child.getLayoutParams(); in animateViewIntoPosition() local
263 coord[0] = lp.x + (child.getMeasuredWidth() * (1 - childScale) / 2); in animateViewIntoPosition()
264 coord[1] = lp.y + (child.getMeasuredHeight() * (1 - childScale) / 2); in animateViewIntoPosition()
607 final FrameLayout.LayoutParams lp = (FrameLayout.LayoutParams) child.getLayoutParams(); in onLayout() local
609 if (lp instanceof LayoutParams) { in onLayout()
610 final LayoutParams dlp = (LayoutParams) lp; in onLayout()
623 int gravity = lp.gravity; in onLayout()
638 lp.topMargin - lp.bottomMargin; in onLayout()
641 childTop = width / 2 + lp.rightMargin - height / 2; in onLayout()
645 childTop = parentHeight - lp.leftMargin - width / 2 - height / 2; in onLayout()
[all …]
/packages/apps/Settings/src/com/android/settings/wfd/
DWifiDisplaySettings.java406 ListPreference lp = new ListPreference(getPrefContext()); in buildCertificationMenu() local
407 lp.setOnPreferenceChangeListener(new OnPreferenceChangeListener() { in buildCertificationMenu()
428 lp.setKey("wps"); in buildCertificationMenu()
429 lp.setTitle(R.string.wifi_display_wps_config); in buildCertificationMenu()
430 lp.setEntries(wpsEntries); in buildCertificationMenu()
431 lp.setEntryValues(wpsValues); in buildCertificationMenu()
432 lp.setValue("" + mWpsConfig); in buildCertificationMenu()
433 lp.setSummary("%1$s"); in buildCertificationMenu()
434 mCertCategory.addPreference(lp); in buildCertificationMenu()
437 lp = new ListPreference(getPrefContext()); in buildCertificationMenu()
[all …]
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/latin/utils/
DViewLayoutUtils.java49 final ViewGroup.LayoutParams lp = view.getLayoutParams(); in placeViewAt() local
50 if (lp instanceof MarginLayoutParams) { in placeViewAt()
51 final MarginLayoutParams marginLayoutParams = (MarginLayoutParams)lp; in placeViewAt()
75 final ViewGroup.LayoutParams lp = view.getLayoutParams(); in updateLayoutGravityOf() local
76 if (lp instanceof LinearLayout.LayoutParams) { in updateLayoutGravityOf()
77 final LinearLayout.LayoutParams params = (LinearLayout.LayoutParams)lp; in updateLayoutGravityOf()
82 } else if (lp instanceof FrameLayout.LayoutParams) { in updateLayoutGravityOf()
83 final FrameLayout.LayoutParams params = (FrameLayout.LayoutParams)lp; in updateLayoutGravityOf()
90 + lp.getClass().getName()); in updateLayoutGravityOf()
/packages/apps/Settings/tests/robotests/src/com/android/settings/network/
DPrivateDnsPreferenceControllerTest.java144 private void updateLinkProperties(LinkProperties lp) { in updateLinkProperties() argument
162 nc.onLinkPropertiesChanged(mNetwork, lp); in updateLinkProperties()
212 LinkProperties lp = mock(LinkProperties.class); in getSummary_PrivateDnsModeOpportunistic() local
213 when(lp.getValidatedPrivateDnsServers()).thenReturn(NON_EMPTY_ADDRESS_LIST); in getSummary_PrivateDnsModeOpportunistic()
214 updateLinkProperties(lp); in getSummary_PrivateDnsModeOpportunistic()
219 lp = mock(LinkProperties.class); in getSummary_PrivateDnsModeOpportunistic()
220 when(lp.getValidatedPrivateDnsServers()).thenReturn(Collections.emptyList()); in getSummary_PrivateDnsModeOpportunistic()
221 updateLinkProperties(lp); in getSummary_PrivateDnsModeOpportunistic()
236 LinkProperties lp = mock(LinkProperties.class); in getSummary_PrivateDnsModeProviderHostname() local
237 when(lp.getValidatedPrivateDnsServers()).thenReturn(NON_EMPTY_ADDRESS_LIST); in getSummary_PrivateDnsModeProviderHostname()
[all …]
/packages/apps/Car/Hvac/src/com/android/car/hvac/
DHvacUiService.java227 WindowManager.LayoutParams lp = (WindowManager.LayoutParams) v.getLayoutParams(); in setYPosition() local
228 lp.y = y; in setYPosition()
229 mWindowManager.updateViewLayout(v, lp); in setYPosition()
316 WindowManager.LayoutParams lp = new WindowManager.LayoutParams( in createTemperatureBarLayoutParams() local
323 lp.x = mTemperatureSideMargin; in createTemperatureBarLayoutParams()
324 lp.y = mInitialYOffset; in createTemperatureBarLayoutParams()
325 lp.width = mTemperatureOverlayWidth; in createTemperatureBarLayoutParams()
326 disableAnimations(lp); in createTemperatureBarLayoutParams()
327 lp.setTitle(windowTitle); in createTemperatureBarLayoutParams()
328 lp.height = windowHeight; in createTemperatureBarLayoutParams()
[all …]
/packages/apps/TV/src/com/android/tv/ui/
DTvViewUiManager.java392 FrameLayout.LayoutParams lp; in setTvViewPosition()
399 if (lp == null) { in setTvViewPosition()
400 lp = new FrameLayout.LayoutParams(0, 0); in setTvViewPosition()
401 lp.gravity = startValue.gravity; in setTvViewPosition()
403 interpolateMargins(lp, startValue, endValue, fraction); in setTvViewPosition()
404 return lp; in setTvViewPosition()
609 FrameLayout.LayoutParams lp = new FrameLayout.LayoutParams(0, 0); in createMarginLayoutParams() local
610 lp.setMarginStart(startMargin); in createMarginLayoutParams()
611 lp.setMarginEnd(endMargin); in createMarginLayoutParams()
612 lp.topMargin = topMargin; in createMarginLayoutParams()
[all …]
/packages/apps/Gallery2/src/com/android/photos/views/
DGalleryThumbnailView.java621 ViewGroup.LayoutParams lp = view.getLayoutParams(); in obtainView() local
624 if (lp == null) { in obtainView()
625 lp = generateDefaultLayoutParams(); in obtainView()
626 } else if (!checkLayoutParams(lp)) { in obtainView()
627 lp = generateLayoutParams(lp); in obtainView()
629 view.setLayoutParams(lp); in obtainView()
632 final LayoutParams sglp = (LayoutParams) lp; in obtainView()
683 protected LayoutParams generateLayoutParams(ViewGroup.LayoutParams lp) { in generateLayoutParams() argument
684 return new LayoutParams(lp); in generateLayoutParams()
688 protected boolean checkLayoutParams(ViewGroup.LayoutParams lp) { in checkLayoutParams() argument
[all …]
/packages/apps/Launcher3/src/com/android/launcher3/pageindicators/
DWorkspacePageIndicator.java261 FrameLayout.LayoutParams lp = (FrameLayout.LayoutParams) getLayoutParams(); in setInsets() local
265 lp.leftMargin = padding.left + grid.workspaceCellPaddingXPx; in setInsets()
266 lp.rightMargin = padding.right + grid.workspaceCellPaddingXPx; in setInsets()
267 lp.bottomMargin = padding.bottom; in setInsets()
269 lp.leftMargin = lp.rightMargin = 0; in setInsets()
270 lp.gravity = Gravity.CENTER_HORIZONTAL | Gravity.BOTTOM; in setInsets()
271 lp.bottomMargin = grid.hotseatBarSizePx + insets.bottom; in setInsets()
273 setLayoutParams(lp); in setInsets()

12345