Skip to content
This repository was archived by the owner on Aug 31, 2021. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions docs/notes/bugfix-23089.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# Fix Browser Widget being resized to fit group instead of being clipped
14 changes: 5 additions & 9 deletions engine/src/java/com/runrev/android/Engine.java
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ public interface LifecycleListener
private SoundModule m_sound_module;
private NotificationModule m_notification_module;
private NFCModule m_nfc_module;
private RelativeLayout m_view_layout;
private AbsoluteLayout m_view_layout;

private PowerManager.WakeLock m_wake_lock;

Expand Down Expand Up @@ -1095,7 +1095,7 @@ Object getNativeLayerContainer()
FrameLayout t_main_view;
t_main_view = ((LiveCodeActivity)getContext()).s_main_layout;

m_view_layout = new RelativeLayout(getContext());
m_view_layout = new AbsoluteLayout(getContext());
t_main_view.addView(m_view_layout, new FrameLayout.LayoutParams(FrameLayout.LayoutParams.MATCH_PARENT, FrameLayout.LayoutParams.MATCH_PARENT));
t_main_view.bringChildToFront(m_view_layout);
}
Expand All @@ -1105,7 +1105,7 @@ Object getNativeLayerContainer()

Object createNativeLayerContainer()
{
return new RelativeLayout(getContext());
return new AbsoluteLayout(getContext());
}

// insert the view into the container, layered below p_view_above if not null.
Expand All @@ -1120,7 +1120,7 @@ void addNativeViewToContainer(Object p_view, Object p_view_above, Object p_conta
else
t_index = t_container.getChildCount();

t_container.addView((View)p_view, t_index, new RelativeLayout.LayoutParams(0, 0));
t_container.addView((View)p_view, t_index, new AbsoluteLayout.LayoutParams(0, 0, 0, 0));
}

void removeNativeViewFromContainer(Object p_view)
Expand All @@ -1137,11 +1137,7 @@ void removeNativeViewFromContainer(Object p_view)

void setNativeViewRect(Object p_view, int left, int top, int width, int height)
{
RelativeLayout.LayoutParams t_layout = new RelativeLayout.LayoutParams(width, height);
t_layout.leftMargin = left;
t_layout.topMargin = top;
t_layout.addRule(RelativeLayout.ALIGN_PARENT_LEFT);
t_layout.addRule(RelativeLayout.ALIGN_PARENT_TOP);
AbsoluteLayout.LayoutParams t_layout = new AbsoluteLayout.LayoutParams(width, height, left, top);

View t_view = (View)p_view;

Expand Down