mirror of
https://github.com/AngelAuraMC/Amethyst-Android.git
synced 2025-09-14 23:28:52 -04:00
Reduced memory consumption caused by subButton
This commit is contained in:
parent
29b7aeb999
commit
7ec533a997
@ -146,7 +146,10 @@ public class ControlLayout extends FrameLayout
|
|||||||
view.setAlpha(view.getProperties().opacity);
|
view.setAlpha(view.getProperties().opacity);
|
||||||
view.setFocusable(false);
|
view.setFocusable(false);
|
||||||
view.setFocusableInTouchMode(false);
|
view.setFocusableInTouchMode(false);
|
||||||
|
}else{
|
||||||
|
view.setVisible(drawer.areButtonsVisible);
|
||||||
}
|
}
|
||||||
|
|
||||||
drawer.addButton(view);
|
drawer.addButton(view);
|
||||||
addView(view);
|
addView(view);
|
||||||
|
|
||||||
|
@ -20,9 +20,7 @@ public class ControlSubButton extends ControlButton {
|
|||||||
super(layout, properties);
|
super(layout, properties);
|
||||||
this.parentDrawer = parentDrawer;
|
this.parentDrawer = parentDrawer;
|
||||||
|
|
||||||
//Delayed to let the button inflate first
|
|
||||||
if(!layout.getModifiable())
|
|
||||||
new Handler(Looper.getMainLooper()).postDelayed(() -> setVisibility(parentDrawer.areButtonsVisible ? VISIBLE : GONE), 0);
|
|
||||||
|
|
||||||
filterProperties();
|
filterProperties();
|
||||||
}
|
}
|
||||||
|
@ -43,7 +43,7 @@ public class ActionPopupWindow extends PinnedPopupWindow implements OnClickListe
|
|||||||
private TextView mDeleteTextView;
|
private TextView mDeleteTextView;
|
||||||
private TextView mCloneTextView;
|
private TextView mCloneTextView;
|
||||||
|
|
||||||
private ControlButton editedButton;
|
private final ControlButton editedButton;
|
||||||
|
|
||||||
public ActionPopupWindow(HandleView handleView, ControlButton button){
|
public ActionPopupWindow(HandleView handleView, ControlButton button){
|
||||||
super(handleView);
|
super(handleView);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user